All of lore.kernel.org
 help / color / mirror / Atom feed
From: Marek Vasut <marek.vasut@gmail.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 4/4] ARM: renesas: Configure DRAM size from ATF DT fragment
Date: Tue, 12 Mar 2019 22:11:21 +0100	[thread overview]
Message-ID: <6ab7ba1d-df1d-6636-28f7-20817c3d9491@gmail.com> (raw)
In-Reply-To: <CAH3KO=13vYZWog7PkJV8NEGV=2efnqdOUweeSUBqWJmZhe3j2Q@mail.gmail.com>

On 3/12/19 8:30 PM, Eugeniu Rosca wrote:
> Hi Marek cc: Michael

Hi,

> On Tue, Mar 5, 2019 at 4:37 AM Marek Vasut <marek.vasut@gmail.com> wrote:
>>
>> The ATF can pass additional information via the first four registers,
>> x0...x3. The R-Car Gen3 with mainline ATF, register x1 contains pointer
>> to a device tree with platform information. Parse this device tree and
>> extract DRAM size information from it. This is useful on systems where
>> the DRAM size can vary between configurations.
> 
> 1. Do the ATF changes supporting this feature already exist in mainline ATF?

Yes, for quite some time, see
commit 1d85c4bd5b6291b99feb2409525c96f0c1744328
    plat: rcar: Pass DTB with DRAM layout from BL2 to next stages

> 2. I see more DRAM-related compile-time knobs in vanilla ATF:
> ➜  arm-trusted-firmware (c48d02bade88) $ grep "DRAM.*:"
> plat/renesas/rcar/platform.mk
> RCAR_DRAM_SPLIT := 0
> RCAR_DRAM_LPDDR4_MEMCONF :=1
> RCAR_DRAM_DDR3L_MEMCONF :=1
> RCAR_DRAM_DDR3L_MEMDUAL :=1
> RCAR_DRAM_CHANNEL :=15
> 
> My understanding is that these are local to ATF and U-Boot can stay
> agnostic about them?

Yes, although the long term goal is to get rid of those and replace them
with DT configuration too. So ATF BL2 would then parse supplied DT to
figure out the DRAM layout instead of using those knobs.

> IOW, DRAM start and size are totally enough for U-Boot?

No, U-Boot needs to know start/size of each bank. That's what's in the
DT that is passed in, plus a machine compatible string, so technically,
you might be able to build one U-Boot for all boards already, but then
you hit a size limit where the BL33 must be below 1 MiB. I'm looking
into that one too.

-- 
Best regards,
Marek Vasut

  reply	other threads:[~2019-03-12 21:11 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-03-05  3:25 [U-Boot] [PATCH 1/4] lib: fdt: Split fdtdec_setup_mem_size_base() Marek Vasut
2019-03-05  3:25 ` [U-Boot] [PATCH 2/4] lib: fdt: Split fdtdec_setup_memory_banksize() Marek Vasut
2019-03-10 21:51   ` Simon Glass
2019-03-05  3:25 ` [U-Boot] [PATCH 3/4] ARM: renesas: Save boot parameters passed in by ATF Marek Vasut
2019-03-12 18:59   ` Eugeniu Rosca
2019-03-12 19:42     ` Tom Rini
2019-03-12 20:29       ` Eugeniu Rosca
2019-03-12 21:07         ` Marek Vasut
2019-03-05  3:25 ` [U-Boot] [PATCH 4/4] ARM: renesas: Configure DRAM size from ATF DT fragment Marek Vasut
2019-03-12 19:30   ` Eugeniu Rosca
2019-03-12 21:11     ` Marek Vasut [this message]
2019-03-13 15:25       ` Eugeniu Rosca
2019-04-02  3:45         ` Marek Vasut
2019-04-04 13:45           ` Eugeniu Rosca
2019-05-19 22:50             ` Marek Vasut
2019-05-20  7:39               ` Eugeniu Rosca
2019-03-10 21:51 ` [U-Boot] [PATCH 1/4] lib: fdt: Split fdtdec_setup_mem_size_base() Simon Glass

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=6ab7ba1d-df1d-6636-28f7-20817c3d9491@gmail.com \
    --to=marek.vasut@gmail.com \
    --cc=u-boot@lists.denx.de \
    /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.