ov13858.c (ef1c4a6fa91bbbe9b09f770d28eba31a9edf770c) ov13858.c (d2dc57b10ae2bd2e2e92ce26f2aaf24bcee17c53)
1/*
2 * Copyright (c) 2017 Intel Corporation.
3 *
4 * This program is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU General Public License version
6 * 2 as published by the Free Software Foundation.
7 *
8 * This program is distributed in the hope that it will be useful,

--- 1361 unchanged lines hidden (view full) ---

1370 s64 link_freq;
1371
1372 mutex_lock(&ov13858->mutex);
1373
1374 /* Only one raw bayer(GRBG) order is supported */
1375 if (fmt->format.code != MEDIA_BUS_FMT_SGRBG10_1X10)
1376 fmt->format.code = MEDIA_BUS_FMT_SGRBG10_1X10;
1377
1/*
2 * Copyright (c) 2017 Intel Corporation.
3 *
4 * This program is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU General Public License version
6 * 2 as published by the Free Software Foundation.
7 *
8 * This program is distributed in the hope that it will be useful,

--- 1361 unchanged lines hidden (view full) ---

1370 s64 link_freq;
1371
1372 mutex_lock(&ov13858->mutex);
1373
1374 /* Only one raw bayer(GRBG) order is supported */
1375 if (fmt->format.code != MEDIA_BUS_FMT_SGRBG10_1X10)
1376 fmt->format.code = MEDIA_BUS_FMT_SGRBG10_1X10;
1377
1378 mode = v4l2_find_nearest_size(supported_modes, width, height,
1378 mode = v4l2_find_nearest_size(supported_modes,
1379 ARRAY_SIZE(supported_modes),
1380 width, height,
1379 fmt->format.width, fmt->format.height);
1380 ov13858_update_pad_format(mode, fmt);
1381 if (fmt->which == V4L2_SUBDEV_FORMAT_TRY) {
1382 framefmt = v4l2_subdev_get_try_format(sd, cfg, fmt->pad);
1383 *framefmt = fmt->format;
1384 } else {
1385 ov13858->cur_mode = mode;
1386 __v4l2_ctrl_s_ctrl(ov13858->link_freq, mode->link_freq_index);

--- 437 unchanged lines hidden ---
1381 fmt->format.width, fmt->format.height);
1382 ov13858_update_pad_format(mode, fmt);
1383 if (fmt->which == V4L2_SUBDEV_FORMAT_TRY) {
1384 framefmt = v4l2_subdev_get_try_format(sd, cfg, fmt->pad);
1385 *framefmt = fmt->format;
1386 } else {
1387 ov13858->cur_mode = mode;
1388 __v4l2_ctrl_s_ctrl(ov13858->link_freq, mode->link_freq_index);

--- 437 unchanged lines hidden ---