Removes pointer to pointer cast on a function argument. Issue
detected and resolved using the following coccinelle script:
@@
expression e;
type t;
identifier f;
@@
f(...,
-(t *)
e
,...)
Signed-off-by: Aya Mahfouz <mahfouz.saif.elyazal@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
set_current_state(TASK_INTERRUPTIBLE);
while (count < n) {
if (rptr != wptr) {
- if (copy_to_user(buf+count, (char *) &rbuf[rptr],
+ if (copy_to_user(buf+count, &rbuf[rptr],
sizeof(int))) {
result = -EFAULT;
break;