aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorRon Rindjunsky <ron.rindjunsky@intel.com>2007-11-26 09:14:42 -0500
committerDavid S. Miller <davem@davemloft.net>2008-01-28 18:05:46 -0500
commit9ee1ba474fc37bcaf6a958bf7e995006fc69893b (patch)
tree42224488712bfd808909ce48e0a4c2a8bc69c606 /drivers
parent270243a50574455f593378377c0fa74284730f7d (diff)
iwlwifi: 802.11n add support to 8K A-MSDU Rx frames
This patch give the iwlwifi the ability to support A-MSDU up to 8K Please notice - in order to work in 8K A-MSDU ucode support is needed, version 4.44.1.19 (soon to be published). 4K A-MSDU works in current ucode version as well. Signed-off-by: Ron Rindjunsky <ron.rindjunsky@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-3945-hw.h3
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-3945.c3
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-3945.h31
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-4965-hw.h11
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-4965.c20
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-4965.h5
-rw-r--r--drivers/net/wireless/iwlwifi/iwl4965-base.c21
7 files changed, 73 insertions, 21 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-3945-hw.h b/drivers/net/wireless/iwlwifi/iwl-3945-hw.h
index ec619533fcd9..2c955a6070f9 100644
--- a/drivers/net/wireless/iwlwifi/iwl-3945-hw.h
+++ b/drivers/net/wireless/iwlwifi/iwl-3945-hw.h
@@ -646,9 +646,6 @@ struct iwl3945_eeprom {
646#define RX_FREE_BUFFERS 64 646#define RX_FREE_BUFFERS 64
647#define RX_LOW_WATERMARK 8 647#define RX_LOW_WATERMARK 8
648 648
649/* Size of one Rx buffer in host DRAM */
650#define IWL_RX_BUF_SIZE 3000
651
652/* Sizes and addresses for instruction and data memory (SRAM) in 649/* Sizes and addresses for instruction and data memory (SRAM) in
653 * 3945's embedded processor. Driver access is via HBUS_TARG_MEM_* regs. */ 650 * 3945's embedded processor. Driver access is via HBUS_TARG_MEM_* regs. */
654#define RTC_INST_LOWER_BOUND (0x000000) 651#define RTC_INST_LOWER_BOUND (0x000000)
diff --git a/drivers/net/wireless/iwlwifi/iwl-3945.c b/drivers/net/wireless/iwlwifi/iwl-3945.c
index 1b81545b94ea..7d15b33b9dcd 100644
--- a/drivers/net/wireless/iwlwifi/iwl-3945.c
+++ b/drivers/net/wireless/iwlwifi/iwl-3945.c
@@ -2229,7 +2229,8 @@ int iwl3945_hw_set_hw_setting(struct iwl3945_priv *priv)
2229 } 2229 }
2230 2230
2231 priv->hw_setting.ac_queue_count = AC_NUM; 2231 priv->hw_setting.ac_queue_count = AC_NUM;
2232 priv->hw_setting.rx_buffer_size = IWL_RX_BUF_SIZE; 2232 priv->hw_setting.rx_buf_size = IWL_RX_BUF_SIZE;
2233 priv->hw_setting.max_pkt_size = 2342;
2233 priv->hw_setting.tx_cmd_len = sizeof(struct iwl3945_tx_cmd); 2234 priv->hw_setting.tx_cmd_len = sizeof(struct iwl3945_tx_cmd);
2234 priv->hw_setting.max_rxq_size = RX_QUEUE_SIZE; 2235 priv->hw_setting.max_rxq_size = RX_QUEUE_SIZE;
2235 priv->hw_setting.max_rxq_log = RX_QUEUE_SIZE_LOG; 2236 priv->hw_setting.max_rxq_log = RX_QUEUE_SIZE_LOG;
diff --git a/drivers/net/wireless/iwlwifi/iwl-3945.h b/drivers/net/wireless/iwlwifi/iwl-3945.h
index 263b0b71c0c3..709203a41986 100644
--- a/drivers/net/wireless/iwlwifi/iwl-3945.h
+++ b/drivers/net/wireless/iwlwifi/iwl-3945.h
@@ -75,6 +75,7 @@ enum iwl3945_antenna {
75 * else RTS for data/management frames where MPDU is larger 75 * else RTS for data/management frames where MPDU is larger
76 * than RTS value. 76 * than RTS value.
77 */ 77 */
78#define IWL_RX_BUF_SIZE 3000U
78#define DEFAULT_RTS_THRESHOLD 2347U 79#define DEFAULT_RTS_THRESHOLD 2347U
79#define MIN_RTS_THRESHOLD 0U 80#define MIN_RTS_THRESHOLD 0U
80#define MAX_RTS_THRESHOLD 2347U 81#define MAX_RTS_THRESHOLD 2347U
@@ -452,6 +453,30 @@ union iwl3945_ht_rate_supp {
452 }; 453 };
453}; 454};
454 455
456#ifdef CONFIG_IWL3945_HT
457#define CFG_HT_RX_AMPDU_FACTOR_DEF (0x3)
458#define CFG_HT_MPDU_DENSITY_2USEC (0x5)
459#define CFG_HT_MPDU_DENSITY_DEF CFG_HT_MPDU_DENSITY_2USEC
460
461struct sta_ht_info {
462 u8 is_ht;
463 u16 rx_mimo_ps_mode;
464 u16 tx_mimo_ps_mode;
465 u16 control_channel;
466 u8 max_amsdu_size;
467 u8 ampdu_factor;
468 u8 mpdu_density;
469 u8 operating_mode;
470 u8 supported_chan_width;
471 u8 extension_chan_offset;
472 u8 is_green_field;
473 u8 sgf;
474 u8 supp_rates[16];
475 u8 tx_chan_width;
476 u8 chan_width_cap;
477};
478#endif /*CONFIG_IWL3945_HT */
479
455#ifdef CONFIG_IWL3945_QOS 480#ifdef CONFIG_IWL3945_QOS
456 481
457union iwl3945_qos_capabity { 482union iwl3945_qos_capabity {
@@ -535,7 +560,8 @@ struct iwl3945_ibss_seq {
535 * @ac_queue_count: # Tx queues for EDCA Access Categories (AC) 560 * @ac_queue_count: # Tx queues for EDCA Access Categories (AC)
536 * @tx_cmd_len: Size of Tx command (but not including frame itself) 561 * @tx_cmd_len: Size of Tx command (but not including frame itself)
537 * @max_rxq_size: Max # Rx frames in Rx queue (must be power-of-2) 562 * @max_rxq_size: Max # Rx frames in Rx queue (must be power-of-2)
538 * @rx_buffer_size: 563 * @rx_buf_size:
564 * @max_pkt_size:
539 * @max_rxq_log: Log-base-2 of max_rxq_size 565 * @max_rxq_log: Log-base-2 of max_rxq_size
540 * @max_stations: 566 * @max_stations:
541 * @bcast_sta_id: 567 * @bcast_sta_id:
@@ -547,7 +573,8 @@ struct iwl3945_driver_hw_info {
547 u16 ac_queue_count; 573 u16 ac_queue_count;
548 u16 tx_cmd_len; 574 u16 tx_cmd_len;
549 u16 max_rxq_size; 575 u16 max_rxq_size;
550 u32 rx_buffer_size; 576 u32 rx_buf_size;
577 u32 max_pkt_size;
551 u16 max_rxq_log; 578 u16 max_rxq_log;
552 u8 max_stations; 579 u8 max_stations;
553 u8 bcast_sta_id; 580 u8 bcast_sta_id;
diff --git a/drivers/net/wireless/iwlwifi/iwl-4965-hw.h b/drivers/net/wireless/iwlwifi/iwl-4965-hw.h
index d5d418e61923..7e7d6e497e0f 100644
--- a/drivers/net/wireless/iwlwifi/iwl-4965-hw.h
+++ b/drivers/net/wireless/iwlwifi/iwl-4965-hw.h
@@ -609,7 +609,8 @@ struct iwl4965_eeprom {
609#define RX_LOW_WATERMARK 8 609#define RX_LOW_WATERMARK 8
610 610
611/* Size of one Rx buffer in host DRAM */ 611/* Size of one Rx buffer in host DRAM */
612#define IWL_RX_BUF_SIZE (4 * 1024) 612#define IWL_RX_BUF_SIZE_4K (4 * 1024)
613#define IWL_RX_BUF_SIZE_8K (8 * 1024)
613 614
614/* Sizes and addresses for instruction and data memory (SRAM) in 615/* Sizes and addresses for instruction and data memory (SRAM) in
615 * 4965's embedded processor. Driver access is via HBUS_TARG_MEM_* regs. */ 616 * 4965's embedded processor. Driver access is via HBUS_TARG_MEM_* regs. */
@@ -1457,13 +1458,17 @@ enum {
1457#define FH_RCSR_CHNL0_RX_CONFIG_DMA_CHNL_EN_MASK (0xC0000000) /* bits 30-31 */ 1458#define FH_RCSR_CHNL0_RX_CONFIG_DMA_CHNL_EN_MASK (0xC0000000) /* bits 30-31 */
1458 1459
1459#define FH_RCSR_RX_CONFIG_RBDCB_SIZE_BITSHIFT (20) 1460#define FH_RCSR_RX_CONFIG_RBDCB_SIZE_BITSHIFT (20)
1460#define FH_RCSR_RX_CONFIG_RB_SIZE_BITSHIFT (16) 1461#define FH_RCSR_RX_CONFIG_REG_IRQ_RBTH_BITSHIFT (4)
1462#define RX_RB_TIMEOUT (0x10)
1461 1463
1462#define FH_RCSR_RX_CONFIG_CHNL_EN_PAUSE_VAL (0x00000000) 1464#define FH_RCSR_RX_CONFIG_CHNL_EN_PAUSE_VAL (0x00000000)
1463#define FH_RCSR_RX_CONFIG_CHNL_EN_PAUSE_EOF_VAL (0x40000000) 1465#define FH_RCSR_RX_CONFIG_CHNL_EN_PAUSE_EOF_VAL (0x40000000)
1464#define FH_RCSR_RX_CONFIG_CHNL_EN_ENABLE_VAL (0x80000000) 1466#define FH_RCSR_RX_CONFIG_CHNL_EN_ENABLE_VAL (0x80000000)
1465 1467
1466#define IWL_FH_RCSR_RX_CONFIG_REG_VAL_RB_SIZE_4K (0x00000000) 1468#define FH_RCSR_RX_CONFIG_REG_VAL_RB_SIZE_4K (0x00000000)
1469#define FH_RCSR_RX_CONFIG_REG_VAL_RB_SIZE_8K (0x00010000)
1470#define FH_RCSR_RX_CONFIG_REG_VAL_RB_SIZE_12K (0x00020000)
1471#define FH_RCSR_RX_CONFIG_REG_VAL_RB_SIZE_16K (0x00030000)
1467 1472
1468#define FH_RCSR_CHNL0_RX_CONFIG_IRQ_DEST_NO_INT_VAL (0x00000000) 1473#define FH_RCSR_CHNL0_RX_CONFIG_IRQ_DEST_NO_INT_VAL (0x00000000)
1469#define FH_RCSR_CHNL0_RX_CONFIG_IRQ_DEST_INT_HOST_VAL (0x00001000) 1474#define FH_RCSR_CHNL0_RX_CONFIG_IRQ_DEST_INT_HOST_VAL (0x00001000)
diff --git a/drivers/net/wireless/iwlwifi/iwl-4965.c b/drivers/net/wireless/iwlwifi/iwl-4965.c
index 55d61000e342..f65fd6e5fecc 100644
--- a/drivers/net/wireless/iwlwifi/iwl-4965.c
+++ b/drivers/net/wireless/iwlwifi/iwl-4965.c
@@ -226,6 +226,7 @@ static int iwl4965_rx_init(struct iwl4965_priv *priv, struct iwl4965_rx_queue *r
226{ 226{
227 int rc; 227 int rc;
228 unsigned long flags; 228 unsigned long flags;
229 unsigned int rb_size;
229 230
230 spin_lock_irqsave(&priv->lock, flags); 231 spin_lock_irqsave(&priv->lock, flags);
231 rc = iwl4965_grab_nic_access(priv); 232 rc = iwl4965_grab_nic_access(priv);
@@ -234,6 +235,11 @@ static int iwl4965_rx_init(struct iwl4965_priv *priv, struct iwl4965_rx_queue *r
234 return rc; 235 return rc;
235 } 236 }
236 237
238 if (iwl4965_param_amsdu_size_8K)
239 rb_size = FH_RCSR_RX_CONFIG_REG_VAL_RB_SIZE_8K;
240 else
241 rb_size = FH_RCSR_RX_CONFIG_REG_VAL_RB_SIZE_4K;
242
237 /* Stop Rx DMA */ 243 /* Stop Rx DMA */
238 iwl4965_write_direct32(priv, FH_MEM_RCSR_CHNL0_CONFIG_REG, 0); 244 iwl4965_write_direct32(priv, FH_MEM_RCSR_CHNL0_CONFIG_REG, 0);
239 245
@@ -253,7 +259,7 @@ static int iwl4965_rx_init(struct iwl4965_priv *priv, struct iwl4965_rx_queue *r
253 iwl4965_write_direct32(priv, FH_MEM_RCSR_CHNL0_CONFIG_REG, 259 iwl4965_write_direct32(priv, FH_MEM_RCSR_CHNL0_CONFIG_REG,
254 FH_RCSR_RX_CONFIG_CHNL_EN_ENABLE_VAL | 260 FH_RCSR_RX_CONFIG_CHNL_EN_ENABLE_VAL |
255 FH_RCSR_CHNL0_RX_CONFIG_IRQ_DEST_INT_HOST_VAL | 261 FH_RCSR_CHNL0_RX_CONFIG_IRQ_DEST_INT_HOST_VAL |
256 IWL_FH_RCSR_RX_CONFIG_REG_VAL_RB_SIZE_4K | 262 rb_size |
257 /*0x10 << 4 | */ 263 /*0x10 << 4 | */
258 (RX_QUEUE_SIZE_LOG << 264 (RX_QUEUE_SIZE_LOG <<
259 FH_RCSR_RX_CONFIG_RBDCB_SIZE_BITSHIFT)); 265 FH_RCSR_RX_CONFIG_RBDCB_SIZE_BITSHIFT));
@@ -1771,7 +1777,11 @@ int iwl4965_hw_set_hw_setting(struct iwl4965_priv *priv)
1771 priv->hw_setting.tx_cmd_len = sizeof(struct iwl4965_tx_cmd); 1777 priv->hw_setting.tx_cmd_len = sizeof(struct iwl4965_tx_cmd);
1772 priv->hw_setting.max_rxq_size = RX_QUEUE_SIZE; 1778 priv->hw_setting.max_rxq_size = RX_QUEUE_SIZE;
1773 priv->hw_setting.max_rxq_log = RX_QUEUE_SIZE_LOG; 1779 priv->hw_setting.max_rxq_log = RX_QUEUE_SIZE_LOG;
1774 1780 if (iwl4965_param_amsdu_size_8K)
1781 priv->hw_setting.rx_buf_size = IWL_RX_BUF_SIZE_8K;
1782 else
1783 priv->hw_setting.rx_buf_size = IWL_RX_BUF_SIZE_4K;
1784 priv->hw_setting.max_pkt_size = priv->hw_setting.rx_buf_size - 256;
1775 priv->hw_setting.max_stations = IWL4965_STATION_COUNT; 1785 priv->hw_setting.max_stations = IWL4965_STATION_COUNT;
1776 priv->hw_setting.bcast_sta_id = IWL4965_BROADCAST_ID; 1786 priv->hw_setting.bcast_sta_id = IWL4965_BROADCAST_ID;
1777 return 0; 1787 return 0;
@@ -3619,7 +3629,7 @@ static void iwl4965_handle_data_packet(struct iwl4965_priv *priv, int is_data,
3619 rx_start->byte_count = amsdu->byte_count; 3629 rx_start->byte_count = amsdu->byte_count;
3620 rx_end = (__le32 *) (((u8 *) hdr) + len); 3630 rx_end = (__le32 *) (((u8 *) hdr) + len);
3621 } 3631 }
3622 if (len > IWL_RX_BUF_SIZE || len < 16) { 3632 if (len > priv->hw_setting.max_pkt_size || len < 16) {
3623 IWL_WARNING("byte count out of range [16,4K]" 3633 IWL_WARNING("byte count out of range [16,4K]"
3624 " : %d\n", len); 3634 " : %d\n", len);
3625 return; 3635 return;
@@ -3785,6 +3795,10 @@ void iwl4965_init_ht_hw_capab(struct ieee80211_ht_info *ht_info, int mode)
3785 ht_info->cap |= (u16)IEEE80211_HT_CAP_SGI_20; 3795 ht_info->cap |= (u16)IEEE80211_HT_CAP_SGI_20;
3786 ht_info->cap |= (u16)(IEEE80211_HT_CAP_MIMO_PS & 3796 ht_info->cap |= (u16)(IEEE80211_HT_CAP_MIMO_PS &
3787 (IWL_MIMO_PS_NONE << 2)); 3797 (IWL_MIMO_PS_NONE << 2));
3798 if (iwl4965_param_amsdu_size_8K) {
3799 printk(KERN_DEBUG "iwl4965 in A-MSDU 8K support mode\n");
3800 ht_info->cap |= (u16)IEEE80211_HT_CAP_MAX_AMSDU;
3801 }
3788 3802
3789 ht_info->ampdu_factor = CFG_HT_RX_AMPDU_FACTOR_DEF; 3803 ht_info->ampdu_factor = CFG_HT_RX_AMPDU_FACTOR_DEF;
3790 ht_info->ampdu_density = CFG_HT_MPDU_DENSITY_DEF; 3804 ht_info->ampdu_density = CFG_HT_MPDU_DENSITY_DEF;
diff --git a/drivers/net/wireless/iwlwifi/iwl-4965.h b/drivers/net/wireless/iwlwifi/iwl-4965.h
index 50209e6cdd0c..5a410e284b95 100644
--- a/drivers/net/wireless/iwlwifi/iwl-4965.h
+++ b/drivers/net/wireless/iwlwifi/iwl-4965.h
@@ -60,6 +60,7 @@ extern struct pci_device_id iwl4965_hw_card_ids[];
60/* Module parameters accessible from iwl-*.c */ 60/* Module parameters accessible from iwl-*.c */
61extern int iwl4965_param_hwcrypto; 61extern int iwl4965_param_hwcrypto;
62extern int iwl4965_param_queues_num; 62extern int iwl4965_param_queues_num;
63extern int iwl4965_param_amsdu_size_8K;
63 64
64enum iwl4965_antenna { 65enum iwl4965_antenna {
65 IWL_ANTENNA_DIVERSITY, 66 IWL_ANTENNA_DIVERSITY,
@@ -506,7 +507,6 @@ union iwl4965_ht_rate_supp {
506 507
507#ifdef CONFIG_IWL4965_HT 508#ifdef CONFIG_IWL4965_HT
508#define CFG_HT_RX_AMPDU_FACTOR_DEF (0x3) 509#define CFG_HT_RX_AMPDU_FACTOR_DEF (0x3)
509#define HT_IE_MAX_AMSDU_SIZE_4K (0)
510#define CFG_HT_MPDU_DENSITY_2USEC (0x5) 510#define CFG_HT_MPDU_DENSITY_2USEC (0x5)
511#define CFG_HT_MPDU_DENSITY_DEF CFG_HT_MPDU_DENSITY_2USEC 511#define CFG_HT_MPDU_DENSITY_DEF CFG_HT_MPDU_DENSITY_2USEC
512 512
@@ -618,7 +618,8 @@ struct iwl4965_driver_hw_info {
618 u16 ac_queue_count; 618 u16 ac_queue_count;
619 u16 tx_cmd_len; 619 u16 tx_cmd_len;
620 u16 max_rxq_size; 620 u16 max_rxq_size;
621 u32 rx_buffer_size; 621 u32 rx_buf_size;
622 u32 max_pkt_size;
622 u16 max_rxq_log; 623 u16 max_rxq_log;
623 u8 max_stations; 624 u8 max_stations;
624 u8 bcast_sta_id; 625 u8 bcast_sta_id;
diff --git a/drivers/net/wireless/iwlwifi/iwl4965-base.c b/drivers/net/wireless/iwlwifi/iwl4965-base.c
index 9f89f596283c..3a9f14d8f26a 100644
--- a/drivers/net/wireless/iwlwifi/iwl4965-base.c
+++ b/drivers/net/wireless/iwlwifi/iwl4965-base.c
@@ -70,6 +70,7 @@ static int iwl4965_param_antenna; /* def: 0 = both antennas (use diversity) */
70int iwl4965_param_hwcrypto; /* def: using software encryption */ 70int iwl4965_param_hwcrypto; /* def: using software encryption */
71static int iwl4965_param_qos_enable = 1; /* def: 1 = use quality of service */ 71static int iwl4965_param_qos_enable = 1; /* def: 1 = use quality of service */
72int iwl4965_param_queues_num = IWL_MAX_NUM_QUEUES; /* def: 16 Tx queues */ 72int iwl4965_param_queues_num = IWL_MAX_NUM_QUEUES; /* def: 16 Tx queues */
73int iwl4965_param_amsdu_size_8K; /* def: enable 8K amsdu size */
73 74
74/* 75/*
75 * module name, copyright, version, etc. 76 * module name, copyright, version, etc.
@@ -3263,7 +3264,7 @@ void iwl4965_handle_data_packet_monitor(struct iwl4965_priv *priv,
3263 __le16 phy_flags_hw = cpu_to_le16(phy_flags); 3264 __le16 phy_flags_hw = cpu_to_le16(phy_flags);
3264 3265
3265 /* We received data from the HW, so stop the watchdog */ 3266 /* We received data from the HW, so stop the watchdog */
3266 if (len > IWL_RX_BUF_SIZE - sizeof(*iwl4965_rt)) { 3267 if (len > priv->hw_setting.rx_buf_size - sizeof(*iwl4965_rt)) {
3267 IWL_DEBUG_DROP("Dropping too large packet in monitor\n"); 3268 IWL_DEBUG_DROP("Dropping too large packet in monitor\n");
3268 return; 3269 return;
3269 } 3270 }
@@ -4506,7 +4507,8 @@ static void iwl4965_rx_allocate(struct iwl4965_priv *priv)
4506 4507
4507 /* Alloc a new receive buffer */ 4508 /* Alloc a new receive buffer */
4508 rxb->skb = 4509 rxb->skb =
4509 alloc_skb(IWL_RX_BUF_SIZE, __GFP_NOWARN | GFP_ATOMIC); 4510 alloc_skb(priv->hw_setting.rx_buf_size,
4511 __GFP_NOWARN | GFP_ATOMIC);
4510 if (!rxb->skb) { 4512 if (!rxb->skb) {
4511 if (net_ratelimit()) 4513 if (net_ratelimit())
4512 printk(KERN_CRIT DRV_NAME 4514 printk(KERN_CRIT DRV_NAME
@@ -4522,7 +4524,7 @@ static void iwl4965_rx_allocate(struct iwl4965_priv *priv)
4522 /* Get physical address of RB/SKB */ 4524 /* Get physical address of RB/SKB */
4523 rxb->dma_addr = 4525 rxb->dma_addr =
4524 pci_map_single(priv->pci_dev, rxb->skb->data, 4526 pci_map_single(priv->pci_dev, rxb->skb->data,
4525 IWL_RX_BUF_SIZE, PCI_DMA_FROMDEVICE); 4527 priv->hw_setting.rx_buf_size, PCI_DMA_FROMDEVICE);
4526 list_add_tail(&rxb->list, &rxq->rx_free); 4528 list_add_tail(&rxb->list, &rxq->rx_free);
4527 rxq->free_count++; 4529 rxq->free_count++;
4528 } 4530 }
@@ -4565,7 +4567,8 @@ static void iwl4965_rx_queue_free(struct iwl4965_priv *priv, struct iwl4965_rx_q
4565 if (rxq->pool[i].skb != NULL) { 4567 if (rxq->pool[i].skb != NULL) {
4566 pci_unmap_single(priv->pci_dev, 4568 pci_unmap_single(priv->pci_dev,
4567 rxq->pool[i].dma_addr, 4569 rxq->pool[i].dma_addr,
4568 IWL_RX_BUF_SIZE, PCI_DMA_FROMDEVICE); 4570 priv->hw_setting.rx_buf_size,
4571 PCI_DMA_FROMDEVICE);
4569 dev_kfree_skb(rxq->pool[i].skb); 4572 dev_kfree_skb(rxq->pool[i].skb);
4570 } 4573 }
4571 } 4574 }
@@ -4616,7 +4619,8 @@ void iwl4965_rx_queue_reset(struct iwl4965_priv *priv, struct iwl4965_rx_queue *
4616 if (rxq->pool[i].skb != NULL) { 4619 if (rxq->pool[i].skb != NULL) {
4617 pci_unmap_single(priv->pci_dev, 4620 pci_unmap_single(priv->pci_dev,
4618 rxq->pool[i].dma_addr, 4621 rxq->pool[i].dma_addr,
4619 IWL_RX_BUF_SIZE, PCI_DMA_FROMDEVICE); 4622 priv->hw_setting.rx_buf_size,
4623 PCI_DMA_FROMDEVICE);
4620 priv->alloc_rxb_skb--; 4624 priv->alloc_rxb_skb--;
4621 dev_kfree_skb(rxq->pool[i].skb); 4625 dev_kfree_skb(rxq->pool[i].skb);
4622 rxq->pool[i].skb = NULL; 4626 rxq->pool[i].skb = NULL;
@@ -4750,7 +4754,7 @@ static void iwl4965_rx_handle(struct iwl4965_priv *priv)
4750 rxq->queue[i] = NULL; 4754 rxq->queue[i] = NULL;
4751 4755
4752 pci_dma_sync_single_for_cpu(priv->pci_dev, rxb->dma_addr, 4756 pci_dma_sync_single_for_cpu(priv->pci_dev, rxb->dma_addr,
4753 IWL_RX_BUF_SIZE, 4757 priv->hw_setting.rx_buf_size,
4754 PCI_DMA_FROMDEVICE); 4758 PCI_DMA_FROMDEVICE);
4755 pkt = (struct iwl4965_rx_packet *)rxb->skb->data; 4759 pkt = (struct iwl4965_rx_packet *)rxb->skb->data;
4756 4760
@@ -4803,7 +4807,8 @@ static void iwl4965_rx_handle(struct iwl4965_priv *priv)
4803 } 4807 }
4804 4808
4805 pci_unmap_single(priv->pci_dev, rxb->dma_addr, 4809 pci_unmap_single(priv->pci_dev, rxb->dma_addr,
4806 IWL_RX_BUF_SIZE, PCI_DMA_FROMDEVICE); 4810 priv->hw_setting.rx_buf_size,
4811 PCI_DMA_FROMDEVICE);
4807 spin_lock_irqsave(&rxq->lock, flags); 4812 spin_lock_irqsave(&rxq->lock, flags);
4808 list_add_tail(&rxb->list, &priv->rxq.rx_used); 4813 list_add_tail(&rxb->list, &priv->rxq.rx_used);
4809 spin_unlock_irqrestore(&rxq->lock, flags); 4814 spin_unlock_irqrestore(&rxq->lock, flags);
@@ -9523,6 +9528,8 @@ MODULE_PARM_DESC(queues_num, "number of hw queues.");
9523/* QoS */ 9528/* QoS */
9524module_param_named(qos_enable, iwl4965_param_qos_enable, int, 0444); 9529module_param_named(qos_enable, iwl4965_param_qos_enable, int, 0444);
9525MODULE_PARM_DESC(qos_enable, "enable all QoS functionality"); 9530MODULE_PARM_DESC(qos_enable, "enable all QoS functionality");
9531module_param_named(amsdu_size_8K, iwl4965_param_amsdu_size_8K, int, 0444);
9532MODULE_PARM_DESC(amsdu_size_8K, "enable 8K amsdu size");
9526 9533
9527module_exit(iwl4965_exit); 9534module_exit(iwl4965_exit);
9528module_init(iwl4965_init); 9535module_init(iwl4965_init);