Skip to content
  • Nicholas Kazlauskas's avatar
    lib/igt_fb: Create AMD YUV buffers with AMD GEM IOCTL · a1701d0b
    Nicholas Kazlauskas authored
    
    
    The kmstest_dumb_create API isn't suitable for creating multi-planar
    buffers since it tries to calculate the size based on the first plane's
    pitch only.
    
    AMDGPU requires that the luma pitch be aligned to 256 for YUV buffers
    which results in crashes on kms_plane@pixel-format-pipe-*-planes tests
    when using kmstest_dumb_create since the buffer returned is smaller than
    needed (16384 size returned, 24576 size required).
    
    Create and map the buffer with the correct size by using the AMD helpers
    introduced by this patch: igt_amd_create_bo and igt_amd_mmap_bo.
    
    Cc: Harry Wentland <harry.wentland@amd.com>
    Cc: Leo Li <sunpeng.li@amd.com>
    Signed-off-by: default avatarNicholas Kazlauskas <nicholas.kazlauskas@amd.com>
    Reviewed-by: default avatarLeo Li <sunpeng.li@amd.com>
    a1701d0b