public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Stephen Warren <swarren@wwwdotorg.org>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 8/8] dm: core: abolish u-boot, dm-pre-reloc property
Date: Thu, 20 Nov 2014 10:16:01 -0700	[thread overview]
Message-ID: <546E21D1.8020606@wwwdotorg.org> (raw)
In-Reply-To: <CAPnjgZ2C4sjF=9LuUdTD4g09vQZtN_7Z6BfYHucEnq2zBpB11g@mail.gmail.com>

On 11/20/2014 09:44 AM, Simon Glass wrote:
> Hi Masahiro,
>
> On 19 November 2014 09:21, Masahiro Yamada <yamada.m@jp.panasonic.com> wrote:
>> Hi Simon,
>>
>>
>>
>> On Tue, 18 Nov 2014 14:37:33 +0000
>> Simon Glass <sjg@chromium.org> wrote:
>>
>>> Hi Masahiro,
>>>
>>> On 18 November 2014 12:51, Masahiro Yamada <yamada.m@jp.panasonic.com> wrote:
>>>> Hi Simon,
>>>>
>>>>
>>>>
>>>> On Mon, 17 Nov 2014 18:17:43 +0000
>>>> Simon Glass <sjg@chromium.org> wrote:
>>>>
>>>>> Hi Masahiro,
>>>>>
>>>>> On 17 November 2014 08:19, Masahiro Yamada <yamada.m@jp.panasonic.com> wrote:
>>>>>> The driver model provides two ways to pass the device information,
>>>>>> platform data and device tree.  Either way works to bind devices and
>>>>>> drivers, but there is inconsistency in terms of how to pass the
>>>>>> pre-reloc flag.
>>>>>>
>>>>>> In the platform data way, the pre-reloc DM scan checks if each driver
>>>>>> has DM_FLAG_PRE_RELOC flag (this was changed to use U_BOOT_DRIVER_F
>>>>>> just before).  That is, each **driver** has the pre-reloc attribute.
>>>>>>
>>>>>> In the device tree control, the existence of "u-boot,dm-pre-reloc" is
>>>>>> checked for each device node.  The driver flag "DM_FLAG_PRE_RELOC" is
>>>>>> never checked.  That is, each **device** owns the pre-reloc attribute.
>>>>>>
>>>>>> Drivers should generally work both with platform data and device tree,
>>>>>> but this inconsistency has made our life difficult.
>>>>>
>>>>> I feel we should use device tree where available, and only fall back
>>>>> to platform data when necessary (no device tree available for
>>>>> platform, for example).
>>>>
>>>> No, it is true that device tree is a useful tool, but it should be optional.
>>>>
>>>> All the infrastructures of drivers must work perfectly without device tree.
>>>>
>>>> The device tree is just one choice of how to give device information.
>>>>
>>>
>>> Which platform(s) are we talking about here?
>>
>>
>> I am talking about the general design policy of drivers
>> in U-Boot and Linux.
>
> Well Linux has moved away from platform data, right?

As a blanket statement, that isn't true.

Some architectures (e.g. ARM) have moved to DT. That move is something 
done by the ARM maintainers, not something that's necessarily being 
forced upon every single architecture. I know of no move to force 
everyone to convert to DT.

What makes sense for Linux doesn't always make sense for everything else 
anyway.

In my opinion, DT in Linux isn't actually doing much that's useful, and 
DT in a boot loader is likely to be even less useful.

  reply	other threads:[~2014-11-20 17:16 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-17  8:19 [U-Boot] [PATCH 0/8] dm: core: abolish "u-boot, dm-pre-reloc" property and various refactorings Masahiro Yamada
2014-11-17  8:19 ` [U-Boot] [PATCH 1/8] dm: core: a trivial clean up Masahiro Yamada
2014-11-17  9:08   ` Simon Glass
2014-11-23 13:00     ` Simon Glass
2014-11-17  8:19 ` [U-Boot] [PATCH 2/8] dm: core: remove meaningless if conditional Masahiro Yamada
2014-11-17  9:14   ` Simon Glass
2014-11-17 11:19     ` Masahiro Yamada
2014-11-17 18:23       ` Simon Glass
2014-11-23 13:00         ` Simon Glass
2014-11-17  8:19 ` [U-Boot] [PATCH 3/8] dm: core: remove unnecessary return condition in driver lookup Masahiro Yamada
2014-11-17  9:14   ` Simon Glass
2014-11-23 13:00     ` Simon Glass
2014-11-17  8:19 ` [U-Boot] [PATCH 4/8] dm: core: remove unnecessary return condition in uclass lookup Masahiro Yamada
2014-11-17  9:16   ` Simon Glass
2014-11-23 13:00     ` Simon Glass
2014-11-17  8:19 ` [U-Boot] [PATCH 5/8] dm: core: refactor linker lists lookup code Masahiro Yamada
2014-11-17  9:18   ` Simon Glass
2014-11-17  8:19 ` [U-Boot] [PATCH 6/8] dm: core: look up drivers more efficiently Masahiro Yamada
2014-11-17  9:22   ` Simon Glass
2014-11-17 11:49     ` Masahiro Yamada
2014-11-17 18:25       ` Simon Glass
2014-11-17  8:19 ` [U-Boot] [PATCH 7/8] dm: core: declare pre-reloc drivers with U_BOOT_DRIVER_F Masahiro Yamada
2014-11-17  9:24   ` Simon Glass
2014-11-17  8:19 ` [U-Boot] [PATCH 8/8] dm: core: abolish u-boot, dm-pre-reloc property Masahiro Yamada
2014-11-17 18:17   ` Simon Glass
2014-11-18 12:51     ` Masahiro Yamada
2014-11-18 14:37       ` Simon Glass
2014-11-19  9:21         ` Masahiro Yamada
2014-11-20 16:44           ` Simon Glass
2014-11-20 17:16             ` Stephen Warren [this message]
2014-11-21  9:59             ` Masahiro Yamada
2014-11-24 22:29               ` Simon Glass
2014-11-25  3:18                 ` Masahiro Yamada
2014-11-26 20:54                   ` 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=546E21D1.8020606@wwwdotorg.org \
    --to=swarren@wwwdotorg.org \
    --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