lkml.org 
[lkml]   [2014]   [Feb]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 2/2] asoc: soc-core: fix coccinelle warnings
On Mon, Feb 24, 2014 at 11:05:14AM +0800, Nenghua Cao wrote:
> On 02/22/2014 10:52 AM, Mark Brown wrote:

> > type changes. What coccinelle was suggesting here was to replace with a
> > simple assingment statement rather than change the argument within the
> > memcpy(), I think this stops the warning showing because of that issue

> I am not familiar with coccinelle. But it isn't reasonable and
> convenient to use simple assignment instead of memcpy() here. So let's
> retain it. I will submit another patch to fix "Assignment of bool to
> 0/1" issue. How do you think about it?

Well, the two should be separate patches anyway but it's totally
reasonable to do an assigment - what it's telling you is that with
modern C "a = b" is valid even if a and b are structs.
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2014-02-24 07:21    [W:0.520 / U:0.312 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site