lkml.org 
[lkml]   [2013]   [Jul]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v3 01/10] Driver core and sysfs changes for attribute groups
On Mon, Jul 15, 2013 at 10:27:00AM +1000, Stephen Rothwell wrote:
> Hi Greg,
>
> On Sun, 14 Jul 2013 16:05:50 -0700 Greg Kroah-Hartman <gregkh@linuxfoundation.org> wrote:
> >
> > Anyone else have a better name for this macro:
> > #define DEVICE_PATTR(_name) &dev_attr_##_name.attr
> > that they can think of? It will cut down on the typing done for
> > attribute lists.
>
> Just one small peeve I have about all these places we do symbol pasting,
> is that it makes it impossible to find some things because grep complete
> fails us. We type them once (often by cutting and pasting), but try to
> find them who knows how many times?
>
> Just saying ...

Yeah, I know. But realize that the dev_attr_##_name variable was
originally created with a:
DEV_ATTR_RO(sysfs_file_name);
macro in the first place, so even trying to grep for dev_attr* brings up
nothing. At least this way the grep would find the same thing, so it
does make a little bit sense in a way, right?

Or am I just trying to justify it as I'm tired of typing all that...

greg k-h


\
 
 \ /
  Last update: 2013-07-15 02:41    [W:0.097 / U:1.524 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site