diff options
author | Avinash Patil <patila@marvell.com> | 2015-02-11 12:42:26 -0500 |
---|---|---|
committer | Kalle Valo <kvalo@codeaurora.org> | 2015-02-27 03:08:46 -0500 |
commit | b4e8aebbc7c23c055d171f56c585e946c162b730 (patch) | |
tree | 744901f05ce1fdbc5cb9a6466c7c60c71ea4cd2d /drivers/net/wireless/mwifiex | |
parent | 7521ce6eb2d3650a04ac7a1d176607ae9441826a (diff) |
mwifiex: change datatype to bool for device capability flags
This patch changes datatypes for device capability flags to bool.
Patch also aggregates these variables at single place.
Signed-off-by: Avinash Patil <patila@marvell.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Diffstat (limited to 'drivers/net/wireless/mwifiex')
-rw-r--r-- | drivers/net/wireless/mwifiex/pcie.c | 4 | ||||
-rw-r--r-- | drivers/net/wireless/mwifiex/pcie.h | 6 | ||||
-rw-r--r-- | drivers/net/wireless/mwifiex/sdio.c | 8 | ||||
-rw-r--r-- | drivers/net/wireless/mwifiex/sdio.h | 60 |
4 files changed, 39 insertions, 39 deletions
diff --git a/drivers/net/wireless/mwifiex/pcie.c b/drivers/net/wireless/mwifiex/pcie.c index a5828da59365..0640bd67077c 100644 --- a/drivers/net/wireless/mwifiex/pcie.c +++ b/drivers/net/wireless/mwifiex/pcie.c | |||
@@ -203,7 +203,7 @@ static int mwifiex_pcie_probe(struct pci_dev *pdev, | |||
203 | card->pcie.reg = data->reg; | 203 | card->pcie.reg = data->reg; |
204 | card->pcie.blksz_fw_dl = data->blksz_fw_dl; | 204 | card->pcie.blksz_fw_dl = data->blksz_fw_dl; |
205 | card->pcie.tx_buf_size = data->tx_buf_size; | 205 | card->pcie.tx_buf_size = data->tx_buf_size; |
206 | card->pcie.supports_fw_dump = data->supports_fw_dump; | 206 | card->pcie.can_dump_fw = data->can_dump_fw; |
207 | card->pcie.can_ext_scan = data->can_ext_scan; | 207 | card->pcie.can_ext_scan = data->can_ext_scan; |
208 | } | 208 | } |
209 | 209 | ||
@@ -2271,7 +2271,7 @@ static void mwifiex_pcie_fw_dump_work(struct mwifiex_adapter *adapter) | |||
2271 | int ret; | 2271 | int ret; |
2272 | static char *env[] = { "DRIVER=mwifiex_pcie", "EVENT=fw_dump", NULL }; | 2272 | static char *env[] = { "DRIVER=mwifiex_pcie", "EVENT=fw_dump", NULL }; |
2273 | 2273 | ||
2274 | if (!card->pcie.supports_fw_dump) | 2274 | if (!card->pcie.can_dump_fw) |
2275 | return; | 2275 | return; |
2276 | 2276 | ||
2277 | for (idx = 0; idx < ARRAY_SIZE(mem_type_mapping_tbl); idx++) { | 2277 | for (idx = 0; idx < ARRAY_SIZE(mem_type_mapping_tbl); idx++) { |
diff --git a/drivers/net/wireless/mwifiex/pcie.h b/drivers/net/wireless/mwifiex/pcie.h index 666d40e9dbc3..0e7ee8b72358 100644 --- a/drivers/net/wireless/mwifiex/pcie.h +++ b/drivers/net/wireless/mwifiex/pcie.h | |||
@@ -205,7 +205,7 @@ struct mwifiex_pcie_device { | |||
205 | const struct mwifiex_pcie_card_reg *reg; | 205 | const struct mwifiex_pcie_card_reg *reg; |
206 | u16 blksz_fw_dl; | 206 | u16 blksz_fw_dl; |
207 | u16 tx_buf_size; | 207 | u16 tx_buf_size; |
208 | bool supports_fw_dump; | 208 | bool can_dump_fw; |
209 | bool can_ext_scan; | 209 | bool can_ext_scan; |
210 | }; | 210 | }; |
211 | 211 | ||
@@ -214,7 +214,7 @@ static const struct mwifiex_pcie_device mwifiex_pcie8766 = { | |||
214 | .reg = &mwifiex_reg_8766, | 214 | .reg = &mwifiex_reg_8766, |
215 | .blksz_fw_dl = MWIFIEX_PCIE_BLOCK_SIZE_FW_DNLD, | 215 | .blksz_fw_dl = MWIFIEX_PCIE_BLOCK_SIZE_FW_DNLD, |
216 | .tx_buf_size = MWIFIEX_TX_DATA_BUF_SIZE_2K, | 216 | .tx_buf_size = MWIFIEX_TX_DATA_BUF_SIZE_2K, |
217 | .supports_fw_dump = false, | 217 | .can_dump_fw = false, |
218 | .can_ext_scan = true, | 218 | .can_ext_scan = true, |
219 | }; | 219 | }; |
220 | 220 | ||
@@ -223,7 +223,7 @@ static const struct mwifiex_pcie_device mwifiex_pcie8897 = { | |||
223 | .reg = &mwifiex_reg_8897, | 223 | .reg = &mwifiex_reg_8897, |
224 | .blksz_fw_dl = MWIFIEX_PCIE_BLOCK_SIZE_FW_DNLD, | 224 | .blksz_fw_dl = MWIFIEX_PCIE_BLOCK_SIZE_FW_DNLD, |
225 | .tx_buf_size = MWIFIEX_TX_DATA_BUF_SIZE_4K, | 225 | .tx_buf_size = MWIFIEX_TX_DATA_BUF_SIZE_4K, |
226 | .supports_fw_dump = true, | 226 | .can_dump_fw = true, |
227 | .can_ext_scan = true, | 227 | .can_ext_scan = true, |
228 | }; | 228 | }; |
229 | 229 | ||
diff --git a/drivers/net/wireless/mwifiex/sdio.c b/drivers/net/wireless/mwifiex/sdio.c index 91e36cda9543..78a9e863a934 100644 --- a/drivers/net/wireless/mwifiex/sdio.c +++ b/drivers/net/wireless/mwifiex/sdio.c | |||
@@ -105,8 +105,8 @@ mwifiex_sdio_probe(struct sdio_func *func, const struct sdio_device_id *id) | |||
105 | card->tx_buf_size = data->tx_buf_size; | 105 | card->tx_buf_size = data->tx_buf_size; |
106 | card->mp_tx_agg_buf_size = data->mp_tx_agg_buf_size; | 106 | card->mp_tx_agg_buf_size = data->mp_tx_agg_buf_size; |
107 | card->mp_rx_agg_buf_size = data->mp_rx_agg_buf_size; | 107 | card->mp_rx_agg_buf_size = data->mp_rx_agg_buf_size; |
108 | card->supports_fw_dump = data->supports_fw_dump; | 108 | card->can_dump_fw = data->can_dump_fw; |
109 | card->auto_tdls = data->auto_tdls; | 109 | card->can_auto_tdls = data->can_auto_tdls; |
110 | card->can_ext_scan = data->can_ext_scan; | 110 | card->can_ext_scan = data->can_ext_scan; |
111 | } | 111 | } |
112 | 112 | ||
@@ -1887,7 +1887,7 @@ static int mwifiex_init_sdio(struct mwifiex_adapter *adapter) | |||
1887 | return -1; | 1887 | return -1; |
1888 | } | 1888 | } |
1889 | 1889 | ||
1890 | adapter->auto_tdls = card->auto_tdls; | 1890 | adapter->auto_tdls = card->can_auto_tdls; |
1891 | adapter->ext_scan = card->can_ext_scan; | 1891 | adapter->ext_scan = card->can_ext_scan; |
1892 | return ret; | 1892 | return ret; |
1893 | } | 1893 | } |
@@ -2032,7 +2032,7 @@ static void mwifiex_sdio_fw_dump_work(struct work_struct *work) | |||
2032 | 2032 | ||
2033 | mwifiex_dump_drv_info(adapter); | 2033 | mwifiex_dump_drv_info(adapter); |
2034 | 2034 | ||
2035 | if (!card->supports_fw_dump) | 2035 | if (!card->can_dump_fw) |
2036 | return; | 2036 | return; |
2037 | 2037 | ||
2038 | for (idx = 0; idx < ARRAY_SIZE(mem_type_mapping_tbl); idx++) { | 2038 | for (idx = 0; idx < ARRAY_SIZE(mem_type_mapping_tbl); idx++) { |
diff --git a/drivers/net/wireless/mwifiex/sdio.h b/drivers/net/wireless/mwifiex/sdio.h index 957cca246618..3fe9fb435e7e 100644 --- a/drivers/net/wireless/mwifiex/sdio.h +++ b/drivers/net/wireless/mwifiex/sdio.h | |||
@@ -238,9 +238,6 @@ struct sdio_mmc_card { | |||
238 | const struct mwifiex_sdio_card_reg *reg; | 238 | const struct mwifiex_sdio_card_reg *reg; |
239 | u8 max_ports; | 239 | u8 max_ports; |
240 | u8 mp_agg_pkt_limit; | 240 | u8 mp_agg_pkt_limit; |
241 | bool supports_sdio_new_mode; | ||
242 | bool has_control_mask; | ||
243 | bool supports_fw_dump; | ||
244 | u16 tx_buf_size; | 241 | u16 tx_buf_size; |
245 | u32 mp_tx_agg_buf_size; | 242 | u32 mp_tx_agg_buf_size; |
246 | u32 mp_rx_agg_buf_size; | 243 | u32 mp_rx_agg_buf_size; |
@@ -255,7 +252,10 @@ struct sdio_mmc_card { | |||
255 | u8 curr_wr_port; | 252 | u8 curr_wr_port; |
256 | 253 | ||
257 | u8 *mp_regs; | 254 | u8 *mp_regs; |
258 | u8 auto_tdls; | 255 | bool supports_sdio_new_mode; |
256 | bool has_control_mask; | ||
257 | bool can_dump_fw; | ||
258 | bool can_auto_tdls; | ||
259 | bool can_ext_scan; | 259 | bool can_ext_scan; |
260 | 260 | ||
261 | struct mwifiex_sdio_mpa_tx mpa_tx; | 261 | struct mwifiex_sdio_mpa_tx mpa_tx; |
@@ -267,13 +267,13 @@ struct mwifiex_sdio_device { | |||
267 | const struct mwifiex_sdio_card_reg *reg; | 267 | const struct mwifiex_sdio_card_reg *reg; |
268 | u8 max_ports; | 268 | u8 max_ports; |
269 | u8 mp_agg_pkt_limit; | 269 | u8 mp_agg_pkt_limit; |
270 | bool supports_sdio_new_mode; | ||
271 | bool has_control_mask; | ||
272 | bool supports_fw_dump; | ||
273 | u16 tx_buf_size; | 270 | u16 tx_buf_size; |
274 | u32 mp_tx_agg_buf_size; | 271 | u32 mp_tx_agg_buf_size; |
275 | u32 mp_rx_agg_buf_size; | 272 | u32 mp_rx_agg_buf_size; |
276 | u8 auto_tdls; | 273 | bool supports_sdio_new_mode; |
274 | bool has_control_mask; | ||
275 | bool can_dump_fw; | ||
276 | bool can_auto_tdls; | ||
277 | bool can_ext_scan; | 277 | bool can_ext_scan; |
278 | }; | 278 | }; |
279 | 279 | ||
@@ -412,13 +412,13 @@ static const struct mwifiex_sdio_device mwifiex_sdio_sd8786 = { | |||
412 | .reg = &mwifiex_reg_sd87xx, | 412 | .reg = &mwifiex_reg_sd87xx, |
413 | .max_ports = 16, | 413 | .max_ports = 16, |
414 | .mp_agg_pkt_limit = 8, | 414 | .mp_agg_pkt_limit = 8, |
415 | .supports_sdio_new_mode = false, | ||
416 | .has_control_mask = true, | ||
417 | .tx_buf_size = MWIFIEX_TX_DATA_BUF_SIZE_2K, | 415 | .tx_buf_size = MWIFIEX_TX_DATA_BUF_SIZE_2K, |
418 | .mp_tx_agg_buf_size = MWIFIEX_MP_AGGR_BUF_SIZE_16K, | 416 | .mp_tx_agg_buf_size = MWIFIEX_MP_AGGR_BUF_SIZE_16K, |
419 | .mp_rx_agg_buf_size = MWIFIEX_MP_AGGR_BUF_SIZE_16K, | 417 | .mp_rx_agg_buf_size = MWIFIEX_MP_AGGR_BUF_SIZE_16K, |
420 | .supports_fw_dump = false, | 418 | .supports_sdio_new_mode = false, |
421 | .auto_tdls = false, | 419 | .has_control_mask = true, |
420 | .can_dump_fw = false, | ||
421 | .can_auto_tdls = false, | ||
422 | .can_ext_scan = false, | 422 | .can_ext_scan = false, |
423 | }; | 423 | }; |
424 | 424 | ||
@@ -427,13 +427,13 @@ static const struct mwifiex_sdio_device mwifiex_sdio_sd8787 = { | |||
427 | .reg = &mwifiex_reg_sd87xx, | 427 | .reg = &mwifiex_reg_sd87xx, |
428 | .max_ports = 16, | 428 | .max_ports = 16, |
429 | .mp_agg_pkt_limit = 8, | 429 | .mp_agg_pkt_limit = 8, |
430 | .supports_sdio_new_mode = false, | ||
431 | .has_control_mask = true, | ||
432 | .tx_buf_size = MWIFIEX_TX_DATA_BUF_SIZE_2K, | 430 | .tx_buf_size = MWIFIEX_TX_DATA_BUF_SIZE_2K, |
433 | .mp_tx_agg_buf_size = MWIFIEX_MP_AGGR_BUF_SIZE_16K, | 431 | .mp_tx_agg_buf_size = MWIFIEX_MP_AGGR_BUF_SIZE_16K, |
434 | .mp_rx_agg_buf_size = MWIFIEX_MP_AGGR_BUF_SIZE_16K, | 432 | .mp_rx_agg_buf_size = MWIFIEX_MP_AGGR_BUF_SIZE_16K, |
435 | .supports_fw_dump = false, | 433 | .supports_sdio_new_mode = false, |
436 | .auto_tdls = false, | 434 | .has_control_mask = true, |
435 | .can_dump_fw = false, | ||
436 | .can_auto_tdls = false, | ||
437 | .can_ext_scan = true, | 437 | .can_ext_scan = true, |
438 | }; | 438 | }; |
439 | 439 | ||
@@ -442,13 +442,13 @@ static const struct mwifiex_sdio_device mwifiex_sdio_sd8797 = { | |||
442 | .reg = &mwifiex_reg_sd87xx, | 442 | .reg = &mwifiex_reg_sd87xx, |
443 | .max_ports = 16, | 443 | .max_ports = 16, |
444 | .mp_agg_pkt_limit = 8, | 444 | .mp_agg_pkt_limit = 8, |
445 | .supports_sdio_new_mode = false, | ||
446 | .has_control_mask = true, | ||
447 | .tx_buf_size = MWIFIEX_TX_DATA_BUF_SIZE_2K, | 445 | .tx_buf_size = MWIFIEX_TX_DATA_BUF_SIZE_2K, |
448 | .mp_tx_agg_buf_size = MWIFIEX_MP_AGGR_BUF_SIZE_16K, | 446 | .mp_tx_agg_buf_size = MWIFIEX_MP_AGGR_BUF_SIZE_16K, |
449 | .mp_rx_agg_buf_size = MWIFIEX_MP_AGGR_BUF_SIZE_16K, | 447 | .mp_rx_agg_buf_size = MWIFIEX_MP_AGGR_BUF_SIZE_16K, |
450 | .supports_fw_dump = false, | 448 | .supports_sdio_new_mode = false, |
451 | .auto_tdls = false, | 449 | .has_control_mask = true, |
450 | .can_dump_fw = false, | ||
451 | .can_auto_tdls = false, | ||
452 | .can_ext_scan = true, | 452 | .can_ext_scan = true, |
453 | }; | 453 | }; |
454 | 454 | ||
@@ -457,13 +457,13 @@ static const struct mwifiex_sdio_device mwifiex_sdio_sd8897 = { | |||
457 | .reg = &mwifiex_reg_sd8897, | 457 | .reg = &mwifiex_reg_sd8897, |
458 | .max_ports = 32, | 458 | .max_ports = 32, |
459 | .mp_agg_pkt_limit = 16, | 459 | .mp_agg_pkt_limit = 16, |
460 | .supports_sdio_new_mode = true, | ||
461 | .has_control_mask = false, | ||
462 | .tx_buf_size = MWIFIEX_TX_DATA_BUF_SIZE_4K, | 460 | .tx_buf_size = MWIFIEX_TX_DATA_BUF_SIZE_4K, |
463 | .mp_tx_agg_buf_size = MWIFIEX_MP_AGGR_BUF_SIZE_32K, | 461 | .mp_tx_agg_buf_size = MWIFIEX_MP_AGGR_BUF_SIZE_32K, |
464 | .mp_rx_agg_buf_size = MWIFIEX_MP_AGGR_BUF_SIZE_32K, | 462 | .mp_rx_agg_buf_size = MWIFIEX_MP_AGGR_BUF_SIZE_32K, |
465 | .supports_fw_dump = true, | 463 | .supports_sdio_new_mode = true, |
466 | .auto_tdls = false, | 464 | .has_control_mask = false, |
465 | .can_dump_fw = true, | ||
466 | .can_auto_tdls = false, | ||
467 | .can_ext_scan = true, | 467 | .can_ext_scan = true, |
468 | }; | 468 | }; |
469 | 469 | ||
@@ -472,13 +472,13 @@ static const struct mwifiex_sdio_device mwifiex_sdio_sd8887 = { | |||
472 | .reg = &mwifiex_reg_sd8887, | 472 | .reg = &mwifiex_reg_sd8887, |
473 | .max_ports = 32, | 473 | .max_ports = 32, |
474 | .mp_agg_pkt_limit = 16, | 474 | .mp_agg_pkt_limit = 16, |
475 | .supports_sdio_new_mode = true, | ||
476 | .has_control_mask = false, | ||
477 | .tx_buf_size = MWIFIEX_TX_DATA_BUF_SIZE_4K, | 475 | .tx_buf_size = MWIFIEX_TX_DATA_BUF_SIZE_4K, |
478 | .mp_tx_agg_buf_size = MWIFIEX_MP_AGGR_BUF_SIZE_32K, | 476 | .mp_tx_agg_buf_size = MWIFIEX_MP_AGGR_BUF_SIZE_32K, |
479 | .mp_rx_agg_buf_size = MWIFIEX_MP_AGGR_BUF_SIZE_32K, | 477 | .mp_rx_agg_buf_size = MWIFIEX_MP_AGGR_BUF_SIZE_32K, |
480 | .supports_fw_dump = false, | 478 | .supports_sdio_new_mode = true, |
481 | .auto_tdls = true, | 479 | .has_control_mask = false, |
480 | .can_dump_fw = false, | ||
481 | .can_auto_tdls = true, | ||
482 | .can_ext_scan = true, | 482 | .can_ext_scan = true, |
483 | }; | 483 | }; |
484 | 484 | ||
@@ -492,8 +492,8 @@ static const struct mwifiex_sdio_device mwifiex_sdio_sd8801 = { | |||
492 | .tx_buf_size = MWIFIEX_TX_DATA_BUF_SIZE_2K, | 492 | .tx_buf_size = MWIFIEX_TX_DATA_BUF_SIZE_2K, |
493 | .mp_tx_agg_buf_size = MWIFIEX_MP_AGGR_BUF_SIZE_16K, | 493 | .mp_tx_agg_buf_size = MWIFIEX_MP_AGGR_BUF_SIZE_16K, |
494 | .mp_rx_agg_buf_size = MWIFIEX_MP_AGGR_BUF_SIZE_16K, | 494 | .mp_rx_agg_buf_size = MWIFIEX_MP_AGGR_BUF_SIZE_16K, |
495 | .supports_fw_dump = false, | 495 | .can_dump_fw = false, |
496 | .auto_tdls = false, | 496 | .can_auto_tdls = false, |
497 | .can_ext_scan = true, | 497 | .can_ext_scan = true, |
498 | }; | 498 | }; |
499 | 499 | ||