From patchwork Wed Mar 22 05:13:06 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ming Qian X-Patchwork-Id: 73195 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:604a:0:0:0:0:0 with SMTP id j10csp2167545wrt; Tue, 21 Mar 2023 22:15:26 -0700 (PDT) X-Google-Smtp-Source: AK7set/215sdbrvU9znzdLD8ybhg0TnoOKc5mFX6dlCvHkJ2j+DHX9wmG0w7Q5/jWGrycOg5CxhH X-Received: by 2002:aa7:9798:0:b0:628:4c9:a07 with SMTP id o24-20020aa79798000000b0062804c90a07mr1796582pfp.29.1679462126104; Tue, 21 Mar 2023 22:15:26 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1679462126; cv=pass; d=google.com; s=arc-20160816; b=H9WuE8Fyss5v0CSc36S4G0CUs99Teyx3uqUF/Pp5Es0sWvFRKx3L0JPrPqdyM9duUO 3jK0/l6mG5GsjSfhpIPwFr+mhwUFUFNMetX+PP0HbfxG5K4B+S2xkB+uiV53BBdqS3hR ZZsi8TvwDS+olutk9JgoYKwpiHcSOXFXv0CUr8Y9efb9qYP/TDjDehoFXmk8BAbErtd7 Si+nxydycuHMedB7K7gVC4p2+mqJHP5t+ZORJHGzglKnYeFgW5xkMZpOfRBg+7cnJT/P 4syu07LD4a8oqBFbtLVTns4qgO07NvVb/A97cGLu+N3OntesSEU8YpjzzR46a9pb0ujI fEAg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=z7cKeN0lTqGsO4nqj7pO/oD9FjZqKyVVa6nQ8BbK5Vg=; b=e6dEz2Jc7/B6pbB6tlKWEo5j3bxXhbrl7zJoVAdKoIXHjGlUK5y33SqqCjh5qtDaeF 1n0o/xAK0w+dLdce5LQop7zD56Sf9KF7zd0pF+Qr/8llAx3fsymLrFvMBmGtTSBdND1X ueyxOhjGX8eGc+mj0ACV2eOFaLelTsA525gBQN9RJVCjXxDYJZOfUmTCQJn0YsVhjWVJ alJRqf1sXKeHa485ZyzT55XoPdeSo2QdkEqG4PnbJvZc8imjG1VTwc210idY/QSGLqOH cPgvmwrzZmA7yb4mYWdBfKdXN7ja9wQv9J24N5FHk4uqLWAbqoabSvlL/gZHHu0lmvRB BLWQ== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@nxp.com header.s=selector2 header.b=DSDnNpPj; arc=pass (i=1 spf=pass spfdomain=nxp.com dkim=pass dkdomain=nxp.com dmarc=pass fromdomain=nxp.com); 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=nxp.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id bm13-20020a056a00320d00b00627dd2b5309si11322875pfb.251.2023.03.21.22.15.13; Tue, 21 Mar 2023 22:15:26 -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=@nxp.com header.s=selector2 header.b=DSDnNpPj; arc=pass (i=1 spf=pass spfdomain=nxp.com dkim=pass dkdomain=nxp.com dmarc=pass fromdomain=nxp.com); 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=nxp.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229842AbjCVFOF (ORCPT + 99 others); Wed, 22 Mar 2023 01:14:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42080 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229727AbjCVFN6 (ORCPT ); Wed, 22 Mar 2023 01:13:58 -0400 Received: from EUR05-DB8-obe.outbound.protection.outlook.com (mail-db8eur05on2050.outbound.protection.outlook.com [40.107.20.50]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C4F6651FBE; Tue, 21 Mar 2023 22:13:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=G1CbF4fmL2+jR8NsQornTKcbE8j4kI1GpdQe7ZOEk9KX0rp3mooI7XZnbHaDfFke28B19gvBMKXheH9L5lTeJniO4ofp6a2jrJRbEWaTWSZMSOrLTr9LxCEQ3Z59VSLopFWjgGWyK732g6hVraO6De7xm3oIC3BuT0GOMQvwRb/U7EMHc3iKRwDroUVWz8J81KcRF0MYktTX55iRYJAgwtI+8WMQbdtzJPC6jfPVusFpWtQhSKbRhqzq45ZaUUhcZKMJrRQkAtcSV9WWZGQO1xBgQw6ZVRYWs8MlrYXtNM+MYQNOEbYtYYGVIF33pWscrxePHzOqpn5V12Vda2vcJQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=z7cKeN0lTqGsO4nqj7pO/oD9FjZqKyVVa6nQ8BbK5Vg=; b=Ta4oAAISkgmM8YCKVtOOAPq8vMD/5GTbG/1JB6XbQ+AHucqUyKIKzHcwHCvkqNPIXnKwsGqjzwAd+jvMT0I8Mi1p/X/cdelz+0Io/o9ZghfVkniDHkte7w7xrcSL+pr3twQ+dekQjBodynQ1fv2YdSRSSyiWjvoIZXtFyzBJzIDDNE375DVo2Lnl3uQ0Dk/PYIszxU4E/CkdM8u1M6dOwxTXlLbPa1hn8lwzGfE2XpU5z3CT1K8Mikgj8ZD4dlBVJ5JCx1AVdYZGghBg98ef0LzHNdqW+OuoHzT9PYJ3z2oRYSn2i+cwZ/zbvMKHqJ4L+g5qvLjnSaG3oVl7l/a3zA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=z7cKeN0lTqGsO4nqj7pO/oD9FjZqKyVVa6nQ8BbK5Vg=; b=DSDnNpPjb8REBeRflT3A2Ar0lJgZ9a7OIfsChxi7eGyHAcXl0QRaeXTMGD4SSaAsVz0g/1yP0LlkNjpu9ys8u9husBe7L7/ssg6td1g6a/0Yhm2gixtH8Qqhw7yySL13AcB6mqijt6pb5KBVWRqq1l9JkenW5nLS4fcf7182g0E= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from AM6PR04MB6341.eurprd04.prod.outlook.com (2603:10a6:20b:d8::14) by AM9PR04MB8100.eurprd04.prod.outlook.com (2603:10a6:20b:3e3::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6178.37; Wed, 22 Mar 2023 05:13:54 +0000 Received: from AM6PR04MB6341.eurprd04.prod.outlook.com ([fe80::89aa:9204:790d:e46b]) by AM6PR04MB6341.eurprd04.prod.outlook.com ([fe80::89aa:9204:790d:e46b%5]) with mapi id 15.20.6178.037; Wed, 22 Mar 2023 05:13:54 +0000 From: Ming Qian To: mchehab@kernel.org, mirela.rabulea@oss.nxp.com, hverkuil-cisco@xs4all.nl Cc: shawnguo@kernel.org, s.hauer@pengutronix.de, kernel@pengutronix.de, festevam@gmail.com, xiahong.bao@nxp.com, linux-imx@nxp.com, linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: [PATCH v5 03/10] media: Add Y212 v4l2 format info Date: Wed, 22 Mar 2023 13:13:06 +0800 Message-Id: X-Mailer: git-send-email 2.38.1 In-Reply-To: References: X-ClientProxiedBy: SI1PR02CA0021.apcprd02.prod.outlook.com (2603:1096:4:1f4::14) To AM6PR04MB6341.eurprd04.prod.outlook.com (2603:10a6:20b:d8::14) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: AM6PR04MB6341:EE_|AM9PR04MB8100:EE_ X-MS-Office365-Filtering-Correlation-Id: f8be1dba-1b2e-4474-6350-08db2a943b4a X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: fgnpsEG3eMJtYK/GIgWB1jD1C3IDnOUBGwwFsWYuI4/2mVxCZzdexnd4hga/FwCHu2mdnesyOcmdITUc1uzgg79OlCkLiXdNBF/DBBYWCzGWRK2X9Kv9qhIj+prWB7zDPsHRmTkiQmTLJezw0mpEcAZPOwQKTuwyrGWLzY14HB2MRVA42w+2MLUPtY67/tAnaC/YX6jWefZQjYpmqPskOEJDxDw1STFp91yh7g3XTSYStny7hjiMVSyRFQejdoYAIEZk4j3ikgFjZWxMfpBz5x+qyZRupqihPbfD7pKjFWMwypQ4JpQOb2+YF4cLwIAlBay+1/3WIjvfo0ud+ndmQysUi96vmJiZVb1qihLkft/YNertc9K817URXsPVnsiXHfGyrZrDYF1fY0lbCoNCxGk1t+qQ3MST4lWbhfnjM5PUTML/Oynd79+XkfJ7g11gFhq5TVCEctoYfA2iC8Nb6vwF8MvqGdVXwR4ZJCzRgKWNi/Hbe5/WYIvBf7+XorzoZux+8qSelxuqDBlPjGCkbE7Y4oTpOQnKy4c3iosyDIfwZDXldshws5sxR7G5N3SZfx4K6hWjCXIsdHIac5hZ/QsyqEn7rgHkVsEN/ee24TKb13tIhxz3dll7MfrBRJPX8MG4rbvmY23DCH+IDYscRrdKUilKZroh5PPTVVQXQZWaRL5MXdA3C1zNiNb99BdtnbKRhsSaTy+APaEMURQjaA== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:AM6PR04MB6341.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230025)(4636009)(346002)(366004)(136003)(39860400002)(376002)(396003)(451199018)(6486002)(66556008)(41300700001)(52116002)(66476007)(7416002)(478600001)(66946007)(5660300002)(8936002)(8676002)(316002)(44832011)(4326008)(36756003)(86362001)(6506007)(6512007)(186003)(26005)(6666004)(2616005)(2906002)(38350700002)(38100700002)(83380400001);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: wymhrKO2tPm+jm0Kg+9KVrssrqAsFc43RWYYzOZNd45F4deD2snxxbgzwjvhQhjZm/CMLxjAJ+83wC1L3P/8bW6RIUfrxbPyZOOPWi6f8SZD2tGMeMFrfCoz1c0uYl82RFVwbaa1467z2zvf6aXUk0ISL1bn2HjSeGxL/Kt78TUiaQJXiAapuhAcLiNN2teBQ1sXE/eVJUyxHgHS7w2qbb5/QHqMAwqkvTYKuLhsRRPoU1+cNGem89a8ejyOzEOngjZyuc3o2a55IpEhKrln4Fcdrt/k1PrFGwJQ89jb3rw0EGmgkkWSK563GuGM3eMzRHktYzBcDFXZbbMdG/27eGIR8flGlg9CC4zT55gMYUIb0JgQxWBN5D6mwerhgKyOCSX7IU6jpfjUV9RmW9eWXbj6XGHqbvU6pZMHAWnchKc/I1f1s9KAoUw3A5xY3dVHt6JyEf2DtKFTkIcPXbKoZNkEBSNIlpr95/k5/FGfBo3p+vKC92ntaaTRVY6hj8p3Um6B0BbmTUWdXyh8QTQGEb+cs1E7YQ/J+atOdoiS/c6sO45mj+N7X1TjJ7XTVp2spPFW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6350-08db2a943b4a X-MS-Exchange-CrossTenant-AuthSource: AM6PR04MB6341.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 22 Mar 2023 05:13:54.3345 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: K9KnSpVxMKSwSdmBof0/FxDcGYf4rZTRAY2dM63jlD6zNouJm79UViyt34aO43NOWFD2xr9flIyYPJagbegYNQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM9PR04MB8100 X-Spam-Status: No, score=1.1 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2, RCVD_IN_VALIDITY_RPBL,SPF_HELO_PASS,SPF_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.6 X-Spam-Level: * 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?1761043678377480321?= X-GMAIL-MSGID: =?utf-8?q?1761043678377480321?= Y212 is a YUV format with 12-bits per component like YUYV, expanded to 16bits. Data in the 12 high bits, zeros in the 4 low bits, arranged in little endian order. Add the missing v4l2 foramt info of Y212 Signed-off-by: Ming Qian --- drivers/media/v4l2-core/v4l2-common.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/media/v4l2-core/v4l2-common.c b/drivers/media/v4l2-core/v4l2-common.c index a5e8ba370d33..21ace56fac04 100644 --- a/drivers/media/v4l2-core/v4l2-common.c +++ b/drivers/media/v4l2-core/v4l2-common.c @@ -258,6 +258,7 @@ const struct v4l2_format_info *v4l2_format_info(u32 format) { .format = V4L2_PIX_FMT_YVYU, .pixel_enc = V4L2_PIXEL_ENC_YUV, .mem_planes = 1, .comp_planes = 1, .bpp = { 2, 0, 0, 0 }, .hdiv = 2, .vdiv = 1 }, { .format = V4L2_PIX_FMT_UYVY, .pixel_enc = V4L2_PIXEL_ENC_YUV, .mem_planes = 1, .comp_planes = 1, .bpp = { 2, 0, 0, 0 }, .hdiv = 2, .vdiv = 1 }, { .format = V4L2_PIX_FMT_VYUY, .pixel_enc = V4L2_PIXEL_ENC_YUV, .mem_planes = 1, .comp_planes = 1, .bpp = { 2, 0, 0, 0 }, .hdiv = 2, .vdiv = 1 }, + { .format = V4L2_PIX_FMT_Y212, .pixel_enc = V4L2_PIXEL_ENC_YUV, .mem_planes = 1, .comp_planes = 1, .bpp = { 4, 0, 0, 0 }, .hdiv = 2, .vdiv = 1 }, /* YUV planar formats */ { .format = V4L2_PIX_FMT_NV12, .pixel_enc = V4L2_PIXEL_ENC_YUV, .mem_planes = 1, .comp_planes = 2, .bpp = { 1, 2, 0, 0 }, .hdiv = 2, .vdiv = 2 },