Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp2746319rwl; Mon, 27 Mar 2023 04:54:50 -0700 (PDT) X-Google-Smtp-Source: AKy350azQssFyeRq7GOifrkBGsZ3HY0yJRIQ1hTvzF56v3TWf6TT3PuypK6c7yrDBcOAa87W1Zu2 X-Received: by 2002:aa7:da57:0:b0:4fb:80cf:89e6 with SMTP id w23-20020aa7da57000000b004fb80cf89e6mr12584421eds.8.1679918089757; Mon, 27 Mar 2023 04:54:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1679918089; cv=none; d=google.com; s=arc-20160816; b=EPQIvtuVu8cAqW0trlNV+lcRz6nhSmcBIcVZYLiSFuZzDyxGLXqUSErQlKHroQAu8e 9obxYhX2d6SSynps40rmZQCsWay8nDokIU+O5MxZqsZUuLxEu/6l7QtgwpKN+wrOzJ4H tZx4JSmK7BbeZjeHSdaW8DRJIwwSmVrieZ9ZWp0nPXFF/zzv1IN2/N/AovOZuPQFz6P/ T82HcVaSnZug1ZBUgDs057zmzyy8i1zOI6mLSxQB4Uvd1G1q7FoRSKeOFZPsKPiYsf0s 9Bg18cDVmvEvSMm+fTEFnKRHrXyfH2ni0US6bBdVRN5HoR3OuBBEtkMjhNQdoNBZUxEI QaDA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=o9d0XenKq0q9vI7DXJzFm0rN0H8kURHquHhWITeC+xE=; b=mh+yYNnOmp7VVq6+Pe8f/Wm+kwMgzN3yhnHVmAAO3eUg09emH5vHASfem9TysLD8e7 Vt2+omDpeLOlGRwwiGdcS7+duRVv8FI+ah73XLEsYrE2/3gSCF5yPfeJ2jDSAR9z0NVZ PMNfnxIHLVoW82rPF0NPNQBixZ3QVdgPvK1aTD1aTTY2fFQM6p50MO5HVbn9K8WWALia sQtr/l74UjTM0G+S+1TkhdbsF1RyDAipJYTaTg7Nc9Cu5SehihTJhQB53a+FT838e3cU E57Db32PGLU/2vAuNYMDmKUPLFXyYQEsoFYGLHJm1kiKEt9jUh/C6OhO1l98kiQANYcb yAYg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=T9C2RVcQ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id g12-20020aa7c58c000000b004fd23c8cf1esi18085210edq.52.2023.03.27.04.54.25; Mon, 27 Mar 2023 04:54:49 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=T9C2RVcQ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232509AbjC0LoL (ORCPT + 99 others); Mon, 27 Mar 2023 07:44:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:32862 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232479AbjC0LoJ (ORCPT ); Mon, 27 Mar 2023 07:44:09 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1CA02270E; Mon, 27 Mar 2023 04:44:08 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id B8A54B80B7E; Mon, 27 Mar 2023 11:44:06 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id E5985C433D2; Mon, 27 Mar 2023 11:44:04 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1679917445; bh=39dMlcm9dz8DHNPorL7lH7wJe0iuw2BjZ6ty9Z48GHs=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=T9C2RVcQrn1x/Y1E4n4IcP/nwoRpfeMXmrftTche9bo5eSdefMUJypOw/ZI5srZiO kfGlv+vns8AyOG0vJBQO71KL0WHdKh6HZNZaTmYMLsdgAipBj5WhmKVEPuQr32AW38 I63Cf09Qa/ZxWO8jCmVO1G53QVEDqPo8pbek+GYk= Date: Mon, 27 Mar 2023 13:43:57 +0200 From: Greg Kroah-Hartman To: Nick Alcock Cc: Luis Chamberlain , Geert Uytterhoeven , Masahiro Yamada , Thomas Gleixner , Christoph Hellwig , linux-modules@vger.kernel.org, linux-kernel@vger.kernel.org, Hitomi Hasegawa , Jiri Slaby Subject: Re: [PATCH 10/17] tty: remove MODULE_LICENSE in non-modules Message-ID: References: <87h6uamdzw.fsf@esperi.org.uk> <87tty6lbed.fsf@esperi.org.uk> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <87tty6lbed.fsf@esperi.org.uk> X-Spam-Status: No, score=-5.2 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI,SPF_HELO_NONE, SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Mar 27, 2023 at 11:46:34AM +0100, Nick Alcock wrote: > On 24 Mar 2023, Luis Chamberlain spake thusly: > > > On Fri, Mar 24, 2023 at 03:29:00PM +0100, Greg Kroah-Hartman wrote: > >> Please put back the license bits that you removed, as it is not a good > >> idea to remove that if the file does not have a SPDX entry at the very > >> least. > > > > Nick, I've just dropped your series. > > Thanks, that's much easier than getting all those reverts in. > (Presumably the bits taken by other people can all stay.) > > > Please only re-submit only for > > files where the license is clear. The effort of clarifying licenses > > on files where one doesn't have an SPDX tag is welcomed but can take > > time and we'll need this anyway in the future to help later strive to > > see if we can automatically generate the MODULE_LICENSE() from the > > SPDX tags. > > For now, I have an alternative that might be acceptable. I did a bit of > an audit and it's all a right mess (see below), with wild divergence > even when SPDX is present, GPL versus -only or GPL-2.0+ apparently > applied almost at random and some things being completely different (in > some cases they were both committed simultaneously and were inconsistent > from the moment the module was written). So many things are inconsistent > that kallmodsyms would call a lot of things modules that really aren't: > there is enough error that there probably be noticeable mistakes in > quite a high percentage of kernels. As you have found out, there is a difference that matters in the SPDX lines vs the MODULE_LICENSE lines when it comes to GPL vs GPLv2+ stuff. The SPDX lines are correct for the code itself, while the MODULE_LICENSE lines are correct from a "this is the license of this binary" point of view. So don't get confused here, if you all can figure out a way to generate the MODULE_LICENSE() lines from SPDX, that would be great, but in my quick look I think it's going to be very difficult (think about how multiple files make up a single module binary...) good luck! > But... for our purposes, we don't actually *mind* if non-modules list > things like licenses inconsistently in two different places. Removing > MODULE_LICENSE was a means, not an end. What we're actually interested > in doing is removing .modinfo in things that can't possibly be modules, > and since a .modinfo in a guaranteed-non-module is at best entirely > useless I don't think anyone could reasonably be opposed to that end > goal (though they might reasonably be unhappy about all the churn > involved in getting there). They object to the removal of the visible > MODULE_LICENSE() argument text string, not to the useless compile-time > effect of a MODULE_LICENSE in a non-module. there are other things that create .modinfo lines, so I'm confused why you picked the license line to trigger all of this. > So how about, for the first three groups below (the groups where > MODULE_LICENSE and SPDX are inconsistent, or where a SPDX simply doesn't > exist), instead of removing the MODULE_LICENSE we replace it with an > identical call to a new macro named perhaps NONMODULE_LICENSE(), which > is defined in module.h as simply expanding to nothing, except possibly > emitting a compile-time error if it's ever used in a module? This more > clearly denotes what's going on, keeps the license string in the source > file on a nearly identical line (for whatever purpose it serves), drops > the spurious .modinfo that's causing trouble, and probably makes fewer > people unhappy? Again, no, why aren't you just stubbing out MODULE_LICENSE() in the build if it's not being built as a module like the other MODULE_*() macros are? Why is the license so special here yet the device list or module authors not? Don't treat this macro as somehow special where authors have to remember to not use it (or to use it), while the other MODULE_* macros do not have the issue? That's my main objection here. Don't get confused by the license stuff, that's secondary. thanks, greg k-h