From: Paul Barker <paul.barker@sancloud.com>
To: Lokesh Vutla <lokeshvutla@ti.com>
Cc: Tom Rini <trini@konsulko.com>,
Peter Robinson <pbrobinson@gmail.com>, <u-boot@lists.denx.de>
Subject: Re: [PATCH v2 5/5] configs: am335x_evm: Fix BeagleBone Green DTB selection
Date: Wed, 21 Jul 2021 07:40:06 +0100 [thread overview]
Message-ID: <20210721074006.6c96999d.paul.barker@sancloud.com> (raw)
In-Reply-To: <17e3ec01-dd6a-e79e-4afe-900ddb56d3f9@ti.com>
[-- Attachment #1: Type: text/plain, Size: 2406 bytes --]
On Wed, 21 Jul 2021 11:29:04 +0530
Lokesh Vutla <lokeshvutla@ti.com> wrote:
> On 20/07/21 1:49 pm, Paul Barker wrote:
> > On Tue, 13 Jul 2021 11:59:06 +0530
> > Lokesh Vutla <lokeshvutla@ti.com> wrote:
> >
> >> On 13/07/21 1:44 am, Paul Barker wrote:
> >>> The function board_is_bone_lt() returns true for the BeagleBone Green,
> >>> the BeagleBone Enhanced and the BeagleBone Black. Therefore when
> >>> selecting which devicetree to use we must ensure that the more specific
> >>> functions board_is_bbg1() and board_is_bben() are checked first
> >>> otherwise all three devices would end up using the am335x-boneblack
> >>> devicetree. This can be achieved by placing the relevant devicetree
> >>> names (am335x-sancloud-bbe and am335x-bonegreen) before am335x-boneblack
> >>> in CONFIG_OF_LIST.
> >>
> >> Such restrictions should be handled inside board_fit_config_name_match() and
> >> hiden from user configuration. Can you update the board_fit_config_name_match()
> >> instead of updating defconfig?
> >
> > Hi Lokesh,
> >
> > Apologies for the late reply, I lost most of last week due to illness.
> >
> > I first attempted to fix this by changing the order of things in
> > `board_fit_config_name_match` but it had no effect. Looking at
> > `fit_find_config_node` in `common/common_fit.c`, we loop through the
> > list of dtbs and check each one in turn for a match. So to move
> > am335x-bonegreen ahead of am335x-boneblack we need to change the order
> > in which the dtbs are checked in `fit_find_config_node`. The simplest
> > way I could find to do that is to change the order of the names in
> > CONFIG_OF_LIST.
>
> ahh..ok got it. But still such constraints in config file is most likely will
> not be maintained in future when someone touching the config. Because not
> everyone knows this.
>
> Is it possible to create a new macro which is true only for bbb and use it
> instead in board_fit_config_name_match?
I'm happy to have a look for an alternative solution like that. The
patch here is a quick fix though that can be applied as-is. Perhaps we
should apply this and also look for an alternative implementation of
`board_is_bone_lt`.
If you want to leave this patch out for now, can we move ahead and
merge the other patches in this series?
Thanks,
--
Paul Barker
Principal Software Engineer
SanCloud Ltd
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
next prev parent reply other threads:[~2021-07-21 6:40 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-07-12 20:14 [PATCH v2 0/5] Resync BeagleBone dtbs, add SanCloud BBE support & minor fixups Paul Barker
2021-07-12 20:14 ` [PATCH v2 1/5] dt-bindings: Resync omap & am33xx pinctrl bindings Paul Barker
2021-07-12 20:14 ` [PATCH v2 2/5] arm: dts: Resync BeagleBone device trees Paul Barker
2021-07-12 20:14 ` [PATCH v2 3/5] arm: dts: Import am335x-sancloud-bbe devicetree Paul Barker
2021-07-12 20:14 ` [PATCH v2 4/5] configs: am335x_evm: Support GbE PHYs Paul Barker
2021-07-12 20:14 ` [PATCH v2 5/5] configs: am335x_evm: Fix BeagleBone Green DTB selection Paul Barker
2021-07-13 6:29 ` Lokesh Vutla
2021-07-20 8:19 ` Paul Barker
2021-07-21 5:59 ` Lokesh Vutla
2021-07-21 6:40 ` Paul Barker [this message]
2021-07-26 7:11 ` Lokesh Vutla
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=20210721074006.6c96999d.paul.barker@sancloud.com \
--to=paul.barker@sancloud.com \
--cc=lokeshvutla@ti.com \
--cc=pbrobinson@gmail.com \
--cc=trini@konsulko.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