diff options
author | Marek Belisko <marek.belisko@open-nandra.com> | 2010-12-09 10:13:48 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2010-12-09 19:35:13 -0500 |
commit | 04c6620117488c0ccc612da5f2bcbcde025e9301 (patch) | |
tree | 17d02a46cf7dc4519047b39a37d3861f1e633eee | |
parent | 5fd866fb6401cf6a912e75e1b9c4b906bf42434e (diff) |
staging: ft1000: Fix coding style.
Fix coding style in ft1000CleanupProc and ft1000InitProc
functions.
Signed-off-by: Marek Belisko <marek.belisko@open-nandra.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-rw-r--r-- | drivers/staging/ft1000/ft1000-usb/ft1000_proc.c | 25 |
1 files changed, 12 insertions, 13 deletions
diff --git a/drivers/staging/ft1000/ft1000-usb/ft1000_proc.c b/drivers/staging/ft1000/ft1000-usb/ft1000_proc.c index dbd4a1ce9f55..f197523d0604 100644 --- a/drivers/staging/ft1000/ft1000-usb/ft1000_proc.c +++ b/drivers/staging/ft1000/ft1000-usb/ft1000_proc.c | |||
@@ -196,12 +196,12 @@ static struct notifier_block ft1000_netdev_notifier = { | |||
196 | int ft1000InitProc(struct net_device *dev) | 196 | int ft1000InitProc(struct net_device *dev) |
197 | { | 197 | { |
198 | struct ft1000_info *info; | 198 | struct ft1000_info *info; |
199 | struct proc_dir_entry *ft1000_proc_file; | 199 | struct proc_dir_entry *ft1000_proc_file; |
200 | int ret = 0; | 200 | int ret = 0; |
201 | 201 | ||
202 | info = netdev_priv(dev); | 202 | info = netdev_priv(dev); |
203 | 203 | ||
204 | info->ft1000_proc_dir = proc_mkdir (FT1000_PROC_DIR, FTNET_PROC); | 204 | info->ft1000_proc_dir = proc_mkdir(FT1000_PROC_DIR, FTNET_PROC); |
205 | if (info->ft1000_proc_dir == NULL) { | 205 | if (info->ft1000_proc_dir == NULL) { |
206 | printk(KERN_WARNING "Unable to create %s dir.\n", | 206 | printk(KERN_WARNING "Unable to create %s dir.\n", |
207 | FT1000_PROC_DIR); | 207 | FT1000_PROC_DIR); |
@@ -209,16 +209,18 @@ int ft1000InitProc(struct net_device *dev) | |||
209 | goto fail; | 209 | goto fail; |
210 | } | 210 | } |
211 | 211 | ||
212 | ft1000_proc_file = | 212 | ft1000_proc_file = |
213 | create_proc_read_entry (dev->name, 0644, info->ft1000_proc_dir, | 213 | create_proc_read_entry(dev->name, 0644, |
214 | ft1000ReadProc, dev); | 214 | info->ft1000_proc_dir, ft1000ReadProc, dev); |
215 | |||
215 | if (ft1000_proc_file == NULL) { | 216 | if (ft1000_proc_file == NULL) { |
216 | printk(KERN_WARNING "Unable to create /proc entry.\n"); | 217 | printk(KERN_WARNING "Unable to create /proc entry.\n"); |
217 | ret = -EINVAL; | 218 | ret = -EINVAL; |
218 | goto fail_entry; | 219 | goto fail_entry; |
219 | } | 220 | } |
220 | 221 | ||
221 | snprintf (info->netdevname, IFNAMSIZ, "%s", dev->name); | 222 | snprintf(info->netdevname, IFNAMSIZ, "%s", dev->name); |
223 | |||
222 | ret = register_netdevice_notifier(&ft1000_netdev_notifier); | 224 | ret = register_netdevice_notifier(&ft1000_netdev_notifier); |
223 | if (ret) | 225 | if (ret) |
224 | goto fail_notif; | 226 | goto fail_notif; |
@@ -233,12 +235,9 @@ fail: | |||
233 | return ret; | 235 | return ret; |
234 | } | 236 | } |
235 | 237 | ||
236 | void | 238 | void ft1000CleanupProc(struct ft1000_info *info) |
237 | ft1000CleanupProc(struct ft1000_info *info) | ||
238 | { | 239 | { |
239 | remove_proc_entry (info->netdevname, info->ft1000_proc_dir); | 240 | remove_proc_entry(info->netdevname, info->ft1000_proc_dir); |
240 | remove_proc_entry (FT1000_PROC_DIR, FTNET_PROC); | 241 | remove_proc_entry(FT1000_PROC_DIR, FTNET_PROC); |
241 | unregister_netdevice_notifier (&ft1000_netdev_notifier); | 242 | unregister_netdevice_notifier(&ft1000_netdev_notifier); |
242 | |||
243 | return; | ||
244 | } | 243 | } |