Hi Vunny, On Fri, 2021-08-13 at 17:41 +0800, Sodhi, Vunny wrote: > If we are using I915_FORMAT_MOD_Y_TILED which is needed for > NV12 format then modifiers need to be enabled which can be passed > as flags argument to ioctl. > > Signed-off-by: Sodhi, Vunny <[email protected]> > --- > ...Fixed-tile-modifier-issue-for-NV12-format.patch | 49 > ++++++++++++++++++++++ > .../mediasdk/intel-mediasdk_21.2.3.bb | 1 +
This recipe is at 21.2.3. The lines you are modifying were added in 21.3.0. So the patch fails to apply: stdout: Applying patch 0001-Fixed-tile-modifier-issue-for-NV12- format.patch patching file samples/sample_common/src/vaapi_utils_drm.cpp Hunk #1 FAILED at 422. Hunk #2 FAILED at 452. 2 out of 2 hunks FAILED -- rejects in file samples/sample_common/src/vaapi_utils_drm.cpp Patch 0001-Fixed-tile-modifier-issue-for-NV12-format.patch does not apply (enforce with -f) Thanks, Anuj > 2 files changed, 50 insertions(+) > create mode 100644 recipes-multimedia/mediasdk/files/0001-Fixed-tile- > modifier-issue-for-NV12-format.patch > > diff --git a/recipes-multimedia/mediasdk/files/0001-Fixed-tile- > modifier-issue-for-NV12-format.patch b/recipes- > multimedia/mediasdk/files/0001-Fixed-tile-modifier-issue-for-NV12- > format.patch > new file mode 100644 > index 0000000..c249c17 > --- /dev/null > +++ b/recipes-multimedia/mediasdk/files/0001-Fixed-tile-modifier-issue- > for-NV12-format.patch > @@ -0,0 +1,49 @@ > +From 3fc9fe078c850643f8070cce1d2b0307a9014523 Mon Sep 17 00:00:00 2001 > +From: "Sodhi, Vunny" <[email protected]> > +Date: Fri, 13 Aug 2021 12:09:26 +0800 > +Subject: [meta-intel][PATCH] Fixed tile modifier issue for NV12 format > + > +If we are using I915_FORMAT_MOD_Y_TILED which is needed for > +NV12 format then modifiers need to be enabled which can be passed > +as flags argument to ioctl. > + > +Upstream-Status: Submitted > +https://github.com/Intel-Media-SDK/MediaSDK/pull/2755 > + > +Signed-off-by: Sodhi, Vunny <[email protected]> > +--- > + samples/sample_common/src/vaapi_utils_drm.cpp | 5 +++-- > + 1 file changed, 3 insertions(+), 2 deletions(-) > + > +diff --git a/samples/sample_common/src/vaapi_utils_drm.cpp > b/samples/sample_common/src/vaapi_utils_drm.cpp > +index 5ad73dd..73c8bd2 100644 > +--- a/samples/sample_common/src/vaapi_utils_drm.cpp > ++++ b/samples/sample_common/src/vaapi_utils_drm.cpp > +@@ -422,7 +422,7 @@ void* drmRenderer::acquire(mfxMemId mid) > + int ret = m_drmlib.drmIoctl(m_fd, DRM_IOCTL_GEM_OPEN, > &flink_open); > + if (ret) return NULL; > + > +- uint32_t handles[4], pitches[4], offsets[4], pixel_format; > ++ uint32_t handles[4], pitches[4], offsets[4], pixel_format, > flags = 0; > + uint64_t modifiers[4]; > + > + memset(&handles, 0, sizeof(handles)); > +@@ -452,13 +452,14 @@ void* drmRenderer::acquire(mfxMemId mid) > + pitches[1] = vmid->m_image.pitches[1]; > + offsets[1] = vmid->m_image.offsets[1]; > + modifiers[0] = modifiers[1] = I915_FORMAT_MOD_Y_TILED; > ++ flags = 2; // DRM_MODE_FB_MODIFIERS (1<<1) /* enables - > >modifer[] > + } > + else { > + pixel_format = DRM_FORMAT_XRGB8888; > + } > + > + ret = m_drmlib.drmModeAddFB2WithModifiers(m_fd, vmid- > >m_image.width, vmid->m_image.height, > +- pixel_format, handles, pitches, offsets, modifiers, > &fbhandle, 0); > ++ pixel_format, handles, pitches, offsets, modifiers, > &fbhandle, flags); > + if (ret) return NULL; > + > + MSDK_ZERO_MEMORY(flink_close); > +-- > +2.7.4 > + > diff --git a/recipes-multimedia/mediasdk/intel-mediasdk_21.2.3.bb > b/recipes-multimedia/mediasdk/intel-mediasdk_21.2.3.bb > index acdc83e..73e41f1 100644 > --- a/recipes-multimedia/mediasdk/intel-mediasdk_21.2.3.bb > +++ b/recipes-multimedia/mediasdk/intel-mediasdk_21.2.3.bb > @@ -33,6 +33,7 @@ PACKAGECONFIG[wayland] = "-DENABLE_WAYLAND=ON, > -DENABLE_WAYLAND=OFF, wayland way > > SRC_URI = "git://github.com/Intel-Media- > SDK/MediaSDK.git;protocol=https;nobranch=1;lfs=0 \ > > file://0001-FindITT.cmake-fix-detection-of-header-library.patch \ > + > file://0001-Fixed-tile-modifier-issue-for-NV12-format.patch \ > " > > SRCREV = "24b964e32692f68ed01aad73850bdaa440c2fcd7" > > >
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#7192): https://lists.yoctoproject.org/g/meta-intel/message/7192 Mute This Topic: https://lists.yoctoproject.org/mt/84859960/21656 Group Owner: [email protected] Unsubscribe: https://lists.yoctoproject.org/g/meta-intel/unsub [[email protected]] -=-=-=-=-=-=-=-=-=-=-=-
