lkml.org 
[lkml]   [2016]   [Feb]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [PATCH 10/14] efi: Make checkpatch complain less about efi.h GUID additions

    * Matt Fleming <matt@codeblueprint.co.uk> wrote:

    > On Wed, 03 Feb, at 11:33:35AM, Ingo Molnar wrote:
    > >
    > > * Matt Fleming <matt@codeblueprint.co.uk> wrote:
    > >
    > > > From: Peter Jones <pjones@redhat.com>
    > > >
    > > > This reformats the GUID definitions in include/linux/efi.h so that if
    > > > you add another one with the same style, checkpatch won't complain about
    > > > it.
    > > >
    > > > Signed-off-by: Peter Jones <pjones@redhat.com>
    > > > Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org>
    > > > Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk>
    > > > ---
    > > > include/linux/efi.h | 63 +++++++++++++++++++++++++++++++++++------------------
    > > > 1 file changed, 42 insertions(+), 21 deletions(-)
    > > >
    > > > diff --git a/include/linux/efi.h b/include/linux/efi.h
    > > > index 09f1559e7525..f468f7c53236 100644
    > > > --- a/include/linux/efi.h
    > > > +++ b/include/linux/efi.h
    > > > @@ -535,67 +535,88 @@ void efi_native_runtime_setup(void);
    > > > * EFI Configuration Table and GUID definitions
    > > > */
    > > > #define NULL_GUID \
    > > > - EFI_GUID( 0x00000000, 0x0000, 0x0000, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 )
    > > > + EFI_GUID(0x00000000, 0x0000, 0x0000, \
    > > > + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00)
    > > >
    > > > #define MPS_TABLE_GUID \
    > > > - EFI_GUID( 0xeb9d2d2f, 0x2d88, 0x11d3, 0x9a, 0x16, 0x0, 0x90, 0x27, 0x3f, 0xc1, 0x4d )
    > > > + EFI_GUID(0xeb9d2d2f, 0x2d88, 0x11d3, \
    > > > + 0x9a, 0x16, 0x00, 0x90, 0x27, 0x3f, 0xc1, 0x4d)
    > >
    > > So I really think this is a step backwards.
    > >
    > > Checkpatch should be fixed/enhanced to allow targeted exemption. Something like:
    > >
    > >
    > > #define CHECKPATCH_IGNORE
    > > ...
    > > #undef CHECKPATCH_IGNORE
    > >
    > > ... which checkpatch would parse and interpret accordingly.
    >
    > Irrespective of which tool suggested this change, I think this patch
    > is an improvement because the GUIDs now match the format from the UEFI
    > spec, making checking for typos that much easier (yes, I've really had
    > to do that in the past).

    Hm, so the GUIDs are line-broken in the same fashion in the spec, after the third
    parameter?

    That's a strong reason indeed - and then the changelog and title should say that:
    're-format GUID tables to follow the format of the UEFI spec'. That it also
    pacifies checkpatch is a side effect.

    Thanks,

    Ingo

    \
     
     \ /
      Last update: 2016-02-03 12:01    [W:3.394 / U:0.008 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site