From: York Sun <yorksun@freescale.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [RFC] RFC: convert MPC8536DS to use generic board
Date: Sat, 26 Apr 2014 09:36:47 -0700 [thread overview]
Message-ID: <535BE09F.80005@freescale.com> (raw)
In-Reply-To: <20140426092205.4A4C43801AC@gemini.denx.de>
On 04/26/2014 02:22 AM, Wolfgang Denk wrote:
> Dear York Sun,
>
> In message <1398474623-4709-1-git-send-email-yorksun@freescale.com> you wrote:
>>
>> Add #ifdef CONFIG_OF_CONTROL for reserve_fdt(), setup_fdt(), reloc_fdt().
>
> This looks wrong to me. This is a global file, and you are affecting
> a ton of unrelated boards.
Understood it is a global file. These functions deal with FDT. They should not
be in the path if targets don't use device tree to configure their devices. If
there is another more appropriate macro to use, please let me know. Take the
example I used, MPC8536DS, the gd->fdt_blob would have incorrect value because
it doesn't use device tree.
>
>> Set initial value for gd. Powerpc SoCs use locked cache as init RAM.
>
> Well, some of them do, not all.
arch/powerpc/lib/board.c uses this way. I presume it is safe to use for all PPC
parts.nn
>
>> Change return value for mac_read_from_eeprom() when mismatch happens to
>> prevent calling hang().
>
> You mean, you just ignore the error? This is a change of the cpolicy
> that has nothing to do with generic board support, right? Why should
> this be done now, i. e. why has it been accepted and considered to be
> working before?
This function is helpful but not critical. If reading fails, the board should
continue to boot then users will have a chance to fix it. The new generic board
treats this as other functions in board_init_r. Any error will cause hanging.
>
>> board/freescale/common/sys_eeprom.c | 2 +-
>> common/board_f.c | 18 +++++++++++++++++-
>> include/configs/MPC8536DS.h | 2 ++
>> 3 files changed, 20 insertions(+), 2 deletions(-)
>
> I think thease are at least 2, eventually 3 independent changes. You
> should split them in several commits.
Again, this patch is for discussion. Once we are clear what we should fix, I
will generate appropriate patch set.
>
>> +#ifdef CONFIG_PPC
>> + gd = (gd_t *) (CONFIG_SYS_INIT_RAM_ADDR + CONFIG_SYS_GBL_DATA_OFFSET);
>> + __asm__ __volatile__("":::"memory");
>> +#endif
>
> Again, this is a global change. Why is this now needed?
>
It has been this way for powerpc. Do we have an alternative?
York
next prev parent reply other threads:[~2014-04-26 16:36 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-04-26 1:10 [U-Boot] [RFC] RFC: convert MPC8536DS to use generic board York Sun
2014-04-26 9:22 ` Wolfgang Denk
2014-04-26 16:36 ` York Sun [this message]
2014-04-26 19:36 ` Wolfgang Denk
2014-04-29 23:18 ` Scott Wood
2014-04-26 20:18 ` Simon Glass
2014-04-29 23:12 ` Scott Wood
2014-04-30 18:21 ` York Sun
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=535BE09F.80005@freescale.com \
--to=yorksun@freescale.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox