在使用rt3070wifi驱动的时候,遇到了如下问题:

ERROR: 256 KiB atomic DMA coherent pool is too small!

Please increase it with coherent_pool= kernel parameter!

在网上找了很多资料,都说是linux内核的DMA块太小了,需要修改,使用coherent_pool进行修改,但是一直不知道这个东西在哪修改,能看到的最多的是说修改uEnv.txt,这个东西是什么我不知道,也不知道在哪。也在我的机器里面找了,使用find命令,但是没有找到。

其实coherent_pool就是uboot传给linux内核的内核参数,一般在对应的.h文件会有,比如我的就是在include/configs/sama5d3xek.h文件里面,有个#defined bootargs。只需要修改这个参数就行了,但是增加的位置,好像有要求,我头一次尝试的时候是增加到了最后。结果系统崩溃了ERROR: 256 KiB atomic DMA coherent pool is too small!
Please increase it with coherent_pool= kernel parameter!,给我吓尿了。之后再次鼓起勇气尝试,这次先在uboot的启动界面修改的,把coherent_pool=2M增加到了串口终端定义之后。即console=ttyS0,115200 coherent_pool=2M earlyprintk mtdparts=atmel_nand:1536k(spare)ro,512k(dtb),6M(kernel)ro,-(rootfs) rootfstype=ubifs ubi.mtd=3 root=ubi0:rootfs

在uboot启动界面是如下命令:

setenv bootargs console=ttyS0,115200 coherent_pool=2M earlyprintk mtdparts=atmel_nand:1536k(spare)ro,512k(dtb),6M(kernel)ro,-(rootfs) rootfstype=ubifs ubi.mtd=3 root=ubi0:rootfs

然后重新启动,就ok了。其他的应该同理吧!linux的启动参数实在太多了,搞不懂,到现在也没弄明白如何使用nfs作为ARM启动的根文件系统。请有明白的前辈不吝指点。

更多推荐

如何更改coherent_pool值的大小!