Search Linux Wireless

[PATCH 2/3] wl12xx/wl18xx: limit base for aggregate buffer size to 4K

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



WL{12,18}XX_AGGR_BUFFER_SIZE is depends on PAGE_SIZE which may be more
than 4K. In this case memory might be aggressively wasted.

Use 4K size base for buffer explicitly.

Signed-off-by: Vladimir Murzin <murzin.v@xxxxxxxxx>
---
 drivers/net/wireless/ti/wl12xx/wl12xx.h |    3 ++-
 drivers/net/wireless/ti/wl18xx/wl18xx.h |    3 ++-
 2 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/drivers/net/wireless/ti/wl12xx/wl12xx.h b/drivers/net/wireless/ti/wl12xx/wl12xx.h
index 9e5484a..3649d40 100644
--- a/drivers/net/wireless/ti/wl12xx/wl12xx.h
+++ b/drivers/net/wireless/ti/wl12xx/wl12xx.h
@@ -56,7 +56,8 @@
 #define WL128X_SUBTYPE_MR_VER	WLCORE_FW_VER_IGNORE
 #define WL128X_MINOR_MR_VER	42
 
-#define WL12XX_AGGR_BUFFER_SIZE	(4 * PAGE_SIZE)
+#define WL12XX_PAGE_SIZE	4096
+#define WL12XX_AGGR_BUFFER_SIZE	(4 * WL12XX_PAGE_SIZE)
 
 #define WL12XX_NUM_TX_DESCRIPTORS 16
 #define WL12XX_NUM_RX_DESCRIPTORS 8
diff --git a/drivers/net/wireless/ti/wl18xx/wl18xx.h b/drivers/net/wireless/ti/wl18xx/wl18xx.h
index 9204e07..a3214b4 100644
--- a/drivers/net/wireless/ti/wl18xx/wl18xx.h
+++ b/drivers/net/wireless/ti/wl18xx/wl18xx.h
@@ -33,7 +33,8 @@
 
 #define WL18XX_CMD_MAX_SIZE          740
 
-#define WL18XX_AGGR_BUFFER_SIZE		(13 * PAGE_SIZE)
+#define WL18XX_PAGE_SIZE		4096
+#define WL18XX_AGGR_BUFFER_SIZE		(13 * WL18XX_PAGE_SIZE)
 
 #define WL18XX_NUM_TX_DESCRIPTORS 32
 #define WL18XX_NUM_RX_DESCRIPTORS 32
-- 
1.7.10.4

--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux