rsi: sdio changes to support BT
authorPrameela Rani Garnepudi <prameela.j04cs@gmail.com>
Tue, 27 Feb 2018 14:26:18 +0000 (19:56 +0530)
committerKalle Valo <kvalo@codeaurora.org>
Tue, 13 Mar 2018 16:37:10 +0000 (18:37 +0200)
Queue number is correctly updated for BT traffic. Also, kzalloc
instead of kmalloc is used for Rx packet allocation.

Signed-off-by: Prameela Rani Garnepudi <prameela.j04cs@gmail.com>
Signed-off-by: Amitkumar Karwar <amit.karwar@redpinesignals.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
drivers/net/wireless/rsi/rsi_91x_sdio.c
drivers/net/wireless/rsi/rsi_91x_sdio_ops.c

index 5722736d55570848e68eeabd330c47c50fdd9e9c..beb18d0d0e07d3a180f7c8a7d5029964a0be77b4 100644 (file)
@@ -763,6 +763,8 @@ static int rsi_sdio_host_intf_write_pkt(struct rsi_hw *adapter,
        int status;
 
        queueno = ((pkt[1] >> 4) & 0xf);
+       if (queueno == RSI_BT_MGMT_Q || queueno == RSI_BT_DATA_Q)
+               queueno = RSI_BT_Q;
 
        num_blocks = len / block_size;
 
index 169c98125202aa900d88453b909ebf8d11d28cb4..6e74261186c6fbd87b83ad818b00e9df70bc28c6 100644 (file)
@@ -103,7 +103,7 @@ static int rsi_process_pkt(struct rsi_common *common)
 
        rcv_pkt_len = (num_blks * 256);
 
-       common->rx_data_pkt = kmalloc(rcv_pkt_len, GFP_KERNEL);
+       common->rx_data_pkt = kzalloc(rcv_pkt_len, GFP_KERNEL);
        if (!common->rx_data_pkt) {
                rsi_dbg(ERR_ZONE, "%s: Failed in memory allocation\n",
                        __func__);