From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jeroen Hofstee Date: Mon, 16 Jun 2014 22:03:34 +0200 Subject: [U-Boot] [PATCH] video: ipu_disp: squash clang warning In-Reply-To: <539F4AF6.6030704@boundarydevices.com> References: <1402947663-20632-1-git-send-email-jeroen@myspectrum.nl> <539F4AF6.6030704@boundarydevices.com> Message-ID: <1402949014.2333.14.camel@yellow> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hello Troy, On ma, 2014-06-16 at 12:52 -0700, Troy Kisky wrote: > On 6/16/2014 12:41 PM, Jeroen Hofstee wrote: > > Since &rgb2ycbcr_coeff and friends are declared const, but > > assigned to a void pointer, clang will warn that the const > > is implicity casted away. Add const to indicate the pointer > > points to const data to get rid of these warnings. > > > > Cc: Stefano Babic > > Signed-off-by: Jeroen Hofstee > > --- > > drivers/video/ipu_disp.c | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > diff --git a/drivers/video/ipu_disp.c b/drivers/video/ipu_disp.c > > index cefd2dc..31b5a10 100644 > > --- a/drivers/video/ipu_disp.c > > +++ b/drivers/video/ipu_disp.c > > @@ -33,7 +33,7 @@ enum csc_type_t { > > > > struct dp_csc_param_t { > > int mode; > > - void *coeff; > > + void * const coeff; > > }; > > > > #define SYNC_WAVE 0 > > > > Doesn't this says the pointer is constant, not that it points to constant data? > So, commit log needs updated or > const void *coeff; yup, it does. Thanks. The patch should be updated actually. Regards, Jeroen