.. | .. |
---|
2 | 2 | /* |
---|
3 | 3 | * techpoint v4l2 driver |
---|
4 | 4 | * |
---|
5 | | - * Copyright (C) 2022 Rockchip Electronics Co., Ltd. |
---|
| 5 | + * Copyright (C) 2023 Rockchip Electronics Co., Ltd. |
---|
6 | 6 | * |
---|
7 | 7 | */ |
---|
8 | 8 | |
---|
.. | .. |
---|
217 | 217 | { |
---|
218 | 218 | int ret; |
---|
219 | 219 | struct device *dev = &techpoint->client->dev; |
---|
220 | | - |
---|
221 | | - dev_dbg(dev, "%s\n", __func__); |
---|
222 | 220 | |
---|
223 | 221 | if (!IS_ERR_OR_NULL(techpoint->pins_default)) { |
---|
224 | 222 | ret = pinctrl_select_state(techpoint->pinctrl, |
---|
.. | .. |
---|
471 | 469 | struct v4l2_subdev_frame_size_enum *fse) |
---|
472 | 470 | { |
---|
473 | 471 | struct techpoint *techpoint = to_techpoint(sd); |
---|
474 | | - struct i2c_client *client = techpoint->client; |
---|
475 | | - |
---|
476 | | - dev_dbg(&client->dev, "%s:\n", __func__); |
---|
477 | 472 | |
---|
478 | 473 | if (fse->index >= techpoint->video_modes_num) |
---|
479 | 474 | return -EINVAL; |
---|
.. | .. |
---|
502 | 497 | } |
---|
503 | 498 | |
---|
504 | 499 | static int techpoint_g_mbus_config(struct v4l2_subdev *sd, |
---|
| 500 | + unsigned int pad_id, |
---|
505 | 501 | struct v4l2_mbus_config *cfg) |
---|
506 | 502 | { |
---|
507 | 503 | struct techpoint *techpoint = to_techpoint(sd); |
---|
.. | .. |
---|
512 | 508 | V4L2_MBUS_PCLK_SAMPLE_RISING | |
---|
513 | 509 | V4L2_MBUS_PCLK_SAMPLE_FALLING; |
---|
514 | 510 | } else if (techpoint->input_type == TECHPOINT_MIPI) { |
---|
515 | | - cfg->type = V4L2_MBUS_CSI2; |
---|
| 511 | + cfg->type = V4L2_MBUS_CSI2_DPHY; |
---|
516 | 512 | if (techpoint->data_lanes == 4) { |
---|
517 | 513 | cfg->flags = V4L2_MBUS_CSI2_4_LANE | V4L2_MBUS_CSI2_CHANNELS; |
---|
518 | 514 | } else if (techpoint->data_lanes == 2) { |
---|
.. | .. |
---|
827 | 823 | |
---|
828 | 824 | static const struct v4l2_subdev_video_ops techpoint_video_ops = { |
---|
829 | 825 | .s_stream = techpoint_stream, |
---|
830 | | - .g_mbus_config = techpoint_g_mbus_config, |
---|
831 | 826 | .g_frame_interval = techpoint_g_frame_interval, |
---|
832 | 827 | .querystd = techpoint_querystd, |
---|
833 | 828 | }; |
---|
.. | .. |
---|
837 | 832 | .enum_frame_size = techpoint_enum_frame_sizes, |
---|
838 | 833 | .get_fmt = techpoint_get_fmt, |
---|
839 | 834 | .set_fmt = techpoint_set_fmt, |
---|
| 835 | + .get_mbus_config = techpoint_g_mbus_config, |
---|
840 | 836 | }; |
---|
841 | 837 | |
---|
842 | 838 | static const struct v4l2_subdev_core_ops techpoint_core_ops = { |
---|
.. | .. |
---|
1210 | 1206 | struct device_node *np; |
---|
1211 | 1207 | int i, count; |
---|
1212 | 1208 | |
---|
1213 | | - count = of_count_phandle_with_args(node, "techpoint,audio-in-cascade-slaves", NULL); |
---|
| 1209 | + count = of_count_phandle_with_args(node, |
---|
| 1210 | + "techpoint,audio-in-cascade-slaves", |
---|
| 1211 | + NULL); |
---|
1214 | 1212 | if (count < 0 || count > MAX_SLAVES) |
---|
1215 | 1213 | return -EINVAL; |
---|
1216 | 1214 | |
---|
.. | .. |
---|
1516 | 1514 | |
---|
1517 | 1515 | MODULE_AUTHOR("Vicent Chi <vicent.chi@rock-chips.com>"); |
---|
1518 | 1516 | MODULE_DESCRIPTION("Techpoint decoder driver"); |
---|
1519 | | -MODULE_LICENSE("GPL v2"); |
---|
| 1517 | +MODULE_LICENSE("GPL"); |
---|