Commit b2598d9f authored by Mauro Carvalho Chehab's avatar Mauro Carvalho Chehab

media: atomisp: add a default case at __get_frame_info()

The switch() logic there misses a break and a default case.
That makes it more prone to problems as the code change.
Suggested-by: default avatarAndy Shevchenko <andy.shevchenko@gmail.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab+huawei@kernel.org>
parent 5814f32f
...@@ -2691,9 +2691,11 @@ static int __get_frame_info(struct atomisp_sub_device *asd, ...@@ -2691,9 +2691,11 @@ static int __get_frame_info(struct atomisp_sub_device *asd,
*info = p_info.output_info[1]; *info = p_info.output_info[1];
dev_dbg(isp->dev, "getting second main frame info.\n"); dev_dbg(isp->dev, "getting second main frame info.\n");
break; break;
default:
case ATOMISP_CSS_RAW_FRAME: case ATOMISP_CSS_RAW_FRAME:
*info = p_info.raw_output_info; *info = p_info.raw_output_info;
dev_dbg(isp->dev, "getting raw frame info.\n"); dev_dbg(isp->dev, "getting raw frame info.\n");
break;
} }
dev_dbg(isp->dev, "get frame info: w=%d, h=%d, num_invalid_frames %d.\n", dev_dbg(isp->dev, "get frame info: w=%d, h=%d, num_invalid_frames %d.\n",
info->res.width, info->res.height, p_info.num_invalid_frames); info->res.width, info->res.height, p_info.num_invalid_frames);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment