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


Groups > linux.kernel > #1658875

Re: [PATCH 0/3] move visorbus out of staging to drivers/virt/visorbus

From Greg KH <gregkh@linuxfoundation.org>
Newsgroups linux.kernel
Subject Re: [PATCH 0/3] move visorbus out of staging to drivers/virt/visorbus
Date 2017-06-06 17:40 +0200
Message-ID <tPoKm-2cf-21@gated-at.bofh.it> (permalink)
References <tPhzb-5Qn-5@gated-at.bofh.it> <tPnXY-1DX-15@gated-at.bofh.it> <tPo7D-1Hh-5@gated-at.bofh.it> <tPoKm-2cf-7@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Tue, Jun 06, 2017 at 08:33:49AM -0700, Joe Perches wrote:
> On Tue, 2017-06-06 at 16:53 +0200, Greg KH wrote:
> > On Tue, Jun 06, 2017 at 04:49:09PM +0200, Greg KH wrote:
> > > I noticed that in drivers/staging/unisys/visorbus/visorbus_main.c, you
> > > have 2 tabs for your 'struct attribute' variables, which is really odd.
> []
> > Also, many of the attribute callbacks in that file seem to all have
> > their leading '{' in the wrong place.  Odd that checkpatch.pl doesn't
> > catch that...
> 
> checkpatch doesn't really check much about inconsistent
> indentation.  I believe the only new statement indentation
> check is after an if.
> 
> For instance, checkpatch doesn't emit a warning on this code:
> 
> struct foo {
> 		int bar;
> };
> 
> struct foo *alloc_foo(void)
> {
> 			struct foo *baz = malloc(sizeof(struct foo));
> 		if (baz)
> 			baz->bar = 1;
> 				return baz;
> }

Ok, but the following code in that file should be caught, right:

static ssize_t partition_handle_show(struct device *dev,
                                     struct device_attribute *attr,
                                     char *buf) {
        struct visor_device *vdev = to_visor_device(dev);
        u64 handle = visorchannel_get_clientpartition(vdev->visorchannel);

        return sprintf(buf, "0x%llx\n", handle);
}
static DEVICE_ATTR_RO(partition_handle);


The initial { is in the wrong place...

thanks,

greg k-h

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


Thread

Re: [PATCH 0/3] move visorbus out of staging to drivers/virt/visorbus Greg KH <gregkh@linuxfoundation.org> - 2017-06-06 16:50 +0200
  Re: [PATCH 0/3] move visorbus out of staging to drivers/virt/visorbus Greg KH <gregkh@linuxfoundation.org> - 2017-06-06 17:00 +0200
    Re: [PATCH 0/3] move visorbus out of staging to drivers/virt/visorbus Greg KH <gregkh@linuxfoundation.org> - 2017-06-06 17:10 +0200
      RE: [PATCH 0/3] move visorbus out of staging to drivers/virt/visorbus "Kershner, David A" <David.Kershner@unisys.com> - 2017-06-06 20:30 +0200
        Re: [PATCH 0/3] move visorbus out of staging to drivers/virt/visorbus Greg KH <gregkh@linuxfoundation.org> - 2017-06-06 21:00 +0200
  Re: [PATCH 0/3] move visorbus out of staging to drivers/virt/visorbus Greg KH <gregkh@linuxfoundation.org> - 2017-06-06 17:00 +0200
    Re: [PATCH 0/3] move visorbus out of staging to  drivers/virt/visorbus Joe Perches <joe@perches.com> - 2017-06-06 17:40 +0200
      Re: [PATCH 0/3] move visorbus out of staging to drivers/virt/visorbus Greg KH <gregkh@linuxfoundation.org> - 2017-06-06 17:40 +0200
        Re: [PATCH 0/3] move visorbus out of staging to  drivers/virt/visorbus Joe Perches <joe@perches.com> - 2017-06-06 18:00 +0200
          Re: [PATCH 0/3] move visorbus out of staging to drivers/virt/visorbus Greg KH <gregkh@linuxfoundation.org> - 2017-06-06 18:10 +0200
  Re: [PATCH 0/3] move visorbus out of staging to drivers/virt/visorbus Christoph Hellwig <hch@infradead.org> - 2017-06-07 16:10 +0200

csiph-web