[PATCH v1] media: ov13858: Check for possible null pointer

2018-10-26 Thread Chiranjeevi Rapolu
Check for possible null pointer to avoid crash. Signed-off-by: Chiranjeevi Rapolu --- drivers/media/i2c/ov13858.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/media/i2c/ov13858.c b/drivers/media/i2c/ov13858.c index c8bbc1f..45bb872 100644 --- a/drivers/media

[PATCH v1] media: ov13858: Update to SPDX identifier

2018-02-21 Thread Chiranjeevi Rapolu
Replace GPL v2 license notice with SPDX license identifier. Signed-off-by: Chiranjeevi Rapolu <chiranjeevi.rap...@intel.com> --- drivers/media/i2c/ov13858.c | 15 ++- 1 file changed, 2 insertions(+), 13 deletions(-) diff --git a/drivers/media/i2c/ov13858.c b/drivers/med

[PATCH v1] media: ov5670: Update to SPDX identifier

2018-02-21 Thread Chiranjeevi Rapolu
Replace GPL v2 license notice with SPDX license identifier. Signed-off-by: Chiranjeevi Rapolu <chiranjeevi.rap...@intel.com> --- drivers/media/i2c/ov5670.c | 15 ++- 1 file changed, 2 insertions(+), 13 deletions(-) diff --git a/drivers/media/i2c/ov5670.c b/drivers/media/i2c/ov

[PATCH v1] media: ov13858: Avoid possible null first frame

2018-01-24 Thread Chiranjeevi Rapolu
Previously, the sensor, with default settings, was outputting SOF without data. This results in frame sync error on the receiver side. Now, configure the sensor to output SOF with MIPI data for all frames. This avoids possible null first frame on the bus. Signed-off-by: Chiranjeevi Rapolu

[PATCH v2] media: ov13858: Fix 4224x3136 video flickering at some vblanks

2017-09-18 Thread Chiranjeevi Rapolu
~30fps. Signed-off-by: Chiranjeevi Rapolu <chiranjeevi.rap...@intel.com> --- Changes in v2: - Include Tomasz clarifications in the commit message. drivers/media/i2c/ov13858.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/media/i2c/ov13858.c b/drive

[PATCH v3] media: ov13858: Calculate pixel-rate at runtime, use mode

2017-09-18 Thread Chiranjeevi Rapolu
Calculate pixel-rate at run time instead of compile time. Instead of using hardcoded pixels-per-line, extract it from current sensor mode. Signed-off-by: Chiranjeevi Rapolu <chiranjeevi.rap...@intel.com> --- Changes in v3: - Use LINK_FREQ_TO_PIXEL_RATE macro. - Fix inc

[PATCH v1] media: ov13858: Fix 4224x3136 video flickering at some vblanks

2017-09-13 Thread Chiranjeevi Rapolu
Previously, the sensor was outputting blank every other frame at 4224x3136 video when vblank was in the range [79, 86]. This resulted in video flickering. Omni Vision recommends us to use their settings for crop start/end for 4224x3136. Signed-off-by: Chiranjeevi Rapolu <chiranjeevi.

[PATCH v2] media: ov13858: Calculate pixel-rate at runtime, use mode

2017-09-06 Thread Chiranjeevi Rapolu
Calculate pixel-rate at run time instead of compile time. Instead of using hardcoded pixels-per-line, extract it from current sensor mode. Signed-off-by: Chiranjeevi Rapolu <chiranjeevi.rap...@intel.com> --- Changes in v2: - Removed pixel-rate from struct definition. - Used

[PATCH v1] media: ov5670: Fix not streaming issue after resume.

2017-09-01 Thread Chiranjeevi Rapolu
Previously, the sensor was not streaming after resume from suspend, i.e. on S0->S3->S0 transition. Due to this, camera app preview appeared as stuck. Now, handle streaming state correctly in case of suspend-resume. Signed-off-by: Chiranjeevi Rapolu <chiranjeevi.rap...@intel.com>

[PATCH v1] media: ov5670: Use recommended black level and output bias

2017-08-24 Thread Chiranjeevi Rapolu
dynamically, add these to existing mode register settings. Signed-off-by: Chiranjeevi Rapolu <chiranjeevi.rap...@intel.com> --- drivers/media/i2c/ov5670.c | 30 -- 1 file changed, 24 insertions(+), 6 deletions(-) diff --git a/drivers/media/i2c/ov5670.c b/drivers

[PATCH v1] media: ov13858: Limit vblank to permissible range

2017-08-17 Thread Chiranjeevi Rapolu
. Signed-off-by: Chiranjeevi Rapolu <chiranjeevi.rap...@intel.com> --- drivers/media/i2c/ov13858.c | 35 +++ 1 file changed, 23 insertions(+), 12 deletions(-) diff --git a/drivers/media/i2c/ov13858.c b/drivers/media/i2c/ov13858.c index 45c0e96..af7af0d

[PATCH v1] media: ov5670: Limit vblank to permissible range

2017-08-17 Thread Chiranjeevi Rapolu
. Signed-off-by: Chiranjeevi Rapolu <chiranjeevi.rap...@intel.com> --- drivers/media/i2c/ov5670.c | 40 ++-- 1 file changed, 26 insertions(+), 14 deletions(-) diff --git a/drivers/media/i2c/ov5670.c b/drivers/media/i2c/ov5670.c index 8d8e16c..ddb7009

[PATCH v2] media: ov5670: Fix incorrect frame timing reported to user

2017-08-09 Thread Chiranjeevi Rapolu
ock to pixels domain. Set HBLANK read-only because fixed PPL is used for all resolutions. And, use more accurate link-frequency 422.4MHz instead of rounding down to 420MHz. Signed-off-by: Chiranjeevi Rapolu <chiranjeevi.rap...@intel.com> --- Changes in v2: - Change subject to reflect fra

[PATCH v1] media: ov5670: Fix incorrect fps reported by user

2017-08-09 Thread Chiranjeevi Rapolu
ANK calculation. Now, change pixels-per-line domain from internal sensor clock to pixels domain. Set HBLANK read-only because fixed PPL is used for all resolutions. And, use more accurate link-frequency 422.4MHz instead of rounding down to 420MHz. Signed-off-by: Chiranjeevi Rapolu <chiranjeevi.rap...@int

[PATCH v2] media: ov13858: Correct link-frequency and pixel-rate

2017-07-29 Thread Chiranjeevi Rapolu
Previously both link-frequency and pixel-rate reported by the sensor was incorrect, resulting in incorrect FPS. Report link-frequency in Hz rather than link data rate in bps. Calculate pixel-rate from link-frequency. Signed-off-by: Chiranjeevi Rapolu <chiranjeevi.rap...@intel.com> --- C

[PATCH v1] media: ov13858: Increase digital gain granularity, range

2017-07-28 Thread Chiranjeevi Rapolu
Previously, possible digital gains were just 1x, 2x and 4x. These coarse gains were not sufficient in fine-tuning the image capture. Now, digital gain range is [0, 16x] with each step 1/1024, default 1x. This is achieved through OV13858 MWB R/G/B gain controls. Signed-off-by: Chiranjeevi Rapolu

[PATCH v1] media: ov13858: Correct link-frequency and pixel-rate

2017-07-28 Thread Chiranjeevi Rapolu
Previously both link-frequency and pixel-rate reported by the sensor was incorrect, resulting in incorrect FPS. Report link-frequency in Hz rather than link data rate in bps. Calculate pixel-rate from link-frequency. Signed-off-by: Chiranjeevi Rapolu <chiranjeevi.rap...@intel.com> --- d

[PATCH v1] media: ov13858: Fix initial expsoure max

2017-07-27 Thread Chiranjeevi Rapolu
Previously, initial exposure max was set incorrectly to (0x7fff - 8). Now, limit exposure max to current resolution (VTS - 8). Signed-off-by: Chiranjeevi Rapolu <chiranjeevi.rap...@intel.com> --- drivers/media/i2c/ov13858.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff

[PATCH v1] [media] ov13858 Set default fps as current fps

2017-07-27 Thread Chiranjeevi Rapolu
-by: Chiranjeevi Rapolu <chiranjeevi.rap...@intel.com> --- drivers/media/i2c/ov13858.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/media/i2c/ov13858.c b/drivers/media/i2c/ov13858.c index 86550d8..8e6c8f0 100644 --- a/drivers/media/i2c/ov13858.c +++ b/drivers/med

[PATCH v5 1/1] i2c: Add Omnivision OV5670 5M sensor support

2017-07-13 Thread Chiranjeevi Rapolu
Signed-off-by: Chiranjeevi Rapolu <chiranjeevi.rap...@intel.com> --- drivers/media/i2c/Kconfig | 12 + drivers/media/i2c/Makefile |1 + drivers/media/i2c/ov5670.c | 2587 3 files changed, 2600 insertions(+) create mode 100644 drivers/med

[PATCH v4 1/1] i2c: Add Omnivision OV5670 5M sensor support

2017-07-01 Thread chiranjeevi . rapolu
From: Chiranjeevi Rapolu <chiranjeevi.rap...@intel.com> Provides single source pad with up to 2592x1944 pixels at 10-bit raw bayer format over MIPI CSI2 two lanes at 840Mbps/lane. The driver supports following features: - up to 30fps at 5M pixels - manual exposure - digital/analog gain - V

[PATCH v3 1/1] i2c: Add Omnivision OV5670 5M sensor support

2017-06-13 Thread chiranjeevi . rapolu
From: Chiranjeevi Rapolu <chiranjeevi.rap...@intel.com> Provides single source pad with up to 2592x1944 pixels at 10-bit raw bayer format over MIPI CSI2 two lanes at 640Mbps/lane. The driver supports following features: - up to 30fps at 5M pixels - manual exposure - digital/analog gain - V

[PATCH v2 1/1] [media] i2c: Add Omnivision OV5670 5M sensor support

2017-05-25 Thread chiranjeevi . rapolu
From: Chiranjeevi Rapolu <chiranjeevi.rap...@intel.com> Provides single source pad with up to 2592x1944 pixels at 10-bit raw bayer format over MIPI CSI2 two lanes at 640Mbps/lane. The driver supports following features: - up to 30fps at 5M pixels - manual exposure/analog gain - media cont

[PATCH] ov5670: Add Omnivision OV5670 5M sensor support

2017-05-03 Thread Chiranjeevi Rapolu
Provides single source pad with up to 2576x1936 pixels at 10-bit raw bayer format over MIPI CSI2 two lanes at 640Mbps/lane. Supports up to 30fps at 5M pixels, up to 60fps at 1080p. Signed-off-by: Chiranjeevi Rapolu <chiranjeevi.rap...@intel.com> --- drivers/media/i2c/Kconfig | 11 + d