Re: [PATCH v6 13/44] x86/boot: transition relocation calculations to struct boot_module

2024-10-17 Thread Jason Andryuk
ges_to_xen((unsigned long)maddr_to_virt(bi->mods[i].start), +maddr_to_mfn(bi->mods[i].start), +PFN_UP(bi->mods[i].size), PAGE_HYPERVISOR); I would vertically align all the parameters inside the (. } #ifdef CONFIG_KEXEC With those: Reviewed-by: Jason Andryuk Regards, Jason

Re: [PATCH v6 12/44] x86/boot: update struct boot_module on module relocation

2024-10-17 Thread Jason Andryuk
On 2024-10-17 13:02, Daniel P. Smith wrote: When a boot module is relocated, ensure struct boot_module start and size fields are updated along with early_mod. Signed-off-by: Daniel P. Smith --- Changes since v5: - corrected conversion function for a missed switch from mfn to maddr/paddr --- x

Re: [PATCH v6 11/44] x86/boot: add start and size fields to struct boot_module

2024-10-17 Thread Jason Andryuk
addresses. converted Signed-off-by: Daniel P. Smith with that Reviewed-by: Jason Andryuk EFI now gains the alignment check, but beforehand it was just silently truncating. Seems better to check :) Regards, Jason

Re: [PATCH v6 09/44] x86/boot: introduce boot module types

2024-10-17 Thread Jason Andryuk
, such as domain construction. Signed-off-by: Daniel P. Smith Reviewed-by: Jason Andryuk

Re: [PATCH v6 08/44] x86/boot: convert mod refs to boot_module mod

2024-10-17 Thread Jason Andryuk
On 2024-10-17 13:02, Daniel P. Smith wrote: To allow a slow conversion of x86 over to struct boot_module, start with replacing all references to module_t mod, only in setup.c, to the mod element of struct boot_module. These serves twofold, first to allow the incremental transition from module_t f

Re: [PATCH v6 07/44] x86/boot: move headroom to boot modules

2024-10-17 Thread Jason Andryuk
around. It also lays the groundwork for hyperlaunch mult-domain construction, where multiple instances of state variables like headroom will be needed. Signed-off-by: Daniel P. Smith Reviewed-by: Jason Andryuk

Re: [PATCH v6 02/44] x86/boot: move boot loader name to boot info

2024-10-17 Thread Jason Andryuk
On 2024-10-17 13:02, Daniel P. Smith wrote: Transition the incoming boot loader name to be held in struct boot_info. No functional change intended. Signed-off-by: Daniel P. Smith Reviewed-by: Jason Andryuk

Re: [PATCH v5 20/44] x86/boot: convert xsm policy loading to struct boot_module

2024-10-10 Thread Jason Andryuk
On 2024-10-09 13:21, Daniel P. Smith wrote: On 10/8/24 12:13, Jason Andryuk wrote: On 2024-10-06 17:49, Daniel P. Smith wrote: Iterate through the unclaimed struct boot_module to see if any are an XSM FLASK policy. If one is located, mark it as an xsm policy. Signed-off-by: Daniel P. Smith

Re: [PATCH v3 4/5] x86/xen: Avoid relocatable quantities in Xen ELF notes

2024-10-09 Thread Jason Andryuk
from the symbol value) and linker provided absolute symbols that add the address of the place to the desired value. Tested-by: Jason Andryuk Signed-off-by: Ard Biesheuvel Reviewed-by: Jason Andryuk Thanks, Jason

Re: [PATCH v5 00/44] Boot modules for Hyperlaunch

2024-10-08 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: The Boot Modules for Hyperlaunch series is an effort to split out preliminary changes necessary for the introduction of the Hyperlaunch domain builder logic. These preliminary changes revolve around introducing the struct boot_module and struct boot_dom

Re: [PATCH v5 40/44] x86/boot: add cmdline to struct boot_domain

2024-10-08 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: Add a container for the "cooked" command line for a domain. Signed-off-by: Daniel P. Smith --- xen/arch/x86/include/asm/bootdomain.h | 4 xen/arch/x86/setup.c | 18 -- 2 files changed, 12 insertions(+), 10 de

Re: [PATCH v5 44/44] x86/boot: convert dom0_construct_pvh to struct boot_domain

2024-10-08 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: With construct_dom0 consuming struct boot_domain, continue passing the structure down to dom0_construct_pvh. Signed-off-by: Daniel P. Smith diff --git a/xen/arch/x86/hvm/dom0_build.c b/xen/arch/x86/hvm/dom0_build.c index a3fd5e762dc4..755e257cdf30

Re: [PATCH v5 43/44] x86/boot: convert dom0_construct_pv to struct boot_domain

2024-10-08 Thread Jason Andryuk
;headroom; -unsigned long initrd_len = initrd ? initrd->size : 0; +struct domain *d = bd->d; +struct vcpu *v = bd->d->vcpu[0]; This can stay: struct vcpu *v = d->vcpu[0]; With that: Reviewed-by: Jason Andryuk

Re: [PATCH v5 41/44] x86/boot: add struct domain to struct boot_domain

2024-10-08 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: Store a reference to the created domain in struct boot_domain. Signed-off-by: Daniel P. Smith --- diff --git a/xen/arch/x86/setup.c b/xen/arch/x86/setup.c index f250638edf09..e6a231bd2d42 100644 --- a/xen/arch/x86/setup.c +++ b/xen/arch/x86/setup.c

Re: [PATCH v5 42/44] x86/boot: convert construct_dom0 to struct boot_domain

2024-10-08 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: A struct boot_domain now encapsulates the domain reference, kernel, ramdisk, and command line for the domain being constructed. As a result of this encapsulation, construct_dom0 can now take a single struct boot_domain instead of these four parameters.

Re: [PATCH v5 39/44] x86/boot: introduce domid field to struct boot_domain

2024-10-08 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: Add a domid field to struct boot_domain to hold the assigned domain id for the domain. During initialization, ensure all instances of struct boot_domain have the invalid domid to ensure that the domid must be set either by convention or configuration.

Re: [PATCH v5 39/44] x86/boot: introduce domid field to struct boot_domain

2024-10-08 Thread Jason Andryuk
. Signed-off-by: Daniel P. Smith Reviewed-by: Jason Andryuk

Re: [PATCH v5 38/44] x86/boot: introduce boot domain

2024-10-08 Thread Jason Andryuk
that: Reviewed-by: Jason Andryuk

Re: [PATCH v5 37/44] x86/boot: remove mod from struct boot_module

2024-10-08 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: With all references to mod field removed, remove the mod field from struct boot_module. Signed-off-by: Daniel P. Smith Reviewed-by: Jason Andryuk

Re: [PATCH v5 36/44] x86/boot: remove remaining early_mod references

2024-10-08 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: Any direct usages of struct mod have been transitioned, remove the remaining references to early_mod fields. This is unclear, please try to re-word. "struct mod" and "early_mod" don't exist. Signed-off-by: Daniel P. Smith --- xen/arch/x86/setu

Re: [PATCH v5 35/44] x86/boot: remove usage of mod_end by discard_initial_images

2024-10-08 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: This eliminates usage of early_mod by discard_initial_images Signed-off-by: Daniel P. Smith Reviewed-by: Jason Andryuk

Re: [PATCH v5 34/44] x86/boot: drop the use of initial_images unit global

2024-10-08 Thread Jason Andryuk
N(initial_images[i].mod->mod_end)); + PAGE_ALIGN(bi->mods[i].mod->mod_end)); One line. } bi->nr_modules = 0; -initial_images = NULL; } static void __init init_idle_domain(void) With the line fixups: Reviewed-by: Jason Andryuk

Re: [PATCH v5 33/44] x86/boot: convert initial_images to struct boot_module

2024-10-08 Thread Jason Andryuk
- start + PAGE_ALIGN(initial_images[i].mod_end)); + start + + PAGE_ALIGN(initial_images[i].mod->mod_end)); This can fit on a single line. } bi->nr_modules = 0; With those fixed: Reviewed-by: Jason Andryuk

Re: [PATCH v5 32/44] x86/boot: convert pvh_load_kernel to struct boot_module

2024-10-08 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: This changes both the kernel and ramdisk parameters over to struct boot_module. Signed-off-by: Daniel P. Smith Reviewed-by: Jason Andryuk

Re: [PATCH v5 31/44] x86/boot: convert dom0_construct_pvh to struct boot_module

2024-10-08 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: This changes both the kernel and ramdisk parameters over to struct boot_module. Signed-off-by: Daniel P. Smith Reviewed-by: Jason Andryuk

Re: [PATCH v5 30/44] x86/boot: convert dom0_construct_pv initrd param to struct boot_module

2024-10-08 Thread Jason Andryuk
, unsigned long nr_pt_pages; unsigned long alloc_spfn; unsigned long alloc_epfn; -unsigned long initrd_pfn = -1, initrd_mfn = 0; +unsigned long initrd_pfn = -1; +mfn_t initrd_mfn = { 0 }; = _mfn(0); With that: Reviewed-by: Jason Andryuk unsigned long count

Re: [PATCH v5 29/44] x86/boot: convert dom0_construct_pv image param to struct boot_module

2024-10-08 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: This changes the type for the image parameter of dom0_construct_pv to be struct boot_module. Removing the usage of early_mod field for kernel module. Signed-off-by: Daniel P. Smith Reviewed-by: Jason Andryuk

Re: [PATCH v5 28/44] x86/boot: add cmdline to struct boot_module

2024-10-08 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: Add a char pointer field, cmdline, to struct boot_module to hold the address pointed to by the string field of struct mod. This removes the need to use the early_mod field to get to the dom0 kernel command line. Signed-off-by: Daniel P. Smith --- xe

Re: [PATCH v5 27/44] x86/boot: relocate kextra into boot info

2024-10-08 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: Move kextra into struct boot_info, thus no longer needed to be passed as a parameter to create_dom0. Signed-off-by: Daniel P. Smith Reviewed-by: Jason Andryuk

Re: [PATCH v5 26/44] x86/boot: convert construct_dom0 to use struct boot_module

2024-10-08 Thread Jason Andryuk
. Signed-off-by: Daniel P. Smith Reviewed-by: Jason Andryuk

Re: [PATCH v5 25/44] x86/boot: convert create_dom0 to use boot info

2024-10-08 Thread Jason Andryuk
-by: Jason Andryuk Regards, Jason

Re: [PATCH v5 24/44] x86/boot: remove module_map usage by ramdisk loading

2024-10-08 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: The ramdisk loading is the last user of module_map, remove its usage and any remaining remnants of module_map. Signed-off-by: Daniel P. Smith --- xen/arch/x86/setup.c | 11 +-- 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/x

Re: [PATCH v5 23/44] x86/boot: remove module_map usage from xsm policy loading

2024-10-08 Thread Jason Andryuk
for the module that is the binary policy. */ You can collapse to a single line comment /* ... */ With that: Reviewed-by: Jason Andryuk for ( i = bi->nr_modules-1; i >= 1; i-- ) {

Re: [PATCH v5 22/44] x86/boot: remove module_map usage from microcode loading

2024-10-08 Thread Jason Andryuk
t_and_clear_bit(ucode_mod_idx, module_map) ) + (bi->mods[ucode_mod_idx].type != BOOTMOD_UNKNOWN) ) Just bi->mods[ucode_mod_idx].type != BOOTMOD_UNKNOWN ) With that: Reviewed-by: Jason Andryuk Regards, Jason

Re: [PATCH v5 21/44] x86/boot: convert ramdisk locating to struct boot_module

2024-10-08 Thread Jason Andryuk
a signed int. Switch initrdidx from unsigned to signed. Signed-off-by: Daniel P. Smith Reviewed-by: Jason Andryuk Regards, Jason

Re: [PATCH v5 20/44] x86/boot: convert xsm policy loading to struct boot_module

2024-10-08 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: Iterate through the unclaimed struct boot_module to see if any are an XSM FLASK policy. If one is located, mark it as an xsm policy. Signed-off-by: Daniel P. Smith @@ -161,6 +162,14 @@ int __init xsm_multiboot_init( } ret = xsm_core_

Re: [PATCH v5 19/44] x86/boot: use consumed boot module flag for microcode

2024-10-08 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: To track if the microcode boot module was loaded, a copy of the boot module is kept. The size element of this copy is set to zero as the indicator that the microcode was loaded. A side effect is that the modules have to be rescanned to find the boot mod

Re: [PATCH v5 17/44] x86/boot: convert microcode loading to consume struct boot_info

2024-10-08 Thread Jason Andryuk
On 2024-10-07 17:22, Jason Andryuk wrote: On 2024-10-06 17:49, Daniel P. Smith wrote: Convert the microcode loading functions to take struct boot_info, and then using struct boot_module to map and check for microcode. To keep the changes focused, continue using the struct mod to hold the

Re: [PATCH v5 18/44] x86/boot: convert late microcode loading to struct boot_module

2024-10-08 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: Remove the use of struct mod to hold the reference for the microcode, converting the code to work with a struct boot_module. Signed-off-by: Daniel P. Smith Reviewed-by: Jason Andryuk

Re: [PATCH v5 17/44] x86/boot: convert microcode loading to consume struct boot_info

2024-10-07 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: Convert the microcode loading functions to take struct boot_info, and then using struct boot_module to map and check for microcode. To keep the changes focused, continue using the struct mod to hold the reference to the microcode that is used by the lat

Re: [PATCH v5 16/44] x86/boot: introduce consumed flag for struct boot_module

2024-10-07 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: Allow the tracking of when a boot module has been consumed by a handler in the hypervisor independent of when it is claimed. The instances where the hypervisor does nothing beyond claiming, the dom0 kernel, dom0 ramdisk, and a placeholder for itself, ar

Re: [PATCH v5 15/44] x86/boot: introduce boot module interator

2024-10-07 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: Provide an iterator to go through boot module array searching based on type. Signed-off-by: Daniel P. Smith Reviewed-by: Jason Andryuk

Re: [PATCH v5 14/44] x86/boot: transition relocation calculations to struct boot_module

2024-10-07 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: Use struct boot_module fields, start and size, when calculating the relocation address and size. It also ensures that early_mod references are kept in sync. Signed-off-by: Daniel P. Smith --- xen/arch/x86/setup.c | 36 +--

Re: [PATCH v5 13/44] x86/boot: update struct boot_module on module relocation

2024-10-07 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: When a boot module is relocated, ensure struct boot_module start and size fields are updated along with early_mod. Signed-off-by: Daniel P. Smith --- xen/arch/x86/setup.c | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/xe

Re: [PATCH v5 12/44] x86/boot: add start and size fields to struct boot_module

2024-10-07 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: This commit introduces the start and size fields to struct boot_module and adds a corresponding bootstrap mapping function, bootstrap_map_bm. Signed-off-by: Daniel P. Smith Reviewed-by: Jason Andryuk

Re: [PATCH v5 11/44] x86/boot: split bootstrap_map_addr() out of bootstrap_map()

2024-10-07 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: From: Andrew Cooper Using an interface based on addresses directly, not modules. No functional change. Signed-off-by: Andrew Cooper Signed-off-by: Daniel P. Smith Reviewed-by: Jason Andryuk

Re: [PATCH v5 10/44] x86/boot: introduce boot module flags

2024-10-07 Thread Jason Andryuk
< 0) + Stray newline. Otherwise: Reviewed-by: Jason Andryuk }; /*

Re: [PATCH v5 09/44] x86/boot: introduce boot module types

2024-10-07 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: This commit introduces module types of xen, kernel, and ramdisk to allow boot module detect code to tag the purpose of a boot module. This reduces the need for hard coded order assumptions and global variables to be used by consumers of boot modules, su

Re: [PATCH v5 08/44] x86/boot: convert setup.c mod refs to early_mod

2024-10-07 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: To allow a slow conversion of x86 over to struct boot_module, start with replacing all references to struct mod to the early_mod element of struct boot_module. These serves twofold, first to allow the incremental transition from struct mod fields to str

Re: [PATCH v5 07/44] x86/boot: move headroom to boot modules

2024-10-07 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: The purpose of struct boot_module is to encapsulate the state of boot module as it is processed by Xen. Locating boot module state struct boot_module reduces the number of global variables as well as the number of state variables that must be passed aro

Re: [PATCH v5 06/44] x86/boot: convert consider_modules to struct boot_module

2024-10-07 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: To start transitioning consider_modules() over to struct boot_module, begin with taking the array of struct boot_modules but use the temporary struct element mod. No functional change intended. Signed-off-by: Daniel P. Smith Reviewed-by: Jason

Re: [PATCH v5 05/44] x86/boot: introduce struct boot_module

2024-10-07 Thread Jason Andryuk
[MAX_NR_BOOTMODS + 1]; }; Reviewed-by: Jason Andryuk

Re: [PATCH v5 04/44] x86/boot: move mmap info to boot info

2024-10-07 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: Transition the memory map info to be held in struct boot_info. No functional change intended. Signed-off-by: Daniel P. Smith Reviewed-by: Jason Andryuk

Re: [PATCH v5 03/44] x86/boot: move cmdline to boot info

2024-10-07 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: Transition Xen's command line to being held in struct boot_info. No functional change intended. Signed-off-by: Daniel P. Smith Acked-by: Andrew Cooper --- #endif /* __XEN_X86_BOOTINFO_H__ */ diff --git a/xen/arch/x86/setup.c b/xen/arch/x86/setu

Re: [PATCH v5 02/44] x86/boot: move boot loader name to boot info

2024-10-07 Thread Jason Andryuk
On 2024-10-06 17:49, Daniel P. Smith wrote: Transition the incoming boot loader name to be held in struct boot_info. No functional change intended. Signed-off-by: Daniel P. Smith Reviewed-by: Jason Andryuk

Re: [PATCH v5 01/44] x86/boot: move x86 boot module counting into a new boot_info struct

2024-10-07 Thread Jason Andryuk
__XEN_X86_BOOTINFO_H__ +#define __XEN_X86_BOOTINFO_H__ I haven't been following closely, but I think if we follow Frediano's naming scheme, it would be: ASM__X86__BOOTINFO_H With that (or whatever it should be), Reviewed-by: Jason Andryuk + +/* + * Xen internal representation of i

Re: [PATCH v2 4/5] x86/xen: Avoid relocatable quantities in Xen ELF notes

2024-10-02 Thread Jason Andryuk
from the symbol value) and linker provided absolute symbols that add the address of the place to the desired value. Signed-off-by: Ard Biesheuvel Tested-by: Jason Andryuk The generated values look ok. --- arch/x86/kernel/vmlinux.lds.S | 13 + arch/x86/platform/pvh/head.S

Re: [PATCH 5/5] x86/pvh: Avoid absolute symbol references in .head.text

2024-09-27 Thread Jason Andryuk
relative symbol references: these are always 32-bits wide, even in 64-bit code, and are resolved by the linker at build time. Signed-off-by: Ard Biesheuvel Reviewed-by: Jason Andryuk Tested-by: Jason Andryuk Thanks, Jason

Re: [PATCH 4/5] x86/xen: Avoid relocatable quantities in Xen ELF notes

2024-09-26 Thread Jason Andryuk
On 2024-09-26 06:41, Ard Biesheuvel wrote: From: Ard Biesheuvel Xen puts virtual and physical addresses into ELF notes that are treated by the linker as relocatable by default. Doing so is not only pointless, given that the ELF notes are only intended for consumption by Xen before the kernel bo

Re: [PATCH 3/5] x86/pvh: Omit needless clearing of phys_base

2024-09-26 Thread Jason Andryuk
f-by: Ard Biesheuvel Reviewed-by: Jason Andryuk Tested-by: Jason Andryuk My patch pre-dated the above, but I never liked it. Happy to see this gone. Thanks, Jason

Re: [PATCH 2/5] x86/pvh: Use correct size value in GDT descriptor

2024-09-26 Thread Jason Andryuk
On 2024-09-26 06:41, Ard Biesheuvel wrote: From: Ard Biesheuvel The size field in a GDT descriptor is offset by 1, so subtract 1 from the calculated range. Signed-off-by: Ard Biesheuvel I guess with s/size/limit/ per Andrew. Reviewed-by: Jason Andryuk Tested-by: Jason Andryuk Thanks

Re: [PATCH 1/5] x86/pvh: Call C code via the kernel virtual mapping

2024-09-26 Thread Jason Andryuk
xen_prepare_pvh() via the kernel virtual mapping before invoking startup_32 with paging disabled again. Fixes: 7243b93345f7 ("xen/pvh: Bootstrap PVH guest") Tested-by: Jason Andryuk Reviewed-by: Jason Andryuk Signed-off-by: Ard Biesheuvel --- arch/x86/platform/pvh/head.S | 8 +++

Re: [RFC PATCH 11/28] x86/pvh: Avoid absolute symbol references in .head.text

2024-09-25 Thread Jason Andryuk
On 2024-09-25 17:50, Ard Biesheuvel wrote: On Wed, 25 Sept 2024 at 23:11, Jason Andryuk wrote: Hi Ard, On 2024-09-25 11:01, Ard Biesheuvel wrote: From: Ard Biesheuvel The .head.text section contains code that may execute from a different address than it was linked at. This is fragile

Re: [RFC PATCH 01/28] x86/pvh: Call C code via the kernel virtual mapping

2024-09-25 Thread Jason Andryuk
invoking startup_32 with paging disabled again. Fixes: 7243b93345f7 ("xen/pvh: Bootstrap PVH guest") Signed-off-by: Ard Biesheuvel Tested-by: Jason Andryuk Reviewed-by: Jason Andryuk I found that before this change xen_prepare_pvh() would call through some pv_ops function pointer

Re: [RFC PATCH 11/28] x86/pvh: Avoid absolute symbol references in .head.text

2024-09-25 Thread Jason Andryuk
Hi Ard, On 2024-09-25 11:01, Ard Biesheuvel wrote: From: Ard Biesheuvel The .head.text section contains code that may execute from a different address than it was linked at. This is fragile, given that the x86 ABI can refer to global symbols via absolute or relative references, and the toolcha

[PATCH v2] xen/acpi: upload power and performance related data from a PVH dom0

2024-09-16 Thread Jason Andryuk
one that information for all the other Processors. This won't work on an heterogeneous system with Processors having different power and performance related data between them. Signed-off-by: Roger Pau Monné Signed-off-by: Jason Andryuk --- v2: Add second buffer for _CST. Call was failing with AE_BU

[PATCH] fbdev/xen-fbfront: Assign fb_info->device

2024-09-10 Thread Jason Andryuk
From: Jason Andryuk Probing xen-fbfront faults in video_is_primary_device(). The passed-in struct device is NULL since xen-fbfront doesn't assign it and the memory is kzalloc()-ed. Assign fb_info->device to avoid this. This was exposed by the conversion of fb_is_primary_dev

[PATCH] fbdev/xen-fbfront: Assign fb_info->device

2024-09-09 Thread Jason Andryuk
From: Jason Andryuk Probing xen-fbfront faults in video_is_primary_device(). The passed-in struct device is NULL since xen-fbfront doesn't assign it and the memory is kzalloc()-ed. Assign fb_info->device to avoid this. This was exposed by the conversion of fb_is_primary_dev

[xen_fbfront] - Xen PVH VM: kernel upgrade 6.9.10 > 6.10.7 results in crash

2024-09-07 Thread Jason Andryuk
From: Jason Andryuk Hi Arthur, Can you give the patch below a try? If it works, please respond with a Tested-by. I'll then submit it with your Reported-by and Tested-by. Thanks, Jason [PATCH] fbdev/xen-fbfront: Assign fb_info->device Probing xen-fbfront faults in video_is_primar

IOREQ completions for MMIO writes

2024-08-29 Thread Jason Andryuk
Hi Everyone, I've been looking at ioreq latency and pausing of vCPUs. Specifically for MMIO (IOREQ_TYPE_COPY) writes, they still need completions: static inline bool ioreq_needs_completion(const ioreq_t *ioreq) { return ioreq->state == STATE_IOREQ_READY && !ioreq->data_is_ptr &

Re: [XEN PATCH 3/3] libxl: Probe QEMU for -run-with user=user and use it

2024-08-27 Thread Jason Andryuk
On 2024-08-27 06:03, Anthony PERARD wrote: "-runas" is deprecated since QEMU 9.1 and will be remove in a future release. Signed-off-by: Anthony PERARD Reviewed-by: Jason Andryuk

Re: [XEN PATCH 2/3] libxl: Probe QEMU for -run-with chroot=dir and use it

2024-08-27 Thread Jason Andryuk
;-run-with chroot=dir" is available. Then use it in place of "-chroot". Resolves: xen-project/xen#187 Signed-off-by: Anthony PERARD Reviewed-by: Jason Andryuk though one suggestion below. --- tools/libs/light/libxl_dm.c | 78 +-- tools/lib

Re: [XEN PATCH 1/3] libxl: Implement QEMU command line probe

2024-08-27 Thread Jason Andryuk
complicated fairly quickly. "domain being created"? We already need to check the options "b_info->dm_restrict" for "-chroot" and "state->dm_runas" for "-runas" (which is deprecated). Signed-off-by: Anthony PERARD Reviewed-by: Jason Andryuk

[PATCH v3 4/5] x86/kernel: Move page table macros to header

2024-08-23 Thread Jason Andryuk
The PVH entry point will need an additional set of prebuild page tables. Move the macros and defines to pgtable_64.h, so they can be re-used. Signed-off-by: Jason Andryuk Reviewed-by: Juergen Gross --- v3: Add Juergen's R-b v2: Use existing pgtable_64.h s/-/ - / in pud_index() Did no

[PATCH v3 0/5] x86/pvh: Make 64bit PVH entry relocatable

2024-08-23 Thread Jason Andryuk
ome offset calculations. They happened to be equal in my original builds. When the two values differ, _pa(pvh_start_xen) is the correct one to use. v3: Fix build error for 32bit. Add Juergen's R-b to patch 4. Jason Andryuk (5): xen: sync elfnote.h from xen tree x86/pvh: Make PVH entry

[PATCH v3 5/5] x86/pvh: Add 64bit relocation page tables

2024-08-23 Thread Jason Andryuk
_ident_pgt page. It could be larger with more pages. Signed-off-by: Jason Andryuk --- v3: Include asm/pgtable.h to avoid 32bit build failure v2: Use some defines: PTRS_PER_PGD, PTRS_PER_PMD, PAGE_SIZE Add some spaces around operators and after commas Include asm/pgtable_64.h s/LOAD_PHYSICAL_ADDR/_p

[PATCH v3 2/5] x86/pvh: Make PVH entrypoint PIC for x86-64

2024-08-23 Thread Jason Andryuk
The UNWIND_HINT_END_OF_STACK is to silence: vmlinux.o: warning: objtool: pvh_start_xen+0x7f: unreachable instruction after the lret into 64bit code. Signed-off-by: Jason Andryuk --- v2: Use rip-relative loads in 64bit mode Direct jmp to startup_64 --- arch/x86/platform/pvh/head.S

[PATCH v3 1/5] xen: sync elfnote.h from xen tree

2024-08-23 Thread Jason Andryuk
Sync Xen's elfnote.h header from xen.git to pull in the XEN_ELFNOTE_PHYS32_RELOC define. xen commit dfc9fab00378 ("x86/PVH: Support relocatable dom0 kernels") This is a copy except for the removal of the emacs editor config at the end of the file. Signed-off-by: Jason Andry

[PATCH v3 3/5] x86/pvh: Set phys_base when calling xen_prepare_pvh()

2024-08-23 Thread Jason Andryuk
phys_base needs to be set for __pa() to work in xen_pvh_init() when finding the hypercall page. Set it before calling into xen_prepare_pvh(), which calls xen_pvh_init(). Clear it afterward to avoid __startup_64() adding to it and creating an incorrect value. Signed-off-by: Jason Andryuk

Re: [PATCH v3] x86/boot: Preserve the value clobbered by the load-base calculation

2024-08-23 Thread Jason Andryuk
ion to match. Fixes: 1695e53851e5 ("x86/boot: Fix the boot time relocation calculations") Fixes: d96bb172e8c9 ("x86/entry: Early PVH boot code") Signed-off-by: Frediano Ziglio Signed-off-by: Andrew Cooper Reviewed-by: Jason Andryuk

Re: [PATCH v1 04/10] hw/arm: xenpvh: Add support for SMP guests

2024-08-16 Thread Jason Andryuk
On 2024-08-16 12:53, Stefano Stabellini wrote: On Fri, 16 Aug 2024, Edgar E. Iglesias wrote: On Thu, Aug 15, 2024 at 2:30 AM Stefano Stabellini wrote: On Wed, 14 Aug 2024, Edgar E. Iglesias wrote: > On Tue, Aug 13, 2024 at 03:52:32PM -0700, Stefano Stabellini wrote: > > On

Re: [PATCH v1 04/10] hw/arm: xenpvh: Add support for SMP guests

2024-08-16 Thread Jason Andryuk
On 2024-08-16 12:53, Stefano Stabellini wrote: On Fri, 16 Aug 2024, Edgar E. Iglesias wrote: On Thu, Aug 15, 2024 at 2:30 AM Stefano Stabellini wrote: On Wed, 14 Aug 2024, Edgar E. Iglesias wrote: > On Tue, Aug 13, 2024 at 03:52:32PM -0700, Stefano Stabellini wrote: > > On

[PATCH v2 3/5] x86/pvh: Set phys_base when calling xen_prepare_pvh()

2024-08-14 Thread Jason Andryuk
phys_base needs to be set for __pa() to work in xen_pvh_init() when finding the hypercall page. Set it before calling into xen_prepare_pvh(), which calls xen_pvh_init(). Clear it afterward to avoid __startup_64() adding to it and creating an incorrect value. Signed-off-by: Jason Andryuk

[PATCH v2 4/5] x86/kernel: Move page table macros to header

2024-08-14 Thread Jason Andryuk
The PVH entry point will need an additional set of prebuild page tables. Move the macros and defines to pgtable_64.h, so they can be re-used. Signed-off-by: Jason Andryuk --- v2: Use existing pgtable_64.h s/-/ - / in pud_index() Did not add Juergen's R-b in case the header movement ma

[PATCH v2 1/5] xen: sync elfnote.h from xen tree

2024-08-14 Thread Jason Andryuk
Sync Xen's elfnote.h header from xen.git to pull in the XEN_ELFNOTE_PHYS32_RELOC define. xen commit dfc9fab00378 ("x86/PVH: Support relocatable dom0 kernels") This is a copy except for the removal of the emacs editor config at the end of the file. Signed-off-by: Jason Andry

[PATCH v2 5/5] x86/pvh: Add 64bit relocation page tables

2024-08-14 Thread Jason Andryuk
_ident_pgt page. It could be larger with more pages. Signed-off-by: Jason Andryuk --- v2: Use some defines: PTRS_PER_PGD, PTRS_PER_PMD, PAGE_SIZE Add some spaces around operators and after commas Include asm/pgtable_64.h s/LOAD_PHYSICAL_ADDR/_pa(pvh_start_xen)/ in case they differ --- arch/x86/plat

[PATCH v2 0/5] x86/pvh: Make 64bit PVH entry relocatable

2024-08-14 Thread Jason Andryuk
ome offset calculations. They happened to be equal in my original builds. When the two values differ, _pa(pvh_start_xen) is the correct one to use. Jason Andryuk (5): xen: sync elfnote.h from xen tree x86/pvh: Make PVH entrypoint PIC for x86-64 x86/pvh: Set phys_base when calling xen_prepare_

[PATCH v2 2/5] x86/pvh: Make PVH entrypoint PIC for x86-64

2024-08-14 Thread Jason Andryuk
The UNWIND_HINT_END_OF_STACK is to silence: vmlinux.o: warning: objtool: pvh_start_xen+0x7f: unreachable instruction after the lret into 64bit code. Signed-off-by: Jason Andryuk --- v2: Use rip-relative loads in 64bit mode Direct jmp to startup_64 --- arch/x86/platform/pvh/head.S

Re: [PATCH] tools/xl: add suspend-to-ram and resume subcommands

2024-08-07 Thread Jason Andryuk
On 2024-07-30 02:42, Jan Beulich wrote: On 30.07.2024 00:31, zithro wrote: Added my S-o-B (no other change). PS: re-sent to account for Anthony mail address change On 29 Feb 2024 08:00, zithro / Cyril Rébert wrote: The xl command doesn't provide suspend/resume, so add them : xl suspend-to

Re: [PATCH] libxl/disk: avoid aliasing of abs()

2024-08-07 Thread Jason Andryuk
changing") Signed-off-by: Jan Beulich Reviewed-by: Jason Andryuk Thanks, Jason

[PATCH v5] libxl: Enable stubdom cdrom changing

2024-07-29 Thread Jason Andryuk
eted. For cd-eject, we still need to attach the empty vbd. This is necessary since xenstore is used to determine that hdc exists. Otherwise after eject, hdc would be gone and the cd-insert would fail to find the drive to insert new media. Signed-off-by: Jason Andryuk Signed-off-by: Jas

Re: [PATCH v4] libxl: Enable stubdom cdrom changing

2024-07-29 Thread Jason Andryuk
On Mon, Jul 29, 2024 at 10:32 AM Anthony PERARD wrote: > > On Sun, Jul 28, 2024 at 05:08:56PM -0400, Jason Andryuk wrote: > > +static void cdrom_insert_stubdom_parse_fdset(libxl__egc *egc, > > +

[PATCH v4] libxl: Enable stubdom cdrom changing

2024-07-28 Thread Jason Andryuk
eted. For cd-eject, we still need to attach the empty vbd. This is necessary since xenstore is used to determine that hdc exists. Otherwise after eject, hdc would be gone and the cd-insert would fail to find the drive to insert new media. Signed-off-by: Jason Andryuk Signed-off-by: Jas

Re: [PATCH v3] libxl: Enable stubdom cdrom changing

2024-07-28 Thread Jason Andryuk
On Thu, Jul 25, 2024 at 11:31 AM Anthony PERARD wrote: > > On Wed, May 15, 2024 at 10:10:10PM -0400, Jason Andryuk wrote: > > +static void cdrom_insert_stubdom_parse_fdset_rm(libxl__egc *egc, > > +

Re: [RFC PATCH] automation: add linker symbol name script

2024-07-24 Thread Jason Andryuk
On 2024-07-24 13:48, Lira, Victor M wrote: On 7/24/2024 12:44 AM, Jan Beulich wrote: Nit: In names of new files we prefer - over _. +script_name=`basename "$0"` I have fixed the above comments in v2. +#!/bin/bash Can we rely on bash to be there and at that location? As you using any bash-is

Re: [PATCH for-4.19] hotplug: Restore block-tap phy compatibility (again)

2024-07-24 Thread Jason Andryuk
On 2024-07-24 08:41, Jan Beulich wrote: On 23.07.2024 17:04, Anthony PERARD wrote: On Mon, Jul 15, 2024 at 07:46:31PM -0400, Jason Andryuk wrote: "$dev" needs to be set correctly for backendtype=phy as well as backendtype=tap. Move the setting into the conditional, so it can

Re: [PATCH for-4.19] hotplug: Restore block-tap phy compatibility (again)

2024-07-23 Thread Jason Andryuk
On 2024-07-23 13:34, Andrew Cooper wrote: On 23/07/2024 6:31 pm, oleksii.kuroc...@gmail.com wrote: On Tue, 2024-07-23 at 11:04 -0400, Jason Andryuk wrote: On 2024-07-23 11:04, Anthony PERARD wrote: On Mon, Jul 15, 2024 at 07:46:31PM -0400, Jason Andryuk wrote: "$dev" needs

Re: [PATCH for-4.19] hotplug: Restore block-tap phy compatibility (again)

2024-07-23 Thread Jason Andryuk
On 2024-07-23 11:04, Anthony PERARD wrote: On Mon, Jul 15, 2024 at 07:46:31PM -0400, Jason Andryuk wrote: "$dev" needs to be set correctly for backendtype=phy as well as backendtype=tap. Move the setting into the conditional, so it can be handled properly for each. (dev could b

Re: [PATCH v1.1 5/6] tools/libxs: Use writev()/sendmsg() instead of write()

2024-07-23 Thread Jason Andryuk
aller, so I'd prefer to simply drop it if that's ok? The writev()/sendmsg() won't malfunction if the first element is 0, and update_iov() will now cope too, so I don't think it's necessary. Fine with me. Reviewed-by: Jason Andryuk Looks like xs_write_all() is now unused

Re: [PATCH 6/6] tools/libxs: Stop playing with SIGPIPE

2024-07-23 Thread Jason Andryuk
orgo any playing with the signal disposition. This has a side benefit of saving 2 syscalls per xenstore request. Signed-off-by: Andrew Cooper Reviewed-by: Jason Andryuk

  1   2   3   4   5   6   7   8   9   10   >