Camera: OOT: misc code fixes for drivers

1. Sensor deep power down and mclk enable
   and disable code.
2. Assign pads member in v4l2_subdev_state
   struct passed to v4l2_subdev_call.
3. emc and iso.emc clock are not available
   in K5.15. Disable clock get function.

Bug 3898807

Change-Id: If9e24ccd837af00df250571e6fc4c907886faf93
Signed-off-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2835934
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
This commit is contained in:
Ankur Pawar
2023-01-02 07:18:24 +00:00
committed by mobile promotions
parent 8b04ed92cb
commit 5957f061b3
3 changed files with 27 additions and 23 deletions

View File

@@ -2,7 +2,7 @@
/*
* camera_common.c - utilities for tegra camera driver
*
* Copyright (c) 2015-2022, NVIDIA CORPORATION. All rights reserved.
* Copyright (c) 2015-2023, NVIDIA CORPORATION. All rights reserved.
*/
#include <linux/types.h>
#include <media/tegra-v4l2-camera.h>
@@ -923,7 +923,18 @@ int camera_common_s_power(struct v4l2_subdev *sd, int on)
dev_err(s_data->dev, "%s: error power on\n", __func__);
return err;
}
err = camera_common_mclk_enable(s_data);
if (err) {
dev_err(s_data->dev, "%s: failed to enable mclk\n",
__func__);
call_s_op(s_data, power_off);
return err;
}
camera_common_dpd_disable(s_data);
} else {
camera_common_dpd_enable(s_data);
camera_common_mclk_disable(s_data);
call_s_op(s_data, power_off);
}