kernel: camera: add bayer raw14 format.

Add raw14 bayer format driver support

bug 4335141

Change-Id: I45c4fb2f692a98cf33d81415104e815c14340a68
Signed-off-by: snchen <snchen@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3176545
(cherry picked from commit b2db309d50)
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3226512
Reviewed-by: svcacv <svcacv@nvidia.com>
GVS: buildbot_gerritrpt <buildbot_gerritrpt@nvidia.com>
Reviewed-by: Anubhav Rai <arai@nvidia.com>
Reviewed-by: Bibek Basu <bbasu@nvidia.com>
This commit is contained in:
snchen
2023-10-19 14:56:31 +08:00
committed by Jon Hunter
parent 390f3cb907
commit 14f79046eb
3 changed files with 73 additions and 7 deletions

View File

@@ -1,8 +1,19 @@
// SPDX-License-Identifier: GPL-2.0
/*
* camera_common.c - utilities for tegra camera driver
* SPDX-FileCopyrightText: Copyright (c) 2015-2024 NVIDIA CORPORATION & AFFILIATES.
* All rights reserved.
*
* Copyright (c) 2015-2024, NVIDIA CORPORATION. All rights reserved.
* This program is free software; you can redistribute it and/or modify it
* under the terms and conditions of the GNU General Public License,
* version 2, as published by the Free Software Foundation.
*
* This program is distributed in the hope it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
* more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include <nvidia/conftest.h>
@@ -33,6 +44,26 @@
#define HDR_ENABLE 0x1
static const struct camera_common_colorfmt camera_common_color_fmts[] = {
{
MEDIA_BUS_FMT_SBGGR14_1X14,
V4L2_COLORSPACE_SRGB,
V4L2_PIX_FMT_SBGGR14,
},
{
MEDIA_BUS_FMT_SRGGB14_1X14,
V4L2_COLORSPACE_SRGB,
V4L2_PIX_FMT_SRGGB14,
},
{
MEDIA_BUS_FMT_SGRBG14_1X14,
V4L2_COLORSPACE_SRGB,
V4L2_PIX_FMT_SGRBG14,
},
{
MEDIA_BUS_FMT_SGBRG14_1X14,
V4L2_COLORSPACE_SRGB,
V4L2_PIX_FMT_SGBRG14
},
{
MEDIA_BUS_FMT_SRGGB12_1X12,
V4L2_COLORSPACE_SRGB,