From patchwork Tue Jul 12 12:23:41 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viswanath Boma X-Patchwork-Id: 590494 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7EA75C433EF for ; Tue, 12 Jul 2022 12:24:17 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232760AbiGLMYQ (ORCPT ); Tue, 12 Jul 2022 08:24:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40602 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232693AbiGLMYP (ORCPT ); Tue, 12 Jul 2022 08:24:15 -0400 Received: from alexa-out.qualcomm.com (alexa-out.qualcomm.com [129.46.98.28]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D42D8A5E4B; Tue, 12 Jul 2022 05:24:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; i=@quicinc.com; q=dns/txt; s=qcdkim; t=1657628655; x=1689164655; h=from:to:cc:subject:date:message-id; bh=2yikxSz6ZKr6BUHyL9FxMlsxNJSMOiov0y0jJpxJzvk=; b=rHT12QZlUxE/h+tZOj6Dd7zXCJjMU+3Wo7q2BcCLLhtyrIRyKA70bnMh CSDtb8xjNtuqceizI5fGWGni6PI23eDdk4Y9O3OUMopn4ZL7f3OfU8P/q LcrcWGqaQD8wmFAzfzdP7H3Po19m6d5o1forg4MmRpDQJfc/kyHRfeSL9 4=; Received: from ironmsg09-lv.qualcomm.com ([10.47.202.153]) by alexa-out.qualcomm.com with ESMTP; 12 Jul 2022 05:24:14 -0700 X-QCInternal: smtphost Received: from ironmsg01-blr.qualcomm.com ([10.86.208.130]) by ironmsg09-lv.qualcomm.com with ESMTP/TLS/AES256-SHA; 12 Jul 2022 05:24:13 -0700 X-QCInternal: smtphost Received: from vboma-linux.qualcomm.com ([10.204.65.94]) by ironmsg01-blr.qualcomm.com with ESMTP; 12 Jul 2022 17:54:00 +0530 Received: by vboma-linux.qualcomm.com (Postfix, from userid 72083) id B69F1900883; Tue, 12 Jul 2022 17:53:59 +0530 (IST) From: Viswanath Boma To: video.upstream.external@qti.qualcomm.com, Stanimir Varbanov , Andy Gross , Bjorn Andersson , Mauro Carvalho Chehab , linux-media@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Viswanath Boma Subject: [PATCH 1/7] venus : Add default values for the control V4L2_CID_COLORIMETRY_HDR10_MASTERING_DISPLAY Date: Tue, 12 Jul 2022 17:53:41 +0530 Message-Id: <20220712122347.6781-1-quic_vboma@quicinc.com> X-Mailer: git-send-email 2.17.1 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org From: Stanimir Varbanov V4l2 encoder compliance expecting default values of colormetry for the control. Change-Id: I1db0d4940b54e033d646ce39d60dc488afba8d58 Signed-off-by: Viswanath Boma --- drivers/media/platform/qcom/venus/venc_ctrls.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/media/platform/qcom/venus/venc_ctrls.c b/drivers/media/platform/qcom/venus/venc_ctrls.c index ea5805e71c143..37ba7d97f99b2 100644 --- a/drivers/media/platform/qcom/venus/venc_ctrls.c +++ b/drivers/media/platform/qcom/venus/venc_ctrls.c @@ -352,6 +352,8 @@ static const struct v4l2_ctrl_ops venc_ctrl_ops = { int venc_ctrl_init(struct venus_inst *inst) { int ret; + struct v4l2_ctrl_hdr10_mastering_display p_hdr10_mastering = { {34000, 13250, 7500 }, + { 16000, 34500, 3000 }, 15635, 16450, 10000000, 500 }; ret = v4l2_ctrl_handler_init(&inst->ctrl_handler, 58); if (ret) @@ -580,7 +582,7 @@ int venc_ctrl_init(struct venus_inst *inst) v4l2_ctrl_new_std_compound(&inst->ctrl_handler, &venc_ctrl_ops, V4L2_CID_COLORIMETRY_HDR10_MASTERING_DISPLAY, - v4l2_ctrl_ptr_create(NULL)); + v4l2_ctrl_ptr_create((void *)&p_hdr10_mastering)); v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, V4L2_CID_MPEG_VIDEO_INTRA_REFRESH_PERIOD, 0, From patchwork Tue Jul 12 12:23:42 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viswanath Boma X-Patchwork-Id: 589873 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id B5066CCA481 for ; Tue, 12 Jul 2022 12:24:18 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232036AbiGLMYR (ORCPT ); Tue, 12 Jul 2022 08:24:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40600 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232706AbiGLMYP (ORCPT ); Tue, 12 Jul 2022 08:24:15 -0400 Received: from alexa-out.qualcomm.com (alexa-out.qualcomm.com [129.46.98.28]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5D3F7A5E46; Tue, 12 Jul 2022 05:24:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; i=@quicinc.com; q=dns/txt; s=qcdkim; t=1657628654; x=1689164654; h=from:to:cc:subject:date:message-id:in-reply-to: references; bh=kj0kBuJRKrJztfeW6tmf/UDwOX6Y3wrCB1UmnidfQ4A=; b=gYfvoA5ykL+odve0mrXQQ5JzwlmVILM8bsedolmpx6iBtoXnT+BVw//L xhJ+dgeWS8ofRRUiZjDYw/53t3p7HIMgpzNtDtXdBtI2vL9isGDlnIJ8I 3IFcRnkEYOOyXqJejrT17sOrao5rtdbfDWdQ+2mlmwIpXg7MTq4r1hL+8 Y=; Received: from ironmsg07-lv.qualcomm.com ([10.47.202.151]) by alexa-out.qualcomm.com with ESMTP; 12 Jul 2022 05:24:14 -0700 X-QCInternal: smtphost Received: from ironmsg01-blr.qualcomm.com ([10.86.208.130]) by ironmsg07-lv.qualcomm.com with ESMTP/TLS/AES256-SHA; 12 Jul 2022 05:24:12 -0700 X-QCInternal: smtphost Received: from vboma-linux.qualcomm.com ([10.204.65.94]) by ironmsg01-blr.qualcomm.com with ESMTP; 12 Jul 2022 17:54:04 +0530 Received: by vboma-linux.qualcomm.com (Postfix, from userid 72083) id 36917900883; Tue, 12 Jul 2022 17:54:03 +0530 (IST) From: Viswanath Boma To: video.upstream.external@qti.qualcomm.com, Stanimir Varbanov , Andy Gross , Bjorn Andersson , Mauro Carvalho Chehab , linux-media@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Viswanath Boma Subject: [PATCH 2/7] venus : Addition of control support - V4L2_CID_MIN_BUFFERS_FOR_OUTPUT Date: Tue, 12 Jul 2022 17:53:42 +0530 Message-Id: <20220712122347.6781-2-quic_vboma@quicinc.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20220712122347.6781-1-quic_vboma@quicinc.com> References: <20220712122347.6781-1-quic_vboma@quicinc.com> Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org V4l2 encoder compliance expecting minimum buffers support for the application to allocate buffers as per the control support values. Change-Id: Idb41ff7dce8b8138f28df01d045eae6facf7e93d Signed-off-by: Viswanath Boma --- drivers/media/platform/qcom/venus/venc_ctrls.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/media/platform/qcom/venus/venc_ctrls.c b/drivers/media/platform/qcom/venus/venc_ctrls.c index 37ba7d97f99b2..95fdad160732b 100644 --- a/drivers/media/platform/qcom/venus/venc_ctrls.c +++ b/drivers/media/platform/qcom/venus/venc_ctrls.c @@ -355,7 +355,7 @@ int venc_ctrl_init(struct venus_inst *inst) struct v4l2_ctrl_hdr10_mastering_display p_hdr10_mastering = { {34000, 13250, 7500 }, { 16000, 34500, 3000 }, 15635, 16450, 10000000, 500 }; - ret = v4l2_ctrl_handler_init(&inst->ctrl_handler, 58); + ret = v4l2_ctrl_handler_init(&inst->ctrl_handler, 59); if (ret) return ret; @@ -435,6 +435,9 @@ int venc_ctrl_init(struct venus_inst *inst) V4L2_MPEG_VIDEO_VP8_PROFILE_3, 0, V4L2_MPEG_VIDEO_VP8_PROFILE_0); + v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, + V4L2_CID_MIN_BUFFERS_FOR_OUTPUT, 4, 11, 1, 4); + v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, V4L2_CID_MPEG_VIDEO_BITRATE, BITRATE_MIN, BITRATE_MAX, BITRATE_STEP, BITRATE_DEFAULT); From patchwork Tue Jul 12 12:23:43 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viswanath Boma X-Patchwork-Id: 590493 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 07AAECCA47C for ; Tue, 12 Jul 2022 12:24:18 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229691AbiGLMYQ (ORCPT ); Tue, 12 Jul 2022 08:24:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40598 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232727AbiGLMYP (ORCPT ); Tue, 12 Jul 2022 08:24:15 -0400 Received: from alexa-out.qualcomm.com (alexa-out.qualcomm.com [129.46.98.28]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 058EBA5E45; Tue, 12 Jul 2022 05:24:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; i=@quicinc.com; q=dns/txt; s=qcdkim; t=1657628653; x=1689164653; h=from:to:cc:subject:date:message-id:in-reply-to: references; bh=kjqCC1TQXN5pqJ5k6XuqzpdiFR+t5y37ltNwK7wmqWc=; b=EdU7zWR8UewuwuyIqU1vaIrbdyhYA9QrPGqGGl2DBP7EX/xyadYBQLBP TKLWN5Yfk1366dstRX22nf5thpuhEGAWg4RDRycl7r9tiKy8MtIZ2ogNL zk34NFpV+sHeIIJG0xSi7VwLxNMDBk7TsaOFYL0828q5KilQr/uPNcH0O Q=; Received: from ironmsg07-lv.qualcomm.com ([10.47.202.151]) by alexa-out.qualcomm.com with ESMTP; 12 Jul 2022 05:24:12 -0700 X-QCInternal: smtphost Received: from ironmsg01-blr.qualcomm.com ([10.86.208.130]) by ironmsg07-lv.qualcomm.com with ESMTP/TLS/AES256-SHA; 12 Jul 2022 05:24:10 -0700 X-QCInternal: smtphost Received: from vboma-linux.qualcomm.com ([10.204.65.94]) by ironmsg01-blr.qualcomm.com with ESMTP; 12 Jul 2022 17:54:06 +0530 Received: by vboma-linux.qualcomm.com (Postfix, from userid 72083) id 3EC7F900883; Tue, 12 Jul 2022 17:54:05 +0530 (IST) From: Viswanath Boma To: video.upstream.external@qti.qualcomm.com, Stanimir Varbanov , Andy Gross , Bjorn Andersson , Mauro Carvalho Chehab , linux-media@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Viswanath Boma Subject: [PATCH 3/7] venus : CAPTURE Plane width/height alignment with OUT plane. Date: Tue, 12 Jul 2022 17:53:43 +0530 Message-Id: <20220712122347.6781-3-quic_vboma@quicinc.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20220712122347.6781-1-quic_vboma@quicinc.com> References: <20220712122347.6781-1-quic_vboma@quicinc.com> Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org From: Stanimir Varbanov V4l2 encoder compliance set-format test cases failing as Capture plane width/height not aligned to OUT plane . Change-Id: I7318a8a750f720e81b7b51520823b68ff13a2697 Signed-off-by: Viswanath Boma --- drivers/media/platform/qcom/venus/venc.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/media/platform/qcom/venus/venc.c b/drivers/media/platform/qcom/venus/venc.c index 21bff25e3f814..b56960d7f6c89 100644 --- a/drivers/media/platform/qcom/venus/venc.c +++ b/drivers/media/platform/qcom/venus/venc.c @@ -192,10 +192,8 @@ venc_try_fmt_common(struct venus_inst *inst, struct v4l2_format *f) pixmp->height = clamp(pixmp->height, frame_height_min(inst), frame_height_max(inst)); - if (f->type == V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE) { - pixmp->width = ALIGN(pixmp->width, 128); - pixmp->height = ALIGN(pixmp->height, 32); - } + pixmp->width = ALIGN(pixmp->width, 128); + pixmp->height = ALIGN(pixmp->height, 32); pixmp->width = ALIGN(pixmp->width, 2); pixmp->height = ALIGN(pixmp->height, 2); From patchwork Tue Jul 12 12:23:44 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viswanath Boma X-Patchwork-Id: 589872 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id B11C5C43334 for ; Tue, 12 Jul 2022 12:24:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232590AbiGLMYT (ORCPT ); Tue, 12 Jul 2022 08:24:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40628 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232278AbiGLMYS (ORCPT ); Tue, 12 Jul 2022 08:24:18 -0400 Received: from alexa-out.qualcomm.com (alexa-out.qualcomm.com [129.46.98.28]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1BEA5A5E52; Tue, 12 Jul 2022 05:24:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; i=@quicinc.com; q=dns/txt; s=qcdkim; t=1657628656; x=1689164656; h=from:to:cc:subject:date:message-id:in-reply-to: references; bh=NZcIxal9HP23HwdA1OYoFpYvchF31b6+LHpnoM9W5FA=; b=pmaJnJqG6JnmtfXgqPqYaN8mOG+7R5GHBUC6b2yY4fmyOeeBQPj+2f8Z URKxgqFRKt5+hp9GSW2CZcRgIpEjo3QO6/u/rrbmwgqT860CoX4a2u9bh qTeuvTIrokwwrArl7GmaInCCvZ/JS/ZoIcHmMmNWkXT/wOtwTA7nUnI7s M=; Received: from ironmsg09-lv.qualcomm.com ([10.47.202.153]) by alexa-out.qualcomm.com with ESMTP; 12 Jul 2022 05:24:16 -0700 X-QCInternal: smtphost Received: from ironmsg01-blr.qualcomm.com ([10.86.208.130]) by ironmsg09-lv.qualcomm.com with ESMTP/TLS/AES256-SHA; 12 Jul 2022 05:24:14 -0700 X-QCInternal: smtphost Received: from vboma-linux.qualcomm.com ([10.204.65.94]) by ironmsg01-blr.qualcomm.com with ESMTP; 12 Jul 2022 17:54:07 +0530 Received: by vboma-linux.qualcomm.com (Postfix, from userid 72083) id BEF5E900883; Tue, 12 Jul 2022 17:54:06 +0530 (IST) From: Viswanath Boma To: video.upstream.external@qti.qualcomm.com, Stanimir Varbanov , Andy Gross , Bjorn Andersson , Mauro Carvalho Chehab , linux-media@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Viswanath Boma Subject: [PATCH 4/7] venus : Addition of EOS Event support for Encoder Date: Tue, 12 Jul 2022 17:53:44 +0530 Message-Id: <20220712122347.6781-4-quic_vboma@quicinc.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20220712122347.6781-1-quic_vboma@quicinc.com> References: <20220712122347.6781-1-quic_vboma@quicinc.com> Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org V4l2 encoder compliance expecting End of sream Event registration support for Encoder. Change-Id: I85f7732a2ec08eba47c0d37181f739e90a7ab63a Signed-off-by: Viswanath Boma Acked-by: Stanimir Varbanov --- drivers/media/platform/qcom/venus/venc.c | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/drivers/media/platform/qcom/venus/venc.c b/drivers/media/platform/qcom/venus/venc.c index b56960d7f6c89..30ddb84c24997 100644 --- a/drivers/media/platform/qcom/venus/venc.c +++ b/drivers/media/platform/qcom/venus/venc.c @@ -507,6 +507,20 @@ static int venc_enum_frameintervals(struct file *file, void *fh, return 0; } +static int venc_subscribe_event(struct v4l2_fh *fh, + const struct v4l2_event_subscription *sub) +{ + + switch (sub->type) { + case V4L2_EVENT_EOS: + return v4l2_event_subscribe(fh, sub, 2, NULL); + case V4L2_EVENT_CTRL: + return v4l2_ctrl_subscribe_event(fh, sub); + default: + return -EINVAL; + } +} + static int venc_encoder_cmd(struct file *file, void *fh, struct v4l2_encoder_cmd *cmd) { @@ -572,7 +586,7 @@ static const struct v4l2_ioctl_ops venc_ioctl_ops = { .vidioc_g_parm = venc_g_parm, .vidioc_enum_framesizes = venc_enum_framesizes, .vidioc_enum_frameintervals = venc_enum_frameintervals, - .vidioc_subscribe_event = v4l2_ctrl_subscribe_event, + .vidioc_subscribe_event = venc_subscribe_event, .vidioc_unsubscribe_event = v4l2_event_unsubscribe, .vidioc_encoder_cmd = venc_encoder_cmd, }; From patchwork Tue Jul 12 12:23:45 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viswanath Boma X-Patchwork-Id: 590492 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0B74ECCA482 for ; Tue, 12 Jul 2022 12:24:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232746AbiGLMYT (ORCPT ); Tue, 12 Jul 2022 08:24:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40630 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232314AbiGLMYS (ORCPT ); Tue, 12 Jul 2022 08:24:18 -0400 Received: from alexa-out.qualcomm.com (alexa-out.qualcomm.com [129.46.98.28]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3BA54A5E45; Tue, 12 Jul 2022 05:24:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; i=@quicinc.com; q=dns/txt; s=qcdkim; t=1657628656; x=1689164656; h=from:to:cc:subject:date:message-id:in-reply-to: references; bh=d9r/tdf0+ObtCSJlls88b4SKEF45LTl689Byo2z/09s=; b=ou9hpoht3uF7v6s6XAkPTe3idfphKzklUSppfZjH4oLzEV8rJCRuT5rC IC6o0QP2bnMPsoQzGLrDT15duioN4U7/ZeDBKIiarOnVd35RXA1FQuV5l Xs1yvM7RulCQoC6E2Yg7rymGu+BDRDeObhjCsp8ubn+Y0GGQbRRuZhx9/ 4=; Received: from ironmsg07-lv.qualcomm.com ([10.47.202.151]) by alexa-out.qualcomm.com with ESMTP; 12 Jul 2022 05:24:16 -0700 X-QCInternal: smtphost Received: from ironmsg01-blr.qualcomm.com ([10.86.208.130]) by ironmsg07-lv.qualcomm.com with ESMTP/TLS/AES256-SHA; 12 Jul 2022 05:24:14 -0700 X-QCInternal: smtphost Received: from vboma-linux.qualcomm.com ([10.204.65.94]) by ironmsg01-blr.qualcomm.com with ESMTP; 12 Jul 2022 17:54:09 +0530 Received: by vboma-linux.qualcomm.com (Postfix, from userid 72083) id C0FAB900883; Tue, 12 Jul 2022 17:54:08 +0530 (IST) From: Viswanath Boma To: video.upstream.external@qti.qualcomm.com, Stanimir Varbanov , Andy Gross , Bjorn Andersson , Mauro Carvalho Chehab , linux-media@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Dikshita Agarwal , Viswanath Boma Subject: [PATCH 5/7] venus : Addition of support for VIDIOC_TRY_ENCODER_CMD Date: Tue, 12 Jul 2022 17:53:45 +0530 Message-Id: <20220712122347.6781-5-quic_vboma@quicinc.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20220712122347.6781-1-quic_vboma@quicinc.com> References: <20220712122347.6781-1-quic_vboma@quicinc.com> Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org From: Dikshita Agarwal v4l2 compliance expecting support for vidioc_try_encoder_cmd error details : test VIDIOC_(TRY_)ENCODER_CMD: FAIL Change-Id: I87a655dc506f3e713e2c86ab5203ca9c45cc5e1b Signed-off-by: Viswanath Boma --- drivers/media/platform/qcom/venus/venc.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/media/platform/qcom/venus/venc.c b/drivers/media/platform/qcom/venus/venc.c index 30ddb84c24997..4f10f5de7e3e6 100644 --- a/drivers/media/platform/qcom/venus/venc.c +++ b/drivers/media/platform/qcom/venus/venc.c @@ -589,6 +589,7 @@ static const struct v4l2_ioctl_ops venc_ioctl_ops = { .vidioc_subscribe_event = venc_subscribe_event, .vidioc_unsubscribe_event = v4l2_event_unsubscribe, .vidioc_encoder_cmd = venc_encoder_cmd, + .vidioc_try_encoder_cmd = v4l2_m2m_ioctl_try_encoder_cmd, }; static int venc_pm_get(struct venus_inst *inst) From patchwork Tue Jul 12 12:23:46 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viswanath Boma X-Patchwork-Id: 589871 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 59BF4C43334 for ; Tue, 12 Jul 2022 12:24:23 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232834AbiGLMYV (ORCPT ); Tue, 12 Jul 2022 08:24:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40632 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232276AbiGLMYS (ORCPT ); Tue, 12 Jul 2022 08:24:18 -0400 Received: from alexa-out.qualcomm.com (alexa-out.qualcomm.com [129.46.98.28]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9F398A5E46; Tue, 12 Jul 2022 05:24:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; i=@quicinc.com; q=dns/txt; s=qcdkim; t=1657628657; x=1689164657; h=from:to:cc:subject:date:message-id:in-reply-to: references; bh=WubKUJ4j12eFTZdYGCF0XxgkVzipXBW3gt8uczrmXCM=; b=D6yR6bP+KYnp3mHt000oq1Rd+NdJvj0CVMT7iC5+MJqBmHYt8CbXWTWm rNrl4bBbf1z40GHc1JMjEd7QPsWTbD6eSaLc8GJDgkUQ0U+jZ5b2K0hJr 0EBsD57kXVzIFwFqJeS4Xg12hL2bhCEnt669rDD+Y1M6MjX+0uOdQXI5I 0=; Received: from ironmsg09-lv.qualcomm.com ([10.47.202.153]) by alexa-out.qualcomm.com with ESMTP; 12 Jul 2022 05:24:16 -0700 X-QCInternal: smtphost Received: from ironmsg01-blr.qualcomm.com ([10.86.208.130]) by ironmsg09-lv.qualcomm.com with ESMTP/TLS/AES256-SHA; 12 Jul 2022 05:24:14 -0700 X-QCInternal: smtphost Received: from vboma-linux.qualcomm.com ([10.204.65.94]) by ironmsg01-blr.qualcomm.com with ESMTP; 12 Jul 2022 17:54:11 +0530 Received: by vboma-linux.qualcomm.com (Postfix, from userid 72083) id 77B85900883; Tue, 12 Jul 2022 17:54:10 +0530 (IST) From: Viswanath Boma To: video.upstream.external@qti.qualcomm.com, Stanimir Varbanov , Andy Gross , Bjorn Andersson , Mauro Carvalho Chehab , linux-media@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Viswanath Boma Subject: [PATCH 6/7] venus : Remove the capture plane settings for venc_g_parm/venc_s_parm Date: Tue, 12 Jul 2022 17:53:46 +0530 Message-Id: <20220712122347.6781-6-quic_vboma@quicinc.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20220712122347.6781-1-quic_vboma@quicinc.com> References: <20220712122347.6781-1-quic_vboma@quicinc.com> Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org v4l2 compliance expecting settings for out buffer only and the same values will be propagated to capture buffer setting by h/w encoder . settings on cpature plane are optional , required only if offline-encoding supports. error details : fail: v4l2-test-formats.cpp(1350): !ret Change-Id: I3d33bf1443cb5b20c3be6ce7c86df53aafb7918e Signed-off-by: Viswanath Boma --- drivers/media/platform/qcom/venus/venc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/media/platform/qcom/venus/venc.c b/drivers/media/platform/qcom/venus/venc.c index 4f10f5de7e3e6..420691f71121e 100644 --- a/drivers/media/platform/qcom/venus/venc.c +++ b/drivers/media/platform/qcom/venus/venc.c @@ -390,7 +390,7 @@ static int venc_s_parm(struct file *file, void *fh, struct v4l2_streamparm *a) struct v4l2_fract *timeperframe = &out->timeperframe; u64 us_per_frame, fps; - if (a->type != V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE && + if (a->type != V4L2_BUF_TYPE_VIDEO_OUTPUT && a->type != V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE) return -EINVAL; @@ -422,7 +422,7 @@ static int venc_g_parm(struct file *file, void *fh, struct v4l2_streamparm *a) { struct venus_inst *inst = to_inst(file); - if (a->type != V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE && + if (a->type != V4L2_BUF_TYPE_VIDEO_OUTPUT && a->type != V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE) return -EINVAL; From patchwork Tue Jul 12 12:23:47 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viswanath Boma X-Patchwork-Id: 590491 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 760AFCCA47C for ; Tue, 12 Jul 2022 12:24:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232918AbiGLMYX (ORCPT ); Tue, 12 Jul 2022 08:24:23 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40676 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232821AbiGLMYU (ORCPT ); Tue, 12 Jul 2022 08:24:20 -0400 Received: from alexa-out.qualcomm.com (alexa-out.qualcomm.com [129.46.98.28]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 47242A5E6B; Tue, 12 Jul 2022 05:24:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; i=@quicinc.com; q=dns/txt; s=qcdkim; t=1657628658; x=1689164658; h=from:to:cc:subject:date:message-id:in-reply-to: references; bh=1GXy2fCY/tz9CAmVku5gyITyTFE/cMolO+FZrOVG8xI=; b=RpG9Al0VLxui4uZi1MJz+VagQReD0ejvlfYUvjTSo2z1T6Hk4p0D82s3 qigw8QofT3oMybIqLGXVEFoetc8KXUM39a6QcCPcGcl6w6xj3ii33Wiq/ 0GkM/7AZxt5Oc0RPKy4Au5iwM+FVwMmwUYqeIDDYel2DBkc5b+iepiSU5 U=; Received: from ironmsg09-lv.qualcomm.com ([10.47.202.153]) by alexa-out.qualcomm.com with ESMTP; 12 Jul 2022 05:24:17 -0700 X-QCInternal: smtphost Received: from ironmsg01-blr.qualcomm.com ([10.86.208.130]) by ironmsg09-lv.qualcomm.com with ESMTP/TLS/AES256-SHA; 12 Jul 2022 05:24:16 -0700 X-QCInternal: smtphost Received: from vboma-linux.qualcomm.com ([10.204.65.94]) by ironmsg01-blr.qualcomm.com with ESMTP; 12 Jul 2022 17:54:12 +0530 Received: by vboma-linux.qualcomm.com (Postfix, from userid 72083) id 01C04900883; Tue, 12 Jul 2022 17:54:11 +0530 (IST) From: Viswanath Boma To: video.upstream.external@qti.qualcomm.com, Stanimir Varbanov , Andy Gross , Bjorn Andersson , Mauro Carvalho Chehab , linux-media@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Vikash Garodia , Viswanath Boma Subject: [PATCH 7/7] venus : Allow MIN/MAX settings for the v4l2 encoder controls defined range . Date: Tue, 12 Jul 2022 17:53:47 +0530 Message-Id: <20220712122347.6781-7-quic_vboma@quicinc.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20220712122347.6781-1-quic_vboma@quicinc.com> References: <20220712122347.6781-1-quic_vboma@quicinc.com> Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org From: Vikash Garodia Control MIN/MAX range defined as 0 to 1 ,as MIN value setting enabled for V4L2_CID_MPEG_VIDEO_H264_8X8_TRANSFORM . error details: fail: v4l2-test-controls.cpp(516): invalid maximum range check Change-Id: I8db2585d35a72bf238cec4cd8f49661170e98a85 Signed-off-by: Viswanath Boma --- drivers/media/platform/qcom/venus/venc_ctrls.c | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/drivers/media/platform/qcom/venus/venc_ctrls.c b/drivers/media/platform/qcom/venus/venc_ctrls.c index 95fdad160732b..6dcbd3baa9c86 100644 --- a/drivers/media/platform/qcom/venus/venc_ctrls.c +++ b/drivers/media/platform/qcom/venus/venc_ctrls.c @@ -323,19 +323,6 @@ static int venc_op_s_ctrl(struct v4l2_ctrl *ctrl) if (ctr->profile.h264 != V4L2_MPEG_VIDEO_H264_PROFILE_HIGH && ctr->profile.h264 != V4L2_MPEG_VIDEO_H264_PROFILE_CONSTRAINED_HIGH) return -EINVAL; - - /* - * In video firmware, 8x8 transform is supported only for - * high profile(HP) and constrained high profile(CHP). - * If client wants to disable 8x8 transform for HP/CHP, - * it is better to set profile as main profile(MP). - * Because there is no difference between HP and MP - * if we disable 8x8 transform for HP. - */ - - if (ctrl->val == 0) - return -EINVAL; - ctr->h264_8x8_transform = ctrl->val; break; default: