diff options
author | Joe Perches <joe@perches.com> | 2010-07-12 16:50:13 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2010-08-10 17:35:39 -0400 |
commit | e53e841d451a2d0da094b8fea4a7f22b296234f6 (patch) | |
tree | 0245ff3ec452966a3addc610c67f31b17dd7936c /drivers/usb/usb-skeleton.c | |
parent | 925ce689bb31960c839804c19ef38d676f1939b9 (diff) |
USB: usb-skeleton: Remove unnecessary casts of private_data
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/usb-skeleton.c')
-rw-r--r-- | drivers/usb/usb-skeleton.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/usb/usb-skeleton.c b/drivers/usb/usb-skeleton.c index d110588b56f1..552679b8dbd1 100644 --- a/drivers/usb/usb-skeleton.c +++ b/drivers/usb/usb-skeleton.c | |||
@@ -142,7 +142,7 @@ static int skel_release(struct inode *inode, struct file *file) | |||
142 | { | 142 | { |
143 | struct usb_skel *dev; | 143 | struct usb_skel *dev; |
144 | 144 | ||
145 | dev = (struct usb_skel *)file->private_data; | 145 | dev = file->private_data; |
146 | if (dev == NULL) | 146 | if (dev == NULL) |
147 | return -ENODEV; | 147 | return -ENODEV; |
148 | 148 | ||
@@ -162,7 +162,7 @@ static int skel_flush(struct file *file, fl_owner_t id) | |||
162 | struct usb_skel *dev; | 162 | struct usb_skel *dev; |
163 | int res; | 163 | int res; |
164 | 164 | ||
165 | dev = (struct usb_skel *)file->private_data; | 165 | dev = file->private_data; |
166 | if (dev == NULL) | 166 | if (dev == NULL) |
167 | return -ENODEV; | 167 | return -ENODEV; |
168 | 168 | ||
@@ -246,7 +246,7 @@ static ssize_t skel_read(struct file *file, char *buffer, size_t count, | |||
246 | int rv; | 246 | int rv; |
247 | bool ongoing_io; | 247 | bool ongoing_io; |
248 | 248 | ||
249 | dev = (struct usb_skel *)file->private_data; | 249 | dev = file->private_data; |
250 | 250 | ||
251 | /* if we cannot read at all, return EOF */ | 251 | /* if we cannot read at all, return EOF */ |
252 | if (!dev->bulk_in_urb || !count) | 252 | if (!dev->bulk_in_urb || !count) |
@@ -401,7 +401,7 @@ static ssize_t skel_write(struct file *file, const char *user_buffer, | |||
401 | char *buf = NULL; | 401 | char *buf = NULL; |
402 | size_t writesize = min(count, (size_t)MAX_TRANSFER); | 402 | size_t writesize = min(count, (size_t)MAX_TRANSFER); |
403 | 403 | ||
404 | dev = (struct usb_skel *)file->private_data; | 404 | dev = file->private_data; |
405 | 405 | ||
406 | /* verify that we actually have some data to write */ | 406 | /* verify that we actually have some data to write */ |
407 | if (count == 0) | 407 | if (count == 0) |