Received: by 2002:ac0:aa62:0:0:0:0:0 with SMTP id w31-v6csp2158436ima; Mon, 22 Oct 2018 05:25:11 -0700 (PDT) X-Google-Smtp-Source: ACcGV601bKvukkN3d0/dSPsxsNCN5aE7uusFZpStb6axKigkrnAriVetWS/Ebb6HBm4qxa7Q8t3O X-Received: by 2002:a63:a012:: with SMTP id r18-v6mr43493720pge.282.1540211111722; Mon, 22 Oct 2018 05:25:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1540211111; cv=none; d=google.com; s=arc-20160816; b=K2JP1kFlk7FpazMdsFpPcZUs8xiEJx5qgfjWOY2ibDQr3qQKXq0novXp4ULaLuOl6t gIVxO1C42HdKsWszMHgY6aG4iavrS/E6/p8MhqkKhiFHFJF6i/L4VseyHNCI8igvvo1E I7p93j41HNDxHuctGyM7AyRelLj1y2SqyyHD3vxjlt7HcBItVhTQ8mxqTv3K6+VIVjXC D7FMqsAEhbl+ZIXmpwvD+t6WH374FL1DmqrKx7pfamzogJ9HBYzfqXGO0c4paA/HphMN dfDiYcvG7p6+keVrGMX+kTCXeyPNuKuGR85Ccda0Jn7BCcXcepMNSx/xwvnfOJCV9xtE OfUA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from; bh=hM3e3Juccj4pLbIaIAKTSuYyW5sl8XUBpJzgIR56tn4=; b=QyhKhhvgukJiQ0YTlyI1Eic2bMWeXw1A/xRdUI+U5F+7D3D+TeycYXeEVFTmc6Jy1n JFLBzfqvHPhNbi/VrU7oAz05KG3s3ANYTl+/QToW5qqfzRJdlDx6lGuGjea9ey8QBDuP CkHmSLDkppKe2wxLOWq+vdbfTFPks8ql4AUeTo+UVDOrJPK2S5deo+EQcXiqTWet5Fyo dpo0Wf7tdJOxGIRnMQje96D8BlyikiJbMCexKeRYbLILo/H42E+ew5equNXKaXijyt6A 1K/Lw58CamrxY6zJBV7snZyqVXw3yQRbj2vx5atAKNwWj8fCW7QjqcCU0NBXdwa/+WNM pXgQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i128-v6si36169696pfb.256.2018.10.22.05.24.55; Mon, 22 Oct 2018 05:25:11 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728617AbeJVUYY (ORCPT + 99 others); Mon, 22 Oct 2018 16:24:24 -0400 Received: from alexa-out-blr-02.qualcomm.com ([103.229.18.198]:62590 "EHLO alexa-out-blr.qualcomm.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1727787AbeJVUYY (ORCPT ); Mon, 22 Oct 2018 16:24:24 -0400 X-IronPort-AV: E=Sophos;i="5.54,412,1534789800"; d="scan'208";a="214746" Received: from ironmsg04-blr.qualcomm.com ([10.86.208.133]) by alexa-out-blr.qualcomm.com with ESMTP/TLS/AES256-SHA; 22 Oct 2018 17:35:17 +0530 X-IronPort-AV: E=McAfee;i="5900,7806,9053"; a="1911363" Received: from mgottam-linux.qualcomm.com ([10.204.66.66]) by ironmsg04-blr.qualcomm.com with ESMTP; 22 Oct 2018 17:35:16 +0530 Received: by mgottam-linux.qualcomm.com (Postfix, from userid 2305155) id 7FFED3043; Mon, 22 Oct 2018 17:35:15 +0530 (IST) From: Malathi Gottam To: stanimir.varbanov@linaro.org, hverkuil@xs4all.nl, mchehab@kernel.org Cc: linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, acourbot@chromium.org, vgarodia@codeaurora.org, mgottam@codeaurora.org Subject: [PATCH v2] media: venus: handle peak bitrate set property Date: Mon, 22 Oct 2018 17:35:12 +0530 Message-Id: <1540209912-24834-1-git-send-email-mgottam@codeaurora.org> X-Mailer: git-send-email 1.9.1 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Max bitrate property is not supported for venus version 4xx. Return unsupported from packetization layer. Handle it in hfi_venus layer to exit gracefully to venc layer. Signed-off-by: Malathi Gottam --- drivers/media/platform/qcom/venus/hfi_cmds.c | 2 +- drivers/media/platform/qcom/venus/hfi_venus.c | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/media/platform/qcom/venus/hfi_cmds.c b/drivers/media/platform/qcom/venus/hfi_cmds.c index e8389d8..87a4414 100644 --- a/drivers/media/platform/qcom/venus/hfi_cmds.c +++ b/drivers/media/platform/qcom/venus/hfi_cmds.c @@ -1215,7 +1215,7 @@ static int pkt_session_set_property_1x(struct hfi_session_set_property_pkt *pkt, } case HFI_PROPERTY_CONFIG_VENC_MAX_BITRATE: /* not implemented on Venus 4xx */ - break; + return -ENOTSUPP; default: return pkt_session_set_property_3xx(pkt, cookie, ptype, pdata); } diff --git a/drivers/media/platform/qcom/venus/hfi_venus.c b/drivers/media/platform/qcom/venus/hfi_venus.c index 1240855..9d086b9 100644 --- a/drivers/media/platform/qcom/venus/hfi_venus.c +++ b/drivers/media/platform/qcom/venus/hfi_venus.c @@ -1355,6 +1355,8 @@ static int venus_session_set_property(struct venus_inst *inst, u32 ptype, pkt = (struct hfi_session_set_property_pkt *)packet; ret = pkt_session_set_property(pkt, inst, ptype, pdata); + if (ret == -ENOTSUPP) + return 0; if (ret) return ret; -- 1.9.1