All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jerry Huang <jerry.huang@nxp.com>
To: buildroot@busybox.net
Subject: [Buildroot] [EXT] Re: [PATCH v2 06/10] boot/arm-trusted-firmware: Add RCW support
Date: Tue, 26 Nov 2019 07:34:16 +0000	[thread overview]
Message-ID: <VI1PR04MB5136D82D297EBB06AF151EDFFE450@VI1PR04MB5136.eurprd04.prod.outlook.com> (raw)
In-Reply-To: <VI1PR04MB513683CAA0FCE4A542902D7AFE450@VI1PR04MB5136.eurprd04.prod.outlook.com>

I double check the "boot/arm-trusted-firmware/Config.in",
There is one option BR2_TARGET_ARM_TRUSTED_FIRMWARE_ADDITIONAL_VARIABLES,
I think it can be used to replace my previous mail mentioned: ARM_TRUSTED_FIRMWARE_EXTRA_OPTS.
Add now this option is added to ARM_TRUSTED_FIRMWARE_MAKE_OPTS

So in order to keep consistent with the context, two new options are defined:
BR2_TARGET_ARM_TRUSTED_FIRMWARE_ADDITIONAL_TARGETS
BR2_TARGET_ARM_TRUSTED_FIRMWARE_ADDITIONAL_ DEPENDENCIES

ARM_TRUSTED_FIRMWARE_MAKE_TARGETS += BR2_TARGET_ARM_TRUSTED_FIRMWARE_ADDITIONAL_TARGETS
ARM_TRUSTED_FIRMWARE_DEPENDENCIES += BR2_TARGET_ARM_TRUSTED_FIRMWARE_ADDITIONAL_ DEPENDENCIES

Best Regards
Jerry Huang

> -----Original Message-----
> From: Jerry Huang
> Sent: Tuesday, November 26, 2019 3:07 PM
> To: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
> Cc: buildroot at busybox.net; michael at walle.cc; matthew.weber at collins.com;
> geomatsi at gmail.com
> Subject: RE: [EXT] Re: [Buildroot] [PATCH v2 06/10] boot/arm-trusted-firmware:
> Add RCW support
> 
> Hi, Thomas,
> Some comment in lines, please review them, thanks a lot.
> 
> Best Regards
> Jerry Huang
> 
> > -----Original Message-----
> > From: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
> > Sent: Tuesday, November 26, 2019 6:10 AM
> > To: Jerry Huang <jerry.huang@nxp.com>
> > Cc: buildroot at busybox.net; michael at walle.cc;
> > matthew.weber at collins.com; geomatsi at gmail.com
> > Subject: [EXT] Re: [Buildroot] [PATCH v2 06/10]
> > boot/arm-trusted-firmware: Add RCW support
> >
> > Caution: EXT Email
> >
> > Hello,
> >
> > On Thu, 21 Nov 2019 18:23:20 +0800
> > Changming Huang <jerry.huang@nxp.com> wrote:
> >
> > > diff --git a/boot/arm-trusted-firmware/arm-trusted-firmware.mk
> > > b/boot/arm-trusted-firmware/arm-trusted-firmware.mk
> > > index 2133d39e6d..2bca8109f1 100644
> > > --- a/boot/arm-trusted-firmware/arm-trusted-firmware.mk
> > > +++ b/boot/arm-trusted-firmware/arm-trusted-firmware.mk
> > > @@ -92,6 +92,15 @@ endif
> > >
> > >  ARM_TRUSTED_FIRMWARE_MAKE_TARGETS = all
> > >
> > > +ifeq ($(BR2_PACKAGE_HOST_RCW_ATF),y)
> >
> > This option should be introduced by this patch.
> Sure,
> 
> > Overall, I'm not super happy with how arm-trusted-firmware works. In
> > some cases, it's a sub-option of arm-trusted-firmware that causes it
> > to use some additional package (for example OPTEE as BL32, U-Boot as
> > BL33), but sometimes it's the implicit fact of having another package
> > enabled (mv-ddr-marvell, vexpress-firmware), that causes
> arm-trusted-firmware to use it.
> > Not great.
> >
> > So I'm not sure how to proceed with RCW.
> Yes, it uses some additional package for booting.
> But, if it does not use them (U-Boot as BL33, OPTEE as BL32, RCW as BL2), what
> can arm-trusted-firmware do?
> 
> > > +RCW_BOOT_MODE = $(call
> > qstrip,$(BR2_PACKAGE_HOST_RCW_BOOT_MODE))
> > > +RCW_PATH = $(call qstrip,$(BR2_PACKAGE_HOST_RCW_BIN))
> > > +RCW_FILE = $(lastword $(subst /, ,$(RCW_PATH)))
> >
> > Those variables names should be prefixed with the package name, i.e
> > ARM_TRUSTED_FIRMWARE.
> Sure,
> 
> > > +ARM_TRUSTED_FIRMWARE_MAKE_OPTS +=
> > BOOT_MODE=$(RCW_BOOT_MODE)
> > > +RCW=$(BINARIES_DIR)/$(RCW_FILE)
> >
> > These BOOT_MODE and RCW options are not supported in ATF upstream,
> > apparently only in the NXP fork. I'm not sure we want explicit support
> > for vendor-specific things. Should we look at providing an
> > arm-trusted-firmware that can more easily be customized through options?
> 
> Maybe we can provide three options
> ARM_TRUSTED_FIRMWARE_EXTRA_OPTS: the custom OPTS
> ARM_TRUSTED_FIRMWARE_EXTRA_TARGETS: the custom TARGETS
> ARM_TRUSTED_FIRMWARE_EXTRA_DEPENDENCIES: the custom dependency
> 
> Which are defined in defconfig file or empty, For example, NXP QorIQ:
> ARM_TRUSTED_FIRMWARE_EXTRA_OPTS = " BOOT_MODE=sd
> RCW=$(BINARIES_DIR)/ rcw_1300_sdboot.bin"
> ARM_TRUSTED_FIRMWARE_EXTRA_TARGETS = " pbl"
> ARM_TRUSTED_FIRMWARE_EXTRA_DEPENDENCIES = "host-qoriq-rcw"
> Or Marvell DDR:
> ARM_TRUSTED_FIRMWARE_EXTRA_OPTS = "
> SCP_BL2=$(BINARIES_DIR)/scp-fw.bin"
> ARM_TRUSTED_FIRMWARE_EXTRA_DEPENDENCIES = "mv-ddr-marvell"
> 
> we can use them as below without detecting the condition in ATF makefile:
> ARM_TRUSTED_FIRMWARE_MAKE_OPTS +=
> ARM_TRUSTED_FIRMWARE_EXTRA_OPTS
> ARM_TRUSTED_FIRMWARE_MAKE_TARGETS +=
> ARM_TRUSTED_FIRMWARE_EXTRA_TARGETS
> ARM_TRUSTED_FIRMWARE_DEPENDENCIES +=
> ARM_TRUSTED_FIRMWARE_EXTRA_DEPENDENCIES
> 
> We can put anything we want into these options, and the ATF makefile is very
> clean.
> 
> How do you think about them?
> 
> > That's really an open discussion, I don't yet have a clear idea on how
> > to handle that.
> >
> > Thomas
> > --
> > Thomas Petazzoni, CTO, Bootlin
> > Embedded Linux and Kernel engineering
> > https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fboot
> > lin.c
> om&amp;data=02%7C01%7Cjerry.huang%40nxp.com%7C74c02743671b4e18a
> >
> b5c08d771f42b8f%7C686ea1d3bc2b4c6fa92cd99c5c301635%7C0%7C0%7C637
> >
> 103165822614341&amp;sdata=rcEnN%2B%2FlfMpj0iwpikulfsCH0v813TaG86K
> > GsE3eGTo%3D&amp;reserved=0

  reply	other threads:[~2019-11-26  7:34 UTC|newest]

Thread overview: 51+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-11-21 10:23 [Buildroot] [PATCH v2 0/9] new board ls1028ardb introduced Changming Huang
2019-11-21 10:23 ` [Buildroot] [PATCH v2 01/10] package/freescale-qoriq: new package directory Changming Huang
2019-11-25 21:13   ` Thomas Petazzoni
2019-11-26  2:49     ` [Buildroot] [EXT] " Jerry Huang
2019-11-21 10:23 ` [Buildroot] [PATCH v2 02/10] package/freescale-qoriq/fsl-qoriq-rcw: move rcw into freescale-qoriq and rename it Changming Huang
2019-11-21 10:34   ` Michael Walle
2019-11-21 10:42     ` [Buildroot] [EXT] " Jerry Huang
2019-11-25 21:15   ` [Buildroot] " Thomas Petazzoni
2019-11-26  3:25     ` [Buildroot] [EXT] " Jerry Huang
2019-11-21 10:23 ` [Buildroot] [PATCH v2 03/10] package/freescale-qoriq/fsl-qoriq-rcw: upgrade the rcw version to LSDK-19.09 Changming Huang
2019-11-25 21:17   ` Thomas Petazzoni
2019-11-26  3:51     ` [Buildroot] [EXT] " Jerry Huang
2019-11-21 10:23 ` [Buildroot] [PATCH v2 04/10] package/freescale-qoriq/fsl-qoriq-rcw: add target rcw binary support Changming Huang
2019-11-25 21:23   ` Thomas Petazzoni
2019-11-26  4:33     ` [Buildroot] [EXT] " Jerry Huang
2019-11-21 10:23 ` [Buildroot] [PATCH v2 05/10] boot/arm-trusted-firmware: Add option BR2_TARGET_ARM_TRUSTED_FIRMWARE_UBOOT_BL33_IMAGE Changming Huang
2019-11-22  9:11   ` Sergey Matyukevich
2019-11-22  9:24     ` [Buildroot] [EXT] " Jerry Huang
2019-11-25 21:59   ` [Buildroot] " Thomas Petazzoni
2019-11-21 10:23 ` [Buildroot] [PATCH v2 06/10] boot/arm-trusted-firmware: Add RCW support Changming Huang
2019-11-22  9:19   ` Sergey Matyukevich
2019-11-22  9:31     ` [Buildroot] [EXT] " Jerry Huang
2019-11-25 22:09   ` [Buildroot] " Thomas Petazzoni
2019-11-26  7:06     ` [Buildroot] [EXT] " Jerry Huang
2019-11-26  7:34       ` Jerry Huang [this message]
2019-11-21 10:23 ` [Buildroot] [PATCH v2 07/10] package/freescale-qoriq/fsl-qoriq-cadence-dp-fw: new package Changming Huang
2019-11-21 10:42   ` Michael Walle
2019-11-21 11:04     ` [Buildroot] [EXT] " Jerry Huang
2019-11-22 10:41     ` Jerry Huang
2019-11-21 10:51   ` [Buildroot] " Michael Walle
2019-11-21 11:09     ` [Buildroot] [EXT] " Jerry Huang
2019-11-22 10:40     ` Jerry Huang
2019-11-22 11:00       ` Michael Walle
2019-11-25  2:40         ` Jerry Huang
2019-11-22 11:05       ` Thomas Petazzoni
2019-11-25  6:25         ` Jerry Huang
2019-11-25 22:12   ` [Buildroot] " Thomas Petazzoni
2019-11-26  8:09     ` [Buildroot] [EXT] " Jerry Huang
2019-11-26  9:21       ` Michael Walle
2019-11-26 10:13         ` Jerry Huang
2019-11-26  9:29       ` Michael Walle
2019-11-26 10:12         ` Thomas Petazzoni
2019-11-26 10:31           ` Michael Walle
2019-11-26 12:10             ` Jerry Huang
2019-11-21 10:23 ` [Buildroot] [PATCH v2 08/10] package/freescale-qoriq/fsl-qoriq-rcw:Enable IIC5_PMUX and CLK_OUT_PMUX for GPIO Changming Huang
2019-11-25 22:13   ` Thomas Petazzoni
2019-11-26  8:15     ` [Buildroot] [EXT] " Jerry Huang
2019-11-21 10:23 ` [Buildroot] [PATCH v2 09/10] board/freescale/common/ls: Add standard post image script for Layerscape processors Changming Huang
2019-11-21 10:23 ` [Buildroot] [PATCH v2 10/10] configs/freescale_ls1028ardb*: new board Changming Huang
2019-11-25 22:17   ` Thomas Petazzoni
2019-11-26 12:02     ` [Buildroot] [EXT] " Jerry Huang

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=VI1PR04MB5136D82D297EBB06AF151EDFFE450@VI1PR04MB5136.eurprd04.prod.outlook.com \
    --to=jerry.huang@nxp.com \
    --cc=buildroot@busybox.net \
    /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 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.