diff options
author | Amitkumar Karwar <akarwar@marvell.com> | 2014-09-12 20:08:52 +0530 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2014-09-15 15:00:51 -0400 |
commit | c48ba040acb81bc37ead17cae23fe3d9b3c08474 (patch) | |
tree | 22c5ebcb9e76acab8bab5e68eef3e5909c62c802 /drivers/net/wireless/mwifiex/sdio.c | |
parent | c7346c3231e9b8e530ab7b73796066f7bf60b240 (diff) | |
download | lwn-c48ba040acb81bc37ead17cae23fe3d9b3c08474.tar.gz lwn-c48ba040acb81bc37ead17cae23fe3d9b3c08474.zip |
mwifiex: minor cleanup in multiport aggregation
'mp_data_port_mask' and 'mp_end_port' gives correct information
even for the chipsets supporting SDIO new mode (32 ports).
We will get rid of this chip specific handling.
Signed-off-by: Amitkumar Karwar <akarwar@marvell.com>
Signed-off-by: Avinash Patil <patila@marvell.com>
Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/mwifiex/sdio.c')
-rw-r--r-- | drivers/net/wireless/mwifiex/sdio.c | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/drivers/net/wireless/mwifiex/sdio.c b/drivers/net/wireless/mwifiex/sdio.c index 993841ec007b..bdab122db5cf 100644 --- a/drivers/net/wireless/mwifiex/sdio.c +++ b/drivers/net/wireless/mwifiex/sdio.c @@ -622,22 +622,15 @@ static int mwifiex_get_wr_port_data(struct mwifiex_adapter *adapter, u32 *port) dev_dbg(adapter->dev, "data: mp_wr_bitmap=0x%08x\n", wr_bitmap); - if (card->supports_sdio_new_mode && - !(wr_bitmap & reg->data_port_mask)) { + if (!(wr_bitmap & card->mp_data_port_mask)) { adapter->data_sent = true; return -EBUSY; - } else if (!card->supports_sdio_new_mode && - !(wr_bitmap & card->mp_data_port_mask)) { - return -1; } if (card->mp_wr_bitmap & (1 << card->curr_wr_port)) { card->mp_wr_bitmap &= (u32) (~(1 << card->curr_wr_port)); *port = card->curr_wr_port; - if (((card->supports_sdio_new_mode) && - (++card->curr_wr_port == card->max_ports)) || - ((!card->supports_sdio_new_mode) && - (++card->curr_wr_port == card->mp_end_port))) + if (++card->curr_wr_port == card->mp_end_port) card->curr_wr_port = reg->start_wr_port; } else { adapter->data_sent = true; |