Re: [PATCH 1/4] media: i2c: imx415: Add get_mbus_config() pad operation support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Alexander,

Thanks for the patches. Next time, a cover letter that describes the
overall goal of the changes would be nice for a series like this.

On 2/19/25 10:46, Alexander Shiyan wrote:
> Allow the driver to report static media bus configuration using
> pad get_mbus_config() operation.
> 
> Signed-off-by: Alexander Shiyan <eagle.alexander923@xxxxxxxxx>

Reviewed-by: Michael Riesch <michael.riesch@xxxxxxxxxxxxxx>

Best regards,
Michael

> ---
>  drivers/media/i2c/imx415.c | 13 +++++++++++++
>  1 file changed, 13 insertions(+)
> 
> diff --git a/drivers/media/i2c/imx415.c b/drivers/media/i2c/imx415.c
> index 9f37779bd611..16a52900c61c 100644
> --- a/drivers/media/i2c/imx415.c
> +++ b/drivers/media/i2c/imx415.c
> @@ -1076,6 +1076,18 @@ static int imx415_init_state(struct v4l2_subdev *sd,
>  	return 0;
>  }
>  
> +static int imx415_get_mbus_config(struct v4l2_subdev *sd, unsigned int pad_id,
> +				  struct v4l2_mbus_config *config)
> +{
> +	struct imx415 *sensor = to_imx415(sd);
> +
> +	config->type = V4L2_MBUS_CSI2_DPHY;
> +	config->bus.mipi_csi2.flags = 0;
> +	config->bus.mipi_csi2.num_data_lanes = sensor->num_data_lanes;
> +
> +	return 0;
> +}
> +
>  static const struct v4l2_subdev_video_ops imx415_subdev_video_ops = {
>  	.s_stream = imx415_s_stream,
>  };
> @@ -1086,6 +1098,7 @@ static const struct v4l2_subdev_pad_ops imx415_subdev_pad_ops = {
>  	.get_fmt = v4l2_subdev_get_fmt,
>  	.set_fmt = imx415_set_format,
>  	.get_selection = imx415_get_selection,
> +	.get_mbus_config = imx415_get_mbus_config,
>  };
>  
>  static const struct v4l2_subdev_ops imx415_subdev_ops = {





[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]

  Powered by Linux