浏览代码

xilinx_emaclite buffer overrun

Patch to fix buffer allocation size and alignment. Buffer needs to be u32 aligned and
PKTSIZE_ALIGN bytes long.

Acked-by: Michal Simek <monstr@monstr.eu>

Signed-off-by: Ben Warren <biggerbadderben@gmail.com>
Clive Stubbings 16 年之前
父节点
当前提交
f2a7806fc2
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      drivers/net/xilinx_emaclite.c

+ 1 - 1
drivers/net/xilinx_emaclite.c

@@ -70,7 +70,7 @@ typedef struct {
 
 static xemaclite emaclite;
 
-static char etherrxbuff[PKTSIZE_ALIGN/4]; /* Receive buffer */
+static u32 etherrxbuff[PKTSIZE_ALIGN/4]; /* Receive buffer */
 
 /* hardcoded MAC address for the Xilinx EMAC Core when env is nowhere*/
 #ifdef CONFIG_ENV_IS_NOWHERE