yocto.lists.yoctoproject.org archive mirror
 help / color / mirror / Atom feed
* [yocto][chromium] Need support to enable intel VAAPI with Chromium
@ 2023-06-07  1:24 huy nguyen
  2023-06-07  1:49 ` Mittal, Anuj
  0 siblings, 1 reply; 4+ messages in thread
From: huy nguyen @ 2023-06-07  1:24 UTC (permalink / raw)
  To: yocto


[-- Attachment #1.1: Type: text/plain, Size: 1824 bytes --]

Hi all,

I am working on Intel J4125 platform with these meta layers:
 - poky: master branch
 - meta-intel: master branch
 - meta-browser: master branch

1/ I build chromium by chromium-ozone-wayland_111.0.5563.147.bb recipe with
adding "use-vaapi" and "proprietary-codecs" to PACKAGECONFI in
chromium-gn.inc
That chromium did not call intel VAAPI functions, but I see it loads
iHD_drv_video.so
at runtime.

2/ Then I research to find this link about applying patches to support
VAAPI in chromium https://aur.archlinux.org/packages/chromium-wayland-vaapi
+ 0001-ozone-wayland-add-VA-API-support.patch
+ vaapi-add-av1-support.patch
+ use-oauth2-client-switches-as-default.patch
This chromium loads iHD_drv_video.so and calls Intel VAAPI APIs; however,
chromium reports these errors when I open to play an H264 video so that HW
Acceleration is not working





* [13436:13436:0606/150528.263552:ERROR:vaapi_wrapper.cc(2399)]
vaCreateSurfaces (import mode) failed, VA error: resource allocation
failed[13436:13436:0606/150528.263789:ERROR:vaapi_picture_native_pixmap_ozone.cc(73)]
Failed creating VASurface for
NativePixmap[13436:13436:0606/150528.264843:ERROR:vaapi_wrapper.cc(2399)]
vaCreateSurfaces (import mode) failed, VA error: resource allocation
failed[13436:13436:0606/150528.265073:ERROR:vaapi_picture_native_pixmap_ozone.cc(73)]
Failed creating VASurface for
NativePixmap[13436:13436:0606/150528.265294:VERBOSE1:vaapi_video_decode_accelerator.cc(142)]
NotifyError(): Notifying of error 4*

So far, I could not find a solution to fix chromium errors and I am new to
chromium, intel vaapi, libva debugging.

Please support how to debug the errors there or guidance on how to
officially build chromium with intel VAAPI support in Yocto?

I attached about:gpu in chromium, libva log and vainfo log here.

Thank you,
Huy

[-- Attachment #1.2: Type: text/html, Size: 4519 bytes --]

[-- Attachment #2: libva.152610.thd-0x0000067c --]
[-- Type: application/octet-stream, Size: 5846 bytes --]

[20498.740493][ctx       none]==========va_TraceInitialize
[20498.740523][ctx       none]=========vaInitialize ret = VA_STATUS_SUCCESS, success (no error) 
[20498.740580][ctx       none]==========va_TraceCreateConfig
[20498.740583][ctx       none]	profile = 7, VAProfileH264High
[20498.740585][ctx       none]	entrypoint = 1, VAEntrypointVLD
[20498.740586][ctx       none]	num_attribs = 1
[20498.740587][ctx       none]		attrib_list[0].type = 0x00000000, VAConfigAttribRTFormat
[20498.740588][ctx       none]		attrib_list[0].value = 0x00000001
[20498.740629][ctx       none]=========vaCreateConfig ret = VA_STATUS_SUCCESS, success (no error) 
[20498.753228][ctx       none]==========va_TraceCreateSurfaces
[20498.753237][ctx       none]	width = 1920
[20498.753237][ctx       none]	height = 1088
[20498.753238][ctx       none]	format = 131072
[20498.753238][ctx       none]	num_surfaces = 1
[20498.753239][ctx       none]		surfaces[0] = 0xffffffff
[20498.753240][ctx       none]	attrib_list[0] =
[20498.753241][ctx       none]		type = 6
[20498.753241][ctx       none]		flags = 2
[20498.753241][ctx       none]		value.type = 1
[20498.753242][ctx       none]		value.value.i = 0x40000000
[20498.753242][ctx       none]	attrib_list[1] =
[20498.753243][ctx       none]		type = 7
[20498.753243][ctx       none]		flags = 2
[20498.753244][ctx       none]		value.type = 3
[20498.753244][ctx       none]		value.value.p = 0x7fff1fc86bd0
[20498.753245][ctx       none]		--VADRMPRIMESurfaceDescriptor
[20498.753246][ctx       none]		  pixel_format=0x58424752
[20498.753246][ctx       none]		  width=1920
[20498.753247][ctx       none]		  height=1088
[20498.753247][ctx       none]		  num_objects=0x00000002
[20498.753248][ctx       none]			objects[0].fd=69
[20498.753249][ctx       none]			objects[0].size=8388608
[20498.753249][ctx       none]			objects[0].drm_format_modifier=4
[20498.753250][ctx       none]			objects[1].fd=75
[20498.753250][ctx       none]			objects[1].size=8388608
[20498.753251][ctx       none]			objects[1].drm_format_modifier=4
[20498.753251][ctx       none]		  num_layers=1
[20498.753252][ctx       none]			layers[0].drm_format=0x34324258
[20498.753253][ctx       none]			layers[0].num_planes=0x2
[20498.753253][ctx       none]				layers[0].object_index[0]=0x0
[20498.753254][ctx       none]				layers[0].offset[0]=0x0
[20498.753254][ctx       none]				layers[0].pitch[0]=0x7680
[20498.753255][ctx       none]				layers[0].object_index[1]=0x1
[20498.753256][ctx       none]				layers[0].offset[1]=0x8355840
[20498.753256][ctx       none]				layers[0].pitch[1]=0x256
[20498.753257][ctx       none]				layers[0].object_index[2]=0x0
[20498.753257][ctx       none]				layers[0].offset[2]=0x0
[20498.753258][ctx       none]				layers[0].pitch[2]=0x0
[20498.753258][ctx       none]				layers[0].object_index[3]=0x0
[20498.753259][ctx       none]				layers[0].offset[3]=0x0
[20498.753260][ctx       none]				layers[0].pitch[3]=0x0
[20498.753276][ctx       none]=========vaCreateSurfaces ret = VA_STATUS_ERROR_ALLOCATION_FAILED, resource allocation failed 
[20498.759747][ctx       none]==========va_TraceCreateSurfaces
[20498.759762][ctx       none]	width = 1920
[20498.759763][ctx       none]	height = 1088
[20498.759764][ctx       none]	format = 131072
[20498.759764][ctx       none]	num_surfaces = 1
[20498.759765][ctx       none]		surfaces[0] = 0xffffffff
[20498.759766][ctx       none]	attrib_list[0] =
[20498.759766][ctx       none]		type = 6
[20498.759766][ctx       none]		flags = 2
[20498.759767][ctx       none]		value.type = 1
[20498.759767][ctx       none]		value.value.i = 0x40000000
[20498.759768][ctx       none]	attrib_list[1] =
[20498.759768][ctx       none]		type = 7
[20498.759769][ctx       none]		flags = 2
[20498.759769][ctx       none]		value.type = 3
[20498.759770][ctx       none]		value.value.p = 0x7fff1fc86bd0
[20498.759771][ctx       none]		--VADRMPRIMESurfaceDescriptor
[20498.759771][ctx       none]		  pixel_format=0x58424752
[20498.759772][ctx       none]		  width=1920
[20498.759772][ctx       none]		  height=1088
[20498.759773][ctx       none]		  num_objects=0x00000002
[20498.759774][ctx       none]			objects[0].fd=69
[20498.759775][ctx       none]			objects[0].size=8388608
[20498.759775][ctx       none]			objects[0].drm_format_modifier=4
[20498.759776][ctx       none]			objects[1].fd=75
[20498.759776][ctx       none]			objects[1].size=8388608
[20498.759777][ctx       none]			objects[1].drm_format_modifier=4
[20498.759778][ctx       none]		  num_layers=1
[20498.759778][ctx       none]			layers[0].drm_format=0x34324258
[20498.759779][ctx       none]			layers[0].num_planes=0x2
[20498.759779][ctx       none]				layers[0].object_index[0]=0x0
[20498.759780][ctx       none]				layers[0].offset[0]=0x0
[20498.759780][ctx       none]				layers[0].pitch[0]=0x7680
[20498.759781][ctx       none]				layers[0].object_index[1]=0x1
[20498.759782][ctx       none]				layers[0].offset[1]=0x8355840
[20498.759782][ctx       none]				layers[0].pitch[1]=0x256
[20498.759783][ctx       none]				layers[0].object_index[2]=0x0
[20498.759783][ctx       none]				layers[0].offset[2]=0x0
[20498.759784][ctx       none]				layers[0].pitch[2]=0x0
[20498.759784][ctx       none]				layers[0].object_index[3]=0x0
[20498.759785][ctx       none]				layers[0].offset[3]=0x0
[20498.759786][ctx       none]				layers[0].pitch[3]=0x0
[20498.759823][ctx       none]=========vaCreateSurfaces ret = VA_STATUS_ERROR_ALLOCATION_FAILED, resource allocation failed 
[20498.774730][ctx       none]==========va_TraceDestroyConfig
[20498.774739][ctx       none]	config = 0x00000004
[20498.774766][ctx       none]=========vaDestroyConfig ret = VA_STATUS_SUCCESS, success (no error) 
[20498.775608][ctx       none]==========va_TraceTerminate
[20498.775624][ctx       none]=========vaTerminate ret = VA_STATUS_SUCCESS, success (no error) 

[-- Attachment #3: vainfo.log --]
[-- Type: application/octet-stream, Size: 1944 bytes --]

Trying display: wayland
vainfo: VA-API version: 1.17 (libva 2.17.1)
vainfo: Driver version: Intel iHD driver for Intel(R) Gen Graphics - 23.2.3 (8a65826b7)
vainfo: Supported profile and entrypoints
      VAProfileNone                   :	VAEntrypointVideoProc
      VAProfileNone                   :	VAEntrypointStats
      VAProfileMPEG2Simple            :	VAEntrypointVLD
      VAProfileMPEG2Main              :	VAEntrypointVLD
      VAProfileH264Main               :	VAEntrypointVLD
      VAProfileH264Main               :	VAEntrypointEncSlice
      VAProfileH264Main               :	VAEntrypointFEI
      VAProfileH264Main               :	VAEntrypointEncSliceLP
      VAProfileH264High               :	VAEntrypointVLD
      VAProfileH264High               :	VAEntrypointEncSlice
      VAProfileH264High               :	VAEntrypointFEI
      VAProfileH264High               :	VAEntrypointEncSliceLP
      VAProfileVC1Simple              :	VAEntrypointVLD
      VAProfileVC1Main                :	VAEntrypointVLD
      VAProfileVC1Advanced            :	VAEntrypointVLD
      VAProfileJPEGBaseline           :	VAEntrypointVLD
      VAProfileJPEGBaseline           :	VAEntrypointEncPicture
      VAProfileH264ConstrainedBaseline:	VAEntrypointVLD
      VAProfileH264ConstrainedBaseline:	VAEntrypointEncSlice
      VAProfileH264ConstrainedBaseline:	VAEntrypointFEI
      VAProfileH264ConstrainedBaseline:	VAEntrypointEncSliceLP
      VAProfileVP8Version0_3          :	VAEntrypointVLD
      VAProfileVP8Version0_3          :	VAEntrypointEncSlice
      VAProfileHEVCMain               :	VAEntrypointVLD
      VAProfileHEVCMain               :	VAEntrypointEncSlice
      VAProfileHEVCMain               :	VAEntrypointFEI
      VAProfileHEVCMain10             :	VAEntrypointVLD
      VAProfileHEVCMain10             :	VAEntrypointEncSlice
      VAProfileVP9Profile0            :	VAEntrypointVLD
      VAProfileVP9Profile2            :	VAEntrypointVLD

[-- Attachment #4: about_gpu.log --]
[-- Type: application/octet-stream, Size: 15560 bytes --]

Graphics Feature Status
Canvas: Hardware accelerated
Canvas out-of-process rasterization: Disabled
Direct Rendering Display Compositor: Disabled
Compositing: Hardware accelerated
Multiple Raster Threads: Enabled
OpenGL: Enabled
Rasterization: Hardware accelerated on all pages
Raw Draw: Disabled
Video Decode: Hardware accelerated
Video Encode: Software only. Hardware acceleration disabled
Vulkan: Disabled
WebGL: Hardware accelerated
WebGL2: Hardware accelerated
WebGPU: Disabled
Problems Detected
WebGPU has been disabled via blocklist or the command line.
Disabled Features: webgpu
Accelerated video encode has been disabled, either via blocklist, about:flags or the command line.
Disabled Features: video_encode
DAWN Info

<Integrated GPU> Vulkan backend - Intel(R) UHD Graphics 600 (GLK 2)
[Default Toggle Names]
lazy_clear_resource_on_first_use: https://crbug.com/dawn/145: Clears resource to zero on first usage. This initializes the resource so that no dirty bits from recycled memory is present in the new resource.
use_temporary_buffer_in_texture_to_texture_copy: https://crbug.com/dawn/42: Split texture-to-texture copy into two copies: copy from source texture into a temporary buffer, and copy from the temporary buffer into the destination texture when copying between compressed textures that don't have block-aligned sizes. This workaround is enabled by default on all Vulkan drivers to solve an issue in the Vulkan SPEC about the texture-to-texture copies with compressed formats. See #1005 (https://github.com/KhronosGroup/Vulkan-Docs/issues/1005) for more details.
vulkan_use_d32s8: https://crbug.com/dawn/286: Vulkan mandates support of either D32_FLOAT_S8 or D24_UNORM_S8. When available the backend will use D32S8 (toggle to on) but setting the toggle to off will make it use the D24S8 format when possible.
vulkan_use_s8: https://crbug.com/dawn/666: Vulkan has a pure stencil8 format but it is not universally available. When this toggle is on, the backend will use S8 for the stencil8 format, otherwise it will fallback to D32S8 or D24S8.
disallow_unsafe_apis: http://crbug.com/1138528: Produces validation errors on API entry points or parameter combinations that aren't considered secure yet.
use_vulkan_zero_initialize_workgroup_memory_extension: https://crbug.com/dawn/1302: Initialize workgroup memory with OpConstantNull on Vulkan when the Vulkan extension VK_KHR_zero_initialize_workgroup_memory is supported.
[WebGPU Forced Toggles - enabled]
disallow_spirv: https://crbug.com/1214923: Disallow usage of SPIR-V completely so that only WGSL is used for shader modules. This is useful to prevent a Chromium renderer process from successfully sending SPIR-V code to be compiled in the GPU process.
[Supported Features]
texture-compression-bc
texture-compression-etc2
texture-compression-astc
pipeline-statistics-query
timestamp-query
timestamp-query-inside-passes
depth-clip-control
depth32float-stencil8
indirect-first-instance
rg11b10ufloat-renderable
dawn-internal-usages
dawn-native

<CPU> Vulkan backend - SwiftShader Device (Subzero)
[Default Toggle Names]
lazy_clear_resource_on_first_use: https://crbug.com/dawn/145: Clears resource to zero on first usage. This initializes the resource so that no dirty bits from recycled memory is present in the new resource.
use_temporary_buffer_in_texture_to_texture_copy: https://crbug.com/dawn/42: Split texture-to-texture copy into two copies: copy from source texture into a temporary buffer, and copy from the temporary buffer into the destination texture when copying between compressed textures that don't have block-aligned sizes. This workaround is enabled by default on all Vulkan drivers to solve an issue in the Vulkan SPEC about the texture-to-texture copies with compressed formats. See #1005 (https://github.com/KhronosGroup/Vulkan-Docs/issues/1005) for more details.
vulkan_use_d32s8: https://crbug.com/dawn/286: Vulkan mandates support of either D32_FLOAT_S8 or D24_UNORM_S8. When available the backend will use D32S8 (toggle to on) but setting the toggle to off will make it use the D24S8 format when possible.
vulkan_use_s8: https://crbug.com/dawn/666: Vulkan has a pure stencil8 format but it is not universally available. When this toggle is on, the backend will use S8 for the stencil8 format, otherwise it will fallback to D32S8 or D24S8.
disallow_unsafe_apis: http://crbug.com/1138528: Produces validation errors on API entry points or parameter combinations that aren't considered secure yet.
use_vulkan_zero_initialize_workgroup_memory_extension: https://crbug.com/dawn/1302: Initialize workgroup memory with OpConstantNull on Vulkan when the Vulkan extension VK_KHR_zero_initialize_workgroup_memory is supported.
[WebGPU Forced Toggles - enabled]
disallow_spirv: https://crbug.com/1214923: Disallow usage of SPIR-V completely so that only WGSL is used for shader modules. This is useful to prevent a Chromium renderer process from successfully sending SPIR-V code to be compiled in the GPU process.
[Supported Features]
texture-compression-bc
texture-compression-etc2
texture-compression-astc
timestamp-query
timestamp-query-inside-passes
depth-clip-control
depth32float-stencil8
indirect-first-instance
rg11b10ufloat-renderable
dawn-internal-usages
dawn-native
Version Information
Data exported
2023-06-06T15:11:46.487Z
Chrome version
Chrome/111.0.5563.147
Operating system
Linux 6.1.12-intel-pk-standard
Software rendering list URL
https://chromium.googlesource.com/chromium/src/+/029fd65a4dd711d1078468ed2206999cec86066b/gpu/config/software_rendering_list.json
Driver bug list URL
https://chromium.googlesource.com/chromium/src/+/029fd65a4dd711d1078468ed2206999cec86066b/gpu/config/gpu_driver_bug_list.json
ANGLE commit id
unknown hash
2D graphics backend
Skia/111 59932b057f281ddaeb0926ecfac55486270f8c51
Command Line
/usr/bin/chromium --use-gl=egl --ozone-platform=wayland --enable-features=VaapiVideoDecoder --disable-features=UseChromeOSDirectVideoDecoder --enable-accelerated-video-decode --enable-gpu-rasterization --enable-zero-copy --disable-gpu-driver-bug-workarounds --canvas-oop-rasterization --enable-hardware-overlays --use-cmd-decoder=validating --vmodule=vaapi_wrapper=4,vaapi_video_decode_accelerator=4,vaapi_picture_native_pixmap_ozone=4 --enable-logging=stderr --v=0 --loglevel=0 --ignore-gpu-blocklist --flag-switches-begin --flag-switches-end https://test-videos.co.uk/bigbuckbunny/mp4-h264
Driver Information
Initialization time
554
In-process GPU
false
Passthrough Command Decoder
false
Sandboxed
false
GPU0
VENDOR= 0x8086 [Intel], DEVICE=0x3185 [Mesa Intel(R) UHD Graphics 600 (GLK 2)], DRIVER_VENDOR=Mesa, DRIVER_VERSION=23.0.2 *ACTIVE*
Optimus
false
AMD switchable
false
GPU CUDA compute capability major version
0
Pixel shader version
3.20
Vertex shader version
3.20
Max. MSAA samples
16
Machine model name
Machine model version
GL_VENDOR
Intel
GL_RENDERER
Mesa Intel(R) UHD Graphics 600 (GLK 2)
GL_VERSION
OpenGL ES 3.2 Mesa 23.0.2
GL_EXTENSIONS
GL_EXT_blend_minmax GL_EXT_multi_draw_arrays GL_EXT_texture_filter_anisotropic GL_EXT_texture_compression_s3tc GL_EXT_texture_compression_dxt1 GL_EXT_texture_compression_rgtc GL_EXT_texture_format_BGRA8888 GL_OES_compressed_ETC1_RGB8_texture GL_OES_depth24 GL_OES_element_index_uint GL_OES_fbo_render_mipmap GL_OES_mapbuffer GL_OES_rgb8_rgba8 GL_OES_standard_derivatives GL_OES_stencil8 GL_OES_texture_3D GL_OES_texture_float GL_OES_texture_float_linear GL_OES_texture_half_float GL_OES_texture_half_float_linear GL_OES_texture_npot GL_OES_vertex_half_float GL_EXT_draw_instanced GL_EXT_texture_sRGB_decode GL_OES_EGL_image GL_OES_depth_texture GL_AMD_performance_monitor GL_OES_packed_depth_stencil GL_EXT_texture_type_2_10_10_10_REV GL_NV_conditional_render GL_OES_get_program_binary GL_APPLE_texture_max_level GL_EXT_discard_framebuffer GL_EXT_read_format_bgra GL_NV_pack_subimage GL_EXT_frag_depth GL_NV_fbo_color_attachments GL_OES_EGL_image_external GL_OES_EGL_sync GL_OES_vertex_array_object GL_OES_viewport_array GL_ANGLE_pack_reverse_row_order GL_ANGLE_texture_compression_dxt3 GL_ANGLE_texture_compression_dxt5 GL_EXT_occlusion_query_boolean GL_EXT_robustness GL_EXT_texture_rg GL_EXT_unpack_subimage GL_NV_draw_buffers GL_NV_read_buffer GL_NV_read_depth GL_NV_read_depth_stencil GL_NV_read_stencil GL_EXT_draw_buffers GL_EXT_map_buffer_range GL_KHR_debug GL_KHR_robustness GL_KHR_texture_compression_astc_ldr GL_NV_pixel_buffer_object GL_OES_depth_texture_cube_map GL_OES_required_internalformat GL_OES_surfaceless_context GL_EXT_color_buffer_float GL_EXT_debug_label GL_EXT_sRGB_write_control GL_EXT_separate_shader_objects GL_EXT_shader_framebuffer_fetch GL_EXT_shader_group_vote GL_EXT_shader_implicit_conversions GL_EXT_shader_integer_mix GL_EXT_tessellation_point_size GL_EXT_tessellation_shader GL_INTEL_conservative_rasterization GL_INTEL_performance_query GL_ANDROID_extension_pack_es31a GL_EXT_base_instance GL_EXT_compressed_ETC1_RGB8_sub_texture GL_EXT_copy_image GL_EXT_draw_buffers_indexed GL_EXT_draw_elements_base_vertex GL_EXT_gpu_shader5 GL_EXT_polygon_offset_clamp GL_EXT_primitive_bounding_box GL_EXT_render_snorm GL_EXT_shader_io_blocks GL_EXT_texture_border_clamp GL_EXT_texture_buffer GL_EXT_texture_cube_map_array GL_EXT_texture_norm16 GL_EXT_texture_view GL_KHR_blend_equation_advanced GL_KHR_blend_equation_advanced_coherent GL_KHR_context_flush_control GL_KHR_robust_buffer_access_behavior GL_NV_image_formats GL_NV_shader_noperspective_interpolation GL_OES_copy_image GL_OES_draw_buffers_indexed GL_OES_draw_elements_base_vertex GL_OES_gpu_shader5 GL_OES_primitive_bounding_box GL_OES_sample_shading GL_OES_sample_variables GL_OES_shader_io_blocks GL_OES_shader_multisample_interpolation GL_OES_tessellation_point_size GL_OES_tessellation_shader GL_OES_texture_border_clamp GL_OES_texture_buffer GL_OES_texture_cube_map_array GL_OES_texture_stencil8 GL_OES_texture_storage_multisample_2d_array GL_OES_texture_view GL_EXT_blend_func_extended GL_EXT_buffer_storage GL_EXT_float_blend GL_EXT_geometry_point_size GL_EXT_geometry_shader GL_EXT_shader_samples_identical GL_EXT_texture_sRGB_R8 GL_KHR_no_error GL_KHR_texture_compression_astc_sliced_3d GL_NV_fragment_shader_interlock GL_OES_EGL_image_external_essl3 GL_OES_geometry_point_size GL_OES_geometry_shader GL_OES_shader_image_atomic GL_EXT_clear_texture GL_EXT_clip_cull_distance GL_EXT_disjoint_timer_query GL_EXT_texture_compression_s3tc_srgb GL_MESA_shader_integer_functions GL_EXT_clip_control GL_EXT_color_buffer_half_float GL_EXT_memory_object GL_EXT_memory_object_fd GL_EXT_semaphore GL_EXT_semaphore_fd GL_EXT_texture_compression_bptc GL_EXT_texture_mirror_clamp_to_edge GL_KHR_parallel_shader_compile GL_NV_alpha_to_coverage_dither_control GL_EXT_EGL_image_storage GL_EXT_shader_framebuffer_fetch_non_coherent GL_EXT_texture_shadow_lod GL_INTEL_blackhole_render GL_MESA_framebuffer_flip_y GL_NV_compute_shader_derivatives GL_EXT_demote_to_helper_invocation GL_EXT_depth_clamp GL_EXT_texture_query_lod GL_MESA_bgra
Disabled Extensions
Disabled WebGL Extensions
Window system binding vendor
Mesa Project
Window system binding version
1.5
Window system binding extensions
EGL_ANDROID_blob_cache EGL_ANDROID_native_fence_sync EGL_EXT_buffer_age EGL_EXT_create_context_robustness EGL_EXT_image_dma_buf_import EGL_EXT_image_dma_buf_import_modifiers EGL_EXT_present_opaque EGL_EXT_swap_buffers_with_damage EGL_IMG_context_priority EGL_KHR_cl_event2 EGL_KHR_config_attribs EGL_KHR_context_flush_control EGL_KHR_create_context EGL_KHR_create_context_no_error EGL_KHR_fence_sync EGL_KHR_get_all_proc_addresses EGL_KHR_gl_colorspace EGL_KHR_gl_renderbuffer_image EGL_KHR_gl_texture_2D_image EGL_KHR_gl_texture_3D_image EGL_KHR_gl_texture_cubemap_image EGL_KHR_image_base EGL_KHR_no_config_context EGL_KHR_reusable_sync EGL_KHR_surfaceless_context EGL_KHR_swap_buffers_with_damage EGL_EXT_pixel_format_float EGL_KHR_wait_sync EGL_MESA_configless_context EGL_MESA_drm_image EGL_MESA_image_dma_buf_export EGL_MESA_query_driver EGL_WL_bind_wayland_display EGL_WL_create_wayland_buffer_from_image
XDG_SESSION_TYPE
wayland
Interfaces exposed by the Wayland compositor
wl_compositor:5 wl_subcompositor:1 wp_viewporter:1 zxdg_output_manager_v1:2 wp_presentation:1 wp_single_pixel_buffer_manager_v1:1 zwp_relative_pointer_manager_v1:1 zwp_pointer_constraints_v1:1 zwp_input_timestamps_manager_v1:1 wl_data_device_manager:3 wl_shm:1 wl_seat:7 weston_direct_display_v1:1 zwp_linux_explicit_synchronization_v1:2 weston_content_protection:1 wl_output:3 zwp_input_panel_v1:1 zwp_input_method_v1:1 zwp_text_input_manager_v1:1 xdg_wm_base:5 weston_desktop_shell:1 weston_screenshooter:1 zwp_linux_dmabuf_v1:4 wl_drm:2
Ozone platform
wayland
Direct rendering version
unknown
Reset notification strategy
0x8252
GPU process crash count
0
gfx::BufferFormats supported for allocation and texturing
R_8: not supported, R_16: not supported, RG_88: not supported, RG_1616: not supported, BGR_565: not supported, RGBA_4444: not supported, RGBX_8888: not supported, RGBA_8888: not supported, BGRX_8888: not supported, BGRA_1010102: not supported, RGBA_1010102: not supported, BGRA_8888: not supported, RGBA_F16: not supported, YVU_420: not supported, YUV_420_BIPLANAR: not supported, YUVA_420_TRIPLANAR: not supported, P010: not supported
Compositor Information
Tile Update Mode
Zero-copy
Partial Raster
Enabled
GpuMemoryBuffers Status
R_8
Software only
R_16
Software only
RG_88
Software only
RG_1616
Software only
BGR_565
GPU_READ
RGBA_4444
Software only
RGBX_8888
GPU_READ, SCANOUT, SCANOUT_CPU_READ_WRITE, SCANOUT_FRONT_RENDERING
RGBA_8888
GPU_READ, SCANOUT, SCANOUT_CPU_READ_WRITE, SCANOUT_FRONT_RENDERING
BGRX_8888
GPU_READ, SCANOUT, SCANOUT_CPU_READ_WRITE, SCANOUT_FRONT_RENDERING
BGRA_1010102
SCANOUT, SCANOUT_CPU_READ_WRITE, SCANOUT_FRONT_RENDERING
RGBA_1010102
SCANOUT, SCANOUT_CPU_READ_WRITE, SCANOUT_FRONT_RENDERING
BGRA_8888
GPU_READ, SCANOUT, SCANOUT_CPU_READ_WRITE, SCANOUT_FRONT_RENDERING
RGBA_F16
Software only
YVU_420
GPU_READ, SCANOUT_VEA_CPU_READ, VEA_READ_CAMERA_AND_CPU_READ_WRITE
YUV_420_BIPLANAR
SCANOUT_CAMERA_READ_WRITE, SCANOUT_CPU_READ_WRITE, SCANOUT_VEA_CPU_READ, SCANOUT_FRONT_RENDERING, VEA_READ_CAMERA_AND_CPU_READ_WRITE
YUVA_420_TRIPLANAR
Software only
P010
Software only
Display(s) Information
Info
Display[18] bounds=[0,0 3840x2160], workarea=[0,0 3840x2160], scale=1, rotation=0, panel_rotation=0 external.
Color space (all)
{primaries:BT709, transfer:SRGB, matrix:RGB, range:FULL}
Buffer format (all)
RGBA_8888
Color volume
{name:'srgb', r:[0.6400, 0.3300], g:[0.3000, 0.6000], b:[0.1500, 0.3300], w:[0.3127, 0.3290]}
SDR white level in nits
203
HDR relative maximum luminance
1
Bits per color component
8
Bits per pixel
24
Video Acceleration Information
Decoding
Decode h264 baseline
16x16 to 4096x4096 pixels
Decode h264 main
16x16 to 4096x4096 pixels
Decode h264 high
16x16 to 4096x4096 pixels
Decode vp8
16x16 to 4096x4096 pixels
Decode vp9 profile0
16x16 to 8192x8192 pixels
Encoding
Vulkan Information
Device Performance Information
Log Messages
[713:713:0606/151134.787340:WARNING:gl_utils.cc(94)] : Ignoring request for the validating command decoder. It is not supported on this platform.
[713:713:0606/151134.852918:WARNING:gl_utils.cc(94)] : Ignoring request for the validating command decoder. It is not supported on this platform.
[713:713:0606/151135.288511:ERROR:gpu_init.cc(525)] : Passthrough is not supported, GL is egl, ANGLE is
[713:713:0606/151135.297058:WARNING:sandbox_linux.cc(393)] : InitializeSandbox() called with multiple threads in process gpu-process.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [yocto][chromium] Need support to enable intel VAAPI with Chromium
  2023-06-07  1:24 [yocto][chromium] Need support to enable intel VAAPI with Chromium huy nguyen
@ 2023-06-07  1:49 ` Mittal, Anuj
  2023-06-07  1:57   ` huy nguyen
       [not found]   ` <17663DD3817D729F.23186@lists.yoctoproject.org>
  0 siblings, 2 replies; 4+ messages in thread
From: Mittal, Anuj @ 2023-06-07  1:49 UTC (permalink / raw)
  To: yocto, huykhacnguyen1983

On Wed, 2023-06-07 at 08:24 +0700, HuyK wrote:
> Hi all,
> 
> I am working on Intel J4125 platform with these meta layers:
>  - poky: master branch
>  - meta-intel: master branch
>  - meta-browser: master branch
> 
> 1/ I build chromium by chromium-ozone-wayland_111.0.5563.147.bb
> recipe with adding "use-vaapi" and "proprietary-codecs" to
> PACKAGECONFI in chromium-gn.inc 
> That chromium did not call intel VAAPI functions, but I see it
> loads iHD_drv_video.so at runtime.
> 
> 2/ Then I research to find this link about applying patches to
> support VAAPI in
> chromium https://aur.archlinux.org/packages/chromium-wayland-vaapi
>    + 0001-ozone-wayland-add-VA-API-support.patch
>    + vaapi-add-av1-support.patch
>    + use-oauth2-client-switches-as-default.patch
> This chromium loads iHD_drv_video.so and calls Intel VAAPI APIs;
> however, chromium reports these errors when I open to play an H264
> video so that HW Acceleration is not working 
> 
>  [13436:13436:0606/150528.263552:ERROR:vaapi_wrapper.cc(2399)]
> vaCreateSurfaces (import mode) failed, VA error: resource allocation
> failed
> [13436:13436:0606/150528.263789:ERROR:vaapi_picture_native_pixmap_ozo
> ne.cc(73)] Failed creating VASurface for NativePixmap
> [13436:13436:0606/150528.264843:ERROR:vaapi_wrapper.cc(2399)]
> vaCreateSurfaces (import mode) failed, VA error: resource allocation
> failed
> [13436:13436:0606/150528.265073:ERROR:vaapi_picture_native_pixmap_ozo
> ne.cc(73)] Failed creating VASurface for NativePixmap
> [13436:13436:0606/150528.265294:VERBOSE1:vaapi_video_decode_accelerat
> or.cc(142)] NotifyError(): Notifying of error 4

This doesn't look like complete error log. A complete log would have
helped.

> 
> So far, I could not find a solution to fix chromium errors and I am
> new to chromium, intel vaapi, libva debugging.
> 
> Please support how to debug the errors there or guidance on how to
> officially build chromium with intel VAAPI support in Yocto?

This doesn't seem to be Yocto related. This looks very similar so
please try the suggestions here:

https://github.com/intel/media-driver/issues/1498

Thanks,

Anuj

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [yocto][chromium] Need support to enable intel VAAPI with Chromium
  2023-06-07  1:49 ` Mittal, Anuj
@ 2023-06-07  1:57   ` huy nguyen
       [not found]   ` <17663DD3817D729F.23186@lists.yoctoproject.org>
  1 sibling, 0 replies; 4+ messages in thread
From: huy nguyen @ 2023-06-07  1:57 UTC (permalink / raw)
  To: Mittal, Anuj; +Cc: yocto

[-- Attachment #1: Type: text/plain, Size: 3079 bytes --]

Hi Anuj,

Thank you for the quick response with positive information. It makes me
feel warm about our community.

1- "This doesn't look like complete error log. A complete log would have
helped."
Do you mean a complete run log from chromium? I will submit a full running
log when I run chromium soon.

2- Regarding  the suggestion in
https://github.com/intel/media-driver/issues/1498
 I reviewed that suggestion during my self-research for a solution. It
suggests using chromium r107 and adding
--disable-features=UseChromeOSDirectVideoDecoder
 However, I do not know which chromium recipe version for that r107. For
the flag UseChromOSDirectVideoDecoder, I already have that.

Thank you,
Huy


On Wed, Jun 7, 2023 at 8:49 AM Mittal, Anuj <anuj.mittal@intel.com> wrote:

> On Wed, 2023-06-07 at 08:24 +0700, HuyK wrote:
> > Hi all,
> >
> > I am working on Intel J4125 platform with these meta layers:
> >  - poky: master branch
> >  - meta-intel: master branch
> >  - meta-browser: master branch
> >
> > 1/ I build chromium by chromium-ozone-wayland_111.0.5563.147.bb
> > recipe with adding "use-vaapi" and "proprietary-codecs" to
> > PACKAGECONFI in chromium-gn.inc
> > That chromium did not call intel VAAPI functions, but I see it
> > loads iHD_drv_video.so at runtime.
> >
> > 2/ Then I research to find this link about applying patches to
> > support VAAPI in
> > chromium https://aur.archlinux.org/packages/chromium-wayland-vaapi
> >    + 0001-ozone-wayland-add-VA-API-support.patch
> >    + vaapi-add-av1-support.patch
> >    + use-oauth2-client-switches-as-default.patch
> > This chromium loads iHD_drv_video.so and calls Intel VAAPI APIs;
> > however, chromium reports these errors when I open to play an H264
> > video so that HW Acceleration is not working
> >
> >  [13436:13436:0606/150528.263552:ERROR:vaapi_wrapper.cc(2399)]
> > vaCreateSurfaces (import mode) failed, VA error: resource allocation
> > failed
> > [13436:13436:0606/150528.263789:ERROR:vaapi_picture_native_pixmap_ozo
> > ne.cc(73)] Failed creating VASurface for NativePixmap
> > [13436:13436:0606/150528.264843:ERROR:vaapi_wrapper.cc(2399)]
> > vaCreateSurfaces (import mode) failed, VA error: resource allocation
> > failed
> > [13436:13436:0606/150528.265073:ERROR:vaapi_picture_native_pixmap_ozo
> > ne.cc(73)] Failed creating VASurface for NativePixmap
> > [13436:13436:0606/150528.265294:VERBOSE1:vaapi_video_decode_accelerat
> > or.cc(142)] NotifyError(): Notifying of error 4
>
> This doesn't look like complete error log. A complete log would have
> helped.
>
> >
> > So far, I could not find a solution to fix chromium errors and I am
> > new to chromium, intel vaapi, libva debugging.
> >
> > Please support how to debug the errors there or guidance on how to
> > officially build chromium with intel VAAPI support in Yocto?
>
> This doesn't seem to be Yocto related. This looks very similar so
> please try the suggestions here:
>
> https://github.com/intel/media-driver/issues/1498
>
> Thanks,
>
> Anuj
>

[-- Attachment #2: Type: text/html, Size: 4426 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [yocto][chromium] Need support to enable intel VAAPI with Chromium
       [not found]   ` <17663DD3817D729F.23186@lists.yoctoproject.org>
@ 2023-06-07 12:37     ` huy nguyen
  0 siblings, 0 replies; 4+ messages in thread
From: huy nguyen @ 2023-06-07 12:37 UTC (permalink / raw)
  To: huykhacnguyen1983; +Cc: Mittal, Anuj, yocto


[-- Attachment #1.1: Type: text/plain, Size: 3804 bytes --]

Hi Anuj,

I attached the complete chromium log here.

Thank you,
Huy

On Wed, Jun 7, 2023 at 8:58 AM HuyK via lists.yoctoproject.org
<huykhacnguyen1983=gmail.com@lists.yoctoproject.org> wrote:

> Hi Anuj,
>
> Thank you for the quick response with positive information. It makes me
> feel warm about our community.
>
> 1- "This doesn't look like complete error log. A complete log would have
> helped."
> Do you mean a complete run log from chromium? I will submit a full running
> log when I run chromium soon.
>
> 2- Regarding  the suggestion in
> https://github.com/intel/media-driver/issues/1498
>  I reviewed that suggestion during my self-research for a solution. It
> suggests using chromium r107 and adding
> --disable-features=UseChromeOSDirectVideoDecoder
>  However, I do not know which chromium recipe version for that r107. For
> the flag UseChromOSDirectVideoDecoder, I already have that.
>
> Thank you,
> Huy
>
>
> On Wed, Jun 7, 2023 at 8:49 AM Mittal, Anuj <anuj.mittal@intel.com> wrote:
>
>> On Wed, 2023-06-07 at 08:24 +0700, HuyK wrote:
>> > Hi all,
>> >
>> > I am working on Intel J4125 platform with these meta layers:
>> >  - poky: master branch
>> >  - meta-intel: master branch
>> >  - meta-browser: master branch
>> >
>> > 1/ I build chromium by chromium-ozone-wayland_111.0.5563.147.bb
>> > recipe with adding "use-vaapi" and "proprietary-codecs" to
>> > PACKAGECONFI in chromium-gn.inc
>> > That chromium did not call intel VAAPI functions, but I see it
>> > loads iHD_drv_video.so at runtime.
>> >
>> > 2/ Then I research to find this link about applying patches to
>> > support VAAPI in
>> > chromium https://aur.archlinux.org/packages/chromium-wayland-vaapi
>> >    + 0001-ozone-wayland-add-VA-API-support.patch
>> >    + vaapi-add-av1-support.patch
>> >    + use-oauth2-client-switches-as-default.patch
>> > This chromium loads iHD_drv_video.so and calls Intel VAAPI APIs;
>> > however, chromium reports these errors when I open to play an H264
>> > video so that HW Acceleration is not working
>> >
>> >  [13436:13436:0606/150528.263552:ERROR:vaapi_wrapper.cc(2399)]
>> > vaCreateSurfaces (import mode) failed, VA error: resource allocation
>> > failed
>> > [13436:13436:0606/150528.263789:ERROR:vaapi_picture_native_pixmap_ozo
>> > ne.cc(73)] Failed creating VASurface for NativePixmap
>> > [13436:13436:0606/150528.264843:ERROR:vaapi_wrapper.cc(2399)]
>> > vaCreateSurfaces (import mode) failed, VA error: resource allocation
>> > failed
>> > [13436:13436:0606/150528.265073:ERROR:vaapi_picture_native_pixmap_ozo
>> > ne.cc(73)] Failed creating VASurface for NativePixmap
>> > [13436:13436:0606/150528.265294:VERBOSE1:vaapi_video_decode_accelerat
>> > or.cc(142)] NotifyError(): Notifying of error 4
>>
>> This doesn't look like complete error log. A complete log would have
>> helped.
>>
>> >
>> > So far, I could not find a solution to fix chromium errors and I am
>> > new to chromium, intel vaapi, libva debugging.
>> >
>> > Please support how to debug the errors there or guidance on how to
>> > officially build chromium with intel VAAPI support in Yocto?
>>
>> This doesn't seem to be Yocto related. This looks very similar so
>> please try the suggestions here:
>>
>> https://github.com/intel/media-driver/issues/1498
>>
>> Thanks,
>>
>> Anuj
>>
>
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#60194):
> https://lists.yoctoproject.org/g/yocto/message/60194
> Mute This Topic: https://lists.yoctoproject.org/mt/99376559/7514801
> Group Owner: yocto+owner@lists.yoctoproject.org
> Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [
> huykhacnguyen1983@gmail.com]
> -=-=-=-=-=-=-=-=-=-=-=-
>
>

[-- Attachment #1.2: Type: text/html, Size: 5893 bytes --]

[-- Attachment #2: log_chromium.txt --]
[-- Type: text/plain, Size: 4303 bytes --]

sh-5.2$ source ./start_chromium.sh 
[3980:3980:0607/122727.876476:WARNING:chrome_main_delegate.cc(618)] This is Chrome version 111.0.5563.147 (not a warning)
[3980:3980:0607/122727.965150:WARNING:wayland_object.cc(152)] Binding to zwp_linux_dmabuf_v1 version 3 but version 4 is available.
[3980:3980:0607/122728.036300:WARNING:wayland_surface.cc(149)] Server doesn't support zcr_alpha_compositing_v1.
[3980:3980:0607/122728.036337:WARNING:wayland_surface.cc(164)] Server doesn't support overlay_prioritizer.
[3980:3980:0607/122728.036345:WARNING:wayland_surface.cc(178)] Server doesn't support surface_augmenter.
[3980:3980:0607/122728.036352:WARNING:wayland_surface.cc(193)] Server doesn't support wp_content_type_v1
[3980:3980:0607/122728.036358:WARNING:wayland_surface.cc(212)] Server doesn't support zcr_color_management_surface.
[3980:3980:0607/122728.037024:WARNING:cursor_loader.cc(123)] Failed to load a platform cursor of type kNull
libva info: Open new log file /tmp/libva.122728.thd-0x00000fbe for the thread 0x00000fbe
libva info: LIBVA_TRACE is on, save log into /tmp/libva.122728.thd-0x00000fbe
libva info: VA-API version 1.17.0
libva info: Trying to open /usr/lib/dri/iHD_drv_video.so
libva info: Found init function __vaDriverInit_1_17
libva info: va_openDriver() returns 0
[4030:4030:0607/122728.083000:ERROR:gpu_init.cc(525)] Passthrough is not supported, GL is egl, ANGLE is 
[4030:4030:0607/122728.089781:WARNING:sandbox_linux.cc(393)] InitializeSandbox() called with multiple threads in process gpu-process.
[3980:3980:0607/122728.094363:WARNING:bluez_dbus_manager.cc(247)] Floss manager not present, cannot set Floss enable/disable.
[3980:3980:0607/122756.467072:INFO:CONSOLE(22)] "The Content Security Policy 'child-src 'unsafe-inline' cm.g.doubleclick.net googleads.g.doubleclick.net www.google.
com accounts.google.com pagead2.googlesyndication.com/pagead/s/cookie_push.html gmsg: https://tpc.googlesyndication.com/sadbundle/$csp%3Der3$/12934228281280879862/i
ndex.html;frame-src 'unsafe-inline' cm.g.doubleclick.net googleads.g.doubleclick.net www.google.com accounts.google.com pagead2.googlesyndication.com/pagead/s/cooki
e_push.html gmsg: https://tpc.googlesyndication.com/sadbundle/$csp%3Der3$/12934228281280879862/index.html' was delivered via a <meta> element outside the document's
 <head>, which is disallowed. The policy has been ignored.", source: https://googleads.g.doubleclick.net/pagead/html/r20230601/r20110914/zrt_lookup.html?fsb=1 (22)
[3980:3980:0607/122758.821762:WARNING:cursor_loader.cc(123)] Failed to load a platform cursor of type kHand
[4030:4030:0607/122759.781037:VERBOSE2:vaapi_video_decode_accelerator.cc(200)] Initialize(): Initializing VAVDA, profile: h264 high
libva info: Open new log file /tmp/libva.122759.thd-0x00000fbe for the thread 0x00000fbe
libva info: LIBVA_TRACE is on, save log into /tmp/libva.122759.thd-0x00000fbe
libva info: VA-API version 1.17.0
libva info: Trying to open /usr/lib/dri/iHD_drv_video.so
libva info: Found init function __vaDriverInit_1_17
libva info: va_openDriver() returns 0
[4030:4573:0607/122759.786123:VERBOSE2:vaapi_video_decode_accelerator.cc(487)] DecodeTask(): Decoder requesting a new set of surfaces
[4030:4030:0607/122759.786393:VERBOSE2:vaapi_video_decode_accelerator.cc(582)] InitiateSurfaceSetChange():  |requested_num_pics_| = 13; |requested_num_reference_fra
mes_| = 0
[4030:4030:0607/122759.786547:VERBOSE2:vaapi_video_decode_accelerator.cc(648)] TryFinishSurfaceSetChange(): Requesting 13 pictures of size: 1920x1088 and visible re
ctangle = 0,0 1920x1080
[4030:4030:0607/122759.794571:ERROR:vaapi_wrapper.cc(2399)] vaCreateSurfaces (import mode) failed, VA error: resource allocation failed
[4030:4030:0607/122759.794773:ERROR:vaapi_picture_native_pixmap_ozone.cc(73)] Failed creating VASurface for NativePixmap
[4030:4030:0607/122759.800235:ERROR:vaapi_wrapper.cc(2399)] vaCreateSurfaces (import mode) failed, VA error: resource allocation failed
[4030:4030:0607/122759.800357:ERROR:vaapi_picture_native_pixmap_ozone.cc(73)] Failed creating VASurface for NativePixmap
[4030:4030:0607/122759.800507:VERBOSE1:vaapi_video_decode_accelerator.cc(142)] NotifyError(): Notifying of error 4
[4030:4030:0607/122759.804536:VERBOSE2:vaapi_video_decode_accelerator.cc(1045)] Cleanup(): Destroying VAVDA


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2023-06-07 12:38 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-06-07  1:24 [yocto][chromium] Need support to enable intel VAAPI with Chromium huy nguyen
2023-06-07  1:49 ` Mittal, Anuj
2023-06-07  1:57   ` huy nguyen
     [not found]   ` <17663DD3817D729F.23186@lists.yoctoproject.org>
2023-06-07 12:37     ` huy nguyen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).