From patchwork Tue Oct 27 13:49:21 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marian Cichy X-Patchwork-Id: 11860461 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 5F3F092C for ; Tue, 27 Oct 2020 13:49:46 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 4F6FE21D42 for ; Tue, 27 Oct 2020 13:49:46 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752561AbgJ0Ntp (ORCPT ); Tue, 27 Oct 2020 09:49:45 -0400 Received: from metis.ext.pengutronix.de ([85.220.165.71]:45273 "EHLO metis.ext.pengutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752556AbgJ0Ntp (ORCPT ); Tue, 27 Oct 2020 09:49:45 -0400 Received: from dude02.hi.pengutronix.de ([2001:67c:670:100:1d::28]) by metis.ext.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kXPM8-0006YF-8G; Tue, 27 Oct 2020 14:49:44 +0100 Received: from mci by dude02.hi.pengutronix.de with local (Exim 4.92) (envelope-from ) id 1kXPM7-0007uO-W0; Tue, 27 Oct 2020 14:49:43 +0100 From: Marian Cichy To: linux-media@vger.kernel.org Cc: Marian Cichy Subject: [PATCH 1/2] media-ctl: fix ycbcr property in help description Date: Tue, 27 Oct 2020 14:49:21 +0100 Message-Id: <20201027134922.30321-1-m.cichy@pengutronix.de> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 X-SA-Exim-Connect-IP: 2001:67c:670:100:1d::28 X-SA-Exim-Mail-From: mci@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-media@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org the help description in media-ctl claims that the ycbcr property in v4l2-mbusfmt is called 'ycbcr-enc', which will lead to an EINVAL when used as the property is actually called 'ycbcr'. Signed-off-by: Marian Cichy --- utils/media-ctl/options.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utils/media-ctl/options.c b/utils/media-ctl/options.c index fb923775..fe79af10 100644 --- a/utils/media-ctl/options.c +++ b/utils/media-ctl/options.c @@ -78,7 +78,7 @@ static void usage(const char *argv0) printf("\tv4l2-property = v4l2-mbusfmt | v4l2-crop | v4l2-interval\n"); printf("\t | v4l2-compose | v4l2-interval ;\n"); printf("\tv4l2-mbusfmt = 'fmt:' fcc '/' size ; { 'field:' v4l2-field ; } { 'colorspace:' v4l2-colorspace ; }\n"); - printf("\t { 'xfer:' v4l2-xfer-func ; } { 'ycbcr-enc:' v4l2-ycbcr-enc-func ; }\n"); + printf("\t { 'xfer:' v4l2-xfer-func ; } { 'ycbcr:' v4l2-ycbcr-enc-func ; }\n"); printf("\t { 'quantization:' v4l2-quant ; }\n"); printf("\tv4l2-crop = 'crop:' rectangle ;\n"); printf("\tv4l2-compose = 'compose:' rectangle ;\n"); From patchwork Tue Oct 27 13:49:22 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marian Cichy X-Patchwork-Id: 11860477 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 49E4561C for ; Tue, 27 Oct 2020 13:50:48 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 2DA7A21707 for ; Tue, 27 Oct 2020 13:50:48 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752785AbgJ0Nur (ORCPT ); Tue, 27 Oct 2020 09:50:47 -0400 Received: from metis.ext.pengutronix.de ([85.220.165.71]:60639 "EHLO metis.ext.pengutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752639AbgJ0Ntw (ORCPT ); Tue, 27 Oct 2020 09:49:52 -0400 Received: from dude02.hi.pengutronix.de ([2001:67c:670:100:1d::28]) by metis.ext.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kXPMF-0006ZY-5J; Tue, 27 Oct 2020 14:49:51 +0100 Received: from mci by dude02.hi.pengutronix.de with local (Exim 4.92) (envelope-from ) id 1kXPME-0007xu-Rr; Tue, 27 Oct 2020 14:49:50 +0100 From: Marian Cichy To: linux-media@vger.kernel.org Cc: Marian Cichy Subject: [PATCH 2/2] media-ctl: add v4l2-ycbcr-enc-func field in help description Date: Tue, 27 Oct 2020 14:49:22 +0100 Message-Id: <20201027134922.30321-2-m.cichy@pengutronix.de> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20201027134922.30321-1-m.cichy@pengutronix.de> References: <20201027134922.30321-1-m.cichy@pengutronix.de> MIME-Version: 1.0 X-SA-Exim-Connect-IP: 2001:67c:670:100:1d::28 X-SA-Exim-Mail-From: mci@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-media@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org the help-description of media-ctl shows the possible values for v4l2-colorspace, v4l2-xfer-func anf v4l2-quant, but misses to show them for v4l2-ycbcr-enc-func, eveb though they are perfectly defined in the source code like for the other fields. Lets print them too in the help description. Signed-off-by: Marian Cichy --- utils/media-ctl/options.c | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/utils/media-ctl/options.c b/utils/media-ctl/options.c index fe79af10..ca8106ba 100644 --- a/utils/media-ctl/options.c +++ b/utils/media-ctl/options.c @@ -103,23 +103,29 @@ static void usage(const char *argv0) printf("\t %s\n", v4l2_subdev_field_to_string(i)); - printf("\tv4l2-colorspace One of the following:\n"); + printf("\tv4l2-colorspace One of the following:\n"); for (i = V4L2_COLORSPACE_DEFAULT; i <= V4L2_COLORSPACE_DCI_P3; i++) printf("\t %s\n", v4l2_subdev_colorspace_to_string(i)); - printf("\tv4l2-xfer-func One of the following:\n"); + printf("\tv4l2-xfer-func One of the following:\n"); for (i = V4L2_XFER_FUNC_DEFAULT; i <= V4L2_XFER_FUNC_SMPTE2084; i++) printf("\t %s\n", v4l2_subdev_xfer_func_to_string(i)); - printf("\tv4l2-quant One of the following:\n"); + printf("\tv4l2-quant One of the following:\n"); for (i = V4L2_QUANTIZATION_DEFAULT; i <= V4L2_QUANTIZATION_LIM_RANGE; i++) printf("\t %s\n", v4l2_subdev_quantization_to_string(i)); + + printf("\tv4l2-ycbcr-enc-func One of the following:\n"); + + for (i = V4L2_YCBCR_ENC_DEFAULT; i <= V4L2_YCBCR_ENC_SMPTE240M; i++) + printf("\t %s\n", + v4l2_subdev_ycbcr_encoding_to_string(i)); } #define OPT_PRINT_DOT 256