drivers/video: Return zero if gamma curve isn't supported in initialize_scene_gamma
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
This commit is contained in:
parent
c8868b3745
commit
92e72f8624
@ -824,7 +824,7 @@ static int32_t initialize_scene_gamma(uint8_t **gamma)
|
|||||||
if ((g_video_sensor_ops->get_supported_value == NULL) ||
|
if ((g_video_sensor_ops->get_supported_value == NULL) ||
|
||||||
(g_video_sensor_ops->get_value == NULL))
|
(g_video_sensor_ops->get_value == NULL))
|
||||||
{
|
{
|
||||||
return -ENOTTY;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
ret = g_video_sensor_ops->get_supported_value
|
ret = g_video_sensor_ops->get_supported_value
|
||||||
@ -833,7 +833,7 @@ static int32_t initialize_scene_gamma(uint8_t **gamma)
|
|||||||
{
|
{
|
||||||
/* Unsupported parameter */
|
/* Unsupported parameter */
|
||||||
|
|
||||||
return -EINVAL;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
switch (sup_val.type)
|
switch (sup_val.type)
|
||||||
@ -844,7 +844,7 @@ static int32_t initialize_scene_gamma(uint8_t **gamma)
|
|||||||
{
|
{
|
||||||
/* Multiplication overflow */
|
/* Multiplication overflow */
|
||||||
|
|
||||||
return -EINVAL;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
break;
|
break;
|
||||||
@ -855,7 +855,7 @@ static int32_t initialize_scene_gamma(uint8_t **gamma)
|
|||||||
{
|
{
|
||||||
/* Multiplication overflow */
|
/* Multiplication overflow */
|
||||||
|
|
||||||
return -EINVAL;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
break;
|
break;
|
||||||
@ -866,7 +866,7 @@ static int32_t initialize_scene_gamma(uint8_t **gamma)
|
|||||||
{
|
{
|
||||||
/* Multiplication overflow */
|
/* Multiplication overflow */
|
||||||
|
|
||||||
return -EINVAL;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
break;
|
break;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user