lkml.org 
[lkml]   [2015]   [Apr]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: linux-next: build warning after merge of the char-misc tree
On Tue, Mar 31, 2015 at 09:35:45PM +0200, Fabian Frederick wrote:
>
>
> > On 27 March 2015 at 08:48 Stephen Rothwell <sfr@canb.auug.org.au> wrote:
> >
> >
> > Hi all,
> >
> > After merging the char-misc tree, today's linux-next build (powerpc
> > allyesconfig) produced this warning:
> >
> > In file included from include/linux/module.h:17:0,
> >                  from drivers/uio/uio_pdrv_genirq.c:21:
> > include/linux/moduleparam.h:326:22: warning: initialization discards 'const'
> > qualifier from pointer target type
> >   static const struct kparam_string __param_string_##name  \
> >                       ^
> > drivers/uio/uio_pdrv_genirq.c:260:1: note: in expansion of macro
> > 'module_param_string'
> >  module_param_string(of_id, uio_of_genirq_match[0].compatible, 128, 0);
> >  ^
> >
> > Introduced by commit 4d8beff2ae07 ("uio: constify of_device_id array").
>
> Hi Stephen,
>
> Absolutely, my patch is wrong ; comment below explains struct is filled
> afterwards.Sorry.
> Greg, should I send you a revert or maybe we could standardize that driver ? (it
> seems it's the only one to work that way).
>
> static const struct of_device_id uio_of_genirq_match[] = {
>         { /* This is filled with module_parm */ },
>         { /* Sentinel */ },
> };

A revert would be great, and then work to fix it "correctly" so we can
make it constant would be wonderful. But I don't know how you would do
that at first glance.

I'll just go revert the patch now, thanks.

thanks,

greg k-h


\
 
 \ /
  Last update: 2015-04-03 16:41    [W:0.064 / U:0.184 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site