summaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/renesas/sh_eth.h
diff options
context:
space:
mode:
authorMitsuhiro Kimura <mitsuhiro.kimura.kc@renesas.com>2014-11-27 20:34:00 +0900
committerDavid S. Miller <davem@davemloft.net>2014-11-29 21:09:38 -0800
commit4d6a949c62f123569fb355b6ec7f314b76f93735 (patch)
tree0d0a4d141ac1a69b4d021dc56c7a5249662d7114 /drivers/net/ethernet/renesas/sh_eth.h
parente0ebde0e131b529fd721b24f62872def5ec3718c (diff)
sh_eth: Fix skb alloc size and alignment adjust rule.
In the current driver, allocation size of skb does not care the alignment adjust after allocation. And also, in the current implementation, buffer alignment method by sh_eth_set_receive_align function has a bug that this function displace buffer start address forcedly when the alignment is corrected. In the result, tail of the skb will exceed allocated area and kernel panic will be occurred. This patch fix this issue. Signed-off-by: Mitsuhiro Kimura <mitsuhiro.kimura.kc@renesas.com> Signed-off-by: Yoshihiro Kaneko <ykaneko0929@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/renesas/sh_eth.h')
-rw-r--r--drivers/net/ethernet/renesas/sh_eth.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/ethernet/renesas/sh_eth.h b/drivers/net/ethernet/renesas/sh_eth.h
index b37c427144ee..9fa93321d512 100644
--- a/drivers/net/ethernet/renesas/sh_eth.h
+++ b/drivers/net/ethernet/renesas/sh_eth.h
@@ -162,9 +162,9 @@ enum {
/* Driver's parameters */
#if defined(CONFIG_CPU_SH4) || defined(CONFIG_ARCH_SHMOBILE)
-#define SH4_SKB_RX_ALIGN 32
+#define SH_ETH_RX_ALIGN 32
#else
-#define SH2_SH3_SKB_RX_ALIGN 2
+#define SH_ETH_RX_ALIGN 2
#endif
/* Register's bits