mbox series

[kirkstone,0/4] Graphics, graphics, and more graphics

Message ID 20230126030834.3889448-1-rs@ti.com
Headers show
Series Graphics, graphics, and more graphics | expand

Message

Randolph Sapp Jan. 26, 2023, 3:08 a.m. UTC
Alright, this is the 6th revision of this patch. This uses a revised
dependency chain (hopefully it's a little more logical) and some, well,
interesting switching logic using the PACKAGECONFIG and
virtual/gpudriver PREFERRED_PROVIDER override variable. I'm not sure how
I feel about it, but it solves the issue of silently configuring things
as needed without other layers manually enabling features.

We basically dynamically adjust mesa's PACKAGECONFIG based on what our
selected gpudriver (and display controller, thanks sgx) is. We also add
a runtime recommendation on the gpudriver after this configuration.

The gpudriver providers didn't change too much, they just have a runtime
recommendation for the associated um components. As it stands, the um
components can live alongside the software rendering components thanks
to the mesa-megadriver being able to automatically switch as necessary
at runtime, so we will not clobber mesa's usual packages.

Then we drop all mentions of the gpu machine feature for good measure.

"Why didn't you just add preferred providers for libgles2, etc, etc."
Well, software rendering. If we do that we'll have to edit the
PACKAGECONFIG to drop gles components from mesa, disabling software
rendering. We could add a dynamic switch to do that, but honestly
keeping in line with KISS, this solution has fewer lines and less logic
while keeping swrast as a nice fallback for whenever anything really
goes south... not that I'm expecting that or anything.

Randolph Sapp (4):
  meta-ti-bsp: mesa: Add current patches
  meta-ti-bsp: graphics: Resolve dependency chain
  meta-ti-bsp: machine: Remove all gpu features
  meta-ti-bsp: machine: Attempt to update DC alias

 meta-ti-bsp/conf/machine/am62xx-lp-evm.conf   |   2 -
 meta-ti-bsp/conf/machine/include/am62xx.inc   |   6 +-
 meta-ti-bsp/conf/machine/include/am65xx.inc   |   6 +-
 meta-ti-bsp/conf/machine/include/j721e.inc    |   6 -
 meta-ti-bsp/conf/machine/include/j721s2.inc   |   6 -
 meta-ti-bsp/conf/machine/include/j784s4.inc   |   6 -
 meta-ti-bsp/conf/machine/include/omap-a15.inc |   9 +-
 meta-ti-bsp/conf/machine/include/ti33x.inc    |   9 +-
 meta-ti-bsp/conf/machine/include/ti43x.inc    |   9 +-
 meta-ti-bsp/conf/machine/j784s4-evm.conf      |   2 +
 ...-OpenEmbedded-nodistro-internal-aarc.patch |  29 ----
 ...bb => ti-img-rogue-driver_1.18.6276027.bb} |  20 +--
 .../ti-sgx-ddk-km_1.17.4948957.bb             |   8 +-
 .../ti-img-rogue-umlibs_1.15.6133109.bb       |  71 --------
 .../ti-img-rogue-umlibs_1.18.6276027.bb       |  39 +++++
 .../libgles/ti-sgx-ddk-um_1.17.4948957.bb     |  31 +---
 ...nd-deprecate-drm_handle_format-and-d.patch | 158 ++++++++++++++++++
 ...fine-__NR_futex-if-it-does-not-exist.patch |  34 ++++
 ...sdetects-64bit-atomics-on-mips-clang.patch |  25 +++
 ...k-for-all-linux-host_os-combinations.patch |  43 +++++
 ...ormat-Check-for-NEON-before-using-it.patch |  47 ++++++
 ...02-meson.build-make-TLS-ELF-optional.patch |  61 +++++++
 .../mesa/mesa-gl_22.0.%.bbappend              |   1 +
 .../mesa/mesa_22.0.%.bbappend                 |   2 +
 .../recipes-graphics/mesa/pvr-mesa.inc        |  39 +++++
 25 files changed, 484 insertions(+), 185 deletions(-)
 delete mode 100644 meta-ti-bsp/recipes-bsp/powervr-drivers/ti-img-rogue-driver/0001-compiler-support-OpenEmbedded-nodistro-internal-aarc.patch
 rename meta-ti-bsp/recipes-bsp/powervr-drivers/{ti-img-rogue-driver_1.15.6133109.bb => ti-img-rogue-driver_1.18.6276027.bb} (72%)
 delete mode 100644 meta-ti-bsp/recipes-graphics/libgles/ti-img-rogue-umlibs_1.15.6133109.bb
 create mode 100644 meta-ti-bsp/recipes-graphics/libgles/ti-img-rogue-umlibs_1.18.6276027.bb
 create mode 100644 meta-ti-bsp/recipes-graphics/mesa/files/0001-Revert-egl-wayland-deprecate-drm_handle_format-and-d.patch
 create mode 100644 meta-ti-bsp/recipes-graphics/mesa/files/0001-futex.h-Define-__NR_futex-if-it-does-not-exist.patch
 create mode 100644 meta-ti-bsp/recipes-graphics/mesa/files/0001-meson-misdetects-64bit-atomics-on-mips-clang.patch
 create mode 100644 meta-ti-bsp/recipes-graphics/mesa/files/0001-meson.build-check-for-all-linux-host_os-combinations.patch
 create mode 100644 meta-ti-bsp/recipes-graphics/mesa/files/0001-util-format-Check-for-NEON-before-using-it.patch
 create mode 100644 meta-ti-bsp/recipes-graphics/mesa/files/0002-meson.build-make-TLS-ELF-optional.patch
 create mode 100644 meta-ti-bsp/recipes-graphics/mesa/mesa-gl_22.0.%.bbappend
 create mode 100644 meta-ti-bsp/recipes-graphics/mesa/mesa_22.0.%.bbappend
 create mode 100644 meta-ti-bsp/recipes-graphics/mesa/pvr-mesa.inc

Comments

Andrew Davis Jan. 26, 2023, 6:13 p.m. UTC | #1
On 1/25/23 9:08 PM, Randolph Sapp wrote:
> Alright, this is the 6th revision of this patch. This uses a revised

I've personally had series go to v15+ and v30+ is not unheard of upstream :)

The subject tag look wrong, recommend something like:

> git format-patch origin/kirkstone -o output -C --cover-letter --subject-prefix="meta-ti][master/kirkstone][PATCH v6"

Andrew

> dependency chain (hopefully it's a little more logical) and some, well,
> interesting switching logic using the PACKAGECONFIG and
> virtual/gpudriver PREFERRED_PROVIDER override variable. I'm not sure how
> I feel about it, but it solves the issue of silently configuring things
> as needed without other layers manually enabling features.
> 
> We basically dynamically adjust mesa's PACKAGECONFIG based on what our
> selected gpudriver (and display controller, thanks sgx) is. We also add
> a runtime recommendation on the gpudriver after this configuration.
> 
> The gpudriver providers didn't change too much, they just have a runtime
> recommendation for the associated um components. As it stands, the um
> components can live alongside the software rendering components thanks
> to the mesa-megadriver being able to automatically switch as necessary
> at runtime, so we will not clobber mesa's usual packages.
> 
> Then we drop all mentions of the gpu machine feature for good measure.
> 
> "Why didn't you just add preferred providers for libgles2, etc, etc."
> Well, software rendering. If we do that we'll have to edit the
> PACKAGECONFIG to drop gles components from mesa, disabling software
> rendering. We could add a dynamic switch to do that, but honestly
> keeping in line with KISS, this solution has fewer lines and less logic
> while keeping swrast as a nice fallback for whenever anything really
> goes south... not that I'm expecting that or anything.
> 
> Randolph Sapp (4):
>    meta-ti-bsp: mesa: Add current patches
>    meta-ti-bsp: graphics: Resolve dependency chain
>    meta-ti-bsp: machine: Remove all gpu features
>    meta-ti-bsp: machine: Attempt to update DC alias
> 
>   meta-ti-bsp/conf/machine/am62xx-lp-evm.conf   |   2 -
>   meta-ti-bsp/conf/machine/include/am62xx.inc   |   6 +-
>   meta-ti-bsp/conf/machine/include/am65xx.inc   |   6 +-
>   meta-ti-bsp/conf/machine/include/j721e.inc    |   6 -
>   meta-ti-bsp/conf/machine/include/j721s2.inc   |   6 -
>   meta-ti-bsp/conf/machine/include/j784s4.inc   |   6 -
>   meta-ti-bsp/conf/machine/include/omap-a15.inc |   9 +-
>   meta-ti-bsp/conf/machine/include/ti33x.inc    |   9 +-
>   meta-ti-bsp/conf/machine/include/ti43x.inc    |   9 +-
>   meta-ti-bsp/conf/machine/j784s4-evm.conf      |   2 +
>   ...-OpenEmbedded-nodistro-internal-aarc.patch |  29 ----
>   ...bb => ti-img-rogue-driver_1.18.6276027.bb} |  20 +--
>   .../ti-sgx-ddk-km_1.17.4948957.bb             |   8 +-
>   .../ti-img-rogue-umlibs_1.15.6133109.bb       |  71 --------
>   .../ti-img-rogue-umlibs_1.18.6276027.bb       |  39 +++++
>   .../libgles/ti-sgx-ddk-um_1.17.4948957.bb     |  31 +---
>   ...nd-deprecate-drm_handle_format-and-d.patch | 158 ++++++++++++++++++
>   ...fine-__NR_futex-if-it-does-not-exist.patch |  34 ++++
>   ...sdetects-64bit-atomics-on-mips-clang.patch |  25 +++
>   ...k-for-all-linux-host_os-combinations.patch |  43 +++++
>   ...ormat-Check-for-NEON-before-using-it.patch |  47 ++++++
>   ...02-meson.build-make-TLS-ELF-optional.patch |  61 +++++++
>   .../mesa/mesa-gl_22.0.%.bbappend              |   1 +
>   .../mesa/mesa_22.0.%.bbappend                 |   2 +
>   .../recipes-graphics/mesa/pvr-mesa.inc        |  39 +++++
>   25 files changed, 484 insertions(+), 185 deletions(-)
>   delete mode 100644 meta-ti-bsp/recipes-bsp/powervr-drivers/ti-img-rogue-driver/0001-compiler-support-OpenEmbedded-nodistro-internal-aarc.patch
>   rename meta-ti-bsp/recipes-bsp/powervr-drivers/{ti-img-rogue-driver_1.15.6133109.bb => ti-img-rogue-driver_1.18.6276027.bb} (72%)
>   delete mode 100644 meta-ti-bsp/recipes-graphics/libgles/ti-img-rogue-umlibs_1.15.6133109.bb
>   create mode 100644 meta-ti-bsp/recipes-graphics/libgles/ti-img-rogue-umlibs_1.18.6276027.bb
>   create mode 100644 meta-ti-bsp/recipes-graphics/mesa/files/0001-Revert-egl-wayland-deprecate-drm_handle_format-and-d.patch
>   create mode 100644 meta-ti-bsp/recipes-graphics/mesa/files/0001-futex.h-Define-__NR_futex-if-it-does-not-exist.patch
>   create mode 100644 meta-ti-bsp/recipes-graphics/mesa/files/0001-meson-misdetects-64bit-atomics-on-mips-clang.patch
>   create mode 100644 meta-ti-bsp/recipes-graphics/mesa/files/0001-meson.build-check-for-all-linux-host_os-combinations.patch
>   create mode 100644 meta-ti-bsp/recipes-graphics/mesa/files/0001-util-format-Check-for-NEON-before-using-it.patch
>   create mode 100644 meta-ti-bsp/recipes-graphics/mesa/files/0002-meson.build-make-TLS-ELF-optional.patch
>   create mode 100644 meta-ti-bsp/recipes-graphics/mesa/mesa-gl_22.0.%.bbappend
>   create mode 100644 meta-ti-bsp/recipes-graphics/mesa/mesa_22.0.%.bbappend
>   create mode 100644 meta-ti-bsp/recipes-graphics/mesa/pvr-mesa.inc
>
Denys Dmytriyenko Jan. 26, 2023, 8:46 p.m. UTC | #2
On Thu, Jan 26, 2023 at 12:13:37PM -0600, Andrew Davis via lists.yoctoproject.org wrote:
> On 1/25/23 9:08 PM, Randolph Sapp wrote:
> >Alright, this is the 6th revision of this patch. This uses a revised
> 
> I've personally had series go to v15+ and v30+ is not unheard of upstream :)
> 
> The subject tag look wrong, recommend something like:
> 
> >git format-patch origin/kirkstone -o output -C --cover-letter --subject-prefix="meta-ti][master/kirkstone][PATCH v6"

1. You can drop "meta-ti" part in the subject as the mailing list will add it
2. I thought we wanted to go for kirkstone first to avoid duplicating upstream 
mesa, hence "kirkstone" is more correct, instead of "master/kirkstone"


> Andrew
> 
> >dependency chain (hopefully it's a little more logical) and some, well,
> >interesting switching logic using the PACKAGECONFIG and
> >virtual/gpudriver PREFERRED_PROVIDER override variable. I'm not sure how
> >I feel about it, but it solves the issue of silently configuring things
> >as needed without other layers manually enabling features.
> >
> >We basically dynamically adjust mesa's PACKAGECONFIG based on what our
> >selected gpudriver (and display controller, thanks sgx) is. We also add
> >a runtime recommendation on the gpudriver after this configuration.
> >
> >The gpudriver providers didn't change too much, they just have a runtime
> >recommendation for the associated um components. As it stands, the um
> >components can live alongside the software rendering components thanks
> >to the mesa-megadriver being able to automatically switch as necessary
> >at runtime, so we will not clobber mesa's usual packages.
> >
> >Then we drop all mentions of the gpu machine feature for good measure.
> >
> >"Why didn't you just add preferred providers for libgles2, etc, etc."
> >Well, software rendering. If we do that we'll have to edit the
> >PACKAGECONFIG to drop gles components from mesa, disabling software
> >rendering. We could add a dynamic switch to do that, but honestly
> >keeping in line with KISS, this solution has fewer lines and less logic
> >while keeping swrast as a nice fallback for whenever anything really
> >goes south... not that I'm expecting that or anything.
> >
> >Randolph Sapp (4):
> >   meta-ti-bsp: mesa: Add current patches
> >   meta-ti-bsp: graphics: Resolve dependency chain
> >   meta-ti-bsp: machine: Remove all gpu features
> >   meta-ti-bsp: machine: Attempt to update DC alias
> >
> >  meta-ti-bsp/conf/machine/am62xx-lp-evm.conf   |   2 -
> >  meta-ti-bsp/conf/machine/include/am62xx.inc   |   6 +-
> >  meta-ti-bsp/conf/machine/include/am65xx.inc   |   6 +-
> >  meta-ti-bsp/conf/machine/include/j721e.inc    |   6 -
> >  meta-ti-bsp/conf/machine/include/j721s2.inc   |   6 -
> >  meta-ti-bsp/conf/machine/include/j784s4.inc   |   6 -
> >  meta-ti-bsp/conf/machine/include/omap-a15.inc |   9 +-
> >  meta-ti-bsp/conf/machine/include/ti33x.inc    |   9 +-
> >  meta-ti-bsp/conf/machine/include/ti43x.inc    |   9 +-
> >  meta-ti-bsp/conf/machine/j784s4-evm.conf      |   2 +
> >  ...-OpenEmbedded-nodistro-internal-aarc.patch |  29 ----
> >  ...bb => ti-img-rogue-driver_1.18.6276027.bb} |  20 +--
> >  .../ti-sgx-ddk-km_1.17.4948957.bb             |   8 +-
> >  .../ti-img-rogue-umlibs_1.15.6133109.bb       |  71 --------
> >  .../ti-img-rogue-umlibs_1.18.6276027.bb       |  39 +++++
> >  .../libgles/ti-sgx-ddk-um_1.17.4948957.bb     |  31 +---
> >  ...nd-deprecate-drm_handle_format-and-d.patch | 158 ++++++++++++++++++
> >  ...fine-__NR_futex-if-it-does-not-exist.patch |  34 ++++
> >  ...sdetects-64bit-atomics-on-mips-clang.patch |  25 +++
> >  ...k-for-all-linux-host_os-combinations.patch |  43 +++++
> >  ...ormat-Check-for-NEON-before-using-it.patch |  47 ++++++
> >  ...02-meson.build-make-TLS-ELF-optional.patch |  61 +++++++
> >  .../mesa/mesa-gl_22.0.%.bbappend              |   1 +
> >  .../mesa/mesa_22.0.%.bbappend                 |   2 +
> >  .../recipes-graphics/mesa/pvr-mesa.inc        |  39 +++++
> >  25 files changed, 484 insertions(+), 185 deletions(-)
> >  delete mode 100644 meta-ti-bsp/recipes-bsp/powervr-drivers/ti-img-rogue-driver/0001-compiler-support-OpenEmbedded-nodistro-internal-aarc.patch
> >  rename meta-ti-bsp/recipes-bsp/powervr-drivers/{ti-img-rogue-driver_1.15.6133109.bb => ti-img-rogue-driver_1.18.6276027.bb} (72%)
> >  delete mode 100644 meta-ti-bsp/recipes-graphics/libgles/ti-img-rogue-umlibs_1.15.6133109.bb
> >  create mode 100644 meta-ti-bsp/recipes-graphics/libgles/ti-img-rogue-umlibs_1.18.6276027.bb
> >  create mode 100644 meta-ti-bsp/recipes-graphics/mesa/files/0001-Revert-egl-wayland-deprecate-drm_handle_format-and-d.patch
> >  create mode 100644 meta-ti-bsp/recipes-graphics/mesa/files/0001-futex.h-Define-__NR_futex-if-it-does-not-exist.patch
> >  create mode 100644 meta-ti-bsp/recipes-graphics/mesa/files/0001-meson-misdetects-64bit-atomics-on-mips-clang.patch
> >  create mode 100644 meta-ti-bsp/recipes-graphics/mesa/files/0001-meson.build-check-for-all-linux-host_os-combinations.patch
> >  create mode 100644 meta-ti-bsp/recipes-graphics/mesa/files/0001-util-format-Check-for-NEON-before-using-it.patch
> >  create mode 100644 meta-ti-bsp/recipes-graphics/mesa/files/0002-meson.build-make-TLS-ELF-optional.patch
> >  create mode 100644 meta-ti-bsp/recipes-graphics/mesa/mesa-gl_22.0.%.bbappend
> >  create mode 100644 meta-ti-bsp/recipes-graphics/mesa/mesa_22.0.%.bbappend
> >  create mode 100644 meta-ti-bsp/recipes-graphics/mesa/pvr-mesa.inc