Message ID | 20241213154843.27592-4-twoerner@gmail.com |
---|---|
State | New |
Headers | show |
Series | [meta-rockchip,v2,1/4] u-boot: switch to upstream SRCREV for rk-u-boot-env | expand |
Hi Trevor, On 12/13/24 4:48 PM, Trevor Woerner via lists.yoctoproject.org wrote: > A PREFERRED_PROVIDER entry was missed for rk3308 builds: > > NOTE: Multiple providers are available for trusted-firmware-a (rk3308-rkbin, rockchip-rkbin-tf-a) > Consider defining a PREFERRED_PROVIDER entry to match trusted-firmware-a > > This allows the RKBIN_RK3308_LATEST knob to work in all cases again. > > Signed-off-by: Trevor Woerner <twoerner@gmail.com> > --- > changes from v1 > - added > --- > conf/machine/include/rk3308.inc | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/conf/machine/include/rk3308.inc b/conf/machine/include/rk3308.inc > index 1ecf085cd5de..d30901f15b4f 100644 > --- a/conf/machine/include/rk3308.inc > +++ b/conf/machine/include/rk3308.inc > @@ -19,6 +19,7 @@ KERNEL_IMAGETYPE ?= "fitImage" > UBOOT_SUFFIX ?= "itb" > UBOOT_ENTRYPOINT ?= "0x06000000" > > +PREFERRED_PROVIDER_trusted-firmware-a = "${@bb.utils.contains('RKBIN_RK3308_LATEST', '1', 'rockchip-rkbin-tf-a', 'rk3308-rkbin', d)}" PREFERRED_PROVIDER_trusted-firmware-a = "rockchip-rkbin-tf-a" Should be enough I believe, and it would be consistent with rk3566, rk3568 and rk3588s where we already have that. Anyone requesting trusted-firmware-a would get rockchip-rkbin-tf-a. When that happens, BitBake will check PREFERRED_PROVIDER_rockchip-rkbin-tf-a and pick what it should. By having the suggested implementation, it would technically be possible to have someone request trusted-firmware-a to be rk3308-rkbin and rockchip-rkbin-tf-a (the provider) be rockchip-rkbin-tf-a (the recipe). Basically, we use a knob where there's no need to. Cheers, Quentin
On Fri 2024-12-13 @ 05:28:40 PM, Quentin Schulz via lists.yoctoproject.org wrote: > Hi Trevor, > > On 12/13/24 4:48 PM, Trevor Woerner via lists.yoctoproject.org wrote: > > A PREFERRED_PROVIDER entry was missed for rk3308 builds: > > > > NOTE: Multiple providers are available for trusted-firmware-a (rk3308-rkbin, rockchip-rkbin-tf-a) > > Consider defining a PREFERRED_PROVIDER entry to match trusted-firmware-a > > > > This allows the RKBIN_RK3308_LATEST knob to work in all cases again. > > > > Signed-off-by: Trevor Woerner <twoerner@gmail.com> > > --- > > changes from v1 > > - added > > --- > > conf/machine/include/rk3308.inc | 1 + > > 1 file changed, 1 insertion(+) > > > > diff --git a/conf/machine/include/rk3308.inc b/conf/machine/include/rk3308.inc > > index 1ecf085cd5de..d30901f15b4f 100644 > > --- a/conf/machine/include/rk3308.inc > > +++ b/conf/machine/include/rk3308.inc > > @@ -19,6 +19,7 @@ KERNEL_IMAGETYPE ?= "fitImage" > > UBOOT_SUFFIX ?= "itb" > > UBOOT_ENTRYPOINT ?= "0x06000000" > > +PREFERRED_PROVIDER_trusted-firmware-a = "${@bb.utils.contains('RKBIN_RK3308_LATEST', '1', 'rockchip-rkbin-tf-a', 'rk3308-rkbin', d)}" > > PREFERRED_PROVIDER_trusted-firmware-a = "rockchip-rkbin-tf-a" > > Should be enough I believe, and it would be consistent with rk3566, rk3568 > and rk3588s where we already have that. This fails when RKBIN_RK3308_LATEST is not defined: ERROR: Multiple .bb files are due to be built which each provide rockchip-rkbin-tf-a /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rockchip-rkbin-tf-a_git.bb /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rk3308-rkbin_git.bb A list of tasks depending on these providers is shown and may help explain where the dependency comes from. /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rockchip-rkbin-tf-a_git.bb has unique dependees: /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rk3308-rkbin_git.bb has unique dependees: It could be that one recipe provides something the other doesn't and should. The following provider and runtime provider differences may be helpful. /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rockchip-rkbin-tf-a_git.bb has unique provides: /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rockchip-rkbin-tf-a_git.bb has unique rprovides: ^rockchip-rkbin-tf-a-locale-.* rockchip-rkbin-tf-a /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rk3308-rkbin_git.bb has unique provides: rockchip-rkbin-optee-os rk3308-rkbin rockchip-rkbin-ddr optee-os /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rk3308-rkbin_git.bb has unique rprovides: rk3308-rkbin ^rk3308-rkbin-locale-.* ERROR: Multiple .bb files are due to be built which each provide trusted-firmware-a: /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rockchip-rkbin-tf-a_git.bb /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rk3308-rkbin_git.bb A list of tasks depending on these providers is shown and may help explain where the dependency comes from. /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rockchip-rkbin-tf-a_git.bb has unique dependees: /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rk3308-rkbin_git.bb has unique dependees: It could be that one recipe provides something the other doesn't and should. The following provider and runtime provider differences may be helpful. /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rockchip-rkbin-tf-a_git.bb has unique provides: /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rockchip-rkbin-tf-a_git.bb has unique rprovides: ^rockchip-rkbin-tf-a-locale-.* rockchip-rkbin-tf-a /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rk3308-rkbin_git.bb has unique provides: rockchip-rkbin-optee-os rk3308-rkbin rockchip-rkbin-ddr optee-os /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rk3308-rkbin_git.bb has unique rprovides: rk3308-rkbin ^rk3308-rkbin-locale-.* The way I suggested builds in all cases, and runs fine both ways too. > Anyone requesting trusted-firmware-a would get rockchip-rkbin-tf-a. When > that happens, BitBake will check PREFERRED_PROVIDER_rockchip-rkbin-tf-a and > pick what it should. > > By having the suggested implementation, it would technically be possible to > have someone request trusted-firmware-a to be rk3308-rkbin and > rockchip-rkbin-tf-a (the provider) be rockchip-rkbin-tf-a (the recipe). > Basically, we use a knob where there's no need to. > > Cheers, > Quentin > > > -=-=-=-=-=-=-=-=-=-=-=- > Links: You receive all messages sent to this group. > View/Reply Online (#905): https://lists.yoctoproject.org/g/yocto-patches/message/905 > Mute This Topic: https://lists.yoctoproject.org/mt/110099069/900817 > Group Owner: yocto-patches+owner@lists.yoctoproject.org > Unsubscribe: https://lists.yoctoproject.org/g/yocto-patches/leave/13168745/900817/63955952/xyzzy [twoerner@gmail.com] > -=-=-=-=-=-=-=-=-=-=-=- > >
Hi Trevor, On 12/13/24 6:11 PM, Trevor Woerner via lists.yoctoproject.org wrote: > On Fri 2024-12-13 @ 05:28:40 PM, Quentin Schulz via lists.yoctoproject.org wrote: >> Hi Trevor, >> >> On 12/13/24 4:48 PM, Trevor Woerner via lists.yoctoproject.org wrote: >>> A PREFERRED_PROVIDER entry was missed for rk3308 builds: >>> >>> NOTE: Multiple providers are available for trusted-firmware-a (rk3308-rkbin, rockchip-rkbin-tf-a) >>> Consider defining a PREFERRED_PROVIDER entry to match trusted-firmware-a >>> >>> This allows the RKBIN_RK3308_LATEST knob to work in all cases again. >>> >>> Signed-off-by: Trevor Woerner <twoerner@gmail.com> >>> --- >>> changes from v1 >>> - added >>> --- >>> conf/machine/include/rk3308.inc | 1 + >>> 1 file changed, 1 insertion(+) >>> >>> diff --git a/conf/machine/include/rk3308.inc b/conf/machine/include/rk3308.inc >>> index 1ecf085cd5de..d30901f15b4f 100644 >>> --- a/conf/machine/include/rk3308.inc >>> +++ b/conf/machine/include/rk3308.inc >>> @@ -19,6 +19,7 @@ KERNEL_IMAGETYPE ?= "fitImage" >>> UBOOT_SUFFIX ?= "itb" >>> UBOOT_ENTRYPOINT ?= "0x06000000" >>> +PREFERRED_PROVIDER_trusted-firmware-a = "${@bb.utils.contains('RKBIN_RK3308_LATEST', '1', 'rockchip-rkbin-tf-a', 'rk3308-rkbin', d)}" >> >> PREFERRED_PROVIDER_trusted-firmware-a = "rockchip-rkbin-tf-a" >> >> Should be enough I believe, and it would be consistent with rk3566, rk3568 >> and rk3588s where we already have that. > > This fails when RKBIN_RK3308_LATEST is not defined: > > ERROR: Multiple .bb files are due to be built which each provide rockchip-rkbin-tf-a > /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rockchip-rkbin-tf-a_git.bb > /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rk3308-rkbin_git.bb > A list of tasks depending on these providers is shown and may help explain where the dependency comes from. > /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rockchip-rkbin-tf-a_git.bb has unique dependees: > > /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rk3308-rkbin_git.bb has unique dependees: > > It could be that one recipe provides something the other doesn't and should. The following provider and runtime provider differences may be helpful. > /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rockchip-rkbin-tf-a_git.bb has unique provides: > > /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rockchip-rkbin-tf-a_git.bb has unique rprovides: > ^rockchip-rkbin-tf-a-locale-.* > rockchip-rkbin-tf-a > /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rk3308-rkbin_git.bb has unique provides: > rockchip-rkbin-optee-os > rk3308-rkbin > rockchip-rkbin-ddr > optee-os > /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rk3308-rkbin_git.bb has unique rprovides: > rk3308-rkbin > ^rk3308-rkbin-locale-.* > ERROR: Multiple .bb files are due to be built which each provide trusted-firmware-a: > /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rockchip-rkbin-tf-a_git.bb > /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rk3308-rkbin_git.bb > A list of tasks depending on these providers is shown and may help explain where the dependency comes from. > /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rockchip-rkbin-tf-a_git.bb has unique dependees: > > /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rk3308-rkbin_git.bb has unique dependees: > > It could be that one recipe provides something the other doesn't and should. The following provider and runtime provider differences may be helpful. > /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rockchip-rkbin-tf-a_git.bb has unique provides: > > /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rockchip-rkbin-tf-a_git.bb has unique rprovides: > ^rockchip-rkbin-tf-a-locale-.* > rockchip-rkbin-tf-a > /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rk3308-rkbin_git.bb has unique provides: > rockchip-rkbin-optee-os > rk3308-rkbin > rockchip-rkbin-ddr > optee-os > /scratch/trevor/oe/builds/meta-rockchip/layers/meta-rockchip/recipes-bsp/rkbin/rk3308-rkbin_git.bb has unique rprovides: > rk3308-rkbin > ^rk3308-rkbin-locale-.* > > > The way I suggested builds in all cases, and runs fine both ways too. > Wondering if the righthand of PREFERRED_PROVIDER is pointing to a recipe? We have kind a special case with a virtual provider matching a recipe, maybe that's tripping some code. I'm wondering whether we shouldn't merge rk3308-rkbin with the other ones and have RKBIN_RK3308_LATEST handled in the recipes directly. In any case, not necessary for now. Thus, since it fixes the actual issue this patch seems fine: Reviewed-by: Quentin Schulz <quentin.schulz@cherry.de> Thanks! Quentin
On Fri 2024-12-13 @ 10:48:43 AM, Trevor Woerner wrote: > A PREFERRED_PROVIDER entry was missed for rk3308 builds: > > NOTE: Multiple providers are available for trusted-firmware-a (rk3308-rkbin, rockchip-rkbin-tf-a) > Consider defining a PREFERRED_PROVIDER entry to match trusted-firmware-a > > This allows the RKBIN_RK3308_LATEST knob to work in all cases again. > > Signed-off-by: Trevor Woerner <twoerner@gmail.com> > --- > changes from v1 > - added > --- > conf/machine/include/rk3308.inc | 1 + > 1 file changed, 1 insertion(+) Added to meta-rockchip, branches master and styhead.
diff --git a/conf/machine/include/rk3308.inc b/conf/machine/include/rk3308.inc index 1ecf085cd5de..d30901f15b4f 100644 --- a/conf/machine/include/rk3308.inc +++ b/conf/machine/include/rk3308.inc @@ -19,6 +19,7 @@ KERNEL_IMAGETYPE ?= "fitImage" UBOOT_SUFFIX ?= "itb" UBOOT_ENTRYPOINT ?= "0x06000000" +PREFERRED_PROVIDER_trusted-firmware-a = "${@bb.utils.contains('RKBIN_RK3308_LATEST', '1', 'rockchip-rkbin-tf-a', 'rk3308-rkbin', d)}" PREFERRED_PROVIDER_rockchip-rkbin-ddr = "${@bb.utils.contains('RKBIN_RK3308_LATEST', '1', 'rockchip-rkbin-ddr', 'rk3308-rkbin', d)}" PREFERRED_PROVIDER_rockchip-rkbin-tf-a = "${@bb.utils.contains('RKBIN_RK3308_LATEST', '1', 'rockchip-rkbin-tf-a', 'rk3308-rkbin', d)}" PREFERRED_PROVIDER_rockchip-rkbin-optee-os = "${@bb.utils.contains('RKBIN_RK3308_LATEST', '1', 'rockchip-rkbin-optee-os', 'rk3308-rkbin', d)}"
A PREFERRED_PROVIDER entry was missed for rk3308 builds: NOTE: Multiple providers are available for trusted-firmware-a (rk3308-rkbin, rockchip-rkbin-tf-a) Consider defining a PREFERRED_PROVIDER entry to match trusted-firmware-a This allows the RKBIN_RK3308_LATEST knob to work in all cases again. Signed-off-by: Trevor Woerner <twoerner@gmail.com> --- changes from v1 - added --- conf/machine/include/rk3308.inc | 1 + 1 file changed, 1 insertion(+)