Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1546322

Re: Converting DEVICE_ATTR to DEVICE_ATTR_{RO,RW,WO} and changing function names at the same time

From Julia Lawall <julia.lawall@lip6.fr>
Newsgroups linux.kernel
Subject Re: Converting DEVICE_ATTR to DEVICE_ATTR_{RO,RW,WO} and changing function names at the same time
Date 2016-12-22 13:40 +0100
Message-ID <sRaP9-140-75@gated-at.bofh.it> (permalink)
References <sRaP9-140-77@gated-at.bofh.it> <sRaP9-140-79@gated-at.bofh.it> <sRaP9-140-81@gated-at.bofh.it> <sRaPa-140-83@gated-at.bofh.it> <sRaPa-140-85@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw



On Wed, 21 Dec 2016, Guenter Roeck wrote:

> Hi Julia,
>
> On Wed, Dec 21, 2016 at 08:39:38PM +0100, Julia Lawall wrote:
> >
> >
> > On Wed, 21 Dec 2016, Guenter Roeck wrote:
> >
> > > Hi Julia,
> > >
> > > On Wed, Dec 21, 2016 at 03:05:37PM +0100, Julia Lawall wrote:
> > > > A solution is below: the semantic patch, an explanation of the semantic
> > > > patch, and the results.  I have only tried to compile the results (make
> > > > drivers/hwmon/).  Two affected files were not considered for compilation:
> > > >
> > > > drivers/hwmon/vexpress-hwmon.o
> > > > drivers/hwmon/jz4740-hwmon.o
>
> I compile tested those two patches. If possible please drop vexpress-hwmon.c
> from the patch series; the changes in that file don't add any value.
>
> I compile tested all files, and reviewed the patch. It all looks good.
> Please submit the series.
>
> Again, thanks a lot for your help!

I have sent the patches.  I adjusted the semantic patch so that the
indentation of function parameters/arguments would only change if the
length of the function name changes.

Do you think this could be of more general interest in the Linux kernel?
Since the semantic patch works pretty well, I could add it to the
scripts/coccinelle directory?  Previously, however, I got some negative
feedback about this change, because people felt that the new names hid the
actual behavior, so I didn't pursue it.

julia

Back to linux.kernel | Previous | NextNext in thread | Find similar | Unroll thread


Thread

Re: Converting DEVICE_ATTR to DEVICE_ATTR_{RO,RW,WO} and changing  function names at the same time Julia Lawall <julia.lawall@lip6.fr> - 2016-12-22 13:40 +0100
  Re: Converting DEVICE_ATTR to DEVICE_ATTR_{RO,RW,WO} and changing  function names at the same time Guenter Roeck <linux@roeck-us.net> - 2016-12-22 16:40 +0100
    Re: Converting DEVICE_ATTR to DEVICE_ATTR_{RO,RW,WO} and changing  function names at the same time Julia Lawall <julia.lawall@lip6.fr> - 2016-12-22 16:50 +0100
      Re: Converting DEVICE_ATTR to DEVICE_ATTR_{RO,RW,WO} and changing  function names at the same time Greg KH <gregkh@linuxfoundation.org> - 2016-12-22 18:40 +0100
      Re: Converting DEVICE_ATTR to DEVICE_ATTR_{RO,RW,WO} and changing  function names at the same time Guenter Roeck <linux@roeck-us.net> - 2016-12-22 19:30 +0100
        Re: Converting DEVICE_ATTR to DEVICE_ATTR_{RO,RW,WO} and changing  function names at the same time Guenter Roeck <linux@roeck-us.net> - 2016-12-24 00:20 +0100
          Re: Converting DEVICE_ATTR to DEVICE_ATTR_{RO,RW,WO} and changing  function names at the same time Julia Lawall <julia.lawall@lip6.fr> - 2016-12-24 07:10 +0100

csiph-web