]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
Revert "media: venus: hfi_platform: Correct supported codecs for sc7280"
authorDmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Mon, 6 Apr 2026 22:15:52 +0000 (01:15 +0300)
committerBryan O'Donoghue <bod@kernel.org>
Sat, 30 May 2026 07:41:47 +0000 (08:41 +0100)
This reverts commit c0ab2901fc68 ("media: venus: hfi_platform: Correct
supported codecs for sc7280"). The codecs might be deprecated, but they
still work (somewhat) perfectly and don't cause any issues with the rest
of the system. Reenable VP8 codecs by reverting the offending commit.

Tested with fluster:

|Test|FFmpeg-VP8-v4l2m2m|GStreamer-VP8-V4L2|
|TOTAL|50/61|50/61|
|TOTAL TIME|12.171s|11.824s|

Fixes: c0ab2901fc68 ("media: venus: hfi_platform: Correct supported codecs for sc7280")
Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Signed-off-by: Bryan O'Donoghue <bod@kernel.org>
drivers/media/platform/qcom/venus/hfi_parser.c
drivers/media/platform/qcom/venus/hfi_platform.c
drivers/media/platform/qcom/venus/hfi_platform.h

index 92765f9c88730ae55c388cabed199d84a001ddf1..c4cf6cd50a9a03dacc1e8d4d43e780cd9fb200fb 100644 (file)
@@ -268,7 +268,6 @@ static int hfi_platform_parser(struct venus_core *core, struct venus_inst *inst)
        const struct hfi_plat_caps *caps = NULL;
        u32 enc_codecs, dec_codecs, count = 0;
        unsigned int entries;
-       int ret;
 
        plat = hfi_platform_get(core->res->hfi_version);
        if (!plat)
@@ -277,9 +276,8 @@ static int hfi_platform_parser(struct venus_core *core, struct venus_inst *inst)
        if (inst)
                return 0;
 
-       ret = hfi_platform_get_codecs(core, &enc_codecs, &dec_codecs, &count);
-       if (ret)
-               return ret;
+       if (plat->codecs)
+               plat->codecs(core, &enc_codecs, &dec_codecs, &count);
 
        if (plat->capabilities)
                caps = plat->capabilities(core, &entries);
index cde7f93045ac4567bf4239eeb3c489b887d4ad01..f19572ab1d16132a8270da2ab34cec8c3b82b26d 100644 (file)
@@ -2,9 +2,7 @@
 /*
  * Copyright (c) 2020, The Linux Foundation. All rights reserved.
  */
-#include <linux/of.h>
 #include "hfi_platform.h"
-#include "core.h"
 
 const struct hfi_platform *hfi_platform_get(enum hfi_version version)
 {
@@ -73,25 +71,3 @@ hfi_platform_get_codec_lp_freq(struct venus_core *core,
 
        return freq;
 }
-
-int
-hfi_platform_get_codecs(struct venus_core *core, u32 *enc_codecs,
-                       u32 *dec_codecs, u32 *count)
-{
-       const struct hfi_platform *plat;
-
-       plat = hfi_platform_get(core->res->hfi_version);
-       if (!plat)
-               return -EINVAL;
-
-       if (plat->codecs)
-               plat->codecs(core, enc_codecs, dec_codecs, count);
-
-       if (IS_IRIS2_1(core)) {
-               *enc_codecs &= ~HFI_VIDEO_CODEC_VP8;
-               *dec_codecs &= ~HFI_VIDEO_CODEC_VP8;
-       }
-
-       return 0;
-}
-
index 5e4f8013a6b1db4f4f83cd983ef9e83347ef4e0a..a0b6d19f3e1a04a348f4709f06768a723d50aa44 100644 (file)
@@ -74,6 +74,4 @@ unsigned long hfi_platform_get_codec_vsp_freq(struct venus_core *core,
 unsigned long hfi_platform_get_codec_lp_freq(struct venus_core *core,
                                             enum hfi_version version,
                                             u32 codec, u32 session_type);
-int hfi_platform_get_codecs(struct venus_core *core, u32 *enc_codecs,
-                           u32 *dec_codecs, u32 *count);
 #endif