Skip to content

[gst-vaapi][ICL][HEVC Encode][Low power]vaCreateConfig returns VA_STATUS_ERROR_ATTR_NOT_SUPPORTED. #361

@feiwan1

Description

@feiwan1
  1. cmdline:
    gst-launch-1.0 videotestsrc num-buffers=100 ! vaapih265enc tune=3 rate-control=cbr ! fakesink
    (Note: this cmdline need a patch for gst-vaapi, please feel free to ping me if you need the patch for debug).

  2. error log:
    root@icl_vpg_kernel:~# gst-launch-1.0 videotestsrc num-buffers=100 ! vaapih265enc tune=3 rate-control=cbr ! fakesink
    Setting pipeline to PAUSED ...
    Pipeline is PREROLLING ...
    Got context from element 'vaapiencodeh265-0': gst.vaapi.Display=context, gst.vaapi.Display=(GstVaapiDisplay)"(GstVaapiDisplayDRM)\ vaapidisplaydrm1";
    0:00:00.035357481 17100 0x1e55850 ERROR vaapi 0:00:00.035389684 17100 0x1e55850 ERROR vaapi gstvaapiencoder.c:997:gst_vaapi_encoder_reconfigure_internal: failed to update VA context

  3. bt information:
    (gdb) bt
    #0 MediaLibvaCaps::CreateEncConfig (this=this@entry=0x785a00, profileTableIdx=29, entrypoint=entrypoint@entry=VAEntrypointEncSliceLP, attribList=attribList@entry=0x7fffeb87d880, numAttribs=n
    umAttribs@entry=3, configId=0x7fffe4003a58) at /root/build/media-driver/media_driver/linux/common/ddi/media_libva_caps.cpp:1674
    Don't hardcode install paths #1 0x00007fffec2a5cfc in MediaLibvaCaps::CreateConfig (this=0x785a00, profile=VAProfileHEVCMain, entrypoint=VAEntrypointEncSliceLP, attribList=0x7fffeb87d880, numAttribs=3, configId=) at /
    root/build/media-driver/media_driver/linux/common/ddi/media_libva_caps.cpp:1867
    Driver installation should use libva.pc driverdir variable #2 0x00007ffff356eba9 in vaCreateConfig (dpy=0x72aa60, profile=VAProfileHEVCMain, entrypoint=VAEntrypointEncSliceLP, attrib_list=attrib_list@entry=0x7fffeb87d880, num_attribs=num_attribs@entry=3, config_
    id=config_id@entry=0x7fffe4003a58) at va.c:891

  4. variable in MediaLibvaCaps::CreateEncConfig:
    (gdb) p m_profileEntryTbl[29]
    $47 = {m_profile = VAProfileHEVCMain, m_entrypoint = VAEntrypointEncSliceLP, m_attributes = 0x787390, m_configStartIdx = 73, m_configNum = 9}

(gdb) p m_encConfigs
$41 = std::vector of length 125, capacity 128 = {16, 2, 4, 130, 132, 64, 8, 16, 2,
4, 130, 132, 64, 8, 16, 2, 4, 130, 132, 64, 8, 16, 16, 16, 16, 2, 4, 130,
132, 16, 2, 4, 130, 132, 16, 2, 4, 130, 132, 16, 2, 4, 16, 2, 4, 1, 16, 2,
514, 4, 516, 130, 642, 132, 644, 64, 576, 8, 520, 16, 16, 2, 514, 4, 516,
130, 642, 132, 644, 64, 576, 8, 520, 16, 130, 642, 132, 644, 64, 576, 8,
520, 16, 130, 642, 132, 644, 64, 576, 8, 520, 16, 130, 642, 132, 644, 64,
576, 8, 520, 16, 130, 642, 132, 644, 64, 576, 8, 520, 16, 2, 4, 16, 2, 4,
16, 2, 4, 16, 2, 4, 16, 2, 4, 1}

  1. VA_STATUS_ERROR_ATTR_NOT_SUPPORTED returned in else branch:
    1682│ if (j < (configNum + startIdx))
    1683│ {
    1684│ *configId = j + DDI_CODEC_GEN_CONFIG_ATTRIBUTES_ENC_BASE;
    1685│ return VA_STATUS_SUCCESS;
    1686│ }
    1687│ else
    1688│ {
    1689│ *configId = 0xFFFFFFFF;
    1690│ return VA_STATUS_ERROR_ATTR_NOT_SUPPORTED;
    1691│ }

Metadata

Metadata

Assignees

No one assigned

    Labels

    BugIssue: identify as a bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions