From: hs@denx•de (Heiko Schocher)
To: linux-arm-kernel@lists•infradead.org
Subject: [PATCH v6] ARM: mtd: nand: davinci: add OF support for davinci nand controller
Date: Thu, 03 Jan 2013 08:03:02 +0100 [thread overview]
Message-ID: <50E52D26.9010004@denx.de> (raw)
In-Reply-To: <50E48DFD.2030908@mvista.com>
Hello Sergei,
On 02.01.2013 20:43, Sergei Shtylyov wrote:
> Hello.
>
> On 07/30/2012 11:22 AM, Heiko Schocher wrote:
>
>> add OF support for the davinci nand controller.
>
>> Signed-off-by: Heiko Schocher<hs@denx•de>
>> Cc: davinci-linux-open-source at linux.davincidsp.com
>> Cc: linux-arm-kernel at lists.infradead.org
>> Cc: devicetree-discuss at lists.ozlabs.org
>> Cc: linux-mtd at lists.infradead.org
>> Cc: David Woodhouse<dwmw2@infradead•org>
>> Cc: Grant Likely<grant.likely@secretlab•ca>
>> Cc: Sekhar Nori<nsekhar@ti•com>
>> Cc: Wolfgang Denk<wd@denx•de>
>> Cc: Scott Wood<scottwood@freescale•com>
>
> [...]
>
>> diff --git a/drivers/mtd/nand/davinci_nand.c b/drivers/mtd/nand/davinci_nand.c
>> index d94b03c..f386b3c 100644
>> --- a/drivers/mtd/nand/davinci_nand.c
>> +++ b/drivers/mtd/nand/davinci_nand.c
> [...]
>> @@ -518,9 +519,75 @@ static struct nand_ecclayout hwecc4_2048 __initconst = {
>> },
>> };
>>
>> +#if defined(CONFIG_OF)
>> +static const struct of_device_id davinci_nand_of_match[] = {
>> + {.compatible = "ti,davinci-nand", },
>> + {},
>> +}
>
> I have only one question: have you ever try to compile this patch with
> CONFIG_OF enabled? If you have, you would have noticed:
>
> drivers/mtd/nand/davinci_nand.c:527: error: expected ?,? or ?;? before ?extern?
>
>> +MODULE_DEVICE_TABLE(of, davinci_nand_of_match);
Hmm.. maybe this crept in later after I sent the patches? They were
pending for a while ... I compiled it just yet again (based on my
tree when I posted this patch based on commit:
commit 3bf671af14d591ede9251acb0085e8017f3705e7
Merge: 1c212c6 4a5a418
Author: Linus Torvalds <torvalds@linux-foundation•org>
Date: Mon Aug 13 09:59:04 2012 +0300
Merge branch 'fixes-for-3.6' of git://git.kernel.org/pub/scm/linux/kernel/git/cooloney/linux-leds
and it compiled fine:
$ eldk-switch -r 5.2 armv7a
Setup for armv7a (using ELDK 5.2)
$ make -s uImage
arch/arm/kernel/return_address.c:62:2: warning: #warning "TODO: return_address should use unwind tables" [-Wcpp]
arch/arm/kernel/return_address.c:62:2: warning: #warning "TODO: return_address should use unwind tables" [-Wcpp]
arch/arm/mm/alignment.c: In function 'do_alignment':
arch/arm/mm/alignment.c:327:15: warning: 'offset.un' may be used uninitialized in this function [-Wuninitialized]
arch/arm/mm/alignment.c:749:21: note: 'offset.un' was declared here
drivers/mtd/chips/cfi_cmdset_0002.c: In function 'cfi_amdstd_panic_write':
include/linux/mtd/map.h:331:11: warning: 'r.x[0]' may be used uninitialized in this function [-Wuninitialized]
drivers/mtd/chips/cfi_cmdset_0002.c: In function 'cfi_amdstd_write_words':
include/linux/mtd/map.h:331:11: warning: 'r.x[0]' may be used uninitialized in this function [-Wuninitialized]
drivers/mtd/chips/cfi_cmdset_0001.c: In function 'cfi_intelext_write_words':
include/linux/mtd/map.h:331:11: warning: 'r.x[0]' may be used uninitialized in this function [-Wuninitialized]
Kernel: arch/arm/boot/Image is ready
Kernel: arch/arm/boot/zImage is ready
Image Name: Linux-3.6.0-rc1-01880-g0227e8b
Created: Thu Jan 3 06:55:26 2013
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 2432040 Bytes = 2375.04 kB = 2.32 MB
Load Address: c0008000
Entry Point: c0008000
Image arch/arm/boot/uImage is ready
$
$ ${CROSS_COMPILE}gcc --version
arm-linux-gnueabi-gcc (GCC) 4.6.4 20120303 (prerelease)
Copyright (C) 2011 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
$ grep -n CONFIG_OF .config
707:CONFIG_OF=y
713:# CONFIG_OF_SELFTEST is not set
714:CONFIG_OF_FLATTREE=y
715:CONFIG_OF_EARLY_FLATTREE=y
716:CONFIG_OF_ADDRESS=y
717:CONFIG_OF_IRQ=y
718:CONFIG_OF_DEVICE=y
719:CONFIG_OF_I2C=y
720:CONFIG_OF_NET=y
721:CONFIG_OF_MDIO=y
722:CONFIG_OF_MTD=y
1067:CONFIG_OF_GPIO=y
1629:CONFIG_OF_IOMMU=y
$
> No need to worry now, I'll send out the trivial patch...
Thanks!
bye,
Heiko
--
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
next prev parent reply other threads:[~2013-01-03 7:03 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-07-30 7:22 [PATCH v6] ARM: mtd: nand: davinci: add OF support for davinci nand controller Heiko Schocher
2012-08-07 14:34 ` Heiko Schocher
2012-08-07 17:36 ` Sekhar Nori
2012-08-23 15:34 ` Artem Bityutskiy
2013-01-02 19:43 ` Sergei Shtylyov
2013-01-03 7:03 ` Heiko Schocher [this message]
2013-01-03 11:26 ` Sergei Shtylyov
2013-01-03 11:32 ` David Woodhouse
2013-01-03 11:39 ` Sergei Shtylyov
2013-01-03 17:56 ` Sergei Shtylyov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=50E52D26.9010004@denx.de \
--to=hs@denx$(echo .)de \
--cc=linux-arm-kernel@lists$(echo .)infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox