aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorJeong-Seok Yang <jseok.yang@samsung.com>2010-10-20 01:26:50 +0900
committerArve Hjønnevåg <arve@android.com>2011-11-17 17:51:41 -0800
commit4a93acd6563de66a3875d3c2cea8cae98e70be70 (patch)
treefce00ee37b8f0fe8de1110a780f448a08c2db4fd /arch
parent9bdd02d81012e2aca70b6efa247d065284754894 (diff)
downloadkernel_samsung_crespo-4a93acd6563de66a3875d3c2cea8cae98e70be70.zip
kernel_samsung_crespo-4a93acd6563de66a3875d3c2cea8cae98e70be70.tar.gz
kernel_samsung_crespo-4a93acd6563de66a3875d3c2cea8cae98e70be70.tar.bz2
S5PC11X: Camera: Fix a voltage of CAM_ISP_HOST_2.8V
Additionally, Checking error routine is modified to check not only failure to get the regulator but also another error from regulator_get Change-Id: If61baf8d691a36dbf6b5a772170fefe2a1a588f5 Signed-off-by: Jeong-Seok Yang <jseok.yang@samsung.com>
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/mach-s5pv210/mach-herring.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/arch/arm/mach-s5pv210/mach-herring.c b/arch/arm/mach-s5pv210/mach-herring.c
index 866e120..53b6b62 100644
--- a/arch/arm/mach-s5pv210/mach-herring.c
+++ b/arch/arm/mach-s5pv210/mach-herring.c
@@ -576,9 +576,9 @@ static struct regulator_init_data herring_ldo14_data = {
static struct regulator_init_data herring_ldo15_data = {
.constraints = {
- .name = "CAM_ISP_HOST_3.0V",
- .min_uV = 3000000,
- .max_uV = 3000000,
+ .name = "CAM_ISP_HOST_2.8V",
+ .min_uV = 2800000,
+ .max_uV = 2800000,
.apply_uV = 1,
.valid_ops_mask = REGULATOR_CHANGE_STATUS,
.state_mem = {
@@ -1327,23 +1327,23 @@ static struct regulator *cam_af_regulator;
static bool s5k4ecgx_ldos_enabled;
static int s5k4ecgx_regulator_init(void)
{
- if (cam_isp_core_regulator == NULL) {
+ if (IS_ERR_OR_NULL(cam_isp_core_regulator)) {
cam_isp_core_regulator = regulator_get(NULL, "cam_isp_core");
- if (cam_isp_core_regulator == NULL) {
+ if (IS_ERR_OR_NULL(cam_isp_core_regulator)) {
pr_err("failed to get cam_isp_core regulator");
return -EINVAL;
}
}
- if (cam_isp_host_regulator == NULL) {
+ if (IS_ERR_OR_NULL(cam_isp_host_regulator)) {
cam_isp_host_regulator = regulator_get(NULL, "cam_isp_host");
- if (cam_isp_host_regulator == NULL) {
+ if (IS_ERR_OR_NULL(cam_isp_host_regulator)) {
pr_err("failed to get cam_isp_host regulator");
return -EINVAL;
}
}
- if (cam_af_regulator == NULL) {
+ if (IS_ERR_OR_NULL(cam_af_regulator)) {
cam_af_regulator = regulator_get(NULL, "cam_af");
- if (cam_af_regulator == NULL) {
+ if (IS_ERR_OR_NULL(cam_af_regulator)) {
pr_err("failed to get cam_af regulator");
return -EINVAL;
}
@@ -1384,9 +1384,9 @@ static int s5k4ecgx_ldo_en(bool en)
if (en == s5k4ecgx_ldos_enabled)
return 0;
- if ((cam_isp_core_regulator == NULL) ||
- (cam_isp_host_regulator == NULL) ||
- (cam_af_regulator == NULL)) {
+ if (IS_ERR_OR_NULL(cam_isp_core_regulator) ||
+ IS_ERR_OR_NULL(cam_isp_host_regulator) ||
+ IS_ERR_OR_NULL(cam_af_regulator)) {
pr_err("Camera regulators not initialized\n");
return -EINVAL;
}