gallium/va: Add support for PRIME_2 import.

That way we can actually import surfaces with modifiers & metadata
planes.

Tested with patches for ffmpeg to use this with kmsgrab & modifiers.

For AMD & multiplanar formats we always have 1 format plane = 1
memory plane, even with modifiers.

Intel (non Gallium) does have 1 format plane is 2 memory planes
for some modifiers with NV12. Currently with Gallium we don't really
have info about layer/plane ordering so this manually orders things
so that they align with Intel.

This shouldn't impact other drivers as without modifiers with metadata
planes this should give equivalent behavior to the old import path.

Reviewed-and-Tested-by: Leo Liu <leo.liu@amd.com>
Part-of: <mesa/mesa!10815>
185 jobs for aco_vskip
latest
Status Job ID Name Coverage
  Container
manual #10828098
aarch64 manual
arm_build
manual #10828099
windows shell 1809 mesa manual
windows_build_vs2019
manual #10828096
manual
x86_build-base
manual #10828097
manual
x86_test-base
 
  Container 2
created #10828104
android_build
created #10828101
i386_build
created #10828107
kernel+rootfs_amd64
created #10828108
aarch64
kernel+rootfs_arm64
created #10828109
aarch64
kernel+rootfs_armhf
created #10828102
ppc64el_build
created #10828103
s390x_build
created #10828100
x86_build
created #10828105
x86_test-gl
created #10828106
x86_test-vk
 
  Meson X86 64
created #10828115
meson-clang
created #10828116
meson-clover
created #10828112
meson-clover-testing
created #10828113
meson-gallium
created #10828114
meson-release
created #10828110
meson-testing
created #10828111
meson-testing-asan
created #10828117
meson-vulkan
 
  Build Misc
created #10828118
arm_test
created #10828119
meson-android
created #10828121
aarch64
meson-arm64
created #10828122
aarch64
meson-arm64-asan
created #10828123
aarch64
meson-arm64-build-test
created #10828120
aarch64
meson-armhf
created #10828125
meson-i386
created #10828128
meson-mingw32-x86_64
created #10828127
meson-ppc64el
created #10828126
kvm
meson-s390x
created #10828124
windows docker 1809 mesa
meson-windows-vs2019
 
  Amd
created #10828137
mesa-ci-x86-64-lava-hp-11A-G6-EE-grunt
radeonsi-stoney-gles2:amd64
created #10828140
mesa-ci-x86-64-lava-hp-11A-G6-EE-grunt
radeonsi-stoney-gles31:amd64 1/2
created #10828141
mesa-ci-x86-64-lava-hp-11A-G6-EE-grunt
radeonsi-stoney-gles31:amd64 2/2
created #10828138
mesa-ci-x86-64-lava-hp-11A-G6-EE-grunt
radeonsi-stoney-gles3:amd64 1/2
created #10828139
mesa-ci-x86-64-lava-hp-11A-G6-EE-grunt
radeonsi-stoney-gles3:amd64 2/2
created #10828143
mesa-ci-x86-64-lava-hp-11A-G6-EE-grunt
radeonsi-stoney-piglit-gl:amd64
created #10828142
mesa-ci-x86-64-lava-hp-11A-G6-EE-grunt
radeonsi-stoney-traces:amd64
created #10828136
radv-fossils
created #10828130
amdgpu:codename:NAVY_FLOUNDER manual
radv-navy_flounder-traces
created #10828129
amdgpu:codename:NAVY_FLOUNDER manual
radv-navy_flounder-vkd3d-proton
created #10828132
polaris10 manual
radv_polaris10_vkcts
created #10828131
amdgpu:codename:RAVEN manual
radv-raven-traces
created #10828133
mesa-ci-x86-64-lava-hp-11A-G6-EE-grunt
radv_stoney_vkcts:amd64 1/3
created #10828134
mesa-ci-x86-64-lava-hp-11A-G6-EE-grunt
radv_stoney_vkcts:amd64 2/3
created #10828135
mesa-ci-x86-64-lava-hp-11A-G6-EE-grunt
radv_stoney_vkcts:amd64 3/3
 
  Intel
created #10828144
anholt-g33 manual
i915-g33-deqp
created #10828145
anholt-g33 manual
i915-g33-khr-deqp
created #10828146
anholt-g33 manual
i915-g33-piglit
created #10828147
anholt-g33 manual
i915-g33-traces
created #10828162
mesa-ci-x86-64-lava-asus-C433TA-AJ0005-rammus
iris-amly-egl
created #10828161
mesa-ci-x86-64-lava-asus-C433TA-AJ0005-rammus
iris-amly-gl
created #10828158
mesa-ci-x86-64-lava-asus-C433TA-AJ0005-rammus
iris-amly-gles2
created #10828159
mesa-ci-x86-64-lava-asus-C433TA-AJ0005-rammus manual
iris-amly-gles3
created #10828160
mesa-ci-x86-64-lava-asus-C433TA-AJ0005-rammus manual
iris-amly-gles31
created #10828163
mesa-ci-x86-64-lava-asus-C433TA-AJ0005-rammus
iris-amly-piglit 1/3
created #10828164
mesa-ci-x86-64-lava-asus-C433TA-AJ0005-rammus
iris-amly-piglit 2/3
created #10828165
mesa-ci-x86-64-lava-asus-C433TA-AJ0005-rammus
iris-amly-piglit 3/3
created #10828168
mesa-ci-x86-64-lava-asus-C433TA-AJ0005-rammus
iris-amly-traces
created #10828152
mesa-ci-x86-64-lava-asus-C523NA-A20057-coral
iris-apl-egl
created #10828151
mesa-ci-x86-64-lava-asus-C523NA-A20057-coral manual
iris-apl-gl
created #10828148
mesa-ci-x86-64-lava-asus-C523NA-A20057-coral
iris-apl-gles2
created #10828149
mesa-ci-x86-64-lava-asus-C523NA-A20057-coral
iris-apl-gles3
created #10828150
mesa-ci-x86-64-lava-asus-C523NA-A20057-coral
iris-apl-gles31
created #10828166
mesa-ci-x86-64-lava-asus-C523NA-A20057-coral
iris-apl-traces
created #10828157
mesa-ci-x86-64-lava-hp-x360-12b-n4000-octopus manual
iris-glk-egl
created #10828156
mesa-ci-x86-64-lava-hp-x360-12b-n4000-octopus manual
iris-glk-gl
created #10828153
mesa-ci-x86-64-lava-hp-x360-12b-n4000-octopus manual
iris-glk-gles2
created #10828154
mesa-ci-x86-64-lava-hp-x360-12b-n4000-octopus manual
iris-glk-gles3
created #10828155
mesa-ci-x86-64-lava-hp-x360-12b-n4000-octopus manual
iris-glk-gles31
created #10828167
mesa-ci-x86-64-lava-hp-x360-12b-n4000-octopus manual
iris-glk-traces
created #10828169
mesa-ci-x86-64-lava-hp-x360-14-G1-sona manual
iris-kbl-traces
 
  Arm
created #10828179
mesa-ci-x86-64-lava-meson-g12b-a311d-khadas-vim3
panfrost-g52-gles31:arm64
created #10828177
mesa-ci-x86-64-lava-meson-g12b-a311d-khadas-vim3
panfrost-g52-gles3:arm64 1/2
created #10828178
mesa-ci-x86-64-lava-meson-g12b-a311d-khadas-vim3
panfrost-g52-gles3:arm64 2/2
created #10828170
mesa-ci-x86-64-lava-sun50i-h6-pine-h64
panfrost-t720-gles2:arm64
created #10828171
mesa-ci-x86-64-lava-rk3288-veyron-jaq
panfrost-t760-gles2:armhf
created #10828172
mesa-ci-x86-64-lava-rk3288-veyron-jaq
panfrost-t760-traces:armhf
created #10828175
mesa-ci-x86-64-lava-rk3399-gru-kevin
panfrost-t860-gles31:arm64
created #10828173
mesa-ci-x86-64-lava-rk3399-gru-kevin
panfrost-t860-gles3:arm64 1/2
created #10828174
mesa-ci-x86-64-lava-rk3399-gru-kevin
panfrost-t860-gles3:arm64 2/2
created #10828176
mesa-ci-x86-64-lava-rk3399-gru-kevin
panfrost-t860-traces:arm64
 
  Broadcom
created #10828202
igalia-rpi4
v3d-rpi4-egl:armhf
created #10828198
igalia-rpi4
v3d-rpi4-gles2:armhf
created #10828192
igalia-rpi4
v3d-rpi4-gles31:armhf 1/2
created #10828193
igalia-rpi4
v3d-rpi4-gles31:armhf 2/2
created #10828194
igalia-rpi4
v3d-rpi4-gles3:armhf 1/4
created #10828195
igalia-rpi4
v3d-rpi4-gles3:armhf 2/4
created #10828196
igalia-rpi4
v3d-rpi4-gles3:armhf 3/4
created #10828197
igalia-rpi4
v3d-rpi4-gles3:armhf 4/4
created #10828201
igalia-rpi4
v3d-rpi4-khr-gles2:armhf
created #10828199
igalia-rpi4
v3d-rpi4-khr-gles31:armhf
created #10828200
igalia-rpi4
v3d-rpi4-khr-gles3:armhf
created #10828203
igalia-rpi4
v3d-rpi4-piglit:armhf 1/3
created #10828204
igalia-rpi4
v3d-rpi4-piglit:armhf 2/3
created #10828205
igalia-rpi4
v3d-rpi4-piglit:armhf 3/3
created #10828206
igalia-rpi4
v3dv-rpi4-vk:arm64 1/6
created #10828207
igalia-rpi4
v3dv-rpi4-vk:arm64 2/6
created #10828208
igalia-rpi4
v3dv-rpi4-vk:arm64 3/6
created #10828209
igalia-rpi4
v3dv-rpi4-vk:arm64 4/6
created #10828210
igalia-rpi4
v3dv-rpi4-vk:arm64 5/6
created #10828211
igalia-rpi4
v3dv-rpi4-vk:arm64 6/6
created #10828185
igalia-rpi3
vc4-rpi3-egl:armhf
created #10828180
igalia-rpi3
vc4-rpi3-gles2:armhf 1/4
created #10828181
igalia-rpi3
vc4-rpi3-gles2:armhf 2/4
created #10828182
igalia-rpi3
vc4-rpi3-gles2:armhf 3/4
created #10828183
igalia-rpi3
vc4-rpi3-gles2:armhf 4/4
created #10828184
igalia-rpi3
vc4-rpi3-khr-gles2:armhf
created #10828186
igalia-rpi3 manual
vc4-rpi3-piglit-quick_gl:armhf 1/4
created #10828187
igalia-rpi3 manual
vc4-rpi3-piglit-quick_gl:armhf 2/4
created #10828188
igalia-rpi3 manual
vc4-rpi3-piglit-quick_gl:armhf 3/4
created #10828189
igalia-rpi3 manual
vc4-rpi3-piglit-quick_gl:armhf 4/4
created #10828190
igalia-rpi3 manual
vc4-rpi3-piglit-quick_shader:armhf 1/2
created #10828191
igalia-rpi3 manual
vc4-rpi3-piglit-quick_shader:armhf 2/2
 
  Freedreno
created #10828212
google-freedreno-db410c
a306_gles2
created #10828213
google-freedreno-db410c
a306_gles3 1/3
created #10828214
google-freedreno-db410c
a306_gles3 2/3
created #10828215
google-freedreno-db410c
a306_gles3 3/3
created #10828216
google-freedreno-db410c
a306_gles3_options
created #10828217
google-freedreno-db410c
a306-traces
created #10828218
google-freedreno-db820c
a530_gles2
created #10828221
google-freedreno-db820c
a530_gles31 1/2
created #10828219
google-freedreno-db820c
a530_gles3 1/2
created #10828222
google-freedreno-db820c
a530_gles31 2/2
created #10828220
google-freedreno-db820c
a530_gles3 2/2
created #10828223
google-freedreno-db820c manual
a530_piglit_gl
created #10828224
google-freedreno-db820c
a530_piglit_shader 1/2
created #10828225
google-freedreno-db820c
a530_piglit_shader 2/2
created #10828226
google-freedreno-db820c
a530-traces
created #10828231
google-freedreno-cheza
a630_egl
created #10828230
google-freedreno-cheza
a630_gl
created #10828227
google-freedreno-cheza
a630_gles2
created #10828229
google-freedreno-cheza
a630_gles3
created #10828228
google-freedreno-cheza
a630_gles31
created #10828233
google-freedreno-cheza manual
a630_gles_asan
created #10828232
google-freedreno-cheza
a630_gles_others
created #10828238
google-freedreno-cheza
a630_piglit
created #10828239
google-freedreno-cheza
a630-traces
created #10828234
google-freedreno-cheza
a630_vk 1/2
created #10828235
google-freedreno-cheza
a630_vk 2/2
created #10828236
google-freedreno-cheza manual
a630_vk_asan
created #10828237
google-freedreno-cheza
a630_vk_sysmem
 
  Software Renderer
created #10828262
lavapipe-nir-stress
created #10828261
lavapipe-vk
created #10828250
llvmpipe-egl
created #10828248
llvmpipe-gl
created #10828245
llvmpipe-gles2
created #10828246
llvmpipe-gles3
created #10828247
llvmpipe-gles31
created #10828249
llvmpipe-khr-gles2
created #10828240
llvmpipe-piglit-cl
created #10828242
llvmpipe-piglit-glslparser
created #10828241
llvmpipe-piglit-quick_gl
created #10828243
llvmpipe-piglit-quick_shader
created #10828244
llvmpipe-traces
created #10828258
softpipe-asan-gles31
created #10828260
softpipe-gl
created #10828251
softpipe-gles2
created #10828252
softpipe-gles3
created #10828253
softpipe-gles31 1/2
created #10828254
softpipe-gles31 2/2
created #10828255
softpipe-khr-gles2
created #10828256
softpipe-khr-gles3
created #10828257
softpipe-khr-gles31
created #10828259
softpipe-piglit-quick
 
  Layered Backends
created #10828279
windows docker 1809 mesa
test-d3d12-windows
created #10828267
virgl-gl30-on-gl
created #10828268
virgl-gl31-on-gl
created #10828269
virgl-gl32-on-gl
created #10828263
virgl-gles2-on-gl
created #10828270
manual
virgl-gles2-on-gles
created #10828265
virgl-gles31-on-gl 1/2
created #10828266
virgl-gles31-on-gl 2/2
created #10828272
manual
virgl-gles31-on-gles 1/2
created #10828273
manual
virgl-gles31-on-gles 2/2
created #10828264
virgl-gles3-on-gl
created #10828271
manual
virgl-gles3-on-gles
created #10828274
kvm
virgl-traces
created #10828278
zink-lvp-gl
created #10828276
zink-lvp-gles2
created #10828277
zink-lvp-gles3
created #10828275
zink-piglit-quick_gl
 
  Deploy
manual #10828280
manual
test-docs