Commit Graph

45 Commits

Author SHA1 Message Date
Praveen AC
e3f09d3989 nv_hawk_owl:Fix 3rd Hawk streaming fail.
Enable video pipe line for Hawk3 i.e video pipe 4 & 5.

Bug 4564878

Change-Id: Ib39a5afc332722e5e8476f689a243f7dc71a6a2c
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3099879
Reviewed-by: Narendra Kondapalli <nkondapalli@nvidia.com>
Reviewed-by: Ankur Pawar <ankurp@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
Tested-by: Praveen AC <pac@nvidia.com>
Reviewed-by: Praveen AC <pac@nvidia.com>
Reviewed-by: Bibek Basu <bbasu@nvidia.com>
2024-03-20 04:58:28 -07:00
Shubham Chandra
17e0946ce0 nvidia-oot: imx318: fix probe failure
V4l2 ctrl values are 0 during init time s_ctrl call
from v4l2. Since framerate val parameter is 0, when
set_framerate_ex is called from set_ctrl_ex during
initialization for probing of imx318 sensor, this
results in invalid error and probe failure for imx318.

Assign framerate 'val' to a value from imx318 sensor
device-tree properties within the given range to avoid
probe failure due to this.

Bug 3692128

Change-Id: Ib5f50e64f99c8443bf604066eda315dc96fbde03
Signed-off-by: Shubham Chandra <shubhamc@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3089350
Reviewed-by: svcacv <svcacv@nvidia.com>
Reviewed-by: Praveen AC <pac@nvidia.com>
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2024-03-05 07:09:09 -08:00
Ankur Pawar
4d4e685699 media:i2c: fix imx477 partial frame output
Fix imx477 partial frame issue and wrong frame-length
/exposure time calculations.
Uses hardcoded sensor internal clock frequency
instead of clock values from sensor device tree.

Adding clock frequency to device tree also require
deskew_initial_enable = "true". Setting deskew in
device tree is causing kernel panic in function
nvcsi_deskew_setup(). For unblocking the IMX477
use case, set hardcoded clock in driver for now.

Bug 4384649

Change-Id: Iedb02673c6f4da140aee22adc991805b6aa1eb7e
Signed-off-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3086503
Reviewed-by: Praveen AC <pac@nvidia.com>
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2024-03-04 01:24:48 -08:00
Ankur Pawar
7096cb09a5 media:i2c: fix ar1335 control command
When ar1335_common.c was ported to K5.15 it was refactored
based on the review comments. During that process index
in mcu_send_ctrl_cmd() was set to 0xFFFF which was causing
issue in setting sensor format. Pass the index from the
caller of mcu_send_ctrl_cmd().

Bug 4389285

Change-Id: Ic84a8de58051fe947f0f4d6597d1a55bc29ef9e6
Signed-off-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3024535
Reviewed-by: Praveen AC <pac@nvidia.com>
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2024-02-26 05:24:23 -08:00
Praveen AC
518ae94bb4 media: i2c: update ar0234 EEPROM data structure
- Integrate calibration data structure from
  Leopard Imaging hawk driver into NVIDIA
  hawk driver
- Rearrange EEPROM calibration data structure to
  maintain backward compatibility with HAWK, OWL
  modules with EEPROMs programmed using earlier
  calibration data structure
- Use separate structures for tracking imu noise
  parameters and place it after the module
  serial number.
- Change module serial number length used for
  reading the serial number from EEPROM data

L4T-4649

Change-Id: I17613905e63fef3fc690dca42a0a10bd1f4fc24d
Signed-off-by: Praveen AC <pac@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3072846
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
2024-02-09 01:09:27 -08:00
Praveen AC
6642085af9 i2c:nv_hawk_owl: Reduced sensor stream on time.
Following changes are done to reduce 400ms to 200ms:
1> I2c address trans during every power_on is moved to probe time.
   Since with virtual-i2c mux IMUs are handled and hence we don't need to
   do i2c address trans every time. So once during probe time is enough,
   that reduces ~120ms.
2> Reduced sleeping time during start stream call to 20ms, Which reduced
   ~100ms.

Bug 4180672

Change-Id: I027148f64b892d95e5432394f90bf171156ef9c0
Signed-off-by: Praveen AC <pac@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3072821
Reviewed-by: svcacv <svcacv@nvidia.com>
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
Reviewed-by: Ankur Pawar <ankurp@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2024-02-09 01:09:17 -08:00
Praveen AC
e31d73fa20 media: i2c: ar0234: Fix dual hawk corruption
- Fixes the frame corruption issue encountered
  when simultaneously streaming from two
  hawks via E3653 GMSL2 board
- Route each serializer output to a different
  deserializer output CSI port instead of
  routing video data from both serializers
  to the same deserializer output port
- Route data through two virtual channels for
  each of the two output ports instead of four
  virtual channels all through a single output
  port
- Fix serdes programming comments

Bug 4032165
Bug 3753423
JEC-286

Change-Id: I7b4e929e9f5330cc6eb0aa72646ce429a713df7a
Signed-off-by: Praveen AC <pac@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3072829
Reviewed-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-by: Anubhav Rai <arai@nvidia.com>
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2024-02-08 22:54:15 -08:00
Praveen AC
d7f14a85db t23x:P3762: Fix failed to read 2nd Hawk EEPROM serial number.
Changed EEPROM address to 0x15 for 2nd Hawks EEPROM
to avoid fail to read serial number.

Bug 4244937

Change-Id: Ia920ec6464b5bc374289728395da2bceb3f44d39
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3066257
Reviewed-by: Praveen AC <pac@nvidia.com>
Reviewed-by: Anubhav Rai <arai@nvidia.com>
Reviewed-by: Bibek Basu <bbasu@nvidia.com>
Tested-by: Praveen AC <pac@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2024-02-01 22:39:36 -08:00
Anubhav Rai
1b6db0ce3c camera: lt6911uxc update with Shadow EDID
Update the Lontium driver to flash shadow EDID
to lt6911uxc chip. This will ensure that the requested
resolution through the application is flashed to the
chip and the source is forced to select the
requested resolution only.

bug 4266018
bug 4301203
bug 4168489
Signed-off-by: Anubhav Rai <arai@nvidia.com>

Change-Id: I945a9658b52c82956535f3710312d317c0098be7
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3007702
(cherry picked from commit c3ddb23392)
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3015613
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
2024-01-23 19:09:34 -08:00
Laxman Dewangan
5b4a093e24 i2c: Use conftest to find return type of .remove of i2c_driver struct
Use conftest to determine the return type of .remove() of
struct i2c_driver is int or void type instead of kernel version.

The return type got changed with commmit ed5c2f5fd10d ("i2c:
Make remove callback return void")

Bug 4387902

Change-Id: Id64466613156e0efaf6cce7492d70cab1c1d1af7
Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3036799
(cherry picked from commit 1eab65044c)
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3053705
Tested-by: Jonathan Hunter <jonathanh@nvidia.com>
Reviewed-by: Jonathan Hunter <jonathanh@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2024-01-16 06:39:23 -08:00
Laxman Dewangan
14abda2794 i2c: Use conftest to find if i2c driver probe has i2c_device_i2d arg
Determine if probe of struct i2c_driver has i2c_device_id argument
or not.

This argument get removed from commit 03c835f498b5 ("i2c: Switch
.probe() to not take an id parameter") form Linux 6.3.

Bug 4346767

Change-Id: Ife73b29946246fce5bfcedcabe15992432d86348
Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3030809
(cherry picked from commit 2884c4b380)
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3054211
Tested-by: Jonathan Hunter <jonathanh@nvidia.com>
Reviewed-by: Jonathan Hunter <jonathanh@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2024-01-16 06:39:18 -08:00
Jon Hunter
e3fc979712 camera: Fix build when CONFIG_MEDIA_SUPPORT is not enabled
Some camera drivers are dependent upon CONFIG_MEDIA_SUPPORT being
enabled in the kernel and if it is not enabled, building these drivers
fail. Fix this by only building the camera drivers dependent upon
CONFIG_MEDIA_SUPPORT when this option is actually enabled.

Bug 4449072

Change-Id: I3637b5763667fbc9965bbeaf126115010e711c7e
Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3050559
(cherry picked from commit 9de3e799ae)
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3053101
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2024-01-15 23:54:55 -08:00
Jon Hunter
f7d42ed1c4 media: i2c: Fix build for GCC 6/7
Building nv_ar0234 and nv_hawk_owl sensor drivers with GCC 6/7 fails
with the following errors ...

 drivers/media/i2c/nv_ar0234.c:797:66: error: initialiser element is not
 constant
 .compound_ctrl_size = {sizeof(struct NvCamSyncSensorCalibData),
                        alternating_exposure_cfg_size},
                        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~

 drivers/media/i2c/nv_hawk_owl.c:883:59: error: initialiser element is
 not constant
 .compound_ctrl_size = {sizeof(NvCamSyncSensorCalibData),
                        alternating_exposure_cfg_size},
                        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~

These older versions of GCC are not able to reconcile the size from the
variable 'alternating_exposure_cfg_size' even though it is defined as
const. Given that the variable 'alternating_exposure_cfg_size' is only
used here, fix this by removing this variable and directly defining the
size in the declaration of the 'compound_ctrl_size' parameter.

Note that the minimum GCC compiler currently supported by the Linux
kernel is v5.1.

Bug 4448563

Change-Id: I4d3ac6eeb961a944901e73a1d92e753cae44220c
Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3050272
(cherry picked from commit 8b3ebff940)
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3051959
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2024-01-14 15:24:13 -08:00
Jon Hunter
069d6bb3eb drivers: Enable -Wmissing-prototypes
The compiler option -Wmissing-prototypes is being enabled globally in
the upstream Linux kernel and this causes build failures for various
drivers. The build failures occur because either the driver is missing
an include file which has the prototype or because the function is not
declared statically when it should be (ie. there are no external users).

Fix the various build failures and enable -Wmissing-prototypes to
prevent any new instances from occurring. Note that the only driver that
is not fixed at the moment is rtl8822ce due to large number of failures
and so build this with '-Wno-missing-prototypes' for now, which is not
different to how it was being compiled prior to this change.

Bug 4404965

Change-Id: Ie5572d23659e0346fa035d645d9043b0a6da5fdc
Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3027488
(cherry picked from commit d5391a25ab)
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3034644
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-12-18 09:11:10 -08:00
Shashank Kumar
c56189df5d drivers: media: add alternating exposure support
- update ar0234 driver to support ar0234 sensor
  hardware provided support for capturing frames
  using alternating exposure time and analog gain
  settings through automatic context switching
- added new v4l2 control having control id
  TEGRA_CAMERA_CID_ALTERNATING_EXPOSURE for
  configuring alternating exposure settings
- other changes to support aforementioned changes

Bug 4064517
Jira L4T-4501

Change-Id: Id1d3d745345836436b16da1fd00cc97f2e3b5553
Signed-off-by: Shashank Kumar <shaskumar@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2881141
(cherry picked from commit e973475525c9a7a99552282316e06126b8fff625)
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2987067
Reviewed-by: Anubhav Rai <arai@nvidia.com>
Reviewed-by: Bibek Basu <bbasu@nvidia.com>
Tested-by: Anubhav Rai <arai@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-11-04 09:59:43 -07:00
Kartik Rajput
e0558096ef oot: drivers: Replace gpio_cansleep() with gpiod_cansleep()
Upstream commit "7d0b80647f73"

[gpiolib: remove unused gpio_cansleep()]

Removed gpio_cansleep() API as there are no upstream users.

Replace the usage of gpio_cansleep() with gpiod_cansleep(). This is also
backwards compatible with older Kernels.

Bug 4276500

Change-Id: I37230d4371298d724e2311c803409108e93a4fed
Signed-off-by: Kartik Rajput <kkartik@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2978834
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
2023-09-14 20:45:05 -07:00
Jon Hunter
79e8e9cf3a media: Allow drivers to be built without V4L2
When building the NVIDIA out-of-tree drivers against 3rd party Linux
kernels where V4L2 support is not be enabled by default, the camera
drivers fail to build. Although this is expected, it is preferred that
the driver can still be built but then fail when loaded. Update the
camera drivers to guard around the V4L2 functions so that the drivers
can still be built but will return an error where needed.

Bug 4119327

Change-Id: I3a1115e5f0451153831c396244c01d7525cb51a1
Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2979254
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
2023-09-14 13:32:09 -07:00
Ankur Pawar
f4b8e44a5e media: i2c: camera cert-c and coverity fixes
Cert-C fixes in camera ar1335, imx219 and imx477 driver.

Cert-C
CID:566165
CID:566166
CID:566168
CID:566169
CID:566170
CID:566171
CID:683423
CID:566021

Coverity
CID:10179834

Bug 3959323

Change-Id: Id68deab8051206b6eae3da917d83c32365186fc5
Signed-off-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2939548
Reviewed-by: Praveen AC <pac@nvidia.com>
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-09-13 22:21:06 -07:00
Ankur Pawar
8c434bce54 media: i2c: fix imx185 sensor driver
Don't set the err value when setting parent clock.
Only print the error.

Bug 4191790

Change-Id: Ibab5c8bac08ea1451474ebd43cf9ff0f8200d8f1
Signed-off-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2965648
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-by: Praveen AC <pac@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-09-04 08:13:04 -07:00
Praveen AC
f62619388d t23x:Add virtual i2c mux support & enable IMU.
This change consists of following changes:
1> Add Virtual i2c-mux driver support for P3762.
2> Ser/Dser reg programming to map 1st Hawk's respective MFP's.
   Accel (MFP0) Ser --> Deser (MFP5)
   Gyro (MFP3) Ser --> Deser (MFP7)
3> Disable IMU's for 2nd,3rd & 4th Hawk.
4> Code cleanup.

Bug 4146784

Change-Id: I3f69bd57b1368451d8e2db06366a57b06b5ff0f4
Signed-off-by: Praveen AC <pac@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2971156
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-by: Ankur Pawar <ankurp@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-09-01 12:52:13 -07:00
Praveen AC
8ad7be0833 nv_hawk_owl:Enable external/internal Fsync.
Following support is added:
1.Add external Fsync support for HAWK & OWL.
2.Made Internal Fsync as default mode.
3.External Fsync is set only when TSC driver is called.
4.Swap i2c address translation for Hawks.
5.Add sync mechanism to protect i2c read/write.
6.Move sensor mode table during probe.
7.Code cleanup.

Bug 4125757
Bug 4143918
Bug 4151001
Bug 4161719

Change-Id: I15f1a41a838c883b11c14ed689adeb6d11aa2630
Signed-off-by: Praveen AC <pac@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2971153
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-by: Ankur Pawar <ankurp@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-09-01 12:52:07 -07:00
Praveen AC
35335a44b6 nv_hakw_owl: Add 4xHawk and 4xOwl support.
Following changes are made to add support 4xHawk & 4xOwl
on P3762 / P3783 GMSL board.
1) Driver changes to add i2c address translation.
2) Fix simultaneous streaming of Owl & Hawk.
3) Update ar0234 EEPROM Calibration.
4) Add support for 4xHawks.
5) Add internal Fsync support.
6) Add multiple link combinations for Hawk & Owl.
7) Enable EEPROM support for 4xHawk.

Bug 3620984
Bug 3562348
Bug 3866131
Bug 3817827
Bug 3932004
Bug 4071347
Bug 4095571
Bug 4096788

Change-Id: Ic6289f60258d446f259277fdd1d6d52e687dc74e
Signed-off-by: Praveen AC <pac@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2971143
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-by: Ankur Pawar <ankurp@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-09-01 12:51:51 -07:00
Anubhav Rai
b2b703f13d camera: fix rgba format for lt6911uxc
Fix RGB format streamed by the Lontium HDMI
CSI chip.
Fix Lontium HDMI driver for print. Probe is
info and not error flagged in kwarn scripts

bug 4168439

Change-Id: I7323fa5d6fd0b2c0cdefd9ea7248335b76726b94
Signed-off-by: Anubhav Rai <arai@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2927531
(cherry picked from commit d12b72d44508ff8c36d26dcbb50aa6a05e6a7bdf)
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2966743
Reviewed-by: Narendra Kondapalli <nkondapalli@nvidia.com>
Reviewed-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-by: Bibek Basu <bbasu@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-08-31 05:40:20 -07:00
Ankur Pawar
834dbf0781 i2c: camera: add updated ar1335 firmware
This new firmware provided by E-CON, starts ar1335 sensor
streaming at 100fps for mode0.

Bug 4111978

Change-Id: I2ba6aa3a2aec23c24319995224880e2fc24ca8ac
Signed-off-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2941192
Reviewed-by: Praveen AC <pac@nvidia.com>
Reviewed-by: Addarsh Srivastava <addarshs@nvidia.com>
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-08-22 02:13:17 -07:00
Ankur Pawar
804feada07 media: add imx477 sensor driver
Add imx477 camera sensor driver code,
mode tables and makefile changes.

Bug 3583587

Change-Id: Ib218e7d67f60f381a0e75edad71e9e5b35288dd3
Signed-off-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2864577
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
2023-08-20 07:04:10 -07:00
Ankur Pawar
ff01ad1318 media: add imx219 sensor driver
Add imx219 camera sensor driver code,
mode tables and makefile changes.

Bug 3583587

Change-Id: Ic7693de3cbdeeaecd7d9118a1e7819eaab5fdb3a
Signed-off-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2862964
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
2023-08-19 12:38:50 -07:00
Ankur Pawar
630aa8bba7 media: add pca9570.c driver
Enable pca9570 for IO Expander.
This is used by IMX185.

Bug 4191790

Change-Id: Ia0051718803cc1c898969739a0cb975c7432b647
Signed-off-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2889570
Reviewed-by: Anubhav Rai <arai@nvidia.com>
Reviewed-by: Frank Chen <frankc@nvidia.com>
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-08-18 10:44:06 -07:00
Ankur Pawar
0d04975aed media: i2c: Fix camera driver Coverity defects
Fix the below Coverity defects for lt6911uxc driver

Unchecked return value
CID: 10174208

Dereference null return value
CID: 10174210

Unchecked return value
CID: 10175851

Bug 3952896

Change-Id: I43132879e31f8a27db8fd41c717d598fb2c33490
Signed-off-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2915435
Reviewed-by: Praveen AC <pac@nvidia.com>
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com>
Reviewed-by: svc-mobile-cert <svc-mobile-cert@nvidia.com>
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-by: Frank Chen <frankc@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-07-21 01:24:49 -07:00
Ankur Pawar
8a40c778bf media: add ar1335 sensor driver
Add ar1335 camera sensor driver code,
firmware bin and makefile changes.

Bug 3583587
Bug 4111978

Change-Id: I340eb797233fb62ca9e107d0f774f1110e4c27fe
Signed-off-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2889070
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-by: Semi Malinen <smalinen@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-06-24 07:23:21 -07:00
Jon Hunter
af59e64885 media: lt6911uxc: Fix build for Linux v6.3
Upstream Linux commit 03c835f498b5 ("i2c: Switch .probe() to not
take an id parameter") removes the 'id' argument from the I2C probe
callback. Update the ov5693 driver, which defines an I2C probe callback
function, to fix building the driver for Linux v6.3.

Bug 4014315

Change-Id: I8c8954b7c1e1e322fb3f560f6348caac54e5e43d
Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2919423
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-06-14 22:56:36 -07:00
brucex
7069cb6650 nvidia-oot: disable nv_imx*
Disable nv_imx* modules on android as CONFIG_VIDEO_CAMERA is not enabled
in android config. Building these with clang result in build errors.

Bug 3974840

Signed-off-by: Bruce Xu <brucex@nvidia.com>
Change-Id: I420b1332143917a1ce169cbfba2a6fde1bcc40b6
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2865365
Tested-by: Ankita Garg <ankitag@nvidia.com>
Reviewed-by: Ankita Garg <ankitag@nvidia.com>
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-by: svcacv <svcacv@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-06-14 22:55:29 -07:00
Ankur Pawar
f93dd37a22 media: add lt6911uxc sensor driver
Add lt6911uxc HDMI->CSI sensor driver code,
This driver is copied K5.10 camera driver repo.

Bug 3583587
Bug 4111965

Change-Id: Ib01ac4c4d7d44073858009a8b41c42fa7083c020
Signed-off-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2793944
Reviewed-by: Praveen AC <pac@nvidia.com>
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-by: Shubham Chandra <shubhamc@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-05-30 07:33:01 -07:00
Ankur Pawar
3be100e555 media: i2c: Fix camera driver Coverity defects
Fix the below Coverity defects for IMX390 and
AR0234 sensor driver

Memory corruptions
CID: 10171410

Unchecked return value
CID: 10171825

Bug 3952896

Change-Id: Iff8a557ea3240a7aafd3e8e66fd6716dd28ac201
Signed-off-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2888806
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
2023-04-20 06:47:49 -07:00
Jon Hunter
3cadadc11c media: Fix build for Linux v6.3
Upstream Linux commit 03c835f498b5 ("i2c: Switch .probe() to not take an
id parameter") removes the 'id' argument from the I2C probe callback.
Update the various sensor drivers, which define an I2C probe callback
function, to fix building the drivers for Linux v6.3.

Bug 4014315
Bug 4075345

Change-Id: I2dc06188d1d19e086f108013c63439d9381d6c58
Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2889877
Reviewed-by: Rohit Khanna <rokhanna@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-04-19 10:58:01 -07:00
Ankur Pawar
2ceba857fd media: add imx390 sensor driver
Add imx390 camera sensor driver code,
mode tables and makefile changes.

Bug 3583587
Bug 4058151

Change-Id: I2b67d355d2684ccb6ab12881ac0d0d5b30447cc4
Signed-off-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2879227
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
2023-04-14 20:00:58 -07:00
Ankur Pawar
c9858e1282 media: add ar0234 sensor driver
Add ar0234 camera sensor driver code,
max96712 GMSL serializer code, mode tables
and makefile changes. These drivers are copied
from K5.10 camera driver repo. Changes include
svcacv warning fix and eeprom read status is
ignored due to bug 4064490.

Bug 3583587
Bug 4064490

Change-Id: I7ea0ecf959caccafd283c8db5fb7c3be912cf8bb
Signed-off-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2868422
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-04-14 15:45:38 -07:00
Ankur Pawar
c10d814337 media: i2c: Fix camera driver Coverity defects
Fix the below Coverity defects for IMX318 sensor driver

Copy paste error
CID: 10171759

Null return check
CID: 10171758

Unchecked return value
CID: 10171760

Bug 3952896

Change-Id: I9da2c14911dc119853fa5c96c9c4dcc9f1827c7e
Signed-off-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2885966
Reviewed-by: Chinmay Mahajan <cmahajan@nvidia.com>
Reviewed-by: Frank Chen <frankc@nvidia.com>
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com>
Reviewed-by: svc-mobile-cert <svc-mobile-cert@nvidia.com>
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-04-14 08:18:38 -07:00
Ankur Pawar
c5fa6476ee media: i2c: Fix camera driver Coverity defects
Fix the below Coverity defects for OV5693

Dereference null return
CID: 10171403

Unchecked return value
CID: 10171401

Bug 3952896

Change-Id: I657cb0ae9a2baf6c6cac7faa84debb754582534d
Signed-off-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2885152
Reviewed-by: Frank Chen <frankc@nvidia.com>
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com>
Reviewed-by: svc-mobile-cert <svc-mobile-cert@nvidia.com>
Reviewed-by: Michael Stevens (SW-TEGRA) <michaelst@nvidia.com>
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-04-13 12:24:36 -07:00
Ankur Pawar
2a2ce69017 media: add imx318 sensor driver
Add imx318 camera sensor driver code,
mode tables and makefile changes.

Bug 3583587

Change-Id: I9854909823b67856edc50c2364e519e853134178
Signed-off-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2870729
Reviewed-by: Semi Malinen <smalinen@nvidia.com>
Reviewed-by: Praveen AC <pac@nvidia.com>
Reviewed-by: Shubham Chandra <shubhamc@nvidia.com>
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-04-06 00:42:04 -07:00
Jon Hunter
b66cb3fc6e media: ov5693: Fix build for Linux v6.3
Upstream Linux commit 03c835f498b5 ("i2c: Switch .probe() to not take an
id parameter") removes the 'id' argument from the I2C probe callback.
Update the ov5693 driver, which defines an I2C probe callback function,
to fix building the driver for Linux v6.3.

Bug 4014315

Change-Id: Ic037da06b1999801fb62e6ccd39b92fe86b5402a
Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2875027
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-03-25 02:49:57 -07:00
Ankur Pawar
3713f4d7e0 media: add ov5693 sensor driver
Add ov5693 camera sensor driver code,
mode tables and makefile changes.

Bug 3583587

Change-Id: Ib692c0a68cb893583c41da0d58bda0be80dd74e3
Signed-off-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2864554
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-by: Semi Malinen <smalinen@nvidia.com>
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-03-21 09:39:44 -07:00
Jon Hunter
638edc1cc7 drivers: Fix build for Linux v6.3
Upstream Linux commit 03c835f498b5 ("i2c: Switch .probe() to not take an
id parameter") removes the 'id' argument from the I2C probe callback.
Update the drivers which define an I2C probe callback function to fix
building them for Linux v6.3.

Bug 4014315

Change-Id: I1c9924e3b1b6413d385f7d0daa9ef181dadfabe4
Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2870268
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
2023-03-18 16:19:11 -07:00
Frank Chen
7766a528ee media: i2c: Fix camera driver Coverity defects
Fix the below Coverity defects for IMX274 and IMX185 drivers.

Dereference null return value (NULL_RETURNS)
CID 10170833
CID 10171218

Unchecked return value (CHECKED_RETURN)
CID 10170834
CID 10171219
`
Bug 3952896

Change-Id: I9de754f6a06cd800c8567871f3ba8c8385f453d8
Signed-off-by: Frank Chen <frankc@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2868219
Reviewed-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com>
Reviewed-by: svc-mobile-cert <svc-mobile-cert@nvidia.com>
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-03-14 04:56:49 -07:00
Ankur Pawar
1697a2aab4 media: add imx185 sensor driver
Add imx185 camera sensor driver code,
mode tables and makefile changes.

Bug 3583587

Change-Id: I2990f7ce391c45be5caa0e7bea2ba46c35714fc9
Signed-off-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2863985
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
Reviewed-by: Semi Malinen <smalinen@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-03-06 00:38:18 -08:00
Ankur Pawar
4b7107449b media: add imx274 sensor driver
Add imx274 camera sensor driver code,
mode tables and makefile changes.

Bug 3583587

Change-Id: Ica3d468715a2bd1113ecdadef4f4d4d044e210ac
Signed-off-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2856283
Reviewed-by: Semi Malinen <smalinen@nvidia.com>
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-02-24 04:04:10 -08:00