ZYNQ NIC DMAエラーの問題

1743 ワード

エラー:
macb e000b000.ethernet eth0: DMA bus error: HRESP not OK

分析:
DMAは、0 x 00080000未満のメモリアドレスに存在するデータを転送するとエラーが発生します.Zynq-7000リファレンスマニュアル(UG 585)によれば、DMAは、0 x 00000000~0 x 007 ffffのアドレス範囲(0 x 00000000~0 x 003 ffffのアドレス範囲:アドレスはSCUによってフィルタリングされ、OCMは高さにマッピングされる)にアクセスすべきではない.
解決:linux-xlnx-xilinx-v 2016を開く.4\arch\arm\mach-zynq\common.cアドレスを0 x 80000に変更する.
/**
 * zynq_memory_init - Initialize special memory
 *
 * We need to stop things allocating the low memory as DMA can't work in
 * the 1st 512K of memory.
 */
static void __init zynq_memory_init(void)
{
	if (!__pa(PAGE_OFFSET))
         memblock_reserve(__pa(PAGE_OFFSET), 0x80000);
         //memblock_reserve(__pa(PAGE_OFFSET),__pa(swapper_pg_dir));
}