mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Wenmeng Liu <wenmeng.liu@oss.qualcomm.com>
To: Kieran Bingham <kieran.bingham@ideasonboard.com>,
	Conor Dooley <conor+dt@kernel.org>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	Mauro Carvalho Chehab <mchehab@kernel.org>,
	Rob Herring <robh@kernel.org>,
	Sakari Ailus <sakari.ailus@linux.intel.com>,
	Vladimir Zapolskiy <vladimir.zapolskiy@linaro.org>
Cc: linux-media@vger.kernel.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/2] media: i2c: og0va1b: Add OmniVision OG0VA1B camera sensor
Date: Thu, 18 Jun 2026 22:00:32 +0800	[thread overview]
Message-ID: <7c25faea-7e86-43d5-9aff-2bf6f609e311@oss.qualcomm.com> (raw)
In-Reply-To: <178178854034.861173.9780571180496261859@ping.linuxembedded.co.uk>



On 6/18/2026 9:15 PM, Kieran Bingham wrote:
> Quoting Wenmeng Liu (2026-06-18 13:36:27)
>>
>>
>> On 6/18/2026 6:50 PM, Vladimir Zapolskiy wrote:
>>> Hello Wenmeng.
>>>
>>> On 6/18/26 13:37, Wenmeng Liu wrote:
>>>> Add V4L2 sub device driver for OmniVision OG0VA1B image sensor.
>>>> OmniVision OG0VA1B is an image sensor, which produces frames in 10-bit
>>>> raw output format (Y10) over a 1-lane MIPI CSI-2 interface and supports
>>>> the 640x480 (VGA) resolution.
>>>>
>>>> Signed-off-by: Wenmeng Liu <wenmeng.liu@oss.qualcomm.com>
>>>> ---
>>>>    MAINTAINERS                 |   1 +
>>>>    drivers/media/i2c/Kconfig   |  10 +
>>>>    drivers/media/i2c/Makefile  |   1 +
>>>>    drivers/media/i2c/og0va1b.c | 867 ++++++++++++++++++++++++++++++++++
>>>> ++++++++++
>>>>    4 files changed, 879 insertions(+)
>>>>
>>>> diff --git a/MAINTAINERS b/MAINTAINERS
>>>> index
>>>> 5aa846c8479b20651291d5bd2e316308310f826c..85a06eb9eacc410a565b80d56979eaa565515d0e 100644
>>>> --- a/MAINTAINERS
>>>> +++ b/MAINTAINERS
>>>> @@ -19891,6 +19891,7 @@ M:    Wenmeng Liu <wenmeng.liu@oss.qualcomm.com>
>>>>    L:    linux-media@vger.kernel.org
>>>>    S:    Maintained
>>>>    F:    Documentation/devicetree/bindings/media/i2c/ovti,og0va1b.yaml
>>>> +F:    drivers/media/i2c/og0va1b.c
>>>>    OMNIVISION OG0VE1B SENSOR DRIVER
>>>>    M:    Vladimir Zapolskiy <vladimir.zapolskiy@linaro.org>
>>>> diff --git a/drivers/media/i2c/Kconfig b/drivers/media/i2c/Kconfig
>>>> index
>>>> 5d173e0ecf424f2f204f8d426be818e44357f8e4..56680772f5f47b4629c4e17f5a5feba08b1d94fc 100644
>>>> --- a/drivers/media/i2c/Kconfig
>>>> +++ b/drivers/media/i2c/Kconfig
>>>> @@ -363,6 +363,16 @@ config VIDEO_OG01A1B
>>>>          To compile this driver as a module, choose M here: the
>>>>          module will be called og01a1b.
>>>> +config VIDEO_OG0VA1B
>>>> +    tristate "OmniVision OG0VA1B sensor support"
>>>> +    select V4L2_CCI_I2C
>>>> +    help
>>>> +      This is a Video4Linux2 sensor driver for the OmniVision
>>>> +      OG0VA1B camera.
>>>> +
>>>> +      To compile this driver as a module, choose M here: the
>>>> +      module will be called og0va1b.
>>>> +
>>>>    config VIDEO_OG0VE1B
>>>>        tristate "OmniVision OG0VE1B sensor support"
>>>>        select V4L2_CCI_I2C
>>>> diff --git a/drivers/media/i2c/Makefile b/drivers/media/i2c/Makefile
>>>> index
>>>> e45359efe0e41e13e3c0869e5ead7d6cf4aca3a7..c60851c7fe07e3bdc511c5f482525ba7a044f48e 100644
>>>> --- a/drivers/media/i2c/Makefile
>>>> +++ b/drivers/media/i2c/Makefile
>>>> @@ -83,6 +83,7 @@ obj-$(CONFIG_VIDEO_MT9V011) += mt9v011.o
>>>>    obj-$(CONFIG_VIDEO_MT9V032) += mt9v032.o
>>>>    obj-$(CONFIG_VIDEO_MT9V111) += mt9v111.o
>>>>    obj-$(CONFIG_VIDEO_OG01A1B) += og01a1b.o
>>>> +obj-$(CONFIG_VIDEO_OG0VA1B) += og0va1b.o
>>>>    obj-$(CONFIG_VIDEO_OG0VE1B) += og0ve1b.o
>>>>    obj-$(CONFIG_VIDEO_OS05B10) += os05b10.o
>>>>    obj-$(CONFIG_VIDEO_OV01A10) += ov01a10.o
>>>> diff --git a/drivers/media/i2c/og0va1b.c b/drivers/media/i2c/og0va1b.c
>>>> new file mode 100644
>>>> index
>>>> 0000000000000000000000000000000000000000..f0505b7ba7f329ad57ffafa8f90a24204f002d3c
>>>> --- /dev/null
>>>> +++ b/drivers/media/i2c/og0va1b.c
>>>> @@ -0,0 +1,867 @@
>>>> +// SPDX-License-Identifier: GPL-2.0
>>>> +/*
>>>> + * OmniVision OG0VA1B Camera Sensor Driver
>>>> + *
>>>> + * Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries
>>>> + */
>>>> +
>>>> +#include <linux/clk.h>
>>>> +#include <linux/delay.h>
>>>> +#include <linux/gpio/consumer.h>
>>>> +#include <linux/i2c.h>
>>>> +#include <linux/module.h>
>>>> +#include <linux/of.h>
>>>> +#include <linux/pm_runtime.h>
>>>> +#include <linux/regulator/consumer.h>
>>>> +
>>>> +#include <media/v4l2-cci.h>
>>>> +#include <media/v4l2-ctrls.h>
>>>> +#include <media/v4l2-device.h>
>>>> +#include <media/v4l2-fwnode.h>
>>>> +#include <media/v4l2-subdev.h>
>>>> +
>>>> +#define OG0VA1B_REG_CHIP_ID        CCI_REG16(0x300a)
>>>> +#define OG0VA1B_CHIP_ID            0xC756
>>>
>>> This is the same chip id as of the OG0VE1B sensor device.
>>>
>>> What's the difference between these two sensors, and do you find it
>>> possible
>>> to add support of OG0VA1B sensor/modes into OG0VE1B sensor driver? Or is
>>> it just the same device?
>>>
>>> Hardware specifics described in dt changes also does not show a difference
>>> in comparison to ovti,og0ve1b.yaml.
>>>
>>
>>
>> Hi Vladimir,
>>
>>
>> Both OG0VE1B and OG0VA1B belong to the same OmniVision VGA monochrome
>> sensor family. They share the same resolution, power rails, reset GPIO
>> behavior and power management framework.
>>
>> But they are different:
>> OG0VE1B:  8-bit RAW, lower FPS
>> OG0VA1B: 10-bit RAW, higher FPS
>> and some registers are not same.
> 
> Can you identify which registers are not the same?
> 
For example, regarding the CHIP_ID,
OG0VE1B is 0xc75645, while OG0VA1B is 0xc75641, including the test 
pattern registers.
Since I do not have the specification for OG0VE1B, I cannot perform a 
detailed comparison. However, based on the current observations, OG0VA1B 
can be integrated into the OG0VE1B driver.

> Mapping between 8bit and 10 bit or different frame rates could easily be
> managed in a single driver with exposing different capabilities based on
> the variant.
> 
> We should really work towards reducing the huge duplication that is
> happening with copy/paste sensor drivers.

Indeed, will do so.

Thanks,
Wenmeng



  reply	other threads:[~2026-06-18 14:00 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-18 10:37 [PATCH 0/2] media: i2c: Add OmniVision OG0VA1B camera sensor driver Wenmeng Liu
2026-06-18 10:37 ` [PATCH 1/2] dt-bindings: media: i2c: Add OmniVision OG0VA1B Wenmeng Liu
2026-06-18 10:55   ` Vladimir Zapolskiy
2026-06-18 10:37 ` [PATCH 2/2] media: i2c: og0va1b: Add OmniVision OG0VA1B camera sensor Wenmeng Liu
2026-06-18 10:50   ` Vladimir Zapolskiy
2026-06-18 12:36     ` Wenmeng Liu
2026-06-18 13:04       ` Vladimir Zapolskiy
2026-06-18 13:15       ` Kieran Bingham
2026-06-18 14:00         ` Wenmeng Liu [this message]
2026-06-18 17:27   ` Uwe Kleine-König

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7c25faea-7e86-43d5-9aff-2bf6f609e311@oss.qualcomm.com \
    --to=wenmeng.liu@oss.qualcomm.com \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=kieran.bingham@ideasonboard.com \
    --cc=krzk+dt@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=mchehab@kernel.org \
    --cc=robh@kernel.org \
    --cc=sakari.ailus@linux.intel.com \
    --cc=vladimir.zapolskiy@linaro.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®