diff options
author | Luca Ceresoli <luca@lucaceresoli.net> | 2018-06-11 07:35:33 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab+samsung@kernel.org> | 2018-07-04 07:25:08 -0400 |
commit | 96a2c731a4e661470d3a0a39d5efc792a22c7bba (patch) | |
tree | f0f44008004a0b25e7e78d86c4fb82a9eab46df5 /drivers/media/platform/qcom | |
parent | 438ac1fd5e1e132782795ba474b97fffbc79bbd5 (diff) | |
download | linux-96a2c731a4e661470d3a0a39d5efc792a22c7bba.tar.gz |
media: imx274: consolidate per-mode data in imx274_frmfmt
Data about the implemented readout modes is partially stored in
imx274_formats[], the rest is scattered in several arrays. The latter
are then accessed using the mode index, e.g.:
min_frame_len[priv->mode_index]
Consolidate all these data in imx274_formats[], and store a pointer to
the selected mode (i.e. imx274_formats[priv->mode_index]) in the main
device struct. This way code to use these data becomes more readable,
e.g.:
priv->mode->min_frame_len
This removes lots of scaffolding code and keeps data about each mode
in a unique place.
Also remove a parameter to imx274_mode_regs() that is now unused.
While this adds the mode pointer to the device struct, it does not
remove the mode_index from it because mode_index is still used in two
dev_dbg() calls. This will be handled in a follow-up commit.
Signed-off-by: Luca Ceresoli <luca@lucaceresoli.net>
Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
Diffstat (limited to 'drivers/media/platform/qcom')
0 files changed, 0 insertions, 0 deletions