All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mauro Carvalho Chehab <mchehab@s-opensource.com>
To: Ulrich Hecht <ulrich.hecht+renesas@gmail.com>
Cc: hans.verkuil@cisco.com, niklas.soderlund@ragnatech.se,
	linux-media@vger.kernel.org, linux-renesas-soc@vger.kernel.org,
	magnus.damm@gmail.com, laurent.pinchart@ideasonboard.com,
	ian.molton@codethink.co.uk, lars@metafoo.de,
	william.towle@codethink.co.uk
Subject: Re: [PATCH v4 3/8] media: rcar_vin: Use correct pad number in try_fmt
Date: Tue, 28 Jun 2016 08:32:38 -0300	[thread overview]
Message-ID: <20160628083238.5fe7e32b@recife.lan> (raw)
In-Reply-To: <1462975376-491-4-git-send-email-ulrich.hecht+renesas@gmail.com>

Em Wed, 11 May 2016 16:02:51 +0200
Ulrich Hecht <ulrich.hecht+renesas@gmail.com> escreveu:

> Fix rcar_vin_try_fmt's use of an inappropriate pad number when calling
> the subdev set_fmt function - for the ADV7612, IDs should be non-zero.
> 
> Signed-off-by: William Towle <william.towle@codethink.co.uk>
> Reviewed-by: Rob Taylor <rob.taylor@codethink.co.uk>
> Acked-by: Hans Verkuil <hans.verkuil@cisco.com>
> [uli: adapted to rcar-vin rewrite]

Please use [email@domain: some revierwer note], as stated at Documentation/SubmittingPatches.

> Signed-off-by: Ulrich Hecht <ulrich.hecht+renesas@gmail.com>

This patch breaks compilation:

drivers/media/platform/rcar-vin/rcar-v4l2.c: In function '__rvin_try_format_source':
drivers/media/platform/rcar-vin/rcar-v4l2.c:115:18: error: 'struct rvin_dev' has no member named 'src_pad_idx'
  format.pad = vin->src_pad_idx;
                  ^~



> ---
>  drivers/media/platform/rcar-vin/rcar-v4l2.c | 14 +++++++++++---
>  1 file changed, 11 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/media/platform/rcar-vin/rcar-v4l2.c b/drivers/media/platform/rcar-vin/rcar-v4l2.c
> index 0bc4487..42dbd35 100644
> --- a/drivers/media/platform/rcar-vin/rcar-v4l2.c
> +++ b/drivers/media/platform/rcar-vin/rcar-v4l2.c
> @@ -98,7 +98,7 @@ static int __rvin_try_format_source(struct rvin_dev *vin,
>  					struct rvin_source_fmt *source)
>  {
>  	struct v4l2_subdev *sd;
> -	struct v4l2_subdev_pad_config pad_cfg;
> +	struct v4l2_subdev_pad_config *pad_cfg;
>  	struct v4l2_subdev_format format = {
>  		.which = which,
>  	};
> @@ -108,10 +108,16 @@ static int __rvin_try_format_source(struct rvin_dev *vin,
>  
>  	v4l2_fill_mbus_format(&format.format, pix, vin->source.code);
>  
> +	pad_cfg = v4l2_subdev_alloc_pad_config(sd);
> +	if (pad_cfg == NULL)
> +		return -ENOMEM;
> +
> +	format.pad = vin->src_pad_idx;
> +
>  	ret = v4l2_device_call_until_err(sd->v4l2_dev, 0, pad, set_fmt,
> -					 &pad_cfg, &format);
> +					 pad_cfg, &format);
>  	if (ret < 0)
> -		return ret;
> +		goto cleanup;
>  
>  	v4l2_fill_pix_format(pix, &format.format);
>  
> @@ -121,6 +127,8 @@ static int __rvin_try_format_source(struct rvin_dev *vin,
>  	vin_dbg(vin, "Source resolution: %ux%u\n", source->width,
>  		source->height);
>  
> +cleanup:
> +	v4l2_subdev_free_pad_config(pad_cfg);
>  	return 0;
>  }
>  



Thanks,
Mauro

  reply	other threads:[~2016-06-28 11:32 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-11 14:02 [PATCH v4 0/8] Lager/Koelsch board HDMI input support Ulrich Hecht
2016-05-11 14:02 ` [PATCH v4 1/8] v4l: subdev: Add pad config allocator and init Ulrich Hecht
2016-05-13  8:28   ` Hans Verkuil
2016-05-11 14:02 ` [PATCH v4 2/8] media: adv7604: automatic "default-input" selection Ulrich Hecht
2016-06-27  9:26   ` Hans Verkuil
2016-05-11 14:02 ` [PATCH v4 3/8] media: rcar_vin: Use correct pad number in try_fmt Ulrich Hecht
2016-06-28 11:32   ` Mauro Carvalho Chehab [this message]
2016-06-28 11:59     ` Geert Uytterhoeven
2016-05-11 14:02 ` [PATCH v4 4/8] media: rcar-vin: pad-aware driver initialisation Ulrich Hecht
2016-05-11 14:02 ` [PATCH v4 5/8] media: rcar-vin: add DV timings support Ulrich Hecht
2016-06-27  9:28   ` Hans Verkuil
2016-05-11 14:02 ` [PATCH v4 6/8] media: rcar-vin: initialize EDID data Ulrich Hecht
2016-05-13  8:36   ` Hans Verkuil
2016-06-27  9:30     ` Hans Verkuil
2016-05-11 14:02 ` [PATCH v4 7/8] ARM: dts: lager: Add entries for VIN HDMI input support Ulrich Hecht
2016-05-11 14:02 ` [PATCH v4 8/8] r8a7791-koelsch.dts: add HDMI input Ulrich Hecht
2016-05-12  4:55   ` Simon Horman

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=20160628083238.5fe7e32b@recife.lan \
    --to=mchehab@s-opensource.com \
    --cc=hans.verkuil@cisco.com \
    --cc=ian.molton@codethink.co.uk \
    --cc=lars@metafoo.de \
    --cc=laurent.pinchart@ideasonboard.com \
    --cc=linux-media@vger.kernel.org \
    --cc=linux-renesas-soc@vger.kernel.org \
    --cc=magnus.damm@gmail.com \
    --cc=niklas.soderlund@ragnatech.se \
    --cc=ulrich.hecht+renesas@gmail.com \
    --cc=william.towle@codethink.co.uk \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.