Skip to contentSkip to conversation

net: mvpp2: use cache_line_size() to get cacheline size

PATCH Applied Jisheng Zhang 2 participants 2 messages Apr 1, 2016

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 net: mvpp2: use cache_line_size() to get cacheline size

L1_CACHE_BYTES may not be the real cacheline size, use cache_line_size to determine the cacheline size in runtime.

---
 drivers/net/ethernet/marvell/mvpp2.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/ethernet/marvell/mvpp2.c +1 -1
index 05f358b..23f3c08 100644
@@ -376,7 +376,7 @@
 
 #define MVPP2_RX_PKT_SIZE(mtu) \
 	ALIGN((mtu) + MVPP2_MH_SIZE + MVPP2_VLAN_TAG_LEN + \
-	      ETH_HLEN + ETH_FCS_LEN, L1_CACHE_BYTES)
+	      ETH_HLEN + ETH_FCS_LEN, cache_line_size())
 
 #define MVPP2_RX_BUF_SIZE(pkt_size)	((pkt_size) + NET_SKB_PAD)
 #define MVPP2_RX_TOTAL_SIZE(buf_size)	((buf_size) + MVPP2_SKB_SHINFO_SIZE)
Signature · 1 line
2.8.0.rc3