Passing NAND mtdparts to OMAP2+ Kernel
Adam Ford
aford173 at gmail.com
Wed Mar 29 04:39:00 PDT 2017
On Tue, Mar 28, 2017 at 2:57 PM, Boris Brezillon
<boris.brezillon at free-electrons.com> wrote:
> +Roger and Enrico
>
> On Tue, 28 Mar 2017 10:43:01 -0500
> Adam Ford <aford173 at gmail.com> wrote:
>
>> I posted this on the linux-omap list, and I was asked to post this on
>> the linux-mtd list:
>>
>>
>> I tried to remove the MTD partitions from the Linux device tree, and I
>> noticed that there was no partition information being pushed anymore
>> unless I changed the mtdparts name in U-Boot.
>>
>> It appears as if the MTD drivers have changed a bit. I found a few
>> e-mails floating around that attempt to fix this
>>
>> Commit f7a8e38f07a17be907585 ("mtd: nand: assign reasonable default
>> name for NAND drivers") attempts to address this, and someone over at
>> https://patchwork.ozlabs.org/patch/707065/ attempted to address it as
>> well in a slightly different way.
>
> Can you test the patch and let me know if solves the problem. If it
> does, I'll send a clean version of the patch and queue it for 4.12.
>
I tried to apply the patch directly, but it failed. I then manually
copy-pasted it into the proper place, but it fails to compile.
drivers/mtd/nand/omap2.c: In function ‘omap_nand_probe’:
drivers/mtd/nand/omap2.c:1859:14: error: implicit declaration of
function ‘devm_kasprinf’ [-Werror=implicit-function-declaration]
mtd->name = devm_kasprinf(&pdev->dev, "omap2-nand.%d", info->gpmc_cs);
^~~~~~~~~~~~~
drivers/mtd/nand/omap2.c:1859:12: warning: assignment makes pointer
from integer without a cast [-Wint-conversion]
mtd->name = devm_kasprinf(&pdev->dev, "omap2-nand.%d", info->gpmc_cs);
^
cc1: some warnings being treated as errors
I use buildroot to build my toolchain and I am using gcc version 6.3.0
with glibc 2.24. Is there supposed to be an include somewhere? I am
not familiar with devm_kasprinf.
> Thanks,
Thank you
adam
>
> Boris
More information about the linux-mtd
mailing list