From patchwork Tue May 30 12:30:48 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 100818 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:994d:0:b0:3d9:f83d:47d9 with SMTP id k13csp2149602vqr; Tue, 30 May 2023 05:41:44 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ5Ni85NWwu2IxzF1W2qCm07nZnq/2Zl1lovm6POVuTWLyginjRBDCnrkhNglqpqYdtEIcE+ X-Received: by 2002:a05:6a00:240b:b0:650:154:8bd with SMTP id z11-20020a056a00240b00b00650015408bdmr1322263pfh.17.1685450504154; Tue, 30 May 2023 05:41:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1685450504; cv=none; d=google.com; s=arc-20160816; b=kxdrUEMX1P5baV83F5h7t4Ozg8RVIujk78q+kmm4ANsFO3pxOJ1xpjPIMlhjIHlmzp YZjrkDiHHI097vhRY6VbfkYjA/NEdGb/lKAt48OB/um9/KRpwRLxEDY+CeV3hs+p9Y93 FoUO2u93L+xaOEvyGV/nhk0j91yGoNghoulzjuj3wXIuSFm7ESrVwYw2sC2EmxL+su44 z5pcQhIifGvqJbNoijpWa/HDvpwy0r7wSMXq3gOgXzHNtA8f2yuOA0ry2QANIe+cBOw7 LviZFvnA/wwjfJ1bc8V/eaFd245cRE/s2ruIINn8HLyFjNs36Ep9GhTRzo3jDqbENwJz MK2Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:in-reply-to:references:message-id :content-transfer-encoding:mime-version:subject:date:from :dkim-signature; bh=YRnWjbY4eUpy9oiw3Jwu9xibfYWN+hzyctbtgGIUQYc=; b=R1tcTtGeZQnvgPENwaid/JHWhhfvuHXF9h3sGEkD7FxT6CmSzJBIrCViKZYnBmOiRF QtR0L5nL0Sx1ILvZsBF1EIMlGC/OD6MXf39W/9PKFmQSHRpw3cgNuXyzi8T1+gWnF1Ap gU0sFH2kpeEpDgoKDjrXTFdU5Ny8Gm3rwkMi6QDZc22ur1dBqajIj9trQcMYBwpiwc8p ijs3zE3oxiA75PrW7ourQ4dVlZ9hGPSAufwcD4E67sPi8YWWFC7Ka9wrMCJ74clqOmNG I4GOfY/NNkhlzCUBZmlCLma5Obnz7E/N4Cgm0R6TpMReen7GdnMclaqUeZau4gOni+Sl kTLw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=km8NCG0k; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id h191-20020a6383c8000000b0053fb69cc365si1032046pge.238.2023.05.30.05.41.30; Tue, 30 May 2023 05:41:44 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=km8NCG0k; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232071AbjE3Mcu (ORCPT + 99 others); Tue, 30 May 2023 08:32:50 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58500 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231443AbjE3Mc2 (ORCPT ); Tue, 30 May 2023 08:32:28 -0400 Received: from mail-lf1-x12b.google.com (mail-lf1-x12b.google.com [IPv6:2a00:1450:4864:20::12b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 48B1F10CB for ; Tue, 30 May 2023 05:31:49 -0700 (PDT) Received: by mail-lf1-x12b.google.com with SMTP id 2adb3069b0e04-4f505aace48so1902442e87.0 for ; Tue, 30 May 2023 05:31:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1685449859; x=1688041859; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=YRnWjbY4eUpy9oiw3Jwu9xibfYWN+hzyctbtgGIUQYc=; b=km8NCG0kZRfT8qnXV6rt816QmQM6EzBrPUyMg/8X0Qr20WzDkXOjCU7Y91USgTWtLb GgFdDM1fjtSmww+I6XUIooQ/CsrRU7mjNBccf2n9qQKkc49EOczsxb1H/wfWNMloap1b TkBf6jtSH8/j/HZ9tVDKwBbKw9n96BZC9rN4H76OsenTbkN/fTFSIsggrq/P236jUWwq xO2mV5FfHag9y0Ro8kJepCgpa3E0a/IJFn4bzC/dWo1L7gyMomsqh+GNyPpJzr5Dn8n8 qU5nRabs7Xg6DvMFZBHSkSE/NFS4h3qQy58qvCpdQlxnQ+k6t2DazBNLMcCExK6FeZ7j kRjg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1685449859; x=1688041859; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=YRnWjbY4eUpy9oiw3Jwu9xibfYWN+hzyctbtgGIUQYc=; b=dDdwzJ71Q3X97Jj5yajr8fx/N6Z2Cx5VpcX9+bBcfzN4ZkfEIqzbn4VphbnwMWUUy3 lEW4/hzyNwHgS14F+66lM8Zg/YcDIS3xqhR5a2uIZCFtFflpHkdS+AUKuPLUI2dzg5wa a31zR+1xYIC9FMRMnktXWpr2Tv0uynSMv1SdBMxLkOqQsNVDwUmhQ8BpJqeVRYRKStRB lJ1jKprl9TazR2FHpAOYu/AMiQe8C/VLQyIIN/7wM7lGzzxNp2ARzVRgZhPPM35/fOVy 0sFEC+JjsjjYmXiMMFyNkZZMu0bUIbUhM29AciciCpPeu5cyPsK0yzLlEKIC8NPpO5ay Apug== X-Gm-Message-State: AC+VfDxVUE28tqpQ3nUh/TTtR/LMYNYY400WG2redcUdJPVq51Jleemm sfgZSEs1KIQMrrFpow5wUXOQ1yTC07+LJHTKrqA= X-Received: by 2002:a2e:b1d3:0:b0:2ad:9751:8d79 with SMTP id e19-20020a2eb1d3000000b002ad97518d79mr695211lja.31.1685449859370; Tue, 30 May 2023 05:30:59 -0700 (PDT) Received: from [192.168.1.101] (abyj77.neoplus.adsl.tpnet.pl. [83.9.29.77]) by smtp.gmail.com with ESMTPSA id u18-20020a2e91d2000000b002a8b8baf542sm2854814ljg.126.2023.05.30.05.30.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 30 May 2023 05:30:59 -0700 (PDT) From: Konrad Dybcio Date: Tue, 30 May 2023 14:30:48 +0200 Subject: [PATCH v4 14/17] media: venus: vdec: Sanitize vdec_set_work_route() per-VPU-version MIME-Version: 1.0 Message-Id: <20230228-topic-venus-v4-14-feebb2f6e9b8@linaro.org> References: <20230228-topic-venus-v4-0-feebb2f6e9b8@linaro.org> In-Reply-To: <20230228-topic-venus-v4-0-feebb2f6e9b8@linaro.org> To: Stanimir Varbanov , Vikash Garodia , Andy Gross , Bjorn Andersson , Mauro Carvalho Chehab , Dikshita Agarwal , Bryan O'Donoghue , Mansur Alisha Shaik , Jonathan Marek , Hans Verkuil , Dikshita Agarwal Cc: Mauro Carvalho Chehab , Stanimir Varbanov , linux-media@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org, Marijn Suijten , Konrad Dybcio , Vikash Garodia X-Mailer: b4 0.12.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1685449837; l=867; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=VGY5gPiqtp3BTJb/zA96U45nnyM1YeyDLDunCuTDVFE=; b=QkUtZtfy1Bmq8vawWj2OnYkiTfqBytb97u4bsYds4a47S03RWHQbiGtpEXfmwIrEFCOjZpjN6 SIhJpleXbiKAayuh71xUgC5V6dMI7JDvUCOsO7rCTthDQChW+drW2bq X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1767322947411662782?= X-GMAIL-MSGID: =?utf-8?q?1767322947411662782?= Replace the general IS_V6 checks with more specific VPU version checks. Reviewed-by: Bryan O'Donoghue Signed-off-by: Konrad Dybcio Reviewed-by: Vikash Garodia --- drivers/media/platform/qcom/venus/vdec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/media/platform/qcom/venus/vdec.c b/drivers/media/platform/qcom/venus/vdec.c index 12a2e99508f5..063a8b0d357b 100644 --- a/drivers/media/platform/qcom/venus/vdec.c +++ b/drivers/media/platform/qcom/venus/vdec.c @@ -727,7 +727,7 @@ static int vdec_set_work_route(struct venus_inst *inst) u32 ptype = HFI_PROPERTY_PARAM_WORK_ROUTE; struct hfi_video_work_route wr; - if (!IS_V6(inst->core)) + if (!(IS_IRIS2(inst->core) || IS_IRIS2_1(inst->core))) return 0; wr.video_work_route = inst->core->res->num_vpp_pipes;