Skip to contentSkip to conversation

xen: Update recipes for xen and xen-tools

PATCH RESEND Superseded Michal Orzel 2 participants 6 messages Jan 5, 2023 – Jan 6, 2023

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

cover xen: Update recipes for xen and xen-tools

This patch series:
- updates the 4.16 recipes to the latest 4.16.3 release,
- adds 4.17 recipes, fixes conflicts and updates master,
- bumps default version to 4.17.

Tested by building all the available Xen versions on qemu{arm64/x86-64} and running them using runqemu.

Note:
The first attempt to send a series resulted in not being delivered to the mailing list. This is the attempt after subscribing to the list.

Michal Orzel (3):
xen: Bump SRCREV of 4.16 recipes to 4.16.3
xen: Add recipes for stable Xen 4.17 release and update master
xen: Bump default version to 4.17 stable

 .../include/meta-virt-default-versions.inc    |   4 +-
 .../files/xen-fix-gcc12-build-issues.patch    | 433 ------------------
 recipes-extended/xen/xen-tools.inc            |   8 +
 recipes-extended/xen/xen-tools_4.16.bb        |   5 +-
 recipes-extended/xen/xen-tools_4.17.bb        |  19 +
 recipes-extended/xen/xen-tools_git.bb         |   8 +-
 recipes-extended/xen/xen_4.16.bb              |   5 +-
 recipes-extended/xen/xen_4.17.bb              |  19 +
 recipes-extended/xen/xen_git.bb               |   8 +-
 9 files changed, 60 insertions(+), 449 deletions(-)
 delete mode 100644 recipes-extended/xen/files/xen-fix-gcc12-build-issues.patch
 create mode 100644 recipes-extended/xen/xen-tools_4.17.bb
 create mode 100644 recipes-extended/xen/xen_4.17.bb
Signature · 1 line
2.25.1
#1 lore raw

PATCH RESEND 1/3 xen: Bump SRCREV of 4.16 recipes to 4.16.3

Update 4.16 recipes to use the latest 4.16.3 release. Also, remove the GCC 12 fix patch as it seems to be no longer needed.

---
 .../files/xen-fix-gcc12-build-issues.patch    | 433 ------------------
 recipes-extended/xen/xen-tools_4.16.bb        |   5 +-
 recipes-extended/xen/xen_4.16.bb              |   5 +-
 3 files changed, 4 insertions(+), 439 deletions(-)
 delete mode 100644 recipes-extended/xen/files/xen-fix-gcc12-build-issues.patch
recipes-extended/xen/files/xen-fix-gcc12-build-issues.patch deleted +0 -433
deleted file mode 100644
index 6cdd312db110..000000000000
@@ -1,433 +0,0 @@
-References: bsc#1196545
-
-Compiling against gcc12.
-
-Many of the failures are -Werror=array-bounds where macros
-from mm.h are being used. Common Examples are,
-include/asm/mm.h:528:61: error: array subscript 0 is outside array bounds of 'long unsigned int[0]' [-Werror=array-bounds]
-include/xen/mm.h:287:21: error: array subscript [0, 288230376151711743] is outside array bounds of 'struct page_info[0]' [-Werror=array-bounds]
-
-There are also several other headers that generate array-bounds macro failures.
-The pragmas to override are mostly in '.c' files with the exception of,
-xen/arch/x86/mm/shadow/private.h
-xen/include/asm-x86/paging.h
-
-[Upstream-Status: imported from: https://build.opensuse.org/package/view_file/openSUSE:Factory/xen/gcc12-fixes.patch?expand=1]
-
-Signed-off-by: Bruce Ashfield <[email protected]>
-
-
-Index: xen-4.16.1-testing/xen/drivers/passthrough/amd/iommu_intr.c
-===================================================================
---- xen-4.16.1-testing.orig/xen/drivers/passthrough/amd/iommu_intr.c
-+++ xen-4.16.1-testing/xen/drivers/passthrough/amd/iommu_intr.c
-@@ -23,6 +23,10 @@
- 
- #include "iommu.h"
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#endif
-+
- union irte32 {
-     uint32_t raw;
-     struct {
-Index: xen-4.16.1-testing/xen/drivers/passthrough/x86/hvm.c
-===================================================================
---- xen-4.16.1-testing.orig/xen/drivers/passthrough/x86/hvm.c
-+++ xen-4.16.1-testing/xen/drivers/passthrough/x86/hvm.c
-@@ -901,6 +901,9 @@ static void __hvm_dpci_eoi(struct domain
-     hvm_pirq_eoi(pirq);
- }
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Waddress"
-+#endif
- static void hvm_gsi_eoi(struct domain *d, unsigned int gsi)
- {
-     struct pirq *pirq = pirq_info(d, gsi);
-Index: xen-4.16.1-testing/xen/common/domctl.c
-===================================================================
---- xen-4.16.1-testing.orig/xen/common/domctl.c
-+++ xen-4.16.1-testing/xen/common/domctl.c
-@@ -32,6 +32,10 @@
- #include <public/domctl.h>
- #include <xsm/xsm.h>
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#endif
-+
- static DEFINE_SPINLOCK(domctl_lock);
- 
- static int nodemask_to_xenctl_bitmap(struct xenctl_bitmap *xenctl_nodemap,
-Index: xen-4.16.1-testing/xen/common/efi/boot.c
-===================================================================
---- xen-4.16.1-testing.orig/xen/common/efi/boot.c
-+++ xen-4.16.1-testing/xen/common/efi/boot.c
-@@ -31,6 +31,10 @@
- #undef __ASSEMBLY__
- #endif
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#endif
-+
- #define EFI_REVISION(major, minor) (((major) << 16) | (minor))
- 
- #define SMBIOS3_TABLE_GUID \
-Index: xen-4.16.1-testing/xen/common/xmalloc_tlsf.c
-===================================================================
---- xen-4.16.1-testing.orig/xen/common/xmalloc_tlsf.c
-+++ xen-4.16.1-testing/xen/common/xmalloc_tlsf.c
-@@ -28,6 +28,10 @@
- #include <xen/pfn.h>
- #include <asm/time.h>
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#endif
-+
- #define MAX_POOL_NAME_LEN       16
- 
- /* Some IMPORTANT TLSF parameters */
-Index: xen-4.16.1-testing/xen/common/memory.c
-===================================================================
---- xen-4.16.1-testing.orig/xen/common/memory.c
-+++ xen-4.16.1-testing/xen/common/memory.c
-@@ -35,6 +35,10 @@
- #include <asm/guest.h>
- #endif
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#endif
-+
- struct memop_args {
-     /* INPUT */
-     struct domain *domain;     /* Domain to be affected. */
-Index: xen-4.16.1-testing/xen/common/page_alloc.c
-===================================================================
---- xen-4.16.1-testing.orig/xen/common/page_alloc.c
-+++ xen-4.16.1-testing/xen/common/page_alloc.c
-@@ -155,6 +155,10 @@
- #define PGC_reserved 0
- #endif
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#endif
-+
- /*
-  * Comma-separated list of hexadecimal page numbers containing bad bytes.
-  * e.g. 'badpage=0x3f45,0x8a321'.
-@@ -1529,6 +1533,7 @@ static void free_heap_pages(
- }
- 
- 
-+
- /*
-  * Following rules applied for page offline:
-  * Once a page is broken, it can't be assigned anymore
-Index: xen-4.16.1-testing/xen/common/vmap.c
-===================================================================
---- xen-4.16.1-testing.orig/xen/common/vmap.c
-+++ xen-4.16.1-testing/xen/common/vmap.c
-@@ -9,6 +9,10 @@
- #include <xen/vmap.h>
- #include <asm/page.h>
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#endif
-+
- static DEFINE_SPINLOCK(vm_lock);
- static void *__read_mostly vm_base[VMAP_REGION_NR];
- #define vm_bitmap(x) ((unsigned long *)vm_base[x])
-Index: xen-4.16.1-testing/xen/include/asm-x86/paging.h
-===================================================================
---- xen-4.16.1-testing.orig/xen/include/asm-x86/paging.h
-+++ xen-4.16.1-testing/xen/include/asm-x86/paging.h
-@@ -32,6 +32,10 @@
- #include <asm/flushtlb.h>
- #include <asm/domain.h>
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#endif
-+
- /*****************************************************************************
-  * Macros to tell which paging mode a domain is in */
- 
-Index: xen-4.16.1-testing/xen/arch/x86/x86_64/traps.c
-===================================================================
---- xen-4.16.1-testing.orig/xen/arch/x86/x86_64/traps.c
-+++ xen-4.16.1-testing/xen/arch/x86/x86_64/traps.c
-@@ -25,6 +25,9 @@
- #include <asm/hvm/hvm.h>
- #include <asm/hvm/support.h>
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#endif
- 
- static void print_xen_info(void)
- {
-Index: xen-4.16.1-testing/xen/arch/x86/cpu/mcheck/mcaction.c
-===================================================================
---- xen-4.16.1-testing.orig/xen/arch/x86/cpu/mcheck/mcaction.c
-+++ xen-4.16.1-testing/xen/arch/x86/cpu/mcheck/mcaction.c
-@@ -4,6 +4,10 @@
- #include "vmce.h"
- #include "mce.h"
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#endif
-+
- static struct mcinfo_recovery *
- mci_action_add_pageoffline(int bank, struct mc_info *mi,
-                            mfn_t mfn, uint32_t status)
-Index: xen-4.16.1-testing/xen/arch/x86/cpu/mcheck/mce.c
-===================================================================
---- xen-4.16.1-testing.orig/xen/arch/x86/cpu/mcheck/mce.c
-+++ xen-4.16.1-testing/xen/arch/x86/cpu/mcheck/mce.c
-@@ -30,6 +30,10 @@
- #include "util.h"
- #include "vmce.h"
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#endif
-+
- bool __read_mostly opt_mce = true;
- boolean_param("mce", opt_mce);
- bool __read_mostly mce_broadcast;
-Index: xen-4.16.1-testing/xen/arch/x86/hvm/hvm.c
-===================================================================
---- xen-4.16.1-testing.orig/xen/arch/x86/hvm/hvm.c
-+++ xen-4.16.1-testing/xen/arch/x86/hvm/hvm.c
-@@ -81,6 +81,10 @@
- 
- #include <compat/hvm/hvm_op.h>
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#endif
-+
- bool_t __read_mostly hvm_enabled;
- 
- #ifdef DBG_LEVEL_0
-Index: xen-4.16.1-testing/xen/arch/x86/pv/dom0_build.c
-===================================================================
---- xen-4.16.1-testing.orig/xen/arch/x86/pv/dom0_build.c
-+++ xen-4.16.1-testing/xen/arch/x86/pv/dom0_build.c
-@@ -22,6 +22,10 @@
- #include <asm/pv/mm.h>
- #include <asm/setup.h>
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#endif
-+
- /* Allow ring-3 access in long mode as guest cannot use ring 1 ... */
- #define BASE_PROT (_PAGE_PRESENT|_PAGE_RW|_PAGE_ACCESSED|_PAGE_USER)
- #define L1_PROT (BASE_PROT|_PAGE_GUEST_KERNEL)
-Index: xen-4.16.1-testing/xen/arch/x86/pv/ro-page-fault.c
-===================================================================
---- xen-4.16.1-testing.orig/xen/arch/x86/pv/ro-page-fault.c
-+++ xen-4.16.1-testing/xen/arch/x86/pv/ro-page-fault.c
-@@ -26,6 +26,10 @@
- #include "emulate.h"
- #include "mm.h"
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#endif
-+
- /*********************
-  * Writable Pagetables
-  */
-Index: xen-4.16.1-testing/xen/arch/x86/pv/emul-priv-op.c
-===================================================================
---- xen-4.16.1-testing.orig/xen/arch/x86/pv/emul-priv-op.c
-+++ xen-4.16.1-testing/xen/arch/x86/pv/emul-priv-op.c
-@@ -40,6 +40,10 @@
- #include "emulate.h"
- #include "mm.h"
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#endif
-+
- struct priv_op_ctxt {
-     struct x86_emulate_ctxt ctxt;
-     struct {
-Index: xen-4.16.1-testing/xen/arch/x86/pv/mm.c
-===================================================================
---- xen-4.16.1-testing.orig/xen/arch/x86/pv/mm.c
-+++ xen-4.16.1-testing/xen/arch/x86/pv/mm.c
-@@ -26,6 +26,10 @@
- 
- #include "mm.h"
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#endif
-+
- /*
-  * Get a mapping of a PV guest's l1e for this linear address.  The return
-  * pointer should be unmapped using unmap_domain_page().
-Index: xen-4.16.1-testing/xen/arch/x86/domain_page.c
-===================================================================
---- xen-4.16.1-testing.orig/xen/arch/x86/domain_page.c
-+++ xen-4.16.1-testing/xen/arch/x86/domain_page.c
-@@ -18,6 +18,10 @@
- #include <asm/hardirq.h>
- #include <asm/setup.h>
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#endif
-+
- static DEFINE_PER_CPU(struct vcpu *, override);
- 
- static inline struct vcpu *mapcache_current_vcpu(void)
-Index: xen-4.16.1-testing/xen/arch/x86/mm/shadow/private.h
-===================================================================
---- xen-4.16.1-testing.orig/xen/arch/x86/mm/shadow/private.h
-+++ xen-4.16.1-testing/xen/arch/x86/mm/shadow/private.h
-@@ -33,6 +33,10 @@
- 
- #include "../mm-locks.h"
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#endif
-+
- /******************************************************************************
-  * Levels of self-test and paranoia
-  */
-Index: xen-4.16.1-testing/xen/arch/x86/mm/hap/hap.c
-===================================================================
---- xen-4.16.1-testing.orig/xen/arch/x86/mm/hap/hap.c
-+++ xen-4.16.1-testing/xen/arch/x86/mm/hap/hap.c
-@@ -42,6 +42,10 @@
- 
- #include "private.h"
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#endif
-+
- /************************************************/
- /*          HAP VRAM TRACKING SUPPORT           */
- /************************************************/
-Index: xen-4.16.1-testing/xen/arch/x86/mm/p2m-pod.c
-===================================================================
---- xen-4.16.1-testing.orig/xen/arch/x86/mm/p2m-pod.c
-+++ xen-4.16.1-testing/xen/arch/x86/mm/p2m-pod.c
-@@ -31,6 +31,10 @@
- 
- #include "mm-locks.h"
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#endif
-+
- #define superpage_aligned(_x)  (((_x)&(SUPERPAGE_PAGES-1))==0)
- 
- /* Enforce lock ordering when grabbing the "external" page_alloc lock */
-Index: xen-4.16.1-testing/xen/arch/x86/mm/p2m-ept.c
-===================================================================
---- xen-4.16.1-testing.orig/xen/arch/x86/mm/p2m-ept.c
-+++ xen-4.16.1-testing/xen/arch/x86/mm/p2m-ept.c
-@@ -36,6 +36,10 @@
- 
- #include "mm-locks.h"
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#endif
-+
- #define atomic_read_ept_entry(__pepte)                              \
-     ( (ept_entry_t) { .epte = read_atomic(&(__pepte)->epte) } )
- 
-Index: xen-4.16.1-testing/xen/arch/x86/mm/p2m.c
-===================================================================
---- xen-4.16.1-testing.orig/xen/arch/x86/mm/p2m.c
-+++ xen-4.16.1-testing/xen/arch/x86/mm/p2m.c
-@@ -44,6 +44,10 @@
- 
- #include "mm-locks.h"
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#endif
-+
- /* Override macro from asm/page.h to make work with mfn_t */
- #undef virt_to_mfn
- #define virt_to_mfn(v) _mfn(__virt_to_mfn(v))
-Index: xen-4.16.1-testing/xen/arch/x86/tboot.c
-===================================================================
---- xen-4.16.1-testing.orig/xen/arch/x86/tboot.c
-+++ xen-4.16.1-testing/xen/arch/x86/tboot.c
-@@ -16,6 +16,10 @@
- #include <asm/setup.h>
- #include <crypto/vmac.h>
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#endif
-+
- /* tboot=<physical address of shared page> */
- static unsigned long __initdata opt_tboot_pa;
- integer_param("tboot", opt_tboot_pa);
-Index: xen-4.16.1-testing/tools/firmware/hvmloader/ovmf.c
-===================================================================
---- xen-4.16.1-testing.orig/tools/firmware/hvmloader/ovmf.c
-+++ xen-4.16.1-testing/tools/firmware/hvmloader/ovmf.c
-@@ -34,6 +34,11 @@
- #include <xen/hvm/ioreq.h>
- #include <xen/memory.h>
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#pragma GCC diagnostic ignored "-Wstringop-overflow"
-+#endif
-+
- #define OVMF_MAXOFFSET          0x000FFFFFULL
- #define OVMF_END                0x100000000ULL
- #define LOWCHUNK_BEGIN          0x000F0000
-Index: xen-4.16.1-testing/tools/firmware/hvmloader/seabios.c
-===================================================================
---- xen-4.16.1-testing.orig/tools/firmware/hvmloader/seabios.c
-+++ xen-4.16.1-testing/tools/firmware/hvmloader/seabios.c
-@@ -29,6 +29,11 @@
- #include <acpi2_0.h>
- #include <libacpi.h>
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#pragma GCC diagnostic ignored "-Wstringop-overflow"
-+#endif
-+
- struct seabios_info {
-     char signature[14]; /* XenHVMSeaBIOS\0 */
-     uint8_t length;     /* Length of this struct */
-Index: xen-4.16.1-testing/tools/firmware/hvmloader/util.c
-===================================================================
---- xen-4.16.1-testing.orig/tools/firmware/hvmloader/util.c
-+++ xen-4.16.1-testing/tools/firmware/hvmloader/util.c
-@@ -31,6 +31,10 @@
- #include <xen/hvm/hvm_xs_strings.h>
- #include <xen/hvm/params.h>
- 
-+#if __GNUC__ >= 12
-+#pragma GCC diagnostic ignored "-Warray-bounds"
-+#endif
-+
- /*
-  * Check whether there exists overlap in the specified memory range.
-  * Returns true if exists, else returns false.
-
recipes-extended/xen/xen-tools_4.16.bb +2 -3
index 2200a5a44abe..b5e555e6eabb 100644
@@ -1,5 +1,5 @@
-# xen 4.16.2 release sha
-SRCREV ?= "cea5ed49bb5716698a11312a3f38bc8865cd1e67"
+# xen 4.16.3 release sha
+SRCREV ?= "556c2e817c9cf23b675eb4eaa2dc091f7bb3039f"
 
 XEN_REL ?= "4.16"
 XEN_BRANCH ?= "stable-${XEN_REL}"
@@ -7,7 +7,6 @@ XEN_BRANCH ?= "stable-${XEN_REL}"
 SRC_URI = " \
     git://xenbits.xen.org/xen.git;branch=${XEN_BRANCH} \
     file://0001-python-pygrub-pass-DISTUTILS-xen-4.15.patch \
-    file://xen-fix-gcc12-build-issues.patch \
     "
 
 LIC_FILES_CHKSUM ?= "file://COPYING;md5=419739e325a50f3d7b4501338e44a4e5"
recipes-extended/xen/xen_4.16.bb +2 -3
index 70e1d70e9c29..14a4fa79c5dd 100644
@@ -1,5 +1,5 @@
-# xen 4.16.2 release sha
-SRCREV ?= "cea5ed49bb5716698a11312a3f38bc8865cd1e67"
+# xen 4.16.3 release sha
+SRCREV ?= "556c2e817c9cf23b675eb4eaa2dc091f7bb3039f"
 
 XEN_REL ?= "4.16"
 XEN_BRANCH ?= "stable-${XEN_REL}"
@@ -7,7 +7,6 @@ XEN_BRANCH ?= "stable-${XEN_REL}"
 SRC_URI = " \
     git://xenbits.xen.org/xen.git;branch=${XEN_BRANCH} \
     file://0001-menuconfig-mconf-cfg-Allow-specification-of-ncurses-location.patch \
-    file://xen-fix-gcc12-build-issues.patch \ 
     "
 
 LIC_FILES_CHKSUM ?= "file://COPYING;md5=419739e325a50f3d7b4501338e44a4e5"
Signature · 1 line
2.25.1
#2 lore raw

PATCH RESEND 2/3 xen: Add recipes for stable Xen 4.17 release and update master

In reply to Michal Orzel

Add recipes for xen and tools for the newly released 4.17 version and take the opportunity to update master recipes.

Reflect 4.17 tools changes in xen-tools.inc:
- add test-paging-mempool to test package,
- add a new package init-dom0less that contains init-dom0less script,
- add localstatedir to dev package.

---
Adding localstatedir to dev package is a little quirk just to keep the old behavior unchanged and silence Yocto installed-but-not-shipped error. The reason being, 4.17 onwards removed /var/lib/xenstored as it is mostly unused. This leaves the build with empty /var and /var/lib. There are other possible ways to handle this problem. We could remove the complete localstatedir while removing installed volatiles or add some checks for the version. Suggestions are welcomed.

---
 recipes-extended/xen/xen-tools.inc     |  8 ++++++++
 recipes-extended/xen/xen-tools_4.17.bb | 19 +++++++++++++++++++
 recipes-extended/xen/xen-tools_git.bb  |  8 ++++----
 recipes-extended/xen/xen_4.17.bb       | 19 +++++++++++++++++++
 recipes-extended/xen/xen_git.bb        |  8 ++++----
 5 files changed, 54 insertions(+), 8 deletions(-)
 create mode 100644 recipes-extended/xen/xen-tools_4.17.bb
 create mode 100644 recipes-extended/xen/xen_4.17.bb
recipes-extended/xen/xen-tools.inc +8 -0
index d47309a72b1c..1a422255014e 100644
@@ -212,6 +212,7 @@ PACKAGES = " \
     ${PN}-test \
     ${PN}-xen-vmtrace \
     ${PN}-xen-mceinj \
+    ${PN}-init-dom0less \
     "
 
 PROVIDES =+ " \
@@ -245,6 +246,7 @@ FILES:${PN}-dbg += "\
 
 FILES:${PN}-dev = "\
     ${includedir} \
+    ${localstatedir} \
     "
 
 FILES:${PN}-doc = "\
@@ -688,6 +690,7 @@ FILES:${PN}-test += "\
     ${libdir}/xen/bin/test-resource \
     ${libdir}/xen/bin/test-cpu-policy \
     ${libdir}/xen/bin/test-tsx \
+    ${libdir}/xen/bin/test-paging-mempool \
     "
 
 # test-xenstore and test-resource currently only exist in 4.16
@@ -708,6 +711,11 @@ FILES:${PN}-xen-vmtrace +="\
 # xen-vmtrace is only built for x86 4.16, so allow empty package
 ALLOW_EMPTY:${PN}-xen-vmtrace = "1"
 
+FILES:${PN}-init-dom0less += "${libdir}/xen/bin/init-dom0less"
+
+# init-dom0less is only built for Arm 4.17, so allow empty package
+ALLOW_EMPTY:${PN}-init-dom0less = "1"
+
 INSANE_SKIP:${PN} = "already-stripped"
 
 # configure init.d scripts
recipes-extended/xen/xen-tools_4.17.bb new file +19 -0
new file mode 100644
index 000000000000..0f323cb32aac
@@ -0,0 +1,19 @@
+# xen 4.17.0 release sha
+SRCREV ?= "11560248ffda3f00f20bbdf3ae088af474f7f2a3"
+
+XEN_REL ?= "4.17"
+XEN_BRANCH ?= "stable-${XEN_REL}"
+
+SRC_URI = " \
+    git://xenbits.xen.org/xen.git;branch=${XEN_BRANCH} \
+    file://0001-python-pygrub-pass-DISTUTILS-xen-4.15.patch \
+    "
+
+LIC_FILES_CHKSUM ?= "file://COPYING;md5=d1a1e216f80b6d8da95fec897d0dbec9"
+
+PV = "${XEN_REL}+stable${SRCPV}"
+
+S = "${WORKDIR}/git"
+
+require xen.inc
+require xen-tools.inc
recipes-extended/xen/xen-tools_git.bb +4 -4
index a450a7d6574a..fd42cf2963b4 100644
@@ -1,7 +1,7 @@
-# master status on 2022-04-05
-SRCREV ?= "14dd241aad8af447680ac73e8579990e2c09c1e7"
+# master status on 2022-12-29
+SRCREV ?= "7eef80e06ed2282bbcec3619d860c6aacb0515d8"
 
-XEN_REL ?= "4.17"
+XEN_REL ?= "4.18"
 XEN_BRANCH ?= "master"
 
 SRC_URI = " \
@@ -9,7 +9,7 @@ SRC_URI = " \
     file://0001-python-pygrub-pass-DISTUTILS-xen-4.15.patch \
     "
 
-LIC_FILES_CHKSUM ?= "file://COPYING;md5=419739e325a50f3d7b4501338e44a4e5"
+LIC_FILES_CHKSUM ?= "file://COPYING;md5=d1a1e216f80b6d8da95fec897d0dbec9"
 
 PV = "${XEN_REL}+git${SRCPV}"
 
recipes-extended/xen/xen_4.17.bb new file +19 -0
new file mode 100644
index 000000000000..f35689d4120f
@@ -0,0 +1,19 @@
+# xen 4.17.0 release sha
+SRCREV ?= "11560248ffda3f00f20bbdf3ae088af474f7f2a3"
+
+XEN_REL ?= "4.17"
+XEN_BRANCH ?= "stable-${XEN_REL}"
+
+SRC_URI = " \
+    git://xenbits.xen.org/xen.git;branch=${XEN_BRANCH} \
+    file://0001-menuconfig-mconf-cfg-Allow-specification-of-ncurses-location.patch \
+    "
+
+LIC_FILES_CHKSUM ?= "file://COPYING;md5=d1a1e216f80b6d8da95fec897d0dbec9"
+
+PV = "${XEN_REL}+stable${SRCPV}"
+
+S = "${WORKDIR}/git"
+
+require xen.inc
+require xen-hypervisor.inc
recipes-extended/xen/xen_git.bb +4 -4
index ebd1b76ff420..2138424406f9 100644
@@ -1,7 +1,7 @@
-# master status on 2022-04-05
-SRCREV ?= "14dd241aad8af447680ac73e8579990e2c09c1e7"
+# master status on 2022-12-29
+SRCREV ?= "7eef80e06ed2282bbcec3619d860c6aacb0515d8"
 
-XEN_REL ?= "4.17"
+XEN_REL ?= "4.18"
 XEN_BRANCH ?= "master"
 
 SRC_URI = " \
@@ -9,7 +9,7 @@ SRC_URI = " \
     file://0001-menuconfig-mconf-cfg-Allow-specification-of-ncurses-location.patch \
     "
 
-LIC_FILES_CHKSUM ?= "file://COPYING;md5=419739e325a50f3d7b4501338e44a4e5"
+LIC_FILES_CHKSUM ?= "file://COPYING;md5=d1a1e216f80b6d8da95fec897d0dbec9"
 
 PV = "${XEN_REL}+git${SRCPV}"
 
Signature · 1 line
2.25.1
#3 lore raw

Re: [PATCH 2/3 RESEND] xen: Add recipes for stable Xen 4.17 release and update master

Quoted 3 lines · Michal Orzel

Add recipes for xen and tools for the newly released 4.17 version and take the opportunity to update master recipes.

Thanks for taking this on, Michal.

Quoted 5 lines

Reflect 4.17 tools changes in xen-tools.inc:
- add test-paging-mempool to test package,
- add a new package init-dom0less that contains init-dom0less script,

This tool requires control domain privileges and it depends upon several Xen libraries including libxl, so would it be better to just include in the standard xl package, alongside the existing xen-init-dom0?

If it does belong in a new separate package, would it make sense for any of the existing packages to RRECOMMEND it, to ensure that it gets installed where it is expected to be present?

Quoted 2 lines

- add localstatedir to dev package.

(I've replied to your comment about localstatedir below.)

Quoted 12 lines

---
Adding localstatedir to dev package is a little quirk just to keep the old behavior unchanged and silence Yocto installed-but-not-shipped error. The reason being, 4.17 onwards removed /var/lib/xenstored as it is mostly unused. This leaves the build with empty /var and /var/lib. There are other possible ways to handle this problem. We could remove the complete localstatedir
while removing installed volatiles or add some checks for the version. Suggestions are welcomed.

In the same xen-tools.inc file, there is a reference to var-lib-xenstored in the SYSTEMD_SERVICE declaration for the xencommons package, so: would it make more sense to add localstatedir to xencommons, which is typically installed in the control domain, rather than the dev package, which is not? That should handle the case where there does happen to be a runtime dependency in the Xen tools on the presence of a /var/lib directory.

Quoted 40 lines
---
 recipes-extended/xen/xen-tools.inc     |  8 ++++++++
 recipes-extended/xen/xen-tools_4.17.bb | 19 +++++++++++++++++++
 recipes-extended/xen/xen-tools_git.bb  |  8 ++++----
 recipes-extended/xen/xen_4.17.bb       | 19 +++++++++++++++++++
 recipes-extended/xen/xen_git.bb        |  8 ++++----
 5 files changed, 54 insertions(+), 8 deletions(-)
 create mode 100644 recipes-extended/xen/xen-tools_4.17.bb
 create mode 100644 recipes-extended/xen/xen_4.17.bb
recipes-extended/xen/xen-tools.inc +3 -0
index d47309a72b1c..1a422255014e 100644
@@ -212,6 +212,7 @@ PACKAGES = " \
     ${PN}-test \
     ${PN}-xen-vmtrace \
     ${PN}-xen-mceinj \
+    ${PN}-init-dom0less \
     "
 
 PROVIDES =+ " \
@@ -245,6 +246,7 @@ FILES:${PN}-dbg += "\
 
 FILES:${PN}-dev = "\
     ${includedir} \
+    ${localstatedir} \
     "
 
 FILES:${PN}-doc = "\
@@ -688,6 +690,7 @@ FILES:${PN}-test += "\
     ${libdir}/xen/bin/test-resource \
     ${libdir}/xen/bin/test-cpu-policy \
     ${libdir}/xen/bin/test-tsx \
+    ${libdir}/xen/bin/test-paging-mempool \
     "
 
 # test-xenstore and test-resource currently only exist in 4.16

recipes-extended/xen/xen-tools.inc FILES:${PN}-xen-vmtrace +="\ · line 715

Quoted 5 lines
recipes-extended/xen/xen-tools.inc +1 -0
@@ -708,6 +711,11 @@ FILES:${PN}-xen-vmtrace +="\
 # xen-vmtrace is only built for x86 4.16, so allow empty package
 ALLOW_EMPTY:${PN}-xen-vmtrace = "1"
 
+FILES:${PN}-init-dom0less += "${libdir}/xen/bin/init-dom0less"
 

All the existing FILES:${PN} definitions are sorted alphabetically, so when adding a new one, please could you insert it at the correct point -- which would be after FILES:${PN}-hvmloader in this case.

thanks,
Christopher

Quoted 119 lines
recipes-extended/xen/xen-tools.inc +4 -0
+
+# init-dom0less is only built for Arm 4.17, so allow empty package
+ALLOW_EMPTY:${PN}-init-dom0less = "1"
+
 INSANE_SKIP:${PN} = "already-stripped"
 
 # configure init.d scripts
recipes-extended/xen/xen-tools_4.17.bb new file +8 -0
new file mode 100644
index 000000000000..0f323cb32aac
@@ -0,0 +1,19 @@
+# xen 4.17.0 release sha
+SRCREV ?= "11560248ffda3f00f20bbdf3ae088af474f7f2a3"
+
+XEN_REL ?= "4.17"
+XEN_BRANCH ?= "stable-${XEN_REL}"
+
+SRC_URI = " \
+    git://xenbits.xen.org/xen.git;branch=${XEN_BRANCH}

<http://xenbits.xen.org/xen.git;branch=$%7BXEN_BRANCH%7D> \

recipes-extended/xen/xen-tools_4.17.bb new file +11 -0
+    file://0001-python-pygrub-pass-DISTUTILS-xen-4.15.patch \
+    "
+
+LIC_FILES_CHKSUM ?= "file://COPYING;md5=d1a1e216f80b6d8da95fec897d0dbec9"
+
+PV = "${XEN_REL}+stable${SRCPV}"
+
+S = "${WORKDIR}/git"
+
+require xen.inc
+require xen-tools.inc
recipes-extended/xen/ renamed from recipes-extended/xen/xen-tools_git.bb +0 -0

xen-tools_git.bb
index a450a7d6574a..fd42cf2963b4 100644

recipes-extended/xen/xen-tools_git.bb +4 -4
@@ -1,7 +1,7 @@
-# master status on 2022-04-05
-SRCREV ?= "14dd241aad8af447680ac73e8579990e2c09c1e7"
+# master status on 2022-12-29
+SRCREV ?= "7eef80e06ed2282bbcec3619d860c6aacb0515d8"
 
-XEN_REL ?= "4.17"
+XEN_REL ?= "4.18"
 XEN_BRANCH ?= "master"
 
 SRC_URI = " \
@@ -9,7 +9,7 @@ SRC_URI = " \
     file://0001-python-pygrub-pass-DISTUTILS-xen-4.15.patch \
     "
 
-LIC_FILES_CHKSUM ?= "file://COPYING;md5=419739e325a50f3d7b4501338e44a4e5"
+LIC_FILES_CHKSUM ?= "file://COPYING;md5=d1a1e216f80b6d8da95fec897d0dbec9"
 
 PV = "${XEN_REL}+git${SRCPV}"
 
recipes-extended/xen/ renamed from recipes-extended/xen/xen_4.17.bb +0 -0

xen_4.17.bb
new file mode 100644
index 000000000000..f35689d4120f

recipes-extended/xen/xen_4.17.bb new file +8 -0
@@ -0,0 +1,19 @@
+# xen 4.17.0 release sha
+SRCREV ?= "11560248ffda3f00f20bbdf3ae088af474f7f2a3"
+
+XEN_REL ?= "4.17"
+XEN_BRANCH ?= "stable-${XEN_REL}"
+
+SRC_URI = " \
+    git://xenbits.xen.org/xen.git;branch=${XEN_BRANCH}

<http://xenbits.xen.org/xen.git;branch=$%7BXEN_BRANCH%7D> \
+ file://0001-menuconfig-mconf-cfg-Allow-specification-of-ncurses-location.patch \

recipes-extended/xen/xen_4.17.bb new file +10 -0
+    "
+
+LIC_FILES_CHKSUM ?= "file://COPYING;md5=d1a1e216f80b6d8da95fec897d0dbec9"
+
+PV = "${XEN_REL}+stable${SRCPV}"
+
+S = "${WORKDIR}/git"
+
+require xen.inc
+require xen-hypervisor.inc
recipes-extended/xen/ renamed from recipes-extended/xen/xen_git.bb +0 -0

xen_git.bb
index ebd1b76ff420..2138424406f9 100644

recipes-extended/xen/xen_git.bb +4 -4
@@ -1,7 +1,7 @@
-# master status on 2022-04-05
-SRCREV ?= "14dd241aad8af447680ac73e8579990e2c09c1e7"
+# master status on 2022-12-29
+SRCREV ?= "7eef80e06ed2282bbcec3619d860c6aacb0515d8"
 
-XEN_REL ?= "4.17"
+XEN_REL ?= "4.18"
 XEN_BRANCH ?= "master"
 
 SRC_URI = " \
@@ -9,7 +9,7 @@ SRC_URI = " \
 
 file://0001-menuconfig-mconf-cfg-Allow-specification-of-ncurses-location.patch
 \
     "
 
-LIC_FILES_CHKSUM ?= "file://COPYING;md5=419739e325a50f3d7b4501338e44a4e5"
+LIC_FILES_CHKSUM ?= "file://COPYING;md5=d1a1e216f80b6d8da95fec897d0dbec9"
 

PV = "${XEN_REL}+git${SRCPV}"

--
2.25.1

#4 lore raw

Re: [PATCH 2/3 RESEND] xen: Add recipes for stable Xen 4.17 release and update master

Hi Chris,

Quoted 14 lines · Christopher Clark

On Thu, Jan 5, 2023 at 5:54 AM Michal Orzel <[email protected] <mailto:[email protected]>> wrote:

Add recipes for xen and tools for the newly released 4.17 version and take the opportunity to update master recipes.

Thanks for taking this on, Michal.

Quoted 6 lines

Reflect 4.17 tools changes in xen-tools.inc:
 - add test-paging-mempool to test package,
 - add a new package init-dom0less that contains init-dom0less script,

This tool requires control domain privileges and it depends upon several Xen libraries including libxl, so would it be better to just include in the standard xl package, alongside the existing xen-init-dom0?

Yes, this would look better to be present next to xen-init-dom0. I will add this into ${PN}-xl.

Quoted 22 lines

If it does belong in a new separate package, would it make sense for any of the existing packages to RRECOMMEND it, to ensure that it gets installed where it is expected to be present?

 - add localstatedir to dev package.

(I've replied to your comment about localstatedir below.)

Signed-off-by Michal Orzel <[email protected] <mailto:[email protected]>>

---
Adding localstatedir to dev package is a little quirk just to keep the old behavior unchanged and silence Yocto installed-but-not-shipped error. The reason being, 4.17 onwards removed /var/lib/xenstored as it is mostly unused. This leaves the build with empty /var and /var/lib. There are other possible ways to handle this problem. We could remove the complete localstatedir while removing installed volatiles or add some checks for the version. Suggestions are welcomed.

Quoted 1 line

In the same xen-tools.inc file, there is a reference to var-lib-xenstored in the SYSTEMD_SERVICE declaration for the xencommons package, so: would it make more sense to add localstatedir to xencommons, which is typically installed in the control domain, rather than the dev package, which is not? That should handle the case where there does happen to be a runtime dependency in the Xen tools on the presence of a /var/lib directory.

Sounds good to me. I will add this into ${PN}-xencommons where var-lib-xenstored.mount already is.

Quoted 48 lines

    ---
     recipes-extended/xen/xen-tools.inc     |  8 ++++++++
     recipes-extended/xen/xen-tools_4.17.bb <https://nam11.safelinks.protection.outlook.com/?url=http%3A%2F%2Fxen-tools_4.17.bb%2F&data=05%7C01%7Cmichal.orzel%40amd.com%7Cbcb1629273014bb2320e08daefb64d1b%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C638085863517570625%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=M1xgeAw3kTynautLaKMyx07D0ZbwMK2MyODbBzqz1WQ%3D&reserved=0> | 19 +++++++++++++++++++
     recipes-extended/xen/xen-tools_git.bb <https://nam11.safelinks.protection.outlook.com/?url=http%3A%2F%2Fxen-tools_git.bb%2F&data=05%7C01%7Cmichal.orzel%40amd.com%7Cbcb1629273014bb2320e08daefb64d1b%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C638085863517570625%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=6%2F80CN3U7TxiL1oda%2FwqNL6Whbg2ogQDEkCJaRoZL%2BE%3D&reserved=0>  |  8 ++++----
     recipes-extended/xen/xen_4.17.bb <https://nam11.safelinks.protection.outlook.com/?url=http%3A%2F%2Fxen_4.17.bb%2F&data=05%7C01%7Cmichal.orzel%40amd.com%7Cbcb1629273014bb2320e08daefb64d1b%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C638085863517570625%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=o5Fa47Bd89zLwAFQDj4ahsnt%2FXOYs9%2F%2BimHJHb7PC0s%3D&reserved=0>       | 19 +++++++++++++++++++
     recipes-extended/xen/xen_git.bb <https://nam11.safelinks.protection.outlook.com/?url=http%3A%2F%2Fxen_git.bb%2F&data=05%7C01%7Cmichal.orzel%40amd.com%7Cbcb1629273014bb2320e08daefb64d1b%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C638085863517570625%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=x0xaDPMAK6HZS2oGP2FRouM6hoA7NZrJMdtVinzhtbg%3D&reserved=0>        |  8 ++++----
     5 files changed, 54 insertions(+), 8 deletions(-)
     create mode 100644 recipes-extended/xen/xen-tools_4.17.bb <https://nam11.safelinks.protection.outlook.com/?url=http%3A%2F%2Fxen-tools_4.17.bb%2F&data=05%7C01%7Cmichal.orzel%40amd.com%7Cbcb1629273014bb2320e08daefb64d1b%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C638085863517570625%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=M1xgeAw3kTynautLaKMyx07D0ZbwMK2MyODbBzqz1WQ%3D&reserved=0>
     create mode 100644 recipes-extended/xen/xen_4.17.bb <https://nam11.safelinks.protection.outlook.com/?url=http%3A%2F%2Fxen_4.17.bb%2F&data=05%7C01%7Cmichal.orzel%40amd.com%7Cbcb1629273014bb2320e08daefb64d1b%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C638085863517570625%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=o5Fa47Bd89zLwAFQDj4ahsnt%2FXOYs9%2F%2BimHJHb7PC0s%3D&reserved=0>

    diff --git a/recipes-extended/xen/xen-tools.inc b/recipes-extended/xen/xen-tools.inc
    index d47309a72b1c..1a422255014e 100644
    --- a/recipes-extended/xen/xen-tools.inc
    +++ b/recipes-extended/xen/xen-tools.inc
    @@ -212,6 +212,7 @@ PACKAGES = " \
         ${PN}-test \
         ${PN}-xen-vmtrace \
         ${PN}-xen-mceinj \
    +    ${PN}-init-dom0less \
         "

     PROVIDES =+ " \
    @@ -245,6 +246,7 @@ FILES:${PN}-dbg += "\

     FILES:${PN}-dev = "\
         ${includedir} \
    +    ${localstatedir} \
         "

     FILES:${PN}-doc = "\
    @@ -688,6 +690,7 @@ FILES:${PN}-test += "\
         ${libdir}/xen/bin/test-resource \
         ${libdir}/xen/bin/test-cpu-policy \
         ${libdir}/xen/bin/test-tsx \
    +    ${libdir}/xen/bin/test-paging-mempool \
         "

     # test-xenstore and test-resource currently only exist in 4.16
    @@ -708,6 +711,11 @@ FILES:${PN}-xen-vmtrace +="\
     # xen-vmtrace is only built for x86 4.16, so allow empty package
     ALLOW_EMPTY:${PN}-xen-vmtrace = "1"

    +FILES:${PN}-init-dom0less += "${libdir}/xen/bin/init-dom0less"
Quoted 1 line

All the existing FILES:${PN} definitions are sorted alphabetically, so when adding a new one, please could you insert it at the correct point -- which would be after FILES:${PN}-hvmloader in this case.

There will be no need for that as there will be no new package for init-dom0less.

Quoted 4 lines

thanks,
Christopher

I will send a v2 today with the remarks handled.

~Michal

#5 lore raw

PATCH RESEND 3/3 xen: Bump default version to 4.17 stable

In reply to Michal Orzel
---
 conf/distro/include/meta-virt-default-versions.inc | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
conf/distro/include/meta-virt-default-versions.inc +2 -2
index b2ce0210c05c..388eca90bed4 100644
@@ -1,4 +1,4 @@
 # Meta-virtuailization PREFERED_VERSION
 
-PREFERRED_VERSION_xen ?= "4.16+stable%"
-PREFERRED_VERSION_xen-tools ?= "4.16+stable%"
+PREFERRED_VERSION_xen ?= "4.17+stable%"
+PREFERRED_VERSION_xen-tools ?= "4.17+stable%"
Signature · 1 line
2.25.1