Re: [PATCH] nits: fix several coding style warnings

From: Joe Perches
Date: Sun Mar 08 2015 - 18:18:54 EST


On Sun, 2015-03-08 at 23:14 +0100, Guennadi Liakhovetski wrote:
> On Sun, 8 Mar 2015, Ioana Antoche wrote:
> > Fix checkpatch.pl warnings such as:
> > * missing blank line after declarations
> > * line over 80 characters
[]
> > @@ -298,8 +299,7 @@ static struct device *next_device(struct klist_iter *i)
> > * count in the supplied callback.
> > */
> > int bus_for_each_dev(struct bus_type *bus, struct device *start,
> > - void *data, int (*fn)(struct device *, void *))
> > -{
> > + void *data, int (*fn)(struct device *, void *)) {
>
> Really curious: is this change (and a similar one below) really fixing a
> style violation?

Nope.

The "for_each" use in a function name confuses checkpatch.
Normally, those are macros.

> > @@ -448,8 +449,7 @@ static struct device_driver *next_driver(struct klist_iter *i)
> > * so it doesn't disappear before returning to the caller.
> > */
> > int bus_for_each_drv(struct bus_type *bus, struct device_driver *start,
> > - void *data, int (*fn)(struct device_driver *, void *))
> > -{
> > + void *data, int (*fn)(struct device_driver *, void *)) {



--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/