summaryrefslogtreecommitdiffstats
path: root/recipes-multimedia/libva/files/0001-Encode-fix-fwdRefs-array-out-of-bound-issue.patch
diff options
context:
space:
mode:
Diffstat (limited to 'recipes-multimedia/libva/files/0001-Encode-fix-fwdRefs-array-out-of-bound-issue.patch')
-rw-r--r--recipes-multimedia/libva/files/0001-Encode-fix-fwdRefs-array-out-of-bound-issue.patch35
1 files changed, 35 insertions, 0 deletions
diff --git a/recipes-multimedia/libva/files/0001-Encode-fix-fwdRefs-array-out-of-bound-issue.patch b/recipes-multimedia/libva/files/0001-Encode-fix-fwdRefs-array-out-of-bound-issue.patch
new file mode 100644
index 00000000..7367808d
--- /dev/null
+++ b/recipes-multimedia/libva/files/0001-Encode-fix-fwdRefs-array-out-of-bound-issue.patch
@@ -0,0 +1,35 @@
1From e8bb025cd56c269adf3ffdc3dda404505974f676 Mon Sep 17 00:00:00 2001
2From: bai-isaac <isaac.bai@intel.com>
3Date: Mon, 12 Jun 2023 12:44:29 +0800
4Subject: [PATCH] [Encode] fix fwdRefs array out of bound issue
5
6fix fwdRefs array out of bound issue.
7
8Upstream-Status: Backport [https://github.com/intel/media-driver/commit/d795297127488b328f1cc260cf5da66debf95b99]
9Expect it to be removed once move to intel-media-23.2.4 or above
10
11Signed-off-by: Ch'ng, Seng Guan <seng.guan.chng@intel.com>
12---
13 media_softlet/agnostic/common/hw/vdbox/mhw_vdbox_vdenc_impl.h | 3 ++-
14 1 file changed, 2 insertions(+), 1 deletion(-)
15
16diff --git a/media_softlet/agnostic/common/hw/vdbox/mhw_vdbox_vdenc_impl.h b/media_softlet/agnostic/common/hw/vdbox/mhw_vdbox_vdenc_impl.h
17index 3b79f4886..85a5a4127 100644
18--- a/media_softlet/agnostic/common/hw/vdbox/mhw_vdbox_vdenc_impl.h
19+++ b/media_softlet/agnostic/common/hw/vdbox/mhw_vdbox_vdenc_impl.h
20@@ -649,10 +649,11 @@ protected:
21 &resourceParams));
22 }
23
24+ // SCC will use BwdRef0 as extra slot to store IBC if max fwd ref num is 3.
25 typename cmd_t::VDENC_Reference_Picture_CMD *fwdRefs[] =
26 {&cmd.FwdRef0, &cmd.FwdRef1, &cmd.FwdRef2, &cmd.BwdRef0};
27 uint32_t fwdRefsDwLoaction[] =
28- {_MHW_CMD_DW_LOCATION(FwdRef0), _MHW_CMD_DW_LOCATION(FwdRef1), _MHW_CMD_DW_LOCATION(FwdRef2)};
29+ {_MHW_CMD_DW_LOCATION(FwdRef0), _MHW_CMD_DW_LOCATION(FwdRef1), _MHW_CMD_DW_LOCATION(FwdRef2), _MHW_CMD_DW_LOCATION(BwdRef0)};
30
31 typename cmd_t::VDENC_Down_Scaled_Reference_Picture_CMD *fwdRefsDsStage1[] =
32 {&cmd.DsFwdRef0, &cmd.DsFwdRef1};
33--
342.40.1
35