From patchwork Wed Nov 2 11:28:51 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anthony PERARD X-Patchwork-Id: 13027994 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 3778EC433FE for ; Wed, 2 Nov 2022 11:29:26 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.435805.689609 (Exim 4.92) (envelope-from ) id 1oqBvk-00022r-6b; Wed, 02 Nov 2022 11:29:12 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 435805.689609; Wed, 02 Nov 2022 11:29:12 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1oqBvk-00022k-2b; Wed, 02 Nov 2022 11:29:12 +0000 Received: by outflank-mailman (input) for mailman id 435805; Wed, 02 Nov 2022 11:29:10 +0000 Received: from se1-gles-flk1-in.inumbo.com ([94.247.172.50] helo=se1-gles-flk1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1oqBvi-00021c-Ng for xen-devel@lists.xenproject.org; Wed, 02 Nov 2022 11:29:10 +0000 Received: from esa2.hc3370-68.iphmx.com (esa2.hc3370-68.iphmx.com [216.71.145.153]) by se1-gles-flk1.inumbo.com (Halon) with ESMTPS id 8f745791-5aa1-11ed-8fd0-01056ac49cbb; Wed, 02 Nov 2022 12:29:07 +0100 (CET) X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 8f745791-5aa1-11ed-8fd0-01056ac49cbb DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=citrix.com; s=securemail; t=1667388547; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=sdBaG8nza+w2eZvi73Kk9Zj+hZVkMYunpXxpVdr9hzQ=; b=g8rtRZ2qw0KHt3/bu6i6daM8MWTNKGiFKOV/mDoCJogV9FCAgEHQJ9dZ h4SpmUx3A9J7aHEPhvangoYNkDFxTw7Pc+m7lHTyOpK56Fzysc61/uNFX DLPHShzpyfxv7onrRlRy0+D4+/9wN++YPOzGEJGFELW86KCWbWy0Ydsfh 4=; Authentication-Results: esa2.hc3370-68.iphmx.com; dkim=none (message not signed) header.i=none X-SBRS: 2.7 X-MesageID: 84016366 X-Ironport-Server: esa2.hc3370-68.iphmx.com X-Remote-IP: 162.221.156.83 X-Policy: $RELAYED IronPort-Data: A9a23:wwnYDKoVDoZP1FIIzQGUGXinGBheBmLVZRIvgKrLsJaIsI4StFCzt garIBnUM/iPMzahLdEla9uzoRsAvJCGxoBgTwc+rilgRCxB95uZCYyVIHmrMnLJJKUvbq7FA +Y2MYCccZ9uHhcwgj/3b9ANeFEljfngqoLUUbKCYWYpAFc+E0/NsDo788YhmIlknNOlNA2Ev NL2sqX3NUSsnjV5KQr40YrawP9UlKm06W5wUmAWP6gR5gaHzyNNVfrzGInqR5fGatgMdgKFb 76rIIGRpgvx4xorA9W5pbf3GmVirmn6ZFXmZtJ+AsBOszAazsAA+v9T2Mk0MC+7vw6hjdFpo OihgLTrIesf0g8gr8xGO/VQO3kW0aSrY9YrK1Dn2SCY5xWun3cBX5yCpaz5VGEV0r8fPI1Ay RAXADBVcSC52fz1/KmybehypMMHC9bkGqpK7xmMzRmBZRonaZXKQqGM7t5ExjYgwMtJGJ4yZ eJAN2ApNk6ZJUQSZBFHU/rSn8/x7pX7WzRetFKSo7tx+2XJxRZ9+LPsLMDUapqBQsA9ckOw9 j6epjqiXE9y2Nq3xSC182yehPL1uzLSSK43L7K2x85WjwjGroAUIEJPDgbqyRWjsWa8RtZeJ ko86ico668o+ySDTNPwQhm5q36spQMHVpxbFOhSwB6J4rrZ5UCeHGdsZiVadNUsucsyRDor/ lyEhdXkAXpoqrL9YVKQ8K2F6wy7Pyc9JHUHIyQDSGMt89Tl5Y0+kB/LZtJiC7KuyM34Hynqx DKHpzR4gK8c5fPnzI3iowqB2Wj14MGUEEhlvW07Q15J8Ct5PJGVXdK2qmTA5NFBMqSean6es 14tzp32AP81MbmBkymEQeMoFb6v5uqYPDC0vWODD6XN5Bz2pSf9INk4DCVWYR4wb51aIWOBj Fr741s52XNFAJe9gUabiaqVAt9i86XvHM+Nuhv8PosXOcgZmONqEUhTia+sM4LFyhZEfUIXY 83znSOQ4ZEyUP0P8dZOb71BuYLHPwhnrY8pebj1zg68zZ2Vb2OPRLEOPTOmN75ns/je/1qNo ocGa6NmLimzt8WnPEHqHXM7dwhWfRDX+7irwyCoSgJzClU/QzxwYxMg6bggZ5Zkj8xoehTgp xmAtrtj4AOm3RX6xfCiMC8LhEXHAcki9hrW/EUEYT6V5pTUSd/xsvdEL8tmI+dPGS4K5accc sTpsv6oWpxnIgkrMRxEBXUhhOSOrCiWuD8= IronPort-HdrOrdr: A9a23:orygW6E5DywoYn+EpLqE7seALOsnbusQ8zAXP0AYc3Nom6uj5q eTdZUgpGbJYVkqOU3I9ersBEDEewK/yXcX2/h0AV7BZmnbUQKTRekIh7cKgQeQfhEWntQts5 uIGJIRNDSfNzRHZL7BkWqFL+o= X-IronPort-AV: E=Sophos;i="5.95,232,1661832000"; d="scan'208";a="84016366" From: Anthony PERARD To: CC: Henry Wang , Anthony PERARD , Andrew Cooper , Andrew Cooper , George Dunlap , Jan Beulich , Julien Grall , Stefano Stabellini , Wei Liu Subject: [XEN PATCH for-4.17 1/4] xen: Add licence information to public/errno.h Date: Wed, 2 Nov 2022 11:28:51 +0000 Message-ID: <20221102112854.49020-2-anthony.perard@citrix.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20221102112854.49020-1-anthony.perard@citrix.com> References: <20221102112854.49020-1-anthony.perard@citrix.com> MIME-Version: 1.0 Fixes: 81f559e97974 ("make error codes a formal part of the ABI") Reported-by: Andrew Cooper Signed-off-by: Anthony PERARD --- xen/include/public/errno.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/xen/include/public/errno.h b/xen/include/public/errno.h index 5c53af6af9..6bdc8c5079 100644 --- a/xen/include/public/errno.h +++ b/xen/include/public/errno.h @@ -1,3 +1,5 @@ +/* SPDX-License-Identifier: MIT */ + /* * There are two expected ways of including this header. * From patchwork Wed Nov 2 11:28:52 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anthony PERARD X-Patchwork-Id: 13027996 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 65575C43219 for ; Wed, 2 Nov 2022 11:29:27 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.435806.689620 (Exim 4.92) (envelope-from ) id 1oqBvq-0002M0-ER; Wed, 02 Nov 2022 11:29:18 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 435806.689620; Wed, 02 Nov 2022 11:29:18 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1oqBvq-0002Lo-9W; Wed, 02 Nov 2022 11:29:18 +0000 Received: by outflank-mailman (input) for mailman id 435806; Wed, 02 Nov 2022 11:29:16 +0000 Received: from se1-gles-flk1-in.inumbo.com ([94.247.172.50] helo=se1-gles-flk1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1oqBvo-00021c-N6 for xen-devel@lists.xenproject.org; Wed, 02 Nov 2022 11:29:16 +0000 Received: from esa2.hc3370-68.iphmx.com (esa2.hc3370-68.iphmx.com [216.71.145.153]) by se1-gles-flk1.inumbo.com (Halon) with ESMTPS id 944c0787-5aa1-11ed-8fd0-01056ac49cbb; Wed, 02 Nov 2022 12:29:15 +0100 (CET) X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 944c0787-5aa1-11ed-8fd0-01056ac49cbb DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=citrix.com; s=securemail; t=1667388555; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=pr0JfmwP5/FWVhK0t5YQqcQll6KmEYKssZtRV/z9j94=; b=UMMiSzEnIy3yybdqtVAE/goJXOZnIS4g04N/vpLt77TZjbNKqpwlKJBf 8W82RDZira55YRqW1wvl35l+m5V4pt0/d8k+IYJeGlfT5dko6oqgwz2ed 0ErxmmXiJ9VvmOmbLrBB1CeeZqSpZgVT1iIgPAw4rBa59MDS7CdaTu3Pv g=; Authentication-Results: esa2.hc3370-68.iphmx.com; dkim=none (message not signed) header.i=none X-SBRS: 2.7 X-MesageID: 84016409 X-Ironport-Server: esa2.hc3370-68.iphmx.com X-Remote-IP: 162.221.156.83 X-Policy: $RELAYED IronPort-Data: A9a23:aRFRLKC8Hj8+IhVW/+Tjw5YqxClBgxIJ4kV8jS/XYbTApD9xhDIHz GMXWGjQOK3eZTP8fd93Yd7n8x5XucKHmIVlQQY4rX1jcSlH+JHPbTi7wuUcHAvJd5GeExg3h yk6QoOdRCzhZiaE/n9BCpC48T8nk/nNHuCnYAL9EngZbRd+Tys8gg5Ulec8g4p56fC0GArIs t7pyyHl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C6mlwRA09TySZ// rBoB19726TtN9xYgBZpTnuAsm9qB/nmaKdpLNhWItKPzOW31dATrsSjrcKqgeIc0aVm9K1l5 0QF5SWYOeAdGSS5vya3ODXKbkdKaG8gcKVuds= X-IronPort-AV: E=Sophos;i="5.95,232,1661832000"; d="scan'208";a="84016409" From: Anthony PERARD To: CC: Henry Wang , Anthony PERARD , Andrew Cooper , George Dunlap , Jan Beulich , Julien Grall , Stefano Stabellini , Wei Liu , Andrew Cooper Subject: [XEN PATCH for-4.17 2/4] tools/include/xen-foreign: Capture licences from the input headers Date: Wed, 2 Nov 2022 11:28:52 +0000 Message-ID: <20221102112854.49020-3-anthony.perard@citrix.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20221102112854.49020-1-anthony.perard@citrix.com> References: <20221102112854.49020-1-anthony.perard@citrix.com> MIME-Version: 1.0 The headers install in "/usr/include/xen/foreign/" are missing a licence. While we could probably just add the MIT licence to the generated file, this patch instead try to grab the licence from the original input file. Since licences are in the first multiline C comments, we just look for that. Also with this patch, the possible licences will not be in the "input" variable anymore, but it should be unnecessary to generate the foreign header. With this change, the licence will be copied 2 or 3 time in the install headers depending on the number of input headers. Reported-by: Andrew Cooper Signed-off-by: Anthony PERARD --- Notes: Maybe instead of this, we should just stamp this on the generated header /* SPDX-License-Identifier: MIT */ but we would be missing the "Copyright" informations. I guess we could look for those line with Copyright and copy them. Or, we could replace the licence in the input header by a SPDX and have the script parse that. (Probably still need to grab the Copyright lines) CC: Andrew Cooper CC: George Dunlap CC: Jan Beulich CC: Julien Grall CC: Stefano Stabellini CC: Wei Liu tools/include/xen-foreign/mkheader.py | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/tools/include/xen-foreign/mkheader.py b/tools/include/xen-foreign/mkheader.py index fb268f0dce..07a9bcbd01 100644 --- a/tools/include/xen-foreign/mkheader.py +++ b/tools/include/xen-foreign/mkheader.py @@ -114,9 +114,19 @@ input = ""; output = ""; fileid = re.sub("[-.]", "_", "__FOREIGN_%s__" % outfile.upper()); -# read input header files +# Try to captures licences headers from original files. +# heuristic: just look for the end of the first multiline comment. +licence_headers = ""; + for name in infiles: f = open(name, "r"); + while True: + line = f.readline() + if not line: + break + licence_headers += line + if line == " */\n": + break input += f.read(); f.close(); @@ -126,11 +136,12 @@ output += """ * public xen defines and struct for %s * generated by %s -- DO NOT EDIT */ +%s #ifndef %s #define %s 1 -""" % (arch, sys.argv[0], fileid, fileid) +""" % (arch, sys.argv[0], licence_headers, fileid, fileid) if arch in header: output += header[arch]; From patchwork Wed Nov 2 11:28:53 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anthony PERARD X-Patchwork-Id: 13027997 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 13E2AC433FE for ; Wed, 2 Nov 2022 11:29:42 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.435810.689631 (Exim 4.92) (envelope-from ) id 1oqBw4-00031w-RT; Wed, 02 Nov 2022 11:29:32 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 435810.689631; Wed, 02 Nov 2022 11:29:32 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1oqBw4-00031H-N5; Wed, 02 Nov 2022 11:29:32 +0000 Received: by outflank-mailman (input) for mailman id 435810; Wed, 02 Nov 2022 11:29:31 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1oqBw3-0001la-Mm for xen-devel@lists.xenproject.org; Wed, 02 Nov 2022 11:29:31 +0000 Received: from esa5.hc3370-68.iphmx.com (esa5.hc3370-68.iphmx.com [216.71.155.168]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 9d1f519b-5aa1-11ed-91b5-6bf2151ebd3b; Wed, 02 Nov 2022 12:29:30 +0100 (CET) X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 9d1f519b-5aa1-11ed-91b5-6bf2151ebd3b DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=citrix.com; s=securemail; t=1667388570; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=AB+G/K/xEbC4EusmJ8MPpns5BVj+9RqzmSAPIYA2wGU=; b=NXTdvWjGyf3h6zo9Yw5Q1yfAEKpPFcR/xrkDQ2SSmzq1mYhmCplpe/bG ZEtOdOck3tMYhK7r7vfcIBaf3E8B5VD/qwVf10yspyVIsJiRNVuGqS4a+ 19frH49J7IeX/F+1hL7muSE1LlT1HDlJrPUkSbOPZAgD/hgUe8AV0mhZ/ 4=; Authentication-Results: esa5.hc3370-68.iphmx.com; dkim=none (message not signed) header.i=none X-SBRS: 2.7 X-MesageID: 83088809 X-Ironport-Server: esa5.hc3370-68.iphmx.com X-Remote-IP: 162.221.156.83 X-Policy: $RELAYED IronPort-Data: A9a23:CYfMjKnEl0wY812IrSadzNjo5gxMJkRdPkR7XQ2eYbSJt1+Wr1Gzt xIXCmCFbPjYamOke98gYNnk9B9Sv8KHx9VnGwQ4ryE2RiMWpZLJC+rCIxarNUt+DCFhoGFPt JxCN4aafKjYaleG+39B55C49SEUOZmgH+a6U6icf3grHmeIcQ954Tp7gek1n4V0ttawBgKJq LvartbWfVSowFaYCEpNg064gE4p7amaVA8w5ARkP6kS5AWGzhH5MbpETU2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X5X43DYOCOggLBR+tfBOPZslnd8kbFmNK1u5 0NT0EHMqySMWRH X-IronPort-AV: E=Sophos;i="5.95,232,1661832000"; d="scan'208";a="83088809" From: Anthony PERARD To: CC: Henry Wang , Anthony PERARD , Andrew Cooper , Andrew Cooper , George Dunlap , Jan Beulich , Julien Grall , Stefano Stabellini , Wei Liu Subject: [XEN PATCH for-4.17 3/4] xen: Add licence header to device_tree_defs.h Date: Wed, 2 Nov 2022 11:28:53 +0000 Message-ID: <20221102112854.49020-4-anthony.perard@citrix.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20221102112854.49020-1-anthony.perard@citrix.com> References: <20221102112854.49020-1-anthony.perard@citrix.com> MIME-Version: 1.0 This header have been created by moving code from other part of the project and miss a licence header. The original source code was some version of GPL or LGPL but we intend to have the public header to be MIT so they can be included easily in other projects. Part of device_tree_defs.h were moved from libxl_arm.c which is LGPL-2.1-only. And part were moved from device_tree.h that is GPL-2.0-only. Part of the original code were added by Julien Grall @ Citrix with a Linaro "hat" in commits c3ba52a84dd8 and 405c167f0ec9 and 886f34045bf0. The other part were added by Ian Campbell @ Citrix, with commit 0c64527e7fc9. Resolves: xen-project/xen#35 Fixes: 1c898a9fec7e ("xen/arm: move a few DT related defines to public/device_tree_defs.h") Reported-by: Andrew Cooper Signed-off-by: Anthony PERARD Acked-by: Andrew Cooper Acked-by: Grant Likely > Acked-by: Grant Likely > Reported-by: Andrew Cooper > Signed-off-by: Anthony PERARD > --- Notes: Julian was working @citrix until 2015. xen/include/public/device_tree_defs.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/xen/include/public/device_tree_defs.h b/xen/include/public/device_tree_defs.h index 228daafe81..9e80d0499d 100644 --- a/xen/include/public/device_tree_defs.h +++ b/xen/include/public/device_tree_defs.h @@ -1,3 +1,9 @@ +/* SPDX-License-Identifier: MIT */ +/* + * Copyright (c) 2013 Linaro Limited + * Copyright (c) 2015 Citrix Systems, Inc + */ + #ifndef __XEN_DEVICE_TREE_DEFS_H__ #define __XEN_DEVICE_TREE_DEFS_H__ From patchwork Wed Nov 2 11:28:54 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anthony PERARD X-Patchwork-Id: 13027998 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 59E56C4332F for ; Wed, 2 Nov 2022 11:29:43 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.435811.689642 (Exim 4.92) (envelope-from ) id 1oqBw6-0003J5-3b; Wed, 02 Nov 2022 11:29:34 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 435811.689642; Wed, 02 Nov 2022 11:29:34 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1oqBw6-0003Iw-0G; Wed, 02 Nov 2022 11:29:34 +0000 Received: by outflank-mailman (input) for mailman id 435811; Wed, 02 Nov 2022 11:29:32 +0000 Received: from se1-gles-flk1-in.inumbo.com ([94.247.172.50] helo=se1-gles-flk1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1oqBw4-00021c-LX for xen-devel@lists.xenproject.org; Wed, 02 Nov 2022 11:29:32 +0000 Received: from esa3.hc3370-68.iphmx.com (esa3.hc3370-68.iphmx.com [216.71.145.155]) by se1-gles-flk1.inumbo.com (Halon) with ESMTPS id 9d915115-5aa1-11ed-8fd0-01056ac49cbb; Wed, 02 Nov 2022 12:29:31 +0100 (CET) X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 9d915115-5aa1-11ed-8fd0-01056ac49cbb DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=citrix.com; s=securemail; t=1667388571; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=2iKsKAFpwVBDCeJ/fX/gBxBJJ7BZRdN62cOsn36HHnw=; b=V4KFPLgdYG0ybIjKl0MD3IQK82Jjk9STaCRte8OG1XWMrBwRgAo02oCO tXh4POskyAhMlbjLy0g+83JUlfQP03fbekzr+HfC8ZF1ZcAVsESH4b3Vf o0J/vrhwRWel8/fcV/rQqHT2UAn/7gFSHWiNEutb+nrCkmi+vC4oGB1TV c=; Authentication-Results: esa3.hc3370-68.iphmx.com; dkim=none (message not signed) header.i=none X-SBRS: 2.7 X-MesageID: 83996305 X-Ironport-Server: esa3.hc3370-68.iphmx.com X-Remote-IP: 162.221.156.83 X-Policy: $RELAYED IronPort-Data: A9a23:s4qQOK2AQLakYsWWePbD5R5xkn2cJEfYwER7XKvMYLTBsI5bpzZTy mRODW3QbvqPY2f1LY13bYm+pkNS7cLVndFiGVRqpC1hF35El5HIVI+TRqvS04F+DeWYFR46s J9OAjXkBJppJpMJjk71atANlVEliefTAOK5ULSfUsxIbVcMYD87jh5+kPIOjIdtgNyoayuAo tq3qMDEULOf82cc3lk8tuTS9XuDgNyo4GlC5wVmP6gS1LPjvyJ94Kw3dPnZw0TQGuG4LsbiL 87fwbew+H/u/htFIrtJRZ6iLyXm6paLVeS/oiI+t5qK23CulQRrukoPD9IOaF8/ttm8t4sZJ OOhF3CHYVxB0qXkwIzxWvTDes10FfUuFLTveRBTvSEPpqFvnrSFL/hGVSkL0YMkFulfL21o3 vkbGio0ay+dle7o4LeGEfdXmZF2RCXrFNt3VnBIyDjYCbAtQIzZQrWM7thdtNsyrpkQR7CEP ZNfMGcxKkSbC/FMEg5/5JYWleG0hn75YntApUicv6Yf6GnP1g1hlrPqNbI5f/TaHpQEwB3A+ woq+UzaAghDBMKW4wDf822lierGmz39AKsrQejQGvlC3wTImz175ActfVmmpfi0jGauVtQZL FYbkgI1trQ7/kGvStj7XjW7rWSCsxpaXMBfe8Ul7Cmdx6yS5ByWbkAUQzgEZNE4ucseQT0xy kTPj97vHSZosrCeVTSa7Lj8hRO/PzIEa1ALYyAsRBEApdLkpekbjBjCU9JiG66dlcDuFHf7x DXikcQlr+xN14hRjfz9pA2ZxWL3znTUcuIrzivbeEmg7TFjXYuaeZ6kt3je0K1eF5nMGzFto 0M4s8SZ6ekPC7SEmyqMXPgBEdmV2hqVDNHPqQUxRsd8rlxB71bmJNkNu28meC+FJ+5eIVfUj FnvVRS9DXO5FF+jdudJbo24EKzGJoCwRI2+Bpg4gjejC6WdlTNrHgk0OyZ8PEi3yiDAdJ3T3 r/CKK6R4Y4yU/gP8dZPb751PUUX7i4/33jPYpvw0g6q17GTDFbMF+laawHRMbhovfrYyOkwz zq4H5LUoyizrcWkOnWHmWLtBQ1iwYcH6WDe9JUMK7/rzvtOE2A9Ef7BqY7NiKQ895m5Ytzgp yjlMnK0PXKl2hUr3y3WNS04AF4uNL4jxU8G0dsEZAj2iyN7Mdfxss/ytfIfJNEayQCq9tYsJ 9FtRilKKq0npujvk9jFUaTAkQ== IronPort-HdrOrdr: A9a23:9RKjeaiEwa2Sfx9CX3dWuqmBXHBQXtwji2hC6mlwRA09TySZ// rAoB19726StN9xYgBYpTnuAsi9qB/nmKKdpLNhX4tKPzOW3FdATrsD0WKK+VSJcEfDH6xmpM JdmsBFebvN5DNB4/oSjjPVLz9Z+qjlzJyV X-IronPort-AV: E=Sophos;i="5.95,232,1661832000"; d="scan'208";a="83996305" From: Anthony PERARD To: CC: Henry Wang , Anthony PERARD , Andrew Cooper , George Dunlap , Jan Beulich , Julien Grall , Stefano Stabellini , Wei Liu , Andrew Cooper Subject: [XEN PATCH for-4.17 4/4] Rework COPYING installed in /usr/include/xen/, due to several licences Date: Wed, 2 Nov 2022 11:28:54 +0000 Message-ID: <20221102112854.49020-5-anthony.perard@citrix.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20221102112854.49020-1-anthony.perard@citrix.com> References: <20221102112854.49020-1-anthony.perard@citrix.com> MIME-Version: 1.0 The notice in the COPYING file in "xen/include/public/COPYING" doesn't really apply to the files that ultimately are been install at "/usr/include/xen". The issue are headers in the "sys/" subdirectory that comes from other projects such as Linux or FreeBSD. The main issue is that there are two headers that have a different licence than the MIT licence: - xen-sys/Linux/gntalloc.h (installed as "sys/gntalloc.h") is public domain. - xen-sys/FreeBSD/gntdev.h (installed as "sys/gntdev.h") is BSD-2. To clarify this, we'll install a COPYING file with a different notice. Reported-by: Andrew Cooper Signed-off-by: Anthony PERARD --- Notes: CC: Andrew Cooper CC: George Dunlap CC: Jan Beulich CC: Julien Grall CC: Stefano Stabellini CC: Wei Liu tools/include/Makefile | 1 - tools/include/xen/COPYING | 26 ++++++++++++++++++++++++++ 2 files changed, 26 insertions(+), 1 deletion(-) create mode 100644 tools/include/xen/COPYING diff --git a/tools/include/Makefile b/tools/include/Makefile index 81c3d09039..f838171e8c 100644 --- a/tools/include/Makefile +++ b/tools/include/Makefile @@ -24,7 +24,6 @@ xen-foreign: xen-dir: mkdir -p xen/libelf acpi find xen/ acpi/ -type l -exec rm '{}' + - ln -s $(XEN_ROOT)/xen/include/public/COPYING xen/ ln -s $(XEN_ROOT)/xen/include/public/*.h xen/ ln -s $(XEN_ROOT)/xen/include/public/*/ xen/ ln -s ../xen-sys/$(XEN_OS) xen/sys diff --git a/tools/include/xen/COPYING b/tools/include/xen/COPYING new file mode 100644 index 0000000000..e54eb79832 --- /dev/null +++ b/tools/include/xen/COPYING @@ -0,0 +1,26 @@ +XEN NOTICE +========== + +This licence applies to all files within this subdirectory ("/usr/include/xen") +with the exception of "sys/" which may include an header under public domain or +BSD-2 licence. + +===================================================================== + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to +deal in the Software without restriction, including without limitation the +rights to use, copy, modify, merge, publish, distribute, sublicense, and/or +sell copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE.