diff options
author | Stefan Richter <stefanr@s5r6.in-berlin.de> | 2008-12-14 15:45:45 -0500 |
---|---|---|
committer | Stefan Richter <stefanr@s5r6.in-berlin.de> | 2009-03-24 15:56:39 -0400 |
commit | 2dbd7d7e2327b0c2cc4e2de903e1cfa19980a504 (patch) | |
tree | c0efb5bbd26bc2e18a61bf44d0c53db9494a096c /drivers/firewire/fw-cdev.c | |
parent | c490a6dec6cc1b7f0eab56b9fbd565129b3dea2e (diff) |
firewire: standardize a variable name
"ret" is the new "retval".
Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
Diffstat (limited to 'drivers/firewire/fw-cdev.c')
-rw-r--r-- | drivers/firewire/fw-cdev.c | 44 |
1 files changed, 22 insertions, 22 deletions
diff --git a/drivers/firewire/fw-cdev.c b/drivers/firewire/fw-cdev.c index 44af45205dcd..07c32a4bada2 100644 --- a/drivers/firewire/fw-cdev.c +++ b/drivers/firewire/fw-cdev.c | |||
@@ -169,13 +169,13 @@ dequeue_event(struct client *client, char __user *buffer, size_t count) | |||
169 | unsigned long flags; | 169 | unsigned long flags; |
170 | struct event *event; | 170 | struct event *event; |
171 | size_t size, total; | 171 | size_t size, total; |
172 | int i, retval; | 172 | int i, ret; |
173 | 173 | ||
174 | retval = wait_event_interruptible(client->wait, | 174 | ret = wait_event_interruptible(client->wait, |
175 | !list_empty(&client->event_list) || | 175 | !list_empty(&client->event_list) || |
176 | fw_device_is_shutdown(client->device)); | 176 | fw_device_is_shutdown(client->device)); |
177 | if (retval < 0) | 177 | if (ret < 0) |
178 | return retval; | 178 | return ret; |
179 | 179 | ||
180 | if (list_empty(&client->event_list) && | 180 | if (list_empty(&client->event_list) && |
181 | fw_device_is_shutdown(client->device)) | 181 | fw_device_is_shutdown(client->device)) |
@@ -190,17 +190,17 @@ dequeue_event(struct client *client, char __user *buffer, size_t count) | |||
190 | for (i = 0; i < ARRAY_SIZE(event->v) && total < count; i++) { | 190 | for (i = 0; i < ARRAY_SIZE(event->v) && total < count; i++) { |
191 | size = min(event->v[i].size, count - total); | 191 | size = min(event->v[i].size, count - total); |
192 | if (copy_to_user(buffer + total, event->v[i].data, size)) { | 192 | if (copy_to_user(buffer + total, event->v[i].data, size)) { |
193 | retval = -EFAULT; | 193 | ret = -EFAULT; |
194 | goto out; | 194 | goto out; |
195 | } | 195 | } |
196 | total += size; | 196 | total += size; |
197 | } | 197 | } |
198 | retval = total; | 198 | ret = total; |
199 | 199 | ||
200 | out: | 200 | out: |
201 | kfree(event); | 201 | kfree(event); |
202 | 202 | ||
203 | return retval; | 203 | return ret; |
204 | } | 204 | } |
205 | 205 | ||
206 | static ssize_t | 206 | static ssize_t |
@@ -958,7 +958,7 @@ static int | |||
958 | dispatch_ioctl(struct client *client, unsigned int cmd, void __user *arg) | 958 | dispatch_ioctl(struct client *client, unsigned int cmd, void __user *arg) |
959 | { | 959 | { |
960 | char buffer[256]; | 960 | char buffer[256]; |
961 | int retval; | 961 | int ret; |
962 | 962 | ||
963 | if (_IOC_TYPE(cmd) != '#' || | 963 | if (_IOC_TYPE(cmd) != '#' || |
964 | _IOC_NR(cmd) >= ARRAY_SIZE(ioctl_handlers)) | 964 | _IOC_NR(cmd) >= ARRAY_SIZE(ioctl_handlers)) |
@@ -970,9 +970,9 @@ dispatch_ioctl(struct client *client, unsigned int cmd, void __user *arg) | |||
970 | return -EFAULT; | 970 | return -EFAULT; |
971 | } | 971 | } |
972 | 972 | ||
973 | retval = ioctl_handlers[_IOC_NR(cmd)](client, buffer); | 973 | ret = ioctl_handlers[_IOC_NR(cmd)](client, buffer); |
974 | if (retval < 0) | 974 | if (ret < 0) |
975 | return retval; | 975 | return ret; |
976 | 976 | ||
977 | if (_IOC_DIR(cmd) & _IOC_READ) { | 977 | if (_IOC_DIR(cmd) & _IOC_READ) { |
978 | if (_IOC_SIZE(cmd) > sizeof(buffer) || | 978 | if (_IOC_SIZE(cmd) > sizeof(buffer) || |
@@ -980,7 +980,7 @@ dispatch_ioctl(struct client *client, unsigned int cmd, void __user *arg) | |||
980 | return -EFAULT; | 980 | return -EFAULT; |
981 | } | 981 | } |
982 | 982 | ||
983 | return retval; | 983 | return ret; |
984 | } | 984 | } |
985 | 985 | ||
986 | static long | 986 | static long |
@@ -1014,7 +1014,7 @@ static int fw_device_op_mmap(struct file *file, struct vm_area_struct *vma) | |||
1014 | struct client *client = file->private_data; | 1014 | struct client *client = file->private_data; |
1015 | enum dma_data_direction direction; | 1015 | enum dma_data_direction direction; |
1016 | unsigned long size; | 1016 | unsigned long size; |
1017 | int page_count, retval; | 1017 | int page_count, ret; |
1018 | 1018 | ||
1019 | if (fw_device_is_shutdown(client->device)) | 1019 | if (fw_device_is_shutdown(client->device)) |
1020 | return -ENODEV; | 1020 | return -ENODEV; |
@@ -1040,16 +1040,16 @@ static int fw_device_op_mmap(struct file *file, struct vm_area_struct *vma) | |||
1040 | else | 1040 | else |
1041 | direction = DMA_FROM_DEVICE; | 1041 | direction = DMA_FROM_DEVICE; |
1042 | 1042 | ||
1043 | retval = fw_iso_buffer_init(&client->buffer, client->device->card, | 1043 | ret = fw_iso_buffer_init(&client->buffer, client->device->card, |
1044 | page_count, direction); | 1044 | page_count, direction); |
1045 | if (retval < 0) | 1045 | if (ret < 0) |
1046 | return retval; | 1046 | return ret; |
1047 | 1047 | ||
1048 | retval = fw_iso_buffer_map(&client->buffer, vma); | 1048 | ret = fw_iso_buffer_map(&client->buffer, vma); |
1049 | if (retval < 0) | 1049 | if (ret < 0) |
1050 | fw_iso_buffer_destroy(&client->buffer, client->device->card); | 1050 | fw_iso_buffer_destroy(&client->buffer, client->device->card); |
1051 | 1051 | ||
1052 | return retval; | 1052 | return ret; |
1053 | } | 1053 | } |
1054 | 1054 | ||
1055 | static int shutdown_resource(int id, void *p, void *data) | 1055 | static int shutdown_resource(int id, void *p, void *data) |