* [PATCH] arm: mvebu: Espressobin: Fix checks against machine compatible strings
@ 2020-09-29 12:34 Andre Heider
2020-09-29 12:38 ` Pali Rohár
2020-10-01 12:37 ` Stefan Roese
0 siblings, 2 replies; 9+ messages in thread
From: Andre Heider @ 2020-09-29 12:34 UTC (permalink / raw)
To: u-boot
The patches changing the compatible strings to the ones used by Linux have
not been merged yet, so fix the checks to use the current in-tree ones.
Reported-by: Pali Roh?r <pali@kernel.org>
Signed-off-by: Andre Heider <a.heider@gmail.com>
---
board/Marvell/mvebu_armada-37xx/board.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/board/Marvell/mvebu_armada-37xx/board.c b/board/Marvell/mvebu_armada-37xx/board.c
index eacee15cb3..2bfc7171c4 100644
--- a/board/Marvell/mvebu_armada-37xx/board.c
+++ b/board/Marvell/mvebu_armada-37xx/board.c
@@ -88,14 +88,14 @@ int board_late_init(void)
if (env_get("fdtfile"))
return 0;
- if (!of_machine_is_compatible("globalscale,espressobin"))
+ if (!of_machine_is_compatible("marvell,armada-3720-espressobin"))
return 0;
/* If the memory controller has been configured for DDR4, we're running on v7 */
ddr4 = ((readl(A3700_CH0_MC_CTRL2_REG) >> A3700_MC_CTRL2_SDRAM_TYPE_OFFS)
& A3700_MC_CTRL2_SDRAM_TYPE_MASK) == A3700_MC_CTRL2_SDRAM_TYPE_DDR4;
- emmc = of_machine_is_compatible("globalscale,espressobin-emmc");
+ emmc = of_machine_is_compatible("marvell,armada-3720-espressobin-emmc");
if (ddr4 && emmc)
env_set("fdtfile", "marvell/armada-3720-espressobin-v7-emmc.dtb");
--
2.28.0
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [PATCH] arm: mvebu: Espressobin: Fix checks against machine compatible strings
2020-09-29 12:34 [PATCH] arm: mvebu: Espressobin: Fix checks against machine compatible strings Andre Heider
@ 2020-09-29 12:38 ` Pali Rohár
2020-09-29 12:41 ` Pali Rohár
2020-09-29 12:43 ` Andre Heider
2020-10-01 12:37 ` Stefan Roese
1 sibling, 2 replies; 9+ messages in thread
From: Pali Rohár @ 2020-09-29 12:38 UTC (permalink / raw)
To: u-boot
On Tuesday 29 September 2020 14:34:26 Andre Heider wrote:
> The patches changing the compatible strings to the ones used by Linux have
> not been merged yet, so fix the checks to use the current in-tree ones.
>
> Reported-by: Pali Roh?r <pali@kernel.org>
> Signed-off-by: Andre Heider <a.heider@gmail.com>
> ---
> board/Marvell/mvebu_armada-37xx/board.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/board/Marvell/mvebu_armada-37xx/board.c b/board/Marvell/mvebu_armada-37xx/board.c
> index eacee15cb3..2bfc7171c4 100644
> --- a/board/Marvell/mvebu_armada-37xx/board.c
> +++ b/board/Marvell/mvebu_armada-37xx/board.c
> @@ -88,14 +88,14 @@ int board_late_init(void)
> if (env_get("fdtfile"))
> return 0;
>
> - if (!of_machine_is_compatible("globalscale,espressobin"))
> + if (!of_machine_is_compatible("marvell,armada-3720-espressobin"))
> return 0;
>
> /* If the memory controller has been configured for DDR4, we're running on v7 */
> ddr4 = ((readl(A3700_CH0_MC_CTRL2_REG) >> A3700_MC_CTRL2_SDRAM_TYPE_OFFS)
> & A3700_MC_CTRL2_SDRAM_TYPE_MASK) == A3700_MC_CTRL2_SDRAM_TYPE_DDR4;
>
> - emmc = of_machine_is_compatible("globalscale,espressobin-emmc");
> + emmc = of_machine_is_compatible("marvell,armada-3720-espressobin-emmc");
I run 'git grep marvell,armada-3720-espressobin-emmc origin/master' just
for verification... but it returned me empty result.
So marvell,armada-3720-espressobin-emmc is not correct too and therefore
this patch does not still fix this problem.
>
> if (ddr4 && emmc)
> env_set("fdtfile", "marvell/armada-3720-espressobin-v7-emmc.dtb");
> --
> 2.28.0
>
^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH] arm: mvebu: Espressobin: Fix checks against machine compatible strings
2020-09-29 12:38 ` Pali Rohár
@ 2020-09-29 12:41 ` Pali Rohár
2020-09-29 12:43 ` Andre Heider
1 sibling, 0 replies; 9+ messages in thread
From: Pali Rohár @ 2020-09-29 12:41 UTC (permalink / raw)
To: u-boot
On Tuesday 29 September 2020 14:38:39 Pali Roh?r wrote:
> On Tuesday 29 September 2020 14:34:26 Andre Heider wrote:
> > The patches changing the compatible strings to the ones used by Linux have
> > not been merged yet, so fix the checks to use the current in-tree ones.
> >
> > Reported-by: Pali Roh?r <pali@kernel.org>
> > Signed-off-by: Andre Heider <a.heider@gmail.com>
> > ---
> > board/Marvell/mvebu_armada-37xx/board.c | 4 ++--
> > 1 file changed, 2 insertions(+), 2 deletions(-)
> >
> > diff --git a/board/Marvell/mvebu_armada-37xx/board.c b/board/Marvell/mvebu_armada-37xx/board.c
> > index eacee15cb3..2bfc7171c4 100644
> > --- a/board/Marvell/mvebu_armada-37xx/board.c
> > +++ b/board/Marvell/mvebu_armada-37xx/board.c
> > @@ -88,14 +88,14 @@ int board_late_init(void)
> > if (env_get("fdtfile"))
> > return 0;
> >
> > - if (!of_machine_is_compatible("globalscale,espressobin"))
> > + if (!of_machine_is_compatible("marvell,armada-3720-espressobin"))
> > return 0;
> >
> > /* If the memory controller has been configured for DDR4, we're running on v7 */
> > ddr4 = ((readl(A3700_CH0_MC_CTRL2_REG) >> A3700_MC_CTRL2_SDRAM_TYPE_OFFS)
> > & A3700_MC_CTRL2_SDRAM_TYPE_MASK) == A3700_MC_CTRL2_SDRAM_TYPE_DDR4;
> >
> > - emmc = of_machine_is_compatible("globalscale,espressobin-emmc");
> > + emmc = of_machine_is_compatible("marvell,armada-3720-espressobin-emmc");
>
> I run 'git grep marvell,armada-3720-espressobin-emmc origin/master' just
> for verification... but it returned me empty result.
>
> So marvell,armada-3720-espressobin-emmc is not correct too and therefore
> this patch does not still fix this problem.
Ok, now I see where is the problem. eMMC support for Espressobin is not
in U-Boot master yet.
So for U-Boot master the best would be to revert/remove this emmc chunk
of code.
> >
> > if (ddr4 && emmc)
> > env_set("fdtfile", "marvell/armada-3720-espressobin-v7-emmc.dtb");
> > --
> > 2.28.0
> >
^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH] arm: mvebu: Espressobin: Fix checks against machine compatible strings
2020-09-29 12:38 ` Pali Rohár
2020-09-29 12:41 ` Pali Rohár
@ 2020-09-29 12:43 ` Andre Heider
2020-10-01 8:23 ` Pali Rohár
1 sibling, 1 reply; 9+ messages in thread
From: Andre Heider @ 2020-09-29 12:43 UTC (permalink / raw)
To: u-boot
On 29/09/2020 14:38, Pali Roh?r wrote:
> On Tuesday 29 September 2020 14:34:26 Andre Heider wrote:
>> The patches changing the compatible strings to the ones used by Linux have
>> not been merged yet, so fix the checks to use the current in-tree ones.
>>
>> Reported-by: Pali Roh?r <pali@kernel.org>
>> Signed-off-by: Andre Heider <a.heider@gmail.com>
>> ---
>> board/Marvell/mvebu_armada-37xx/board.c | 4 ++--
>> 1 file changed, 2 insertions(+), 2 deletions(-)
>>
>> diff --git a/board/Marvell/mvebu_armada-37xx/board.c b/board/Marvell/mvebu_armada-37xx/board.c
>> index eacee15cb3..2bfc7171c4 100644
>> --- a/board/Marvell/mvebu_armada-37xx/board.c
>> +++ b/board/Marvell/mvebu_armada-37xx/board.c
>> @@ -88,14 +88,14 @@ int board_late_init(void)
>> if (env_get("fdtfile"))
>> return 0;
>>
>> - if (!of_machine_is_compatible("globalscale,espressobin"))
>> + if (!of_machine_is_compatible("marvell,armada-3720-espressobin"))
>> return 0;
>>
>> /* If the memory controller has been configured for DDR4, we're running on v7 */
>> ddr4 = ((readl(A3700_CH0_MC_CTRL2_REG) >> A3700_MC_CTRL2_SDRAM_TYPE_OFFS)
>> & A3700_MC_CTRL2_SDRAM_TYPE_MASK) == A3700_MC_CTRL2_SDRAM_TYPE_DDR4;
>>
>> - emmc = of_machine_is_compatible("globalscale,espressobin-emmc");
>> + emmc = of_machine_is_compatible("marvell,armada-3720-espressobin-emmc");
>
> I run 'git grep marvell,armada-3720-espressobin-emmc origin/master' just
> for verification... but it returned me empty result.
>
> So marvell,armada-3720-espressobin-emmc is not correct too and therefore
> this patch does not still fix this problem.
Right, without my set there is no support for the eMMC board in u-boot
at all. We could remove the code, but I figured that'll be just
unnecessary churn. The check evaluates correctly to non-emmc, so it
works for the in-tree board just fine. This is the smaller fixup for the
release.
>
>>
>> if (ddr4 && emmc)
>> env_set("fdtfile", "marvell/armada-3720-espressobin-v7-emmc.dtb");
>> --
>> 2.28.0
>>
^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH] arm: mvebu: Espressobin: Fix checks against machine compatible strings
2020-09-29 12:43 ` Andre Heider
@ 2020-10-01 8:23 ` Pali Rohár
2020-10-01 10:42 ` Heinrich Schuchardt
0 siblings, 1 reply; 9+ messages in thread
From: Pali Rohár @ 2020-10-01 8:23 UTC (permalink / raw)
To: u-boot
On Tuesday 29 September 2020 14:43:25 Andre Heider wrote:
> On 29/09/2020 14:38, Pali Roh?r wrote:
> > On Tuesday 29 September 2020 14:34:26 Andre Heider wrote:
> > > The patches changing the compatible strings to the ones used by Linux have
> > > not been merged yet, so fix the checks to use the current in-tree ones.
> > >
> > > Reported-by: Pali Roh?r <pali@kernel.org>
> > > Signed-off-by: Andre Heider <a.heider@gmail.com>
> > > ---
> > > board/Marvell/mvebu_armada-37xx/board.c | 4 ++--
> > > 1 file changed, 2 insertions(+), 2 deletions(-)
> > >
> > > diff --git a/board/Marvell/mvebu_armada-37xx/board.c b/board/Marvell/mvebu_armada-37xx/board.c
> > > index eacee15cb3..2bfc7171c4 100644
> > > --- a/board/Marvell/mvebu_armada-37xx/board.c
> > > +++ b/board/Marvell/mvebu_armada-37xx/board.c
> > > @@ -88,14 +88,14 @@ int board_late_init(void)
> > > if (env_get("fdtfile"))
> > > return 0;
> > > - if (!of_machine_is_compatible("globalscale,espressobin"))
> > > + if (!of_machine_is_compatible("marvell,armada-3720-espressobin"))
> > > return 0;
> > > /* If the memory controller has been configured for DDR4, we're running on v7 */
> > > ddr4 = ((readl(A3700_CH0_MC_CTRL2_REG) >> A3700_MC_CTRL2_SDRAM_TYPE_OFFS)
> > > & A3700_MC_CTRL2_SDRAM_TYPE_MASK) == A3700_MC_CTRL2_SDRAM_TYPE_DDR4;
> > > - emmc = of_machine_is_compatible("globalscale,espressobin-emmc");
> > > + emmc = of_machine_is_compatible("marvell,armada-3720-espressobin-emmc");
> >
> > I run 'git grep marvell,armada-3720-espressobin-emmc origin/master' just
> > for verification... but it returned me empty result.
> >
> > So marvell,armada-3720-espressobin-emmc is not correct too and therefore
> > this patch does not still fix this problem.
>
> Right, without my set there is no support for the eMMC board in u-boot at
> all. We could remove the code, but I figured that'll be just unnecessary
> churn. The check evaluates correctly to non-emmc, so it works for the
> in-tree board just fine. This is the smaller fixup for the release.
Ok, Lets include it!
Reviewed-by: Pali Roh?r <pali@kernel.org>
Stefan, can you send this patch for U-Boot 2020.10 release?
Maybe following patch for documentation (doc/README.marvell) may be useful to:
https://patchwork.ozlabs.org/project/uboot/patch/20200925075416.16124-1-pali at kernel.org/
> >
> > > if (ddr4 && emmc)
> > > env_set("fdtfile", "marvell/armada-3720-espressobin-v7-emmc.dtb");
> > > --
> > > 2.28.0
> > >
>
^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH] arm: mvebu: Espressobin: Fix checks against machine compatible strings
2020-10-01 8:23 ` Pali Rohár
@ 2020-10-01 10:42 ` Heinrich Schuchardt
2020-10-01 10:48 ` Pali Rohár
0 siblings, 1 reply; 9+ messages in thread
From: Heinrich Schuchardt @ 2020-10-01 10:42 UTC (permalink / raw)
To: u-boot
On 01.10.20 10:23, Pali Roh?r wrote:
> On Tuesday 29 September 2020 14:43:25 Andre Heider wrote:
>> On 29/09/2020 14:38, Pali Roh?r wrote:
>>> On Tuesday 29 September 2020 14:34:26 Andre Heider wrote:
>>>> The patches changing the compatible strings to the ones used by Linux have
>>>> not been merged yet, so fix the checks to use the current in-tree ones.
>>>>
>>>> Reported-by: Pali Roh?r <pali@kernel.org>
>>>> Signed-off-by: Andre Heider <a.heider@gmail.com>
>>>> ---
>>>> board/Marvell/mvebu_armada-37xx/board.c | 4 ++--
>>>> 1 file changed, 2 insertions(+), 2 deletions(-)
>>>>
>>>> diff --git a/board/Marvell/mvebu_armada-37xx/board.c b/board/Marvell/mvebu_armada-37xx/board.c
>>>> index eacee15cb3..2bfc7171c4 100644
>>>> --- a/board/Marvell/mvebu_armada-37xx/board.c
>>>> +++ b/board/Marvell/mvebu_armada-37xx/board.c
>>>> @@ -88,14 +88,14 @@ int board_late_init(void)
>>>> if (env_get("fdtfile"))
>>>> return 0;
>>>> - if (!of_machine_is_compatible("globalscale,espressobin"))
>>>> + if (!of_machine_is_compatible("marvell,armada-3720-espressobin"))
Linux v5.9-rc6
arch/arm64/boot/dts/marvell/armada-3720-espressobin.dts:19:
compatible = "globalscale,espressobin", "marvell,armada3720",
"marvell,armada3710";
This value has been in Linux since 2016.
We should be able to boot with the U-Boot internal device tree into Linux.
So fix the device tree in U-Boot and not the C code, please.
Best regards
Heinrich
>>>> return 0;
>>>> /* If the memory controller has been configured for DDR4, we're running on v7 */
>>>> ddr4 = ((readl(A3700_CH0_MC_CTRL2_REG) >> A3700_MC_CTRL2_SDRAM_TYPE_OFFS)
>>>> & A3700_MC_CTRL2_SDRAM_TYPE_MASK) == A3700_MC_CTRL2_SDRAM_TYPE_DDR4;
>>>> - emmc = of_machine_is_compatible("globalscale,espressobin-emmc");
>>>> + emmc = of_machine_is_compatible("marvell,armada-3720-espressobin-emmc");
>>>
>>> I run 'git grep marvell,armada-3720-espressobin-emmc origin/master' just
>>> for verification... but it returned me empty result.
>>>
>>> So marvell,armada-3720-espressobin-emmc is not correct too and therefore
>>> this patch does not still fix this problem.
>>
>> Right, without my set there is no support for the eMMC board in u-boot at
>> all. We could remove the code, but I figured that'll be just unnecessary
>> churn. The check evaluates correctly to non-emmc, so it works for the
>> in-tree board just fine. This is the smaller fixup for the release.
>
> Ok, Lets include it!
>
> Reviewed-by: Pali Roh?r <pali@kernel.org>
>
> Stefan, can you send this patch for U-Boot 2020.10 release?
>
> Maybe following patch for documentation (doc/README.marvell) may be useful to:
> https://patchwork.ozlabs.org/project/uboot/patch/20200925075416.16124-1-pali at kernel.org/
>
>>>
>>>> if (ddr4 && emmc)
>>>> env_set("fdtfile", "marvell/armada-3720-espressobin-v7-emmc.dtb");
>>>> --
>>>> 2.28.0
>>>>
>>
^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH] arm: mvebu: Espressobin: Fix checks against machine compatible strings
2020-10-01 10:42 ` Heinrich Schuchardt
@ 2020-10-01 10:48 ` Pali Rohár
2020-10-01 10:54 ` Stefan Roese
0 siblings, 1 reply; 9+ messages in thread
From: Pali Rohár @ 2020-10-01 10:48 UTC (permalink / raw)
To: u-boot
On Thursday 01 October 2020 12:42:21 Heinrich Schuchardt wrote:
> On 01.10.20 10:23, Pali Roh?r wrote:
> > On Tuesday 29 September 2020 14:43:25 Andre Heider wrote:
> >> On 29/09/2020 14:38, Pali Roh?r wrote:
> >>> On Tuesday 29 September 2020 14:34:26 Andre Heider wrote:
> >>>> The patches changing the compatible strings to the ones used by Linux have
> >>>> not been merged yet, so fix the checks to use the current in-tree ones.
> >>>>
> >>>> Reported-by: Pali Roh?r <pali@kernel.org>
> >>>> Signed-off-by: Andre Heider <a.heider@gmail.com>
> >>>> ---
> >>>> board/Marvell/mvebu_armada-37xx/board.c | 4 ++--
> >>>> 1 file changed, 2 insertions(+), 2 deletions(-)
> >>>>
> >>>> diff --git a/board/Marvell/mvebu_armada-37xx/board.c b/board/Marvell/mvebu_armada-37xx/board.c
> >>>> index eacee15cb3..2bfc7171c4 100644
> >>>> --- a/board/Marvell/mvebu_armada-37xx/board.c
> >>>> +++ b/board/Marvell/mvebu_armada-37xx/board.c
> >>>> @@ -88,14 +88,14 @@ int board_late_init(void)
> >>>> if (env_get("fdtfile"))
> >>>> return 0;
> >>>> - if (!of_machine_is_compatible("globalscale,espressobin"))
> >>>> + if (!of_machine_is_compatible("marvell,armada-3720-espressobin"))
>
> Linux v5.9-rc6
> arch/arm64/boot/dts/marvell/armada-3720-espressobin.dts:19:
> compatible = "globalscale,espressobin", "marvell,armada3720",
> "marvell,armada3710";
>
> This value has been in Linux since 2016.
>
> We should be able to boot with the U-Boot internal device tree into Linux.
Hello Heinrich!
This is not possible yet as Linux kernel uses different comphy driver as
U-Boot and device tree structure for these drivers are different.
So you cannot use U-Boot internal device tree file for booting Linux
kernel.
> So fix the device tree in U-Boot and not the C code, please.
Yes, this is ongoing work, Marek is working on replacing U-Boot comphy
driver one from Linux kernel and Andre is working on synchronizing DTS
files from Linux kernel to U-Boot. But these works are not complete yet
and we need non-broken U-Boot 2020.10 release.
> Best regards
>
> Heinrich
>
> >>>> return 0;
> >>>> /* If the memory controller has been configured for DDR4, we're running on v7 */
> >>>> ddr4 = ((readl(A3700_CH0_MC_CTRL2_REG) >> A3700_MC_CTRL2_SDRAM_TYPE_OFFS)
> >>>> & A3700_MC_CTRL2_SDRAM_TYPE_MASK) == A3700_MC_CTRL2_SDRAM_TYPE_DDR4;
> >>>> - emmc = of_machine_is_compatible("globalscale,espressobin-emmc");
> >>>> + emmc = of_machine_is_compatible("marvell,armada-3720-espressobin-emmc");
> >>>
> >>> I run 'git grep marvell,armada-3720-espressobin-emmc origin/master' just
> >>> for verification... but it returned me empty result.
> >>>
> >>> So marvell,armada-3720-espressobin-emmc is not correct too and therefore
> >>> this patch does not still fix this problem.
> >>
> >> Right, without my set there is no support for the eMMC board in u-boot at
> >> all. We could remove the code, but I figured that'll be just unnecessary
> >> churn. The check evaluates correctly to non-emmc, so it works for the
> >> in-tree board just fine. This is the smaller fixup for the release.
> >
> > Ok, Lets include it!
> >
> > Reviewed-by: Pali Roh?r <pali@kernel.org>
> >
> > Stefan, can you send this patch for U-Boot 2020.10 release?
> >
> > Maybe following patch for documentation (doc/README.marvell) may be useful to:
> > https://patchwork.ozlabs.org/project/uboot/patch/20200925075416.16124-1-pali at kernel.org/
> >
> >>>
> >>>> if (ddr4 && emmc)
> >>>> env_set("fdtfile", "marvell/armada-3720-espressobin-v7-emmc.dtb");
> >>>> --
> >>>> 2.28.0
> >>>>
> >>
>
^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH] arm: mvebu: Espressobin: Fix checks against machine compatible strings
2020-10-01 10:48 ` Pali Rohár
@ 2020-10-01 10:54 ` Stefan Roese
0 siblings, 0 replies; 9+ messages in thread
From: Stefan Roese @ 2020-10-01 10:54 UTC (permalink / raw)
To: u-boot
On 01.10.20 12:48, Pali Roh?r wrote:
> On Thursday 01 October 2020 12:42:21 Heinrich Schuchardt wrote:
>> On 01.10.20 10:23, Pali Roh?r wrote:
>>> On Tuesday 29 September 2020 14:43:25 Andre Heider wrote:
>>>> On 29/09/2020 14:38, Pali Roh?r wrote:
>>>>> On Tuesday 29 September 2020 14:34:26 Andre Heider wrote:
>>>>>> The patches changing the compatible strings to the ones used by Linux have
>>>>>> not been merged yet, so fix the checks to use the current in-tree ones.
>>>>>>
>>>>>> Reported-by: Pali Roh?r <pali@kernel.org>
>>>>>> Signed-off-by: Andre Heider <a.heider@gmail.com>
>>>>>> ---
>>>>>> board/Marvell/mvebu_armada-37xx/board.c | 4 ++--
>>>>>> 1 file changed, 2 insertions(+), 2 deletions(-)
>>>>>>
>>>>>> diff --git a/board/Marvell/mvebu_armada-37xx/board.c b/board/Marvell/mvebu_armada-37xx/board.c
>>>>>> index eacee15cb3..2bfc7171c4 100644
>>>>>> --- a/board/Marvell/mvebu_armada-37xx/board.c
>>>>>> +++ b/board/Marvell/mvebu_armada-37xx/board.c
>>>>>> @@ -88,14 +88,14 @@ int board_late_init(void)
>>>>>> if (env_get("fdtfile"))
>>>>>> return 0;
>>>>>> - if (!of_machine_is_compatible("globalscale,espressobin"))
>>>>>> + if (!of_machine_is_compatible("marvell,armada-3720-espressobin"))
>>
>> Linux v5.9-rc6
>> arch/arm64/boot/dts/marvell/armada-3720-espressobin.dts:19:
>> compatible = "globalscale,espressobin", "marvell,armada3720",
>> "marvell,armada3710";
>>
>> This value has been in Linux since 2016.
>>
>> We should be able to boot with the U-Boot internal device tree into Linux.
>
> Hello Heinrich!
>
> This is not possible yet as Linux kernel uses different comphy driver as
> U-Boot and device tree structure for these drivers are different.
>
> So you cannot use U-Boot internal device tree file for booting Linux
> kernel.
>
>> So fix the device tree in U-Boot and not the C code, please.
>
> Yes, this is ongoing work, Marek is working on replacing U-Boot comphy
> driver one from Linux kernel and Andre is working on synchronizing DTS
> files from Linux kernel to U-Boot. But these works are not complete yet
> and we need non-broken U-Boot 2020.10 release.
Thanks for the explanation Pali. Yes, this fix is only temporarily for
the upcoming release. The DT sync will continue after the 2020.10
release.
Thanks,
Stefan
>> Best regards
>>
>> Heinrich
>>
>>>>>> return 0;
>>>>>> /* If the memory controller has been configured for DDR4, we're running on v7 */
>>>>>> ddr4 = ((readl(A3700_CH0_MC_CTRL2_REG) >> A3700_MC_CTRL2_SDRAM_TYPE_OFFS)
>>>>>> & A3700_MC_CTRL2_SDRAM_TYPE_MASK) == A3700_MC_CTRL2_SDRAM_TYPE_DDR4;
>>>>>> - emmc = of_machine_is_compatible("globalscale,espressobin-emmc");
>>>>>> + emmc = of_machine_is_compatible("marvell,armada-3720-espressobin-emmc");
>>>>>
>>>>> I run 'git grep marvell,armada-3720-espressobin-emmc origin/master' just
>>>>> for verification... but it returned me empty result.
>>>>>
>>>>> So marvell,armada-3720-espressobin-emmc is not correct too and therefore
>>>>> this patch does not still fix this problem.
>>>>
>>>> Right, without my set there is no support for the eMMC board in u-boot at
>>>> all. We could remove the code, but I figured that'll be just unnecessary
>>>> churn. The check evaluates correctly to non-emmc, so it works for the
>>>> in-tree board just fine. This is the smaller fixup for the release.
>>>
>>> Ok, Lets include it!
>>>
>>> Reviewed-by: Pali Roh?r <pali@kernel.org>
>>>
>>> Stefan, can you send this patch for U-Boot 2020.10 release?
>>>
>>> Maybe following patch for documentation (doc/README.marvell) may be useful to:
>>> https://patchwork.ozlabs.org/project/uboot/patch/20200925075416.16124-1-pali at kernel.org/
>>>
>>>>>
>>>>>> if (ddr4 && emmc)
>>>>>> env_set("fdtfile", "marvell/armada-3720-espressobin-v7-emmc.dtb");
>>>>>> --
>>>>>> 2.28.0
>>>>>>
>>>>
>>
Viele Gr??e,
Stefan
--
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-51 Fax: (+49)-8142-66989-80 Email: sr at denx.de
^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH] arm: mvebu: Espressobin: Fix checks against machine compatible strings
2020-09-29 12:34 [PATCH] arm: mvebu: Espressobin: Fix checks against machine compatible strings Andre Heider
2020-09-29 12:38 ` Pali Rohár
@ 2020-10-01 12:37 ` Stefan Roese
1 sibling, 0 replies; 9+ messages in thread
From: Stefan Roese @ 2020-10-01 12:37 UTC (permalink / raw)
To: u-boot
On 29.09.20 14:34, Andre Heider wrote:
> The patches changing the compatible strings to the ones used by Linux have
> not been merged yet, so fix the checks to use the current in-tree ones.
>
> Reported-by: Pali Roh?r <pali@kernel.org>
> Signed-off-by: Andre Heider <a.heider@gmail.com>
Applied to u-boot-marvell/master
Thanks,
Stefan
> ---
> board/Marvell/mvebu_armada-37xx/board.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/board/Marvell/mvebu_armada-37xx/board.c b/board/Marvell/mvebu_armada-37xx/board.c
> index eacee15cb3..2bfc7171c4 100644
> --- a/board/Marvell/mvebu_armada-37xx/board.c
> +++ b/board/Marvell/mvebu_armada-37xx/board.c
> @@ -88,14 +88,14 @@ int board_late_init(void)
> if (env_get("fdtfile"))
> return 0;
>
> - if (!of_machine_is_compatible("globalscale,espressobin"))
> + if (!of_machine_is_compatible("marvell,armada-3720-espressobin"))
> return 0;
>
> /* If the memory controller has been configured for DDR4, we're running on v7 */
> ddr4 = ((readl(A3700_CH0_MC_CTRL2_REG) >> A3700_MC_CTRL2_SDRAM_TYPE_OFFS)
> & A3700_MC_CTRL2_SDRAM_TYPE_MASK) == A3700_MC_CTRL2_SDRAM_TYPE_DDR4;
>
> - emmc = of_machine_is_compatible("globalscale,espressobin-emmc");
> + emmc = of_machine_is_compatible("marvell,armada-3720-espressobin-emmc");
>
> if (ddr4 && emmc)
> env_set("fdtfile", "marvell/armada-3720-espressobin-v7-emmc.dtb");
>
Viele Gr??e,
Stefan
--
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-51 Fax: (+49)-8142-66989-80 Email: sr at denx.de
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2020-10-01 12:37 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-29 12:34 [PATCH] arm: mvebu: Espressobin: Fix checks against machine compatible strings Andre Heider
2020-09-29 12:38 ` Pali Rohár
2020-09-29 12:41 ` Pali Rohár
2020-09-29 12:43 ` Andre Heider
2020-10-01 8:23 ` Pali Rohár
2020-10-01 10:42 ` Heinrich Schuchardt
2020-10-01 10:48 ` Pali Rohár
2020-10-01 10:54 ` Stefan Roese
2020-10-01 12:37 ` Stefan Roese
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.