From: Pavel Machek <pavel@denx.de>
To: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
Cc: cip-dev@lists.cip-project.org,
Nobuhiro Iwamatsu <nobuhiro1.iwamatsu@toshiba.co.jp>,
Pavel Machek <pavel@denx.de>,
Biju Das <biju.das.jz@bp.renesas.com>
Subject: Re: [PATCH v2 5.10.y-cip 10/28] media: platform: Add Renesas RZ/G2L MIPI CSI-2 receiver driver
Date: Tue, 5 Nov 2024 12:27:28 +0100 [thread overview]
Message-ID: <ZyoBIAONV1wUteVt@duo.ucw.cz> (raw)
In-Reply-To: <20241101125746.33222-11-prabhakar.mahadev-lad.rj@bp.renesas.com>
[-- Attachment #1: Type: text/plain, Size: 2133 bytes --]
Hi!
> commit 51e8415e39a962db2a753940fca18e9710c24902 upstream.
>
> Add MIPI CSI-2 receiver driver for Renesas RZ/G2L. The MIPI
> CSI-2 is part of the CRU module found on RZ/G2L family.
>
> Based on a patch in the BSP by Hien Huynh
> <hien.huynh.px@renesas.com>
> +++ b/drivers/media/platform/renesas/rzg2l-cru/rzg2l-csi2.c
> +static int rzg2l_csi2_notify_bound(struct v4l2_async_notifier *notifier,
> + struct v4l2_subdev *subdev,
> + struct v4l2_async_subdev *asd)
> +{
> + struct rzg2l_csi2 *csi2 = notifier_to_csi2(notifier);
> +
> + csi2->remote_source = subdev;
> +
> + dev_dbg(csi2->dev, "Bound subdev: %s pad\n", subdev->name);
> +
> + return media_create_pad_link(&subdev->entity, RZG2L_CSI2_SINK,
> + &csi2->subdev.entity, 0,
> + MEDIA_LNK_FL_ENABLED |
> + MEDIA_LNK_FL_IMMUTABLE);
> +}
> +
> +static void rzg2l_csi2_notify_unbind(struct v4l2_async_notifier *notifier,
> + struct v4l2_subdev *subdev,
> + struct v4l2_async_subdev *asd)
> +{
> + struct rzg2l_csi2 *csi2 = notifier_to_csi2(notifier);
> +
> + csi2->remote_source = NULL;
> +
> + dev_dbg(csi2->dev, "Unbind subdev %s\n", subdev->name);
> +}
Are the dev_dbgs still needed?
> +static int rzg2l_csi2_parse_dt(struct rzg2l_csi2 *csi2)
> +{
> + struct v4l2_fwnode_endpoint v4l2_ep = {
> + .bus_type = V4L2_MBUS_CSI2_DPHY
> + };
> + struct v4l2_async_subdev *asd;
> + struct fwnode_handle *fwnode;
> + struct fwnode_handle *ep;
> + int ret;
> +
> + ep = fwnode_graph_get_endpoint_by_id(dev_fwnode(csi2->dev), 0, 0, 0);
> + if (!ep) {
> + dev_err(csi2->dev, "Not connected to subdevice\n");
> + return -EINVAL;
> + }
> +
> + ret = v4l2_fwnode_endpoint_parse(ep, &v4l2_ep);
> + if (ret) {
> + dev_err(csi2->dev, "Could not parse v4l2 endpoint\n");
> + fwnode_handle_put(ep);
> + return -EINVAL;
> + }
Would it be better to propagate error (return ret) here?
Best regards,
Pavel
--
DENX Software Engineering GmbH, Managing Director: Erika Unter
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 195 bytes --]
next prev parent reply other threads:[~2024-11-05 11:27 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-01 12:57 [PATCH v2 5.10.y-cip 00/28] Add CRU, CSI support for Renesas RZ/{G2L, V2L} SoCs Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 01/28] media: i2c: ov5645: Drop fetching the clk reference by name Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 02/28] media: i2c: ov5645: Use runtime PM Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 03/28] media: i2c: ov5645: Drop empty comment Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 04/28] media: i2c: ov5645: Make sure to call PM functions Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 05/28] media: i2c: ov5645: Call ov5645_entity_init_cfg() before registering the subdev Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 06/28] media: i2c: ov5645: Remove software reset entry from ov5645_global_init_setting Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 07/28] media: v4l: subdev: Add pre_streamon and post_streamoff callbacks Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 08/28] media: dt-bindings: Document Renesas RZ/G2L CSI-2 block Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 09/28] media: dt-bindings: Document Renesas RZ/G2L CRU block Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 10/28] media: platform: Add Renesas RZ/G2L MIPI CSI-2 receiver driver Lad Prabhakar
2024-11-05 11:27 ` Pavel Machek [this message]
2024-11-05 11:35 ` Prabhakar Mahadev Lad
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 11/28] media: platform: Add Renesas RZ/G2L CRU driver Lad Prabhakar
2024-11-05 11:32 ` Pavel Machek
2024-11-05 12:22 ` Prabhakar Mahadev Lad
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 12/28] media: rzg2l-cru: Remove unnecessary shadowing of ret in rzg2l_csi2_s_stream() Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 13/28] media: platform: renesas: rzg2l-cru: Add missing documentation for image_conv_irq Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 14/28] media: rzg2l-cru: Fix missing error code in rzg2l_cru_start_streaming_vq() Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 15/28] media: rzg2l-cru: fix a test for timeout Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 16/28] media: rzg2l-cru: Remove unneeded semicolon Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 17/28] media: platform: rzg2l-cru: rzg2l-csi2: Enclose the macro in parentheses Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 18/28] media: platform: rzg2l-cru: rzg2l-csi2: Switch to RUNTIME_PM_OPS() Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 19/28] media: platform: rzg2l-cru: rzg2l-ip: Add delay after D-PHY reset Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 20/28] media: platform: rzg2l-cru: rzg2l-video: Fix image processing initialization Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 21/28] media: platform: rzg2l-cru: rzg2l-csi2: Restructure vclk handling Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 22/28] media: platform: rzg2l-cru: rzg2l-video: Fix start reception procedure Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 23/28] media: platform: rzg2l-cru: rzg2l-csi2: Add missing MODULE_DEVICE_TABLE Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 24/28] clk: renesas: r9a07g044: Add clock and reset entries for CRU Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 25/28] arm64: dts: renesas: r9a07g044: Add CSI and CRU nodes Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 26/28] arm64: dts: renesas: r9a07g054: " Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 27/28] arm64: dts: renesas: rzg2l-smarc: Enable CRU, CSI support Lad Prabhakar
2024-11-01 12:57 ` [PATCH v2 5.10.y-cip 28/28] arm64: defconfig: Enable RZ/G2L MIPI CSI-2 and CRU support Lad Prabhakar
2024-11-05 11:19 ` [PATCH v2 5.10.y-cip 00/28] Add CRU, CSI support for Renesas RZ/{G2L, V2L} SoCs Pavel Machek
2024-11-06 11:24 ` Pavel Machek
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=ZyoBIAONV1wUteVt@duo.ucw.cz \
--to=pavel@denx.de \
--cc=biju.das.jz@bp.renesas.com \
--cc=cip-dev@lists.cip-project.org \
--cc=nobuhiro1.iwamatsu@toshiba.co.jp \
--cc=prabhakar.mahadev-lad.rj@bp.renesas.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox