From: Conor Dooley <conor@kernel.org>
To: Evan Green <evan@rivosinc.com>
Cc: linux-sunxi@lists.linux.dev, conor.dooley@microchip.com,
Albert Ou <aou@eecs.berkeley.edu>, Chen-Yu Tsai <wens@csie.org>,
Jernej Skrabec <jernej.skrabec@gmail.com>,
Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
Palmer Dabbelt <palmer@dabbelt.com>,
Paul Walmsley <paul.walmsley@sifive.com>,
Rob Herring <robh+dt@kernel.org>,
Samuel Holland <samuel@sholland.org>,
Trevor Woerner <twoerner@gmail.com>,
devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org, linux-riscv@lists.infradead.org
Subject: Re: [RFC PATCH] riscv: dts: nezha-d1: Add memory
Date: Fri, 31 Mar 2023 19:39:09 +0100 [thread overview]
Message-ID: <25837ca5-b709-4d20-912b-ab13e6353069@spud> (raw)
In-Reply-To: <20230331182727.4062790-1-evan@rivosinc.com>
[-- Attachment #1: Type: text/plain, Size: 1613 bytes --]
On Fri, Mar 31, 2023 at 11:27:27AM -0700, Evan Green wrote:
> Add memory info for the D1 Nezha, which seems to be required for it to
> boot with the stock firmware. Note that this hardcodes 1GB, which is
> not technically correct as they also make models with different amounts
> of RAM.
> Is the firmware supposed to populate this?
Yup. Samuel intentionally did it this way:
https://lore.kernel.org/linux-riscv/8a2194bf-93bd-de4d-8d39-0cd72aabb0a9@sholland.org/
Since I don't like using the firmware provided stuff to more easily
test I do this in my u-boot boot script:
tftp 0x54000000 d1-fitImage.fit
bootm start 0x54000000
bootm loados 0x54000000
bootm ramdisk;
bootm prep;
fdt memory 0x40000000 0x20000000
bootm go;
Hope either of the above are helpful,
Conor.
>
> Signed-off-by: Evan Green <evan@rivosinc.com>
>
> ---
>
> arch/riscv/boot/dts/allwinner/sun20i-d1-nezha.dts | 6 ++++++
> 1 file changed, 6 insertions(+)
>
> diff --git a/arch/riscv/boot/dts/allwinner/sun20i-d1-nezha.dts b/arch/riscv/boot/dts/allwinner/sun20i-d1-nezha.dts
> index 4ed33c1e7c9c..6aba68cf5541 100644
> --- a/arch/riscv/boot/dts/allwinner/sun20i-d1-nezha.dts
> +++ b/arch/riscv/boot/dts/allwinner/sun20i-d1-nezha.dts
> @@ -32,6 +32,12 @@ / {
> model = "Allwinner D1 Nezha";
> compatible = "allwinner,d1-nezha", "allwinner,sun20i-d1";
>
> + // FIXME: this is temporary.
> + memory@40000000 {
> + device_type = "memory";
> + reg = <0x40000000 0x40000000>; /* 1 GB */
> + };
> +
> aliases {
> ethernet0 = &emac;
> ethernet1 = &xr829;
> --
> 2.25.1
>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
next prev parent reply other threads:[~2023-03-31 18:39 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-31 18:27 Evan Green
2023-03-31 18:39 ` Conor Dooley [this message]
2023-03-31 19:02 ` Evan Green
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=25837ca5-b709-4d20-912b-ab13e6353069@spud \
--to=conor@kernel.org \
--cc=aou@eecs.berkeley.edu \
--cc=conor.dooley@microchip.com \
--cc=devicetree@vger.kernel.org \
--cc=evan@rivosinc.com \
--cc=jernej.skrabec@gmail.com \
--cc=krzysztof.kozlowski+dt@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-riscv@lists.infradead.org \
--cc=linux-sunxi@lists.linux.dev \
--cc=palmer@dabbelt.com \
--cc=paul.walmsley@sifive.com \
--cc=robh+dt@kernel.org \
--cc=samuel@sholland.org \
--cc=twoerner@gmail.com \
--cc=wens@csie.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®