Received: by 2002:a05:6a10:413:0:0:0:0 with SMTP id 19csp253501pxp; Wed, 16 Mar 2022 05:14:00 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx3MmcHYBHaOXkfIdOrjbYAFA+AGPQJ8aY/phJUZRzvlm/J/60aTbx6G4/F50lO4CX2Zvn6 X-Received: by 2002:a17:902:b202:b0:151:4f64:e516 with SMTP id t2-20020a170902b20200b001514f64e516mr33434923plr.16.1647432839904; Wed, 16 Mar 2022 05:13:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1647432839; cv=none; d=google.com; s=arc-20160816; b=pZQS9O/4/bMmsH5AU8SP0yeycTD+taacFrQ55bLYVkWB/NA4Ocl5lwNCQBe10AQJB+ OTAPylKgpG4FcluHwRCJY8sA33E73KKSXPfW1iP5HZDtHRFvPR0qb0OeIRPNrh9tLXNg 7vxttyqbWRzkbN1g6dQfuGGWnOhcoE8oRQlXs7Mu2yEsjaQFBpQRPvpyZoHPYcn8Pr6H qUoBnH22uxdWdSkbFWFHxfUNxiApf152vNyPPbVPjqemAHr3NjsC5s2JRxIdO/dfM1XX dEYxdaMwk/Gttthj5WGaOYeYgE3HJEHuV+WcaZoJOc3Ft7TqglG9mM6C7UUI12fY8nny i5pQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=Gdgwc50V9R2+QH5FBUvazQfb7JYjYQJxqctQWcR0o0M=; b=wC9b69zqv2OiJ9JGXxKoir6lC76wquVz7gqkH/h2jSemAXgAd/6tcdrv8x863zd6H1 ooVGflYtntvnyiyFlwlsUceDZcP5focoYS445cISXA8SjC/35YgpnUtl1oDs6kaSa7/O KulJ5h2QJffDKENZ0zOhBvzldh0uNVbCeencmT4WUKYwHeb4W+w3Ts4rnsVm5I+w8RBS cFxsKScnRUo4uRvFWeo6drC3N2379MbZunypspxp9t8gSHSXxlE+drDRYp4+IQuxw/gw ISX8oOQrl9FS9rmVMu7q+aP7eMsB1OHCMFyt7VtYAho+ynjZRSDvYE33XGjfherHP2v6 4uiA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=X9afLoy+; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id k11-20020aa788cb000000b004f77b04dcd1si1951921pff.296.2022.03.16.05.13.40; Wed, 16 Mar 2022 05:13:59 -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=@gmail.com header.s=20210112 header.b=X9afLoy+; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1350389AbiCOXkg (ORCPT + 99 others); Tue, 15 Mar 2022 19:40:36 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46376 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239050AbiCOXkf (ORCPT ); Tue, 15 Mar 2022 19:40:35 -0400 Received: from mail-pl1-x635.google.com (mail-pl1-x635.google.com [IPv6:2607:f8b0:4864:20::635]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8F1CB5C870; Tue, 15 Mar 2022 16:39:22 -0700 (PDT) Received: by mail-pl1-x635.google.com with SMTP id e13so444095plh.3; Tue, 15 Mar 2022 16:39:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=Gdgwc50V9R2+QH5FBUvazQfb7JYjYQJxqctQWcR0o0M=; b=X9afLoy+Ml4ks/kD1uF3I63U/IvRzLI8Wayo9PTqvrLdXNdY9g7SxZ3aPHGh9P+JQQ 2X/BS74LPouGFZiTft7ay/9ZzxqgCEGVssFqxN6qeR+IovKA9Mg0GG3wG9NiClZemos7 4jzEeKmOoryRpkcpWs/vsXHtnGzAKYyqtgY4LTMvzzuX/rsfZ7sgAJi1f8KHgCkZLghk msY+tiZA3MmEEYrpMC+XuOrhn02JMIvdeCxy5rQ+FgBbXS6sNcoO0D9Mq/0i+JKDfpFW e3OvKaO1Tib0eO/TEloIoCLILRwuTtbTOYrQ/aD5aRAZG4ggxkTHkhQB6w/kc+E5wP8t LQLA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=Gdgwc50V9R2+QH5FBUvazQfb7JYjYQJxqctQWcR0o0M=; b=td1L4Gnw7PZ8jmFsqVB4EmSE5/oeQzLL6M5ngpl31+DmjRUW/N+NKWXMWtmAG5VX2V zNBRjv7o9keBwuY1Rckemf0qAnlqgxOvStf8AWPOhg5Z39lOMpexBWwX/mMzPwnGc4Gx j/EcsPUsKetqcRh4WwpOauS6AMoPZtoiwvSZ0SaUtwWyTDrTPbwEF43IMSgKickX6VAx vh990QZsdc7y7OP90eVr/RQerSJ6px4Z8mNu+P34dYipYc+Fu5Ifv402J0Ff+jo0FsUF 8bxvPDrqgBYZUtdE2z557ZxpYZKsZqj6VcBk5udTbIfw2q/CTZU2EEkHGlwrcFiJnDq5 2SVA== X-Gm-Message-State: AOAM531dReVg1X37ZLisNNV2hOdKY2OD7wAPh4HNcE4HRrHlrTBGx8Kk El+wGZG8bXfZ7JCFVkRYElJDvvLyVvEynhOR/nzCMpRQ X-Received: by 2002:a17:90a:3e42:b0:1bf:53ce:f1ef with SMTP id t2-20020a17090a3e4200b001bf53cef1efmr7231971pjm.33.1647387561997; Tue, 15 Mar 2022 16:39:21 -0700 (PDT) MIME-Version: 1.0 References: <1d2931e80c03f4d3f7263beaf8f19a4867e9fe32.1647212431.git.dxu@dxuuu.xyz> <53a71699-3ffb-4a49-9d15-7fe4a0f51612@www.fastmail.com> In-Reply-To: <53a71699-3ffb-4a49-9d15-7fe4a0f51612@www.fastmail.com> From: Alexei Starovoitov Date: Tue, 15 Mar 2022 16:39:10 -0700 Message-ID: Subject: Re: [PATCH bpf-next] bpftool: Add SPDX identifier to btf-dump-file output To: Daniel Xu Cc: "bpf@vger.kernel.org" , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , LKML Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham 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 Tue, Mar 15, 2022 at 4:10 PM Daniel Xu wrote: > > Hi Alexei, > > On Tue, Mar 15, 2022, at 2:38 PM, Alexei Starovoitov wrote: > > On Sun, Mar 13, 2022 at 4:01 PM Daniel Xu wrote: > >> > >> A concern about potential GPL violations came up at the new $DAYJOB when > >> I tried to vendor the vmlinux.h output. The central point was that the > >> generated vmlinux.h does not embed a license string -- making the > >> licensing of the file non-obvious. > >> > >> This commit adds a LGPL-2.1 OR BSD-2-Clause SPDX license identifier to > >> the generated vmlinux.h output. This is line with what bpftool generates > >> in object file skeletons. > >> > >> Signed-off-by: Daniel Xu > >> --- > >> tools/bpf/bpftool/btf.c | 1 + > >> 1 file changed, 1 insertion(+) > >> > >> diff --git a/tools/bpf/bpftool/btf.c b/tools/bpf/bpftool/btf.c > >> index a2c665beda87..fca810a27768 100644 > >> --- a/tools/bpf/bpftool/btf.c > >> +++ b/tools/bpf/bpftool/btf.c > >> @@ -425,6 +425,7 @@ static int dump_btf_c(const struct btf *btf, > >> if (err) > >> return err; > >> > >> + printf("/* SPDX-License-Identifier: (LGPL-2.1 OR BSD-2-Clause) */\n\n"); > > > > I don't think we can add any kind of license identifier > > to the auto generated output. > > vmlinux.h is a pretty printed dwarfdump. > > Just so I understand better, when you say "I don't think we can", > do you mean: > > 1) There may be legal issues w/ adding the license identifier > 2) It doesn't make sense to add the license header > 3) Something else? 2