All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jaedon Shin <jaedon.shin@gmail.com>
To: Florian Fainelli <f.fainelli@gmail.com>
Cc: Ralf Baechle <ralf@linux-mips.org>,
	Jonas Gorski <jonas.gorski@gmail.com>,
	Kevin Cernekee <cernekee@gmail.com>,
	Rob Herring <robh+dt@kernel.org>,
	MIPS Mailing List <linux-mips@linux-mips.org>
Subject: Re: [v3 4/5] MIPS: BMIPS: Add support NAND device nodes
Date: Tue, 16 Aug 2016 19:51:34 +0900	[thread overview]
Message-ID: <89CBA8CF-E399-4CA1-9493-E9310A978CC6@gmail.com> (raw)
In-Reply-To: <947152ab-0a28-365d-4fd9-eb84cdfd2147@gmail.com>

Hi Florian,

On Aug 13, 2016, at 8:17 AM, Florian Fainelli <f.fainelli@gmail.com> wrote:
> 
> On 08/12/2016 01:52 AM, Jaedon Shin wrote:
>> Adds NAND device nodes to BCM7xxx MIPS based SoCs.
>> 
>> Signed-off-by: Jaedon Shin <jaedon.shin@gmail.com>
>> ---
> 
> I did not check all the reference boards, but for 7425 and 7435 here is
> what you should have:
> 
>> diff --git a/arch/mips/boot/dts/brcm/bcm97425svmb.dts b/arch/mips/boot/dts/brcm/bcm97425svmb.dts
>> index 1c6b74daef56..3b917cac7efe 100644
>> --- a/arch/mips/boot/dts/brcm/bcm97425svmb.dts
>> +++ b/arch/mips/boot/dts/brcm/bcm97425svmb.dts
>> @@ -1,6 +1,7 @@
>> /dts-v1/;
>> 
>> /include/ "bcm7425.dtsi"
>> +/include/ "bcm97xxx-nand-cs1-bch8.dtsi"
>> 
>> / {
>> 	compatible = "brcm,bcm97425svmb", "brcm,bcm7425";
>> @@ -95,6 +96,10 @@
>> 	status = "okay";
>> };
>> 
>> +&nand {
>> +	status = "okay";
>> +};
> 
> Here are the correct properties for our BCM97425SVMB board:
> 
> &nand {
>        status = "okay";
> 
>        nandcs@1 {
>                #size-cells = <0x2>;
>                #address-cells = <0x2>;
>                compatible = "brcm,nandcs";
>                reg = <0x1>;
>                nand-on-flash-bbt;
> 
>                nand-ecc-strength = <24>;
>                nand-ecc-step-size = <1024>;
>                brcm,nand-oob-sector-size = <27>;
> 
>> +
>> &sdhci0 {
>> 	status = "okay";
>> };
>> diff --git a/arch/mips/boot/dts/brcm/bcm97435svmb.dts b/arch/mips/boot/dts/brcm/bcm97435svmb.dts
>> index 64bb1988dbc8..54351e54ff68 100644
>> --- a/arch/mips/boot/dts/brcm/bcm97435svmb.dts
>> +++ b/arch/mips/boot/dts/brcm/bcm97435svmb.dts
>> @@ -1,6 +1,7 @@
>> /dts-v1/;
>> 
>> /include/ "bcm7435.dtsi"
>> +/include/ "bcm97xxx-nand-cs1-bch8.dtsi"
> 
> And here are those for the BCM97435SVMB:
> 
> &nand {
>        status = "okay";
> 
>        nandcs@1 {
>                #size-cells = <0x2>;
>                #address-cells = <0x2>;
>                compatible = "brcm,nandcs";
>                reg = <0x1>;
>                nand-on-flash-bbt;
> 
>                nand-ecc-strength = <24>;
>                nand-ecc-step-size = <1024>;
>                brcm,nand-oob-sector-size = <27>;
> 
> -- 
> Florian

I found sample boot logs on CFE.

BCM7346, BCM7425 and BCM7435 have 32Gb (MT29F32G08CBCA) or 16Gb NAND flash, this is
  nand-ecc-strength = <24>;
  nand-ecc-step-size = <1024>;
  brcm,nand-oob-sector-size = <27>;

BCM7358 and BCM7362 have 8Gb(MT29F8G08ABABA) or 2Gb NAND flash, this is
  nand-ecc-strength = <4>;
  nand-ecc-step-size = <512>;
  brcm,nand-oob-sector-size = <16>;

BCM7360 hasn't NAND flash.

So, I will split into two files like bellow,
  bcm97xxx-nand-cs1-bch24.dtsi
  bcm97xxx-nand-cs1-bch4.dtsi

Please let me know if you have better way.

Thanks,
Jaedon

  reply	other threads:[~2016-08-16 10:51 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-08-12  8:52 [v3 0/5] Add device nodes for BCM7xxx SoCs Jaedon Shin
2016-08-12  8:52 ` [v3 1/5] MIPS: BMIPS: Add support PWM device nodes Jaedon Shin
2016-08-12 23:14   ` Florian Fainelli
2016-08-12  8:52 ` [v3 2/5] MIPS: BMIPS: Add support GPIO " Jaedon Shin
2016-08-12  8:52 ` [v3 3/5] MIPS: BMIPS: Add support SDHCI " Jaedon Shin
2016-08-12 23:24   ` Florian Fainelli
2016-08-16 10:51     ` Jaedon Shin
2016-08-16 10:51       ` Jaedon Shin
2016-08-12  8:52 ` [v3 4/5] MIPS: BMIPS: Add support NAND " Jaedon Shin
2016-08-12 23:17   ` Florian Fainelli
2016-08-16 10:51     ` Jaedon Shin [this message]
2016-08-12  8:52 ` [v3 5/5] MIPS: BMIPS: Use interrupt-controller node name Jaedon Shin
2016-08-12 10:51 ` [v3 0/5] Add device nodes for BCM7xxx SoCs Jonas Gorski
2016-08-12 12:19   ` Jaedon Shin
2016-08-12 12:23     ` Jonas Gorski
2016-08-12 13:02       ` Jaedon Shin

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=89CBA8CF-E399-4CA1-9493-E9310A978CC6@gmail.com \
    --to=jaedon.shin@gmail.com \
    --cc=cernekee@gmail.com \
    --cc=f.fainelli@gmail.com \
    --cc=jonas.gorski@gmail.com \
    --cc=linux-mips@linux-mips.org \
    --cc=ralf@linux-mips.org \
    --cc=robh+dt@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.