linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ARM: dts: Makefile: build arm64 device tree
@ 2020-03-13  3:31 peng.fan
  2020-03-13 10:23 ` Arnd Bergmann
  0 siblings, 1 reply; 5+ messages in thread
From: peng.fan @ 2020-03-13  3:31 UTC (permalink / raw)
  To: robh+dt, mark.rutland, arnd, shawnguo
  Cc: devicetree, linux-kernel, linux-imx, Peng Fan

From: Peng Fan <peng.fan@nxp.com>

To support aarch32 mode linux on aarch64 hardware, we need
build the device tree, so include the arm64 device tree path.

Signed-off-by: Peng Fan <peng.fan@nxp.com>
---

V1:
 This is just the device tree part. Besides this,
 I am not sure whether need to create a standalone defconfig under arm32
 for aarch32 mode linux on aarch64 hardware, or use multi_v7_defconfig.
 multi_v7_defconfig should be ok, need to include LPAE config.

 arch/arm/boot/dts/Makefile | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
index e874fbf5a1f3..ff0161c1df5f 100644
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
@@ -1341,3 +1341,5 @@ dtb-$(CONFIG_ARCH_ASPEED) += \
 	aspeed-bmc-opp-zaius.dtb \
 	aspeed-bmc-portwell-neptune.dtb \
 	aspeed-bmc-quanta-q71l.dtb
+
+subdir-y += ../../../../arch/arm64/boot/dts
-- 
2.16.4


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH] ARM: dts: Makefile: build arm64 device tree
  2020-03-13  3:31 [PATCH] ARM: dts: Makefile: build arm64 device tree peng.fan
@ 2020-03-13 10:23 ` Arnd Bergmann
  2020-03-13 10:47   ` Masahiro Yamada
  2020-03-13 12:39   ` Peng Fan
  0 siblings, 2 replies; 5+ messages in thread
From: Arnd Bergmann @ 2020-03-13 10:23 UTC (permalink / raw)
  To: Peng Fan
  Cc: Rob Herring, Mark Rutland, Shawn Guo, DTML, linux-kernel, NXP Linux Team

On Fri, Mar 13, 2020 at 4:38 AM <peng.fan@nxp.com> wrote:
>
> From: Peng Fan <peng.fan@nxp.com>
>
> To support aarch32 mode linux on aarch64 hardware, we need
> build the device tree, so include the arm64 device tree path.
>
> Signed-off-by: Peng Fan <peng.fan@nxp.com>
> ---

There are a few other platforms with similar requirements, in
particular bcm2837,
so maybe try doing it the same way they do, see
arch/arm64/boot/dts/broadcom/bcm2837-rpi-3-b.dts

> V1:
>  This is just the device tree part. Besides this,
>  I am not sure whether need to create a standalone defconfig under arm32
>  for aarch32 mode linux on aarch64 hardware, or use multi_v7_defconfig.
>  multi_v7_defconfig should be ok, need to include LPAE config.

I'd rather not have a standalone defconfig for it, given that we have a
single defconfig for all armv6/armv7/armv7hf i.mx machines.

There was a suggestion to use a fragment for enabling an LPAE
multi_v7_defconfig recently, which I think is still under discussion but
should also help here, both with imx_v6_v7_defconfig and multi_v7_defconfig.

Can you remind us why this platform needs LPAE? Is it only needed to
support more than 4GB of RAM, or something else on top of that?
Note that users that actually have 4GB or more on i.mx8 should
really run a 64-bit kernel anyway, even if they prefer using 32-bit user
space.

Turning on LPAE not only disables imx3 and imx5 but also the Cortex-A9
based imx6 variants.

      Arnd

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] ARM: dts: Makefile: build arm64 device tree
  2020-03-13 10:23 ` Arnd Bergmann
@ 2020-03-13 10:47   ` Masahiro Yamada
  2020-03-13 12:39   ` Peng Fan
  1 sibling, 0 replies; 5+ messages in thread
From: Masahiro Yamada @ 2020-03-13 10:47 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: Peng Fan, Rob Herring, Mark Rutland, Shawn Guo, DTML,
	linux-kernel, NXP Linux Team

On Fri, Mar 13, 2020 at 7:23 PM Arnd Bergmann <arnd@arndb.de> wrote:
>
> On Fri, Mar 13, 2020 at 4:38 AM <peng.fan@nxp.com> wrote:
> >
> > From: Peng Fan <peng.fan@nxp.com>
> >
> > To support aarch32 mode linux on aarch64 hardware, we need
> > build the device tree, so include the arm64 device tree path.
> >
> > Signed-off-by: Peng Fan <peng.fan@nxp.com>
> > ---
>
> There are a few other platforms with similar requirements, in
> particular bcm2837,
> so maybe try doing it the same way they do, see
> arch/arm64/boot/dts/broadcom/bcm2837-rpi-3-b.dts

I think this was discussed over again,
but it is odd to tightly couple
DT and Linux arch.


Maybe, a long time solution might be to
create a new directory, dts/
and collect all DT stuff into it.

dts/<vendor>/<board>.dts


Then, also move like follows:

Documentation/devicetree/bindings/
 ->  dts/Bindings/

include/dt-bingins/
 -> dts/include/dt-bindings/






>
> > V1:
> >  This is just the device tree part. Besides this,
> >  I am not sure whether need to create a standalone defconfig under arm32
> >  for aarch32 mode linux on aarch64 hardware, or use multi_v7_defconfig.
> >  multi_v7_defconfig should be ok, need to include LPAE config.
>
> I'd rather not have a standalone defconfig for it, given that we have a
> single defconfig for all armv6/armv7/armv7hf i.mx machines.
>
> There was a suggestion to use a fragment for enabling an LPAE
> multi_v7_defconfig recently, which I think is still under discussion but
> should also help here, both with imx_v6_v7_defconfig and multi_v7_defconfig.
>
> Can you remind us why this platform needs LPAE? Is it only needed to
> support more than 4GB of RAM, or something else on top of that?
> Note that users that actually have 4GB or more on i.mx8 should
> really run a 64-bit kernel anyway, even if they prefer using 32-bit user
> space.
>
> Turning on LPAE not only disables imx3 and imx5 but also the Cortex-A9
> based imx6 variants.
>
>       Arnd



-- 
Best Regards
Masahiro Yamada

^ permalink raw reply	[flat|nested] 5+ messages in thread

* RE: [PATCH] ARM: dts: Makefile: build arm64 device tree
  2020-03-13 10:23 ` Arnd Bergmann
  2020-03-13 10:47   ` Masahiro Yamada
@ 2020-03-13 12:39   ` Peng Fan
  2020-03-17  1:44     ` Peng Fan
  1 sibling, 1 reply; 5+ messages in thread
From: Peng Fan @ 2020-03-13 12:39 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: Rob Herring, Mark Rutland, Shawn Guo, DTML, linux-kernel, dl-linux-imx

Hi Arnd,

> Subject: Re: [PATCH] ARM: dts: Makefile: build arm64 device tree
> 
> On Fri, Mar 13, 2020 at 4:38 AM <peng.fan@nxp.com> wrote:
> >
> > From: Peng Fan <peng.fan@nxp.com>
> >
> > To support aarch32 mode linux on aarch64 hardware, we need build the
> > device tree, so include the arm64 device tree path.
> >
> > Signed-off-by: Peng Fan <peng.fan@nxp.com>
> > ---
> 
> There are a few other platforms with similar requirements, in particular
> bcm2837, so maybe try doing it the same way they do, see
> arch/arm64/boot/dts/broadcom/bcm2837-rpi-3-b.dts
> 
> > V1:
> >  This is just the device tree part. Besides this,  I am not sure
> > whether need to create a standalone defconfig under arm32  for aarch32
> > mode linux on aarch64 hardware, or use multi_v7_defconfig.
> >  multi_v7_defconfig should be ok, need to include LPAE config.
> 
> I'd rather not have a standalone defconfig for it, given that we have a single
> defconfig for all armv6/armv7/armv7hf i.mx machines.
> 
> There was a suggestion to use a fragment for enabling an LPAE
> multi_v7_defconfig recently, which I think is still under discussion but should
> also help here, both with imx_v6_v7_defconfig and multi_v7_defconfig.
> 
> Can you remind us why this platform needs LPAE? Is it only needed to support
> more than 4GB of RAM, or something else on top of that?

Currently I only tested LPAE enabled arm32 kernel, I'll give a try with LPAE
disabled later.

Thanks,
Peng.
> Note that users that actually have 4GB or more on i.mx8 should really run a
> 64-bit kernel anyway, even if they prefer using 32-bit user space.
> 
> Turning on LPAE not only disables imx3 and imx5 but also the Cortex-A9 based
> imx6 variants.
> 
>       Arnd

^ permalink raw reply	[flat|nested] 5+ messages in thread

* RE: [PATCH] ARM: dts: Makefile: build arm64 device tree
  2020-03-13 12:39   ` Peng Fan
@ 2020-03-17  1:44     ` Peng Fan
  0 siblings, 0 replies; 5+ messages in thread
From: Peng Fan @ 2020-03-17  1:44 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: Rob Herring, Mark Rutland, Shawn Guo, DTML, linux-kernel, dl-linux-imx

Hi Arnd,

> Subject: RE: [PATCH] ARM: dts: Makefile: build arm64 device tree
> 
> Hi Arnd,
> 
> > Subject: Re: [PATCH] ARM: dts: Makefile: build arm64 device tree
> >
> > On Fri, Mar 13, 2020 at 4:38 AM <peng.fan@nxp.com> wrote:
> > >
> > > From: Peng Fan <peng.fan@nxp.com>
> > >
> > > To support aarch32 mode linux on aarch64 hardware, we need build the
> > > device tree, so include the arm64 device tree path.
> > >
> > > Signed-off-by: Peng Fan <peng.fan@nxp.com>
> > > ---
> >
> > There are a few other platforms with similar requirements, in
> > particular bcm2837, so maybe try doing it the same way they do, see
> > arch/arm64/boot/dts/broadcom/bcm2837-rpi-3-b.dts
> >
> > > V1:
> > >  This is just the device tree part. Besides this,  I am not sure
> > > whether need to create a standalone defconfig under arm32  for
> > > aarch32 mode linux on aarch64 hardware, or use multi_v7_defconfig.
> > >  multi_v7_defconfig should be ok, need to include LPAE config.
> >
> > I'd rather not have a standalone defconfig for it, given that we have
> > a single defconfig for all armv6/armv7/armv7hf i.mx machines.
> >
> > There was a suggestion to use a fragment for enabling an LPAE
> > multi_v7_defconfig recently, which I think is still under discussion
> > but should also help here, both with imx_v6_v7_defconfig and
> multi_v7_defconfig.
> >
> > Can you remind us why this platform needs LPAE? Is it only needed to
> > support more than 4GB of RAM, or something else on top of that?
> 
> Currently I only tested LPAE enabled arm32 kernel, I'll give a try with LPAE
> disabled later.

Tested with imx_v6_v7_defconfig without LPAE, smp boots up with nfsroot.

Thanks,
Peng.

> 
> Thanks,
> Peng.
> > Note that users that actually have 4GB or more on i.mx8 should really
> > run a 64-bit kernel anyway, even if they prefer using 32-bit user space.
> >
> > Turning on LPAE not only disables imx3 and imx5 but also the Cortex-A9
> > based
> > imx6 variants.
> >
> >       Arnd

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2020-03-17  1:45 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-13  3:31 [PATCH] ARM: dts: Makefile: build arm64 device tree peng.fan
2020-03-13 10:23 ` Arnd Bergmann
2020-03-13 10:47   ` Masahiro Yamada
2020-03-13 12:39   ` Peng Fan
2020-03-17  1:44     ` Peng Fan

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).