diff options
author | Andrey Borzenkov <arvidjaar@mail.ru> | 2009-01-25 15:08:43 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-02-09 15:03:32 -0500 |
commit | d14c7c1d6aef1175625ea72938b07cee072723dc (patch) | |
tree | 95022428783c802a21fcbe27d216e4c4d869b62f /drivers/net/wireless/orinoco/airport.c | |
parent | aa6320d336971171df1d13c1c284facf10804881 (diff) |
orinoco: checkpatch cleanup
Fix errors and obvious warnings reported by checkpatch in all files
except orinoco.c. Orinoco.c is part of different patch series of Dave.
Signed-off-by: Andrey Borzenkov <arvidjaar@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/orinoco/airport.c')
-rw-r--r-- | drivers/net/wireless/orinoco/airport.c | 35 |
1 files changed, 20 insertions, 15 deletions
diff --git a/drivers/net/wireless/orinoco/airport.c b/drivers/net/wireless/orinoco/airport.c index 28f1cae48439..5582dca9f7f5 100644 --- a/drivers/net/wireless/orinoco/airport.c +++ b/drivers/net/wireless/orinoco/airport.c | |||
@@ -4,9 +4,9 @@ | |||
4 | * card. | 4 | * card. |
5 | * | 5 | * |
6 | * Copyright notice & release notes in file orinoco.c | 6 | * Copyright notice & release notes in file orinoco.c |
7 | * | 7 | * |
8 | * Note specific to airport stub: | 8 | * Note specific to airport stub: |
9 | * | 9 | * |
10 | * 0.05 : first version of the new split driver | 10 | * 0.05 : first version of the new split driver |
11 | * 0.06 : fix possible hang on powerup, add sleep support | 11 | * 0.06 : fix possible hang on powerup, add sleep support |
12 | */ | 12 | */ |
@@ -60,7 +60,8 @@ airport_suspend(struct macio_dev *mdev, pm_message_t state) | |||
60 | orinoco_unlock(priv, &flags); | 60 | orinoco_unlock(priv, &flags); |
61 | 61 | ||
62 | disable_irq(dev->irq); | 62 | disable_irq(dev->irq); |
63 | pmac_call_feature(PMAC_FTR_AIRPORT_ENABLE, macio_get_of_node(mdev), 0, 0); | 63 | pmac_call_feature(PMAC_FTR_AIRPORT_ENABLE, |
64 | macio_get_of_node(mdev), 0, 0); | ||
64 | 65 | ||
65 | return 0; | 66 | return 0; |
66 | } | 67 | } |
@@ -75,7 +76,8 @@ airport_resume(struct macio_dev *mdev) | |||
75 | 76 | ||
76 | printk(KERN_DEBUG "%s: Airport waking up\n", dev->name); | 77 | printk(KERN_DEBUG "%s: Airport waking up\n", dev->name); |
77 | 78 | ||
78 | pmac_call_feature(PMAC_FTR_AIRPORT_ENABLE, macio_get_of_node(mdev), 0, 1); | 79 | pmac_call_feature(PMAC_FTR_AIRPORT_ENABLE, |
80 | macio_get_of_node(mdev), 0, 1); | ||
79 | msleep(200); | 81 | msleep(200); |
80 | 82 | ||
81 | enable_irq(dev->irq); | 83 | enable_irq(dev->irq); |
@@ -93,7 +95,7 @@ airport_resume(struct macio_dev *mdev) | |||
93 | 95 | ||
94 | priv->hw_unavailable--; | 96 | priv->hw_unavailable--; |
95 | 97 | ||
96 | if (priv->open && (! priv->hw_unavailable)) { | 98 | if (priv->open && (!priv->hw_unavailable)) { |
97 | err = __orinoco_up(dev); | 99 | err = __orinoco_up(dev); |
98 | if (err) | 100 | if (err) |
99 | printk(KERN_ERR "%s: Error %d restarting card on PBOOK_WAKE\n", | 101 | printk(KERN_ERR "%s: Error %d restarting card on PBOOK_WAKE\n", |
@@ -127,7 +129,8 @@ airport_detach(struct macio_dev *mdev) | |||
127 | 129 | ||
128 | macio_release_resource(mdev, 0); | 130 | macio_release_resource(mdev, 0); |
129 | 131 | ||
130 | pmac_call_feature(PMAC_FTR_AIRPORT_ENABLE, macio_get_of_node(mdev), 0, 0); | 132 | pmac_call_feature(PMAC_FTR_AIRPORT_ENABLE, |
133 | macio_get_of_node(mdev), 0, 0); | ||
131 | ssleep(1); | 134 | ssleep(1); |
132 | 135 | ||
133 | macio_set_drvdata(mdev, NULL); | 136 | macio_set_drvdata(mdev, NULL); |
@@ -153,9 +156,11 @@ static int airport_hard_reset(struct orinoco_private *priv) | |||
153 | * off. */ | 156 | * off. */ |
154 | disable_irq(dev->irq); | 157 | disable_irq(dev->irq); |
155 | 158 | ||
156 | pmac_call_feature(PMAC_FTR_AIRPORT_ENABLE, macio_get_of_node(card->mdev), 0, 0); | 159 | pmac_call_feature(PMAC_FTR_AIRPORT_ENABLE, |
160 | macio_get_of_node(card->mdev), 0, 0); | ||
157 | ssleep(1); | 161 | ssleep(1); |
158 | pmac_call_feature(PMAC_FTR_AIRPORT_ENABLE, macio_get_of_node(card->mdev), 0, 1); | 162 | pmac_call_feature(PMAC_FTR_AIRPORT_ENABLE, |
163 | macio_get_of_node(card->mdev), 0, 1); | ||
159 | ssleep(1); | 164 | ssleep(1); |
160 | 165 | ||
161 | enable_irq(dev->irq); | 166 | enable_irq(dev->irq); |
@@ -182,7 +187,7 @@ airport_attach(struct macio_dev *mdev, const struct of_device_id *match) | |||
182 | /* Allocate space for private device-specific data */ | 187 | /* Allocate space for private device-specific data */ |
183 | dev = alloc_orinocodev(sizeof(*card), &mdev->ofdev.dev, | 188 | dev = alloc_orinocodev(sizeof(*card), &mdev->ofdev.dev, |
184 | airport_hard_reset, NULL); | 189 | airport_hard_reset, NULL); |
185 | if (! dev) { | 190 | if (!dev) { |
186 | printk(KERN_ERR PFX "Cannot allocate network device\n"); | 191 | printk(KERN_ERR PFX "Cannot allocate network device\n"); |
187 | return -ENODEV; | 192 | return -ENODEV; |
188 | } | 193 | } |
@@ -214,9 +219,10 @@ airport_attach(struct macio_dev *mdev, const struct of_device_id *match) | |||
214 | } | 219 | } |
215 | 220 | ||
216 | hermes_struct_init(hw, card->vaddr, HERMES_16BIT_REGSPACING); | 221 | hermes_struct_init(hw, card->vaddr, HERMES_16BIT_REGSPACING); |
217 | 222 | ||
218 | /* Power up card */ | 223 | /* Power up card */ |
219 | pmac_call_feature(PMAC_FTR_AIRPORT_ENABLE, macio_get_of_node(mdev), 0, 1); | 224 | pmac_call_feature(PMAC_FTR_AIRPORT_ENABLE, |
225 | macio_get_of_node(mdev), 0, 1); | ||
220 | ssleep(1); | 226 | ssleep(1); |
221 | 227 | ||
222 | /* Reset it before we get the interrupt */ | 228 | /* Reset it before we get the interrupt */ |
@@ -248,7 +254,7 @@ MODULE_AUTHOR("Benjamin Herrenschmidt <benh@kernel.crashing.org>"); | |||
248 | MODULE_DESCRIPTION("Driver for the Apple Airport wireless card."); | 254 | MODULE_DESCRIPTION("Driver for the Apple Airport wireless card."); |
249 | MODULE_LICENSE("Dual MPL/GPL"); | 255 | MODULE_LICENSE("Dual MPL/GPL"); |
250 | 256 | ||
251 | static struct of_device_id airport_match[] = | 257 | static struct of_device_id airport_match[] = |
252 | { | 258 | { |
253 | { | 259 | { |
254 | .name = "radio", | 260 | .name = "radio", |
@@ -256,10 +262,9 @@ static struct of_device_id airport_match[] = | |||
256 | {}, | 262 | {}, |
257 | }; | 263 | }; |
258 | 264 | ||
259 | MODULE_DEVICE_TABLE (of, airport_match); | 265 | MODULE_DEVICE_TABLE(of, airport_match); |
260 | 266 | ||
261 | static struct macio_driver airport_driver = | 267 | static struct macio_driver airport_driver = { |
262 | { | ||
263 | .name = DRIVER_NAME, | 268 | .name = DRIVER_NAME, |
264 | .match_table = airport_match, | 269 | .match_table = airport_match, |
265 | .probe = airport_attach, | 270 | .probe = airport_attach, |