diff options
author | Holger Schurig <hs4233@mail.mn-solutions.de> | 2007-11-23 09:43:44 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-01-28 18:04:54 -0500 |
commit | 69f9032d9dfeb763b467fdbe8cf5938f5457083a (patch) | |
tree | 613598938e17e1a7514e0da3817f3cfebbe346a9 /drivers/net/wireless/libertas/cmdresp.c | |
parent | 96287ac4f7b387acbe17e24b5e1bcbf3bc0e75cd (diff) |
libertas: remove arbitrary typedefs
New typedefs are usually frowned upon. This patch changes
libertas_adapter -> struct libertas_adapter
libertas_priv -> struct libertas_priv
While passing, make everything checkpatch.pl-clean that gets touches.
Signed-off-by: Holger Schurig <hs4233@mail.mn-solutions.de>
Acked-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/libertas/cmdresp.c')
-rw-r--r-- | drivers/net/wireless/libertas/cmdresp.c | 80 |
1 files changed, 40 insertions, 40 deletions
diff --git a/drivers/net/wireless/libertas/cmdresp.c b/drivers/net/wireless/libertas/cmdresp.c index 1f74810a5e15..3596957f1d5a 100644 --- a/drivers/net/wireless/libertas/cmdresp.c +++ b/drivers/net/wireless/libertas/cmdresp.c | |||
@@ -20,12 +20,12 @@ | |||
20 | * reports disconnect to upper layer, clean tx/rx packets, | 20 | * reports disconnect to upper layer, clean tx/rx packets, |
21 | * reset link state etc. | 21 | * reset link state etc. |
22 | * | 22 | * |
23 | * @param priv A pointer to lbs_private structure | 23 | * @param priv A pointer to struct lbs_private structure |
24 | * @return n/a | 24 | * @return n/a |
25 | */ | 25 | */ |
26 | void lbs_mac_event_disconnected(lbs_private * priv) | 26 | void lbs_mac_event_disconnected(struct lbs_private *priv) |
27 | { | 27 | { |
28 | lbs_adapter *adapter = priv->adapter; | 28 | struct lbs_adapter *adapter = priv->adapter; |
29 | union iwreq_data wrqu; | 29 | union iwreq_data wrqu; |
30 | 30 | ||
31 | if (adapter->connect_status != LBS_CONNECTED) | 31 | if (adapter->connect_status != LBS_CONNECTED) |
@@ -85,11 +85,11 @@ void lbs_mac_event_disconnected(lbs_private * priv) | |||
85 | /** | 85 | /** |
86 | * @brief This function handles MIC failure event. | 86 | * @brief This function handles MIC failure event. |
87 | * | 87 | * |
88 | * @param priv A pointer to lbs_private structure | 88 | * @param priv A pointer to struct lbs_private structure |
89 | * @para event the event id | 89 | * @para event the event id |
90 | * @return n/a | 90 | * @return n/a |
91 | */ | 91 | */ |
92 | static void handle_mic_failureevent(lbs_private * priv, u32 event) | 92 | static void handle_mic_failureevent(struct lbs_private *priv, u32 event) |
93 | { | 93 | { |
94 | char buf[50]; | 94 | char buf[50]; |
95 | 95 | ||
@@ -108,11 +108,11 @@ static void handle_mic_failureevent(lbs_private * priv, u32 event) | |||
108 | lbs_deb_leave(LBS_DEB_CMD); | 108 | lbs_deb_leave(LBS_DEB_CMD); |
109 | } | 109 | } |
110 | 110 | ||
111 | static int lbs_ret_reg_access(lbs_private * priv, | 111 | static int lbs_ret_reg_access(struct lbs_private *priv, |
112 | u16 type, struct cmd_ds_command *resp) | 112 | u16 type, struct cmd_ds_command *resp) |
113 | { | 113 | { |
114 | int ret = 0; | 114 | int ret = 0; |
115 | lbs_adapter *adapter = priv->adapter; | 115 | struct lbs_adapter *adapter = priv->adapter; |
116 | 116 | ||
117 | lbs_deb_enter(LBS_DEB_CMD); | 117 | lbs_deb_enter(LBS_DEB_CMD); |
118 | 118 | ||
@@ -152,12 +152,12 @@ static int lbs_ret_reg_access(lbs_private * priv, | |||
152 | return ret; | 152 | return ret; |
153 | } | 153 | } |
154 | 154 | ||
155 | static int lbs_ret_get_hw_spec(lbs_private * priv, | 155 | static int lbs_ret_get_hw_spec(struct lbs_private *priv, |
156 | struct cmd_ds_command *resp) | 156 | struct cmd_ds_command *resp) |
157 | { | 157 | { |
158 | u32 i; | 158 | u32 i; |
159 | struct cmd_ds_get_hw_spec *hwspec = &resp->params.hwspec; | 159 | struct cmd_ds_get_hw_spec *hwspec = &resp->params.hwspec; |
160 | lbs_adapter *adapter = priv->adapter; | 160 | struct lbs_adapter *adapter = priv->adapter; |
161 | int ret = 0; | 161 | int ret = 0; |
162 | DECLARE_MAC_BUF(mac); | 162 | DECLARE_MAC_BUF(mac); |
163 | 163 | ||
@@ -216,11 +216,11 @@ done: | |||
216 | return ret; | 216 | return ret; |
217 | } | 217 | } |
218 | 218 | ||
219 | static int lbs_ret_802_11_sleep_params(lbs_private * priv, | 219 | static int lbs_ret_802_11_sleep_params(struct lbs_private *priv, |
220 | struct cmd_ds_command *resp) | 220 | struct cmd_ds_command *resp) |
221 | { | 221 | { |
222 | struct cmd_ds_802_11_sleep_params *sp = &resp->params.sleep_params; | 222 | struct cmd_ds_802_11_sleep_params *sp = &resp->params.sleep_params; |
223 | lbs_adapter *adapter = priv->adapter; | 223 | struct lbs_adapter *adapter = priv->adapter; |
224 | 224 | ||
225 | lbs_deb_enter(LBS_DEB_CMD); | 225 | lbs_deb_enter(LBS_DEB_CMD); |
226 | 226 | ||
@@ -240,14 +240,14 @@ static int lbs_ret_802_11_sleep_params(lbs_private * priv, | |||
240 | return 0; | 240 | return 0; |
241 | } | 241 | } |
242 | 242 | ||
243 | static int lbs_ret_802_11_stat(lbs_private * priv, | 243 | static int lbs_ret_802_11_stat(struct lbs_private *priv, |
244 | struct cmd_ds_command *resp) | 244 | struct cmd_ds_command *resp) |
245 | { | 245 | { |
246 | lbs_deb_enter(LBS_DEB_CMD); | 246 | lbs_deb_enter(LBS_DEB_CMD); |
247 | /* currently adapter->wlan802_11Stat is unused | 247 | /* currently adapter->wlan802_11Stat is unused |
248 | 248 | ||
249 | struct cmd_ds_802_11_get_stat *p11Stat = &resp->params.gstat; | 249 | struct cmd_ds_802_11_get_stat *p11Stat = &resp->params.gstat; |
250 | lbs_adapter *adapter = priv->adapter; | 250 | struct lbs_adapter *adapter = priv->adapter; |
251 | 251 | ||
252 | // TODO Convert it to Big endian befor copy | 252 | // TODO Convert it to Big endian befor copy |
253 | memcpy(&adapter->wlan802_11Stat, | 253 | memcpy(&adapter->wlan802_11Stat, |
@@ -257,7 +257,7 @@ static int lbs_ret_802_11_stat(lbs_private * priv, | |||
257 | return 0; | 257 | return 0; |
258 | } | 258 | } |
259 | 259 | ||
260 | static int lbs_ret_802_11_snmp_mib(lbs_private * priv, | 260 | static int lbs_ret_802_11_snmp_mib(struct lbs_private *priv, |
261 | struct cmd_ds_command *resp) | 261 | struct cmd_ds_command *resp) |
262 | { | 262 | { |
263 | struct cmd_ds_802_11_snmp_mib *smib = &resp->params.smib; | 263 | struct cmd_ds_802_11_snmp_mib *smib = &resp->params.smib; |
@@ -299,12 +299,12 @@ static int lbs_ret_802_11_snmp_mib(lbs_private * priv, | |||
299 | return 0; | 299 | return 0; |
300 | } | 300 | } |
301 | 301 | ||
302 | static int lbs_ret_802_11_key_material(lbs_private * priv, | 302 | static int lbs_ret_802_11_key_material(struct lbs_private *priv, |
303 | struct cmd_ds_command *resp) | 303 | struct cmd_ds_command *resp) |
304 | { | 304 | { |
305 | struct cmd_ds_802_11_key_material *pkeymaterial = | 305 | struct cmd_ds_802_11_key_material *pkeymaterial = |
306 | &resp->params.keymaterial; | 306 | &resp->params.keymaterial; |
307 | lbs_adapter *adapter = priv->adapter; | 307 | struct lbs_adapter *adapter = priv->adapter; |
308 | u16 action = le16_to_cpu(pkeymaterial->action); | 308 | u16 action = le16_to_cpu(pkeymaterial->action); |
309 | 309 | ||
310 | lbs_deb_enter(LBS_DEB_CMD); | 310 | lbs_deb_enter(LBS_DEB_CMD); |
@@ -355,11 +355,11 @@ static int lbs_ret_802_11_key_material(lbs_private * priv, | |||
355 | return 0; | 355 | return 0; |
356 | } | 356 | } |
357 | 357 | ||
358 | static int lbs_ret_802_11_mac_address(lbs_private * priv, | 358 | static int lbs_ret_802_11_mac_address(struct lbs_private *priv, |
359 | struct cmd_ds_command *resp) | 359 | struct cmd_ds_command *resp) |
360 | { | 360 | { |
361 | struct cmd_ds_802_11_mac_address *macadd = &resp->params.macadd; | 361 | struct cmd_ds_802_11_mac_address *macadd = &resp->params.macadd; |
362 | lbs_adapter *adapter = priv->adapter; | 362 | struct lbs_adapter *adapter = priv->adapter; |
363 | 363 | ||
364 | lbs_deb_enter(LBS_DEB_CMD); | 364 | lbs_deb_enter(LBS_DEB_CMD); |
365 | 365 | ||
@@ -369,11 +369,11 @@ static int lbs_ret_802_11_mac_address(lbs_private * priv, | |||
369 | return 0; | 369 | return 0; |
370 | } | 370 | } |
371 | 371 | ||
372 | static int lbs_ret_802_11_rf_tx_power(lbs_private * priv, | 372 | static int lbs_ret_802_11_rf_tx_power(struct lbs_private *priv, |
373 | struct cmd_ds_command *resp) | 373 | struct cmd_ds_command *resp) |
374 | { | 374 | { |
375 | struct cmd_ds_802_11_rf_tx_power *rtp = &resp->params.txp; | 375 | struct cmd_ds_802_11_rf_tx_power *rtp = &resp->params.txp; |
376 | lbs_adapter *adapter = priv->adapter; | 376 | struct lbs_adapter *adapter = priv->adapter; |
377 | 377 | ||
378 | lbs_deb_enter(LBS_DEB_CMD); | 378 | lbs_deb_enter(LBS_DEB_CMD); |
379 | 379 | ||
@@ -385,11 +385,11 @@ static int lbs_ret_802_11_rf_tx_power(lbs_private * priv, | |||
385 | return 0; | 385 | return 0; |
386 | } | 386 | } |
387 | 387 | ||
388 | static int lbs_ret_802_11_rate_adapt_rateset(lbs_private * priv, | 388 | static int lbs_ret_802_11_rate_adapt_rateset(struct lbs_private *priv, |
389 | struct cmd_ds_command *resp) | 389 | struct cmd_ds_command *resp) |
390 | { | 390 | { |
391 | struct cmd_ds_802_11_rate_adapt_rateset *rates = &resp->params.rateset; | 391 | struct cmd_ds_802_11_rate_adapt_rateset *rates = &resp->params.rateset; |
392 | lbs_adapter *adapter = priv->adapter; | 392 | struct lbs_adapter *adapter = priv->adapter; |
393 | 393 | ||
394 | lbs_deb_enter(LBS_DEB_CMD); | 394 | lbs_deb_enter(LBS_DEB_CMD); |
395 | 395 | ||
@@ -402,11 +402,11 @@ static int lbs_ret_802_11_rate_adapt_rateset(lbs_private * priv, | |||
402 | return 0; | 402 | return 0; |
403 | } | 403 | } |
404 | 404 | ||
405 | static int lbs_ret_802_11_data_rate(lbs_private * priv, | 405 | static int lbs_ret_802_11_data_rate(struct lbs_private *priv, |
406 | struct cmd_ds_command *resp) | 406 | struct cmd_ds_command *resp) |
407 | { | 407 | { |
408 | struct cmd_ds_802_11_data_rate *pdatarate = &resp->params.drate; | 408 | struct cmd_ds_802_11_data_rate *pdatarate = &resp->params.drate; |
409 | lbs_adapter *adapter = priv->adapter; | 409 | struct lbs_adapter *adapter = priv->adapter; |
410 | 410 | ||
411 | lbs_deb_enter(LBS_DEB_CMD); | 411 | lbs_deb_enter(LBS_DEB_CMD); |
412 | 412 | ||
@@ -423,11 +423,11 @@ static int lbs_ret_802_11_data_rate(lbs_private * priv, | |||
423 | return 0; | 423 | return 0; |
424 | } | 424 | } |
425 | 425 | ||
426 | static int lbs_ret_802_11_rf_channel(lbs_private * priv, | 426 | static int lbs_ret_802_11_rf_channel(struct lbs_private *priv, |
427 | struct cmd_ds_command *resp) | 427 | struct cmd_ds_command *resp) |
428 | { | 428 | { |
429 | struct cmd_ds_802_11_rf_channel *rfchannel = &resp->params.rfchannel; | 429 | struct cmd_ds_802_11_rf_channel *rfchannel = &resp->params.rfchannel; |
430 | lbs_adapter *adapter = priv->adapter; | 430 | struct lbs_adapter *adapter = priv->adapter; |
431 | u16 action = le16_to_cpu(rfchannel->action); | 431 | u16 action = le16_to_cpu(rfchannel->action); |
432 | u16 newchannel = le16_to_cpu(rfchannel->currentchannel); | 432 | u16 newchannel = le16_to_cpu(rfchannel->currentchannel); |
433 | 433 | ||
@@ -446,11 +446,11 @@ static int lbs_ret_802_11_rf_channel(lbs_private * priv, | |||
446 | return 0; | 446 | return 0; |
447 | } | 447 | } |
448 | 448 | ||
449 | static int lbs_ret_802_11_rssi(lbs_private * priv, | 449 | static int lbs_ret_802_11_rssi(struct lbs_private *priv, |
450 | struct cmd_ds_command *resp) | 450 | struct cmd_ds_command *resp) |
451 | { | 451 | { |
452 | struct cmd_ds_802_11_rssi_rsp *rssirsp = &resp->params.rssirsp; | 452 | struct cmd_ds_802_11_rssi_rsp *rssirsp = &resp->params.rssirsp; |
453 | lbs_adapter *adapter = priv->adapter; | 453 | struct lbs_adapter *adapter = priv->adapter; |
454 | 454 | ||
455 | lbs_deb_enter(LBS_DEB_CMD); | 455 | lbs_deb_enter(LBS_DEB_CMD); |
456 | 456 | ||
@@ -477,10 +477,10 @@ static int lbs_ret_802_11_rssi(lbs_private * priv, | |||
477 | return 0; | 477 | return 0; |
478 | } | 478 | } |
479 | 479 | ||
480 | static int lbs_ret_802_11_eeprom_access(lbs_private * priv, | 480 | static int lbs_ret_802_11_eeprom_access(struct lbs_private *priv, |
481 | struct cmd_ds_command *resp) | 481 | struct cmd_ds_command *resp) |
482 | { | 482 | { |
483 | lbs_adapter *adapter = priv->adapter; | 483 | struct lbs_adapter *adapter = priv->adapter; |
484 | struct lbs_ioctl_regrdwr *pbuf; | 484 | struct lbs_ioctl_regrdwr *pbuf; |
485 | pbuf = (struct lbs_ioctl_regrdwr *) adapter->prdeeprom; | 485 | pbuf = (struct lbs_ioctl_regrdwr *) adapter->prdeeprom; |
486 | 486 | ||
@@ -503,11 +503,11 @@ static int lbs_ret_802_11_eeprom_access(lbs_private * priv, | |||
503 | return 0; | 503 | return 0; |
504 | } | 504 | } |
505 | 505 | ||
506 | static int lbs_ret_get_log(lbs_private * priv, | 506 | static int lbs_ret_get_log(struct lbs_private *priv, |
507 | struct cmd_ds_command *resp) | 507 | struct cmd_ds_command *resp) |
508 | { | 508 | { |
509 | struct cmd_ds_802_11_get_log *logmessage = &resp->params.glog; | 509 | struct cmd_ds_802_11_get_log *logmessage = &resp->params.glog; |
510 | lbs_adapter *adapter = priv->adapter; | 510 | struct lbs_adapter *adapter = priv->adapter; |
511 | 511 | ||
512 | lbs_deb_enter(LBS_DEB_CMD); | 512 | lbs_deb_enter(LBS_DEB_CMD); |
513 | 513 | ||
@@ -518,11 +518,11 @@ static int lbs_ret_get_log(lbs_private * priv, | |||
518 | return 0; | 518 | return 0; |
519 | } | 519 | } |
520 | 520 | ||
521 | static int lbs_ret_802_11_enable_rsn(lbs_private * priv, | 521 | static int lbs_ret_802_11_enable_rsn(struct lbs_private *priv, |
522 | struct cmd_ds_command *resp) | 522 | struct cmd_ds_command *resp) |
523 | { | 523 | { |
524 | struct cmd_ds_802_11_enable_rsn *enable_rsn = &resp->params.enbrsn; | 524 | struct cmd_ds_802_11_enable_rsn *enable_rsn = &resp->params.enbrsn; |
525 | lbs_adapter *adapter = priv->adapter; | 525 | struct lbs_adapter *adapter = priv->adapter; |
526 | u32 * pdata_buf = adapter->cur_cmd->pdata_buf; | 526 | u32 * pdata_buf = adapter->cur_cmd->pdata_buf; |
527 | 527 | ||
528 | lbs_deb_enter(LBS_DEB_CMD); | 528 | lbs_deb_enter(LBS_DEB_CMD); |
@@ -556,11 +556,11 @@ static int lbs_ret_802_11_bcn_ctrl(struct lbs_private * priv, | |||
556 | 556 | ||
557 | static inline int handle_cmd_response(u16 respcmd, | 557 | static inline int handle_cmd_response(u16 respcmd, |
558 | struct cmd_ds_command *resp, | 558 | struct cmd_ds_command *resp, |
559 | lbs_private *priv) | 559 | struct lbs_private *priv) |
560 | { | 560 | { |
561 | int ret = 0; | 561 | int ret = 0; |
562 | unsigned long flags; | 562 | unsigned long flags; |
563 | lbs_adapter *adapter = priv->adapter; | 563 | struct lbs_adapter *adapter = priv->adapter; |
564 | 564 | ||
565 | lbs_deb_enter(LBS_DEB_HOST); | 565 | lbs_deb_enter(LBS_DEB_HOST); |
566 | 566 | ||
@@ -735,11 +735,11 @@ static inline int handle_cmd_response(u16 respcmd, | |||
735 | return ret; | 735 | return ret; |
736 | } | 736 | } |
737 | 737 | ||
738 | int lbs_process_rx_command(lbs_private * priv) | 738 | int lbs_process_rx_command(struct lbs_private *priv) |
739 | { | 739 | { |
740 | u16 respcmd; | 740 | u16 respcmd; |
741 | struct cmd_ds_command *resp; | 741 | struct cmd_ds_command *resp; |
742 | lbs_adapter *adapter = priv->adapter; | 742 | struct lbs_adapter *adapter = priv->adapter; |
743 | int ret = 0; | 743 | int ret = 0; |
744 | ulong flags; | 744 | ulong flags; |
745 | u16 result; | 745 | u16 result; |
@@ -888,10 +888,10 @@ done: | |||
888 | return ret; | 888 | return ret; |
889 | } | 889 | } |
890 | 890 | ||
891 | int lbs_process_event(lbs_private * priv) | 891 | int lbs_process_event(struct lbs_private *priv) |
892 | { | 892 | { |
893 | int ret = 0; | 893 | int ret = 0; |
894 | lbs_adapter *adapter = priv->adapter; | 894 | struct lbs_adapter *adapter = priv->adapter; |
895 | u32 eventcause; | 895 | u32 eventcause; |
896 | 896 | ||
897 | lbs_deb_enter(LBS_DEB_CMD); | 897 | lbs_deb_enter(LBS_DEB_CMD); |