linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Val Packett <val@packett.cool>
To: Mehdi Djait <mehdi.djait.k@gmail.com>
Cc: mchehab@kernel.org, heiko@sntech.de, hverkuil-cisco@xs4all.nl,
	krzysztof.kozlowski+dt@linaro.org, robh+dt@kernel.org,
	conor+dt@kernel.org, linux-media@vger.kernel.org,
	devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
	thomas.petazzoni@bootlin.com, alexandre.belloni@bootlin.com,
	maxime.chevallier@bootlin.com, paul.kocialkowski@bootlin.com,
	michael.riesch@wolfvision.net, laurent.pinchart@ideasonboard.com,
	Mehdi Djait <mehdi.djait@bootlin.com>
Subject: Re: [RESEND Patch v13 2/3] media: rockchip: Add a driver for Rockchip's camera interface
Date: Wed, 29 May 2024 21:22:07 -0300	[thread overview]
Message-ID: <VOV9ES.1808A7M5SYMM3@packett.cool> (raw)
In-Reply-To: <715d89214d1ed6a8bb16cbb6268718a737485560.1707677804.git.mehdi.djait.k@gmail.com>

Hi,

On Sun, Feb 11 2024 at 20:03:31 +01:00:00, Mehdi Djait 
<mehdi.djait.k@gmail.com> wrote:
> This introduces a V4L2 driver for the Rockchip CIF video capture 
> controller.
> 
> This controller can be found on RK3066, PX30, RK1808, RK3128 and 
> RK3288,
> but for now it's only been tested on the PX30.

I've been testing it on an RK3066 tablet I'm bringing up mainline on, 
recently figured out the clock situation that made the cameras appear 
on I2C and got a camera driver to attach, but still not getting a frame 
and will need to debug more.. Since you're familiar with the hardware, 
could you quickly tell me what exactly causes the CIF interrupt to 
fire? Is it a signal from the camera?

Anyway, two things I noticed with the code:

> +static int cif_enum_input(struct file *file, void *priv,
> +			  struct v4l2_input *input)
> +{
> +	struct cif_stream *stream = video_drvdata(file);
> +	struct v4l2_subdev *sd = stream->cifdev->remote.sd;
> +	int ret;
> +
> +	if (input->index > 0)
> +		return -EINVAL;
> +
> +	ret = v4l2_subdev_call(sd, video, g_input_status, &input->status);
> +	if (ret && ret != -EOPNOTSUPP)
> +		return ret;

v4l2_subdev_call actually returns -ENOIOCTLCMD when the camera driver 
does not handle the requested call.

> +static int cif_plat_probe(struct platform_device *pdev)
> +{
[…]
> +	ret = devm_clk_bulk_get(dev, cif_dev->match_data->clks_num,
> +				cif_dev->match_data->clks);

This looks like it's just modifying the `static` clocks array shared 
between all instances of the driver and not copying the clock 
references into the instance's private struct.

Thanks,
~val



  parent reply	other threads:[~2024-05-30  0:22 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-11 19:03 [RESEND Patch v13 0/3] media: rockchip: Add a driver for Rockchip's camera interface Mehdi Djait
2024-02-11 19:03 ` [RESEND Patch v13 1/3] media: dt-bindings: media: add bindings for Rockchip CIF Mehdi Djait
2024-02-13 12:04   ` Sakari Ailus
2024-02-20 17:04     ` Mehdi Djait
2024-02-20 19:30       ` Sakari Ailus
2024-02-20 20:48         ` Mehdi Djait
2024-02-21 10:57           ` Sakari Ailus
2024-02-11 19:03 ` [RESEND Patch v13 2/3] media: rockchip: Add a driver for Rockchip's camera interface Mehdi Djait
2024-02-13 13:37   ` Sakari Ailus
2024-02-21 17:55     ` Mehdi Djait
2024-02-27 10:23       ` Sakari Ailus
2024-03-02 11:51         ` Mehdi Djait
2024-03-04  9:25           ` Michael Riesch
2024-03-04 11:01             ` Sakari Ailus
2024-05-30  0:22   ` Val Packett [this message]
2024-06-12  5:23   ` Val Packett
2024-06-12 22:01     ` Mehdi Djait
2024-02-11 19:03 ` [RESEND Patch v13 3/3] arm64: dts: rockchip: Add the px30 " Mehdi Djait

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=VOV9ES.1808A7M5SYMM3@packett.cool \
    --to=val@packett.cool \
    --cc=alexandre.belloni@bootlin.com \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=heiko@sntech.de \
    --cc=hverkuil-cisco@xs4all.nl \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=laurent.pinchart@ideasonboard.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=maxime.chevallier@bootlin.com \
    --cc=mchehab@kernel.org \
    --cc=mehdi.djait.k@gmail.com \
    --cc=mehdi.djait@bootlin.com \
    --cc=michael.riesch@wolfvision.net \
    --cc=paul.kocialkowski@bootlin.com \
    --cc=robh+dt@kernel.org \
    --cc=thomas.petazzoni@bootlin.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;
as well as URLs for NNTP newsgroup(s).