diff options
author | Shraddha Barke <shraddha.6596@gmail.com> | 2015-08-04 23:02:34 +0530 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2015-08-05 12:18:00 -0700 |
commit | b7856753856b4e6a20c1c91c6db03852e90de273 (patch) | |
tree | c3937b643b024b9352354b8ac562de3fea322e9e | |
parent | 45b30514a34fa7fcb7a84be799ca5fc53d33a4d7 (diff) | |
download | op-kernel-dev-b7856753856b4e6a20c1c91c6db03852e90de273.zip op-kernel-dev-b7856753856b4e6a20c1c91c6db03852e90de273.tar.gz |
Staging: lustre: osc: Drop unnecessary cast on void *
This patch does away with the cast on void * as it is unnecessary.
Semantic patch used is as follows:
@r@
expression x;
void* e;
type T;
identifier f;
@@
(
*((T *)e)
|
((T *)x)[...]
|
((T *)x)->f
|
- (T *)
e
)
Signed-off-by: Shraddha Barke <shraddha.6596@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r-- | drivers/staging/lustre/lustre/osc/osc_request.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/staging/lustre/lustre/osc/osc_request.c b/drivers/staging/lustre/lustre/osc/osc_request.c index 96c80e9..12113df 100644 --- a/drivers/staging/lustre/lustre/osc/osc_request.c +++ b/drivers/staging/lustre/lustre/osc/osc_request.c @@ -2665,7 +2665,7 @@ static int osc_iocontrol(unsigned int cmd, struct obd_export *exp, int len, buf = NULL; len = 0; - if (obd_ioctl_getdata(&buf, &len, (void *)uarg)) { + if (obd_ioctl_getdata(&buf, &len, uarg)) { err = -EINVAL; goto out; } @@ -2695,7 +2695,7 @@ static int osc_iocontrol(unsigned int cmd, struct obd_export *exp, int len, memcpy(data->ioc_inlbuf2, &obd->obd_uuid, sizeof(uuid)); - err = copy_to_user((void *)uarg, buf, len); + err = copy_to_user(uarg, buf, len); if (err) err = -EFAULT; obd_ioctl_freedata(buf, len); |