From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751860AbeAENFb (ORCPT + 1 other); Fri, 5 Jan 2018 08:05:31 -0500 Received: from mail.free-electrons.com ([62.4.15.54]:41840 "EHLO mail.free-electrons.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751278AbeAENF3 (ORCPT ); Fri, 5 Jan 2018 08:05:29 -0500 Date: Fri, 5 Jan 2018 14:05:26 +0100 From: Alexandre Belloni To: Thomas Gleixner Cc: LKML , Linus Torvalds , Andrew Morton , Jonathan Corbet , Kate Stewart , Philippe Ombredanne , Greg Kroah-Hartman , Christoph Hellwig , Russell King , Rob Herring , Jonas Oberg , Joe Perches , linux-xfs@vger.kernel.org, Charlemagne Lasse , Carmen Bianca Bakker Subject: Re: [V4, 01/11] Documentation: Add license-rules.rst to describe how to properly identify file licenses Message-ID: <20180105130526.GA31648@piout.net> References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.9.2 (2017-12-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Return-Path: Hi, I'm definitively late to the party but... On 17/11/2017 at 11:00:33 +0100, Thomas Gleixner wrote: > +2. Style: > + > + The SPDX license identifier is added in form of a comment. The comment > + style depends on the file type:: > + > + C source: // SPDX-License-Identifier: > + C header: /* SPDX-License-Identifier: */ > + ASM: /* SPDX-License-Identifier: */ > + scripts: # SPDX-License-Identifier: > + .rst: .. SPDX-License-Identifier: > + .dts{i}: // SPDX-License-Identifier: dtc doesn't handle // comments. This works in the kernel tree because dts files are preprocessed by CPP. But this doesn't work when using dtc directly (most likely when compiling DT overlays). So, the choice is between making dtc handle // comments or changing the documentation. I don't have an opinion and Rob doesn't seem to care but I think we need to do something now instead of letting each maintainer have to handle this issue. > + If a specific tool cannot handle the standard comment style, then the > + appropriate comment mechanism which the tool accepts shall be used. This > + is the reason for having the "/\* \*/" style comment in C header > + files. There was build breakage observed with generated .lds files where > + 'ld' failed to parse the C++ comment. This has been fixed by now, but > + there are still older assembler tools which cannot handle C++ style > + comments. > + -- Alexandre Belloni, Free Electrons Embedded Linux and Kernel engineering http://free-electrons.com