msm: camera: Enable camera sub devices
- Enabled driver to support flash eeprom actuator. - Added necessary changes to request irq and free irq. - Added necessary to fix the compilation for flash driver. Change-Id: I0b97e234d9fc1809d745713724816bc55816cdc2 Signed-off-by: Gurram Pravalika <gpravali@codeaurora.org>
This commit is contained in:
committed by
Gerrit - the friendly Code Review server
parent
5edc4e08f3
commit
a89210c1a4
@@ -732,8 +732,9 @@ int msm_camera_register_irq(struct platform_device *pdev,
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
rc = devm_request_irq(&pdev->dev, irq->start, handler,
|
||||
rc = request_threaded_irq(irq->start, handler, NULL,
|
||||
irqflags, irq_name, dev_id);
|
||||
|
||||
if (rc < 0) {
|
||||
pr_err("irq request fail\n");
|
||||
rc = -EINVAL;
|
||||
@@ -797,6 +798,7 @@ int msm_camera_unregister_irq(struct platform_device *pdev,
|
||||
}
|
||||
|
||||
CDBG("Un Registering irq for [resource - %pK]\n", irq);
|
||||
free_irq(irq->start, dev_id);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -5,7 +5,6 @@ ccflags-y += -Idrivers/media/platform/msm/camera_v2/msm_vb2
|
||||
ccflags-y += -Idrivers/media/platform/msm/camera_v2/camera
|
||||
ccflags-y += -Idrivers/media/platform/msm/camera_v2/sensor/io
|
||||
ccflags-y += -Idrivers/media/platform/msm/camera_v2/sensor/cci
|
||||
#obj-$(CONFIG_MSMB_CAMERA) += cci/ io/ csiphy/ csid/ actuator/ eeprom/ ois/ flash/ ir_led/ ir_cut/
|
||||
obj-$(CONFIG_MSMB_CAMERA) += cci/ io/ csiphy/ csid/
|
||||
#bj-$(CONFIG_MSMB_CAMERA) += laser_led/
|
||||
obj-$(CONFIG_MSMB_CAMERA) += cci/ io/ csiphy/ csid/ actuator/ eeprom/ ois/ flash/ ir_led/ ir_cut/
|
||||
obj-$(CONFIG_MSMB_CAMERA) += laser_led/
|
||||
obj-$(CONFIG_MSM_CAMERA_SENSOR) += msm_sensor_init.o msm_sensor_driver.o msm_sensor.o
|
||||
|
||||
@@ -328,7 +328,7 @@ static int32_t msm_flash_i2c_init(
|
||||
flash_init_info->settings, sizeof(
|
||||
struct msm_camera_i2c_reg_setting_array));
|
||||
if (IS_ERR(settings)) {
|
||||
ret = PTR_ERR(settings);
|
||||
return PTR_ERR(settings);
|
||||
rc = msm_flash_i2c_write_table(flash_ctrl, settings);
|
||||
kfree(settings);
|
||||
|
||||
@@ -337,12 +337,12 @@ static int32_t msm_flash_i2c_init(
|
||||
__func__, __LINE__, rc);
|
||||
}
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
|
||||
msm_flash_i2c_init_fail:
|
||||
return rc;
|
||||
}
|
||||
|
||||
static int32_t msm_flash_gpio_init(
|
||||
struct msm_flash_ctrl_t *flash_ctrl,
|
||||
struct msm_flash_cfg_data_t *flash_data)
|
||||
@@ -426,8 +426,8 @@ static int32_t msm_flash_i2c_write_setting_array(
|
||||
settings = memdup_user((void __user *)
|
||||
flash_data->cfg.settings, sizeof(
|
||||
struct msm_camera_i2c_reg_setting_array));
|
||||
if (IS_ERR(settings)) {
|
||||
ret = PTR_ERR(settings);
|
||||
if (IS_ERR(settings))
|
||||
return PTR_ERR(settings);
|
||||
rc = msm_flash_i2c_write_table(flash_ctrl, settings);
|
||||
kfree(settings);
|
||||
|
||||
|
||||
@@ -903,7 +903,7 @@ static long msm_ois_subdev_do_ioctl(
|
||||
settings.reg_setting = memdup_user((void __user *)
|
||||
compat_ptr(settings32.reg_setting),
|
||||
sizeof(struct msm_camera_i2c_seq_reg_array));
|
||||
if (IS_ERR(settings.reg_setting)) {
|
||||
if (IS_ERR(settings.reg_setting))
|
||||
return PTR_ERR(settings.reg_setting);
|
||||
ois_data.cfg.settings = &settings;
|
||||
parg = &ois_data;
|
||||
|
||||
Reference in New Issue
Block a user