linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Josh Wu <josh.wu@atmel.com>
To: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Cc: <linux-media@vger.kernel.org>, <m.chehab@samsung.com>,
	<nicolas.ferre@atmel.com>, <linux-arm-kernel@lists.infradead.org>,
	<laurent.pinchart@ideasonboard.com>
Subject: Re: [PATCH v2 2/3] [media] atmel-isi: convert the pdata from pointer to structure
Date: Fri, 23 May 2014 11:15:18 +0800	[thread overview]
Message-ID: <537EBD46.6030406@atmel.com> (raw)
In-Reply-To: <Pine.LNX.4.64.1405182255540.23804@axis700.grange>

Hi, Guennadi

On 5/19/2014 4:59 AM, Guennadi Liakhovetski wrote:
> Hi Josh,
>
> I'm still waiting for an update of Ben's patches to then also apply yours,
> but I decided to have a look at yours now to see if I find anything, that
> might be worth changing. A small note to this one below.
>
> On Tue, 25 Mar 2014, Josh Wu wrote:
>
>> Now the platform data is initialized by allocation of isi
>> structure. In the future, we use pdata to store the dt parameters.
>>
>> Signed-off-by: Josh Wu <josh.wu@atmel.com>
>> ---
>> v1 --> v2:
>>   no change.
>>
>>   drivers/media/platform/soc_camera/atmel-isi.c |   22 +++++++++++-----------
>>   1 file changed, 11 insertions(+), 11 deletions(-)
>>
>> diff --git a/drivers/media/platform/soc_camera/atmel-isi.c b/drivers/media/platform/soc_camera/atmel-isi.c
>> index 9d977c5..f4add0a 100644
>> --- a/drivers/media/platform/soc_camera/atmel-isi.c
>> +++ b/drivers/media/platform/soc_camera/atmel-isi.c
> [snip]
>
>> @@ -912,7 +912,7 @@ static int atmel_isi_probe(struct platform_device *pdev)
>>   	if (IS_ERR(isi->pclk))
>>   		return PTR_ERR(isi->pclk);
>>   
>> -	isi->pdata = pdata;
>> +	memcpy(&isi->pdata, pdata, sizeof(struct isi_platform_data));
> I think it'd be better to use
>
> +	memcpy(&isi->pdata, pdata, sizeof(isi->pdata));
>
> This way if the type of the pdata changes at any time in the future this
> line will not have to be changed. If you don't mind I can make this change
> myself, so you don't have to make a new version just for this.

Thanks for pointing it out.  I think I will sent out a new version of 
patch (include bus-width parsing) then I will included with this fix.

Best Regards,
Josh Wu

>
> Thanks
> Guennadi
> ---
> Guennadi Liakhovetski, Ph.D.
> Freelance Open-Source Software Developer
> http://www.open-technology.de/


  reply	other threads:[~2014-05-23  3:16 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-25 10:41 [PATCH v2 0/3] [media] atmel-isi: Add DT support for Atmel ISI driver Josh Wu
2014-03-25 10:41 ` [PATCH v2 1/3] [media] atmel-isi: add v4l2 async probe support Josh Wu
2014-03-25 10:41 ` [PATCH v2 2/3] [media] atmel-isi: convert the pdata from pointer to structure Josh Wu
2014-05-18 20:59   ` Guennadi Liakhovetski
2014-05-23  3:15     ` Josh Wu [this message]
2014-03-25 10:45 ` [PATCH v2 3/3] [media] atmel-isi: add primary DT support Josh Wu
2014-03-26 16:12   ` Laurent Pinchart
2014-03-30 21:20   ` Guennadi Liakhovetski
2014-03-31  9:05     ` Josh Wu
2014-07-17 11:00       ` Laurent Pinchart
2014-07-18  3:15         ` Josh Wu
2014-05-18 21:51   ` Guennadi Liakhovetski
2014-05-23  3:12     ` Josh Wu

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=537EBD46.6030406@atmel.com \
    --to=josh.wu@atmel.com \
    --cc=g.liakhovetski@gmx.de \
    --cc=laurent.pinchart@ideasonboard.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-media@vger.kernel.org \
    --cc=m.chehab@samsung.com \
    --cc=nicolas.ferre@atmel.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).