lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CA+55aFzP+b2Vt=+ZZbkpuYi87gO+pZXVxKnySkiedn+SYN2CCw@mail.gmail.com>
Date:   Sat, 25 Nov 2017 10:30:29 -1000
From:   Linus Torvalds <torvalds@...ux-foundation.org>
To:     Mauro Carvalho Chehab <mchehab@...pensource.com>
Cc:     Pavel Machek <pavel@....cz>,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        Thomas Gleixner <tglx@...utronix.de>,
        Christoph Hellwig <hch@....de>,
        LKML <linux-kernel@...r.kernel.org>,
        Andrew Morton <akpm@...uxfoundation.org>,
        Jonathan Corbet <corbet@....net>,
        Kate Stewart <kstewart@...uxfoundation.org>,
        Philippe Ombredanne <pombredanne@...b.com>,
        Russell King <rmk+kernel@...linux.org.uk>,
        Rob Herring <rob.herring@...aro.org>,
        Jonas Oberg <jonas@...e.org>, Joe Perches <joe@...ches.com>,
        linux-xfs <linux-xfs@...r.kernel.org>,
        Charlemagne Lasse <charlemagnelasse@...il.com>,
        Carmen Bianca Bakker <carmenbianca@...e.org>
Subject: Re: [patch V4 01/11] Documentation: Add license-rules.rst to describe
 how to properly identify file licenses

On Sat, Nov 25, 2017 at 9:53 AM, Mauro Carvalho Chehab
<mchehab@...pensource.com> wrote:
>
> Let me see if I got it straight. At drivers/media/common/siano/smsir.c,
> we have, currently:

.. snip snip ..

> With is completely out of standard. I'd like to add an SPDX tag there
> and, while doing that, adjust the comments.
>
> So, if I understand well, your preference would be to make it like:
>
>         // SPDX-License-Identifier: GPL-2.0+
>         //
>         // Siano Mobile Silicon, Inc.
>         // MDTV receiver kernel modules.
>         // Copyright (C) 2006-2009, Uri Shkolnik
>         //
>         // Copyright (c) 2010 - Mauro Carvalho Chehab
>         //      - Ported the driver to use rc-core
>         //      - IR raw event decoding is now done at rc-core
>         //      - Code almost re-written
>
> Right?

Exactly.

I would also like to make clear that this is not a "let's do this in
bulk and automatically". But let's just say that if the "//" for the
SPDX line ends up encouraging people towards this kind of  format over
the long run, I think that would be lovely.

The /* */ format really  ends up encouraging some odd formatting. Your
example with the whole "box of stars" is not standard kernel format,
but it's surprisingly common. And you find various lopsided versions
of the multi-line thing, and even when you do *single* lines, the /*
*/ thing ends up being something where people try to align the closing
"*/" part.

Honestly now, how many people have seen things like

    struct somestruct {
        int member;    /* For Xyz         */
        int other;     /* For Abracadabra */
        ...

where people try to align that ending thing?

Or tell me you haven't seen block comments where  people do

    /*  This is a multi-line
     * thing that tries to be dense */

and other odd formats that are just ugly and unbalanced.

That's why I think "//" ends up being better in the end. And yes, I've
changed my mind over time. Had you asked me ten or fifteen years ago,
I probably would have said that "//" is not real C.

               Linus

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ