[yocto] [meta-raspberrypi][PATCH 5/5] rpi-default-providers: Switch providers according to used gfx stack

Andreas Müller schnitzeltony at googlemail.com
Mon Aug 3 13:14:29 PDT 2015


On Thu, Jul 30, 2015 at 10:34 AM, Javier Martinez Canillas
<javier at osg.samsung.com> wrote:
> From: Derek Foreman <derekf at osg.samsung.com>
>
> The Raspberry Pi boards can use one of two graphics stacks: The "userland"
> user-space driver or the VC4 drm/kms kernel driver. This patch allows the
> user to choose if the VC4 driver has to be used instead and set the right
> preferred providers for that case.
>
> Signed-off-by: Derek Foreman <derekf at osg.samsung.com>
> [javier: Extend commit msg and made conditional instead removing userland]
> Signed-off-by: Javier Martinez Canillas <javier at osg.samsung.com>
>
> ---
>
>  conf/machine/include/rpi-default-providers.inc | 8 ++++----
>  conf/machine/include/rpi-default-versions.inc  | 2 +-
>  2 files changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/conf/machine/include/rpi-default-providers.inc b/conf/machine/include/rpi-default-providers.inc
> index ee3a3acce7bd..233f177bd16e 100644
> --- a/conf/machine/include/rpi-default-providers.inc
> +++ b/conf/machine/include/rpi-default-providers.inc
> @@ -3,8 +3,8 @@
>  PREFERRED_PROVIDER_virtual/kernel = "linux-raspberrypi"
>  PREFERRED_PROVIDER_u-boot = "u-boot-rpi"
>  PREFERRED_PROVIDER_virtual/xserver = "xserver-xorg"
> -PREFERRED_PROVIDER_virtual/egl ?= "userland"
> -PREFERRED_PROVIDER_virtual/libgles2 ?= "userland"
> -PREFERRED_PROVIDER_virtual/libgl ?= "mesa-gl"
> -PREFERRED_PROVIDER_virtual/mesa ?= "mesa-gl"
> +PREFERRED_PROVIDER_virtual/egl ?= "${@bb.utils.contains('DISTRO_FEATURES', 'vc4-gfx', 'mesa', 'userland', d)}"
> +PREFERRED_PROVIDER_virtual/libgles2 ?= "${@bb.utils.contains('DISTRO_FEATURES', 'vc4-gfx', 'mesa', 'userland', d)}"
> +PREFERRED_PROVIDER_virtual/libgl ?= "${@bb.utils.contains('DISTRO_FEATURES', 'vc4-gfx', 'mesa', 'mesa-gl', d)}"
> +PREFERRED_PROVIDER_virtual/mesa ?= "${@bb.utils.contains('DISTRO_FEATURES', 'vc4-gfx', 'mesa', 'mesa-gl', d)}"
>  PREFERRED_PROVIDER_jpeg = "jpeg"
> diff --git a/conf/machine/include/rpi-default-versions.inc b/conf/machine/include/rpi-default-versions.inc
> index bcf78281b6ff..c07ecac5924b 100644
> --- a/conf/machine/include/rpi-default-versions.inc
> +++ b/conf/machine/include/rpi-default-versions.inc
> @@ -1,3 +1,3 @@
>  # RaspberryPi BSP default versions
>
> -PREFERRED_VERSION_linux-raspberrypi ?= "3.18.%"
> +PREFERRED_VERSION_linux-raspberrypi ?= "${@bb.utils.contains("DISTRO_FEATURES", "vc4-gfx", "4.1.%", "3.18.%", d)}"
> --
> 2.4.3
>
> --
This patch series is an exciting starter but I think it is incomplete:
Without further configuration mesa simply builds swrast which is not
what we want. We need some '--with-gallium-drivers=vc4' right? [1]

Andreas

[1] http://dri.freedesktop.org/wiki/VC4/



More information about the yocto mailing list