[ovmf test] 180597: all pass - PUSHED

2023-05-09 Thread osstest service owner
flight 180597 ovmf real [real] http://logs.test-lab.xenproject.org/osstest/logs/180597/ Perfect :-) All tests in this flight passed as required version targeted for testing: ovmf 9165a7e95ec6263c04c8babfdbe8bee133959300 baseline version: ovmf

[XEN PATCH 2/2] x86/Dom0: Use streaming decompression for ZSTD compressed kernels

2023-05-09 Thread Rafaël Kooi
On Arch Linux kernel decompression will fail when Xen has been unified with the kernel and initramfs as a single binary. This change works for both streaming and non-streaming ZSTD content. Signed-off-by: Rafaël Kooi --- xen/common/decompress.c | 37 +++-- 1 file

[XEN PATCH 1/2] xen/decompress: Add a user pointer for book keeping in the callbacks

2023-05-09 Thread Rafaël Kooi
Before this change the callbacks either needed to be completely stateless or use global state for book keeping. In the case where book keeping is needed we can't use global state in decompress.c because the linker disallows the existence of the .data and .bss segments. This change allows for

[XEN PATCH 0/2] Use streaming decompression for ZSTD kernels

2023-05-09 Thread Rafaël Kooi
I've attempted to get Xen to boot Arch Linux as a unified EFI binary. Using https://xenbits.xen.org/docs/unstable/misc/efi.html as my source of information, I've been able to build a unified binary. When trying to boot the kernel Xen complains that the stream is corrupt ("ZSTD-compressed data is

[linux-linus test] 180590: regressions - FAIL

2023-05-09 Thread osstest service owner
flight 180590 linux-linus real [real] http://logs.test-lab.xenproject.org/osstest/logs/180590/ Regressions :-( Tests which did not succeed and are blocking, including tests which could not be run: test-armhf-armhf-xl-credit1 8 xen-boot fail REGR. vs. 180278 build-arm64-pvops

[ovmf test] 180595: all pass - PUSHED

2023-05-09 Thread osstest service owner
flight 180595 ovmf real [real] http://logs.test-lab.xenproject.org/osstest/logs/180595/ Perfect :-) All tests in this flight passed as required version targeted for testing: ovmf e97b9b4e5a4bd53fd5f18c44390b266a2a89881a baseline version: ovmf

[xen-unstable test] 180589: tolerable FAIL - PUSHED

2023-05-09 Thread osstest service owner
flight 180589 xen-unstable real [real] flight 180594 xen-unstable real-retest [real] http://logs.test-lab.xenproject.org/osstest/logs/180589/ http://logs.test-lab.xenproject.org/osstest/logs/180594/ Failures :-/ but no regressions. Tests which are failing intermittently (not blocking):

[xen-unstable-smoke test] 180592: tolerable all pass - PUSHED

2023-05-09 Thread osstest service owner
flight 180592 xen-unstable-smoke real [real] http://logs.test-lab.xenproject.org/osstest/logs/180592/ Failures :-/ but no regressions. Tests which did not succeed, but are not blocking: test-amd64-amd64-libvirt 15 migrate-support-checkfail never pass test-arm64-arm64-xl-xsm

[ovmf test] 180593: all pass - PUSHED

2023-05-09 Thread osstest service owner
flight 180593 ovmf real [real] http://logs.test-lab.xenproject.org/osstest/logs/180593/ Perfect :-) All tests in this flight passed as required version targeted for testing: ovmf bee67e0c142af6599a85aa7640094816b8a24c4f baseline version: ovmf

Re: [PATCH v6 00/16] x86/mtrr: fix handling with PAT but without MTRR

2023-05-09 Thread Borislav Petkov
On Tue, May 09, 2023 at 10:14:37PM +0200, Borislav Petkov wrote: > On Tue, May 02, 2023 at 02:09:15PM +0200, Juergen Gross wrote: > > This series tries to fix the rather special case of PAT being available > > without having MTRRs (either due to CONFIG_MTRR being not set, or > > because the

Re: [PATCH v2] piix: fix regression during unplug in Xen HVM domUs

2023-05-09 Thread Olaf Hering
Resuming this old thread about an unfixed bug, which was introduced in qemu-4.2: qemu ends up in piix_ide_reset from pci_unplug_disks. This was not the case prior 4.2, the removed call to qemu_register_reset(piix3_reset, d) in ee358e919e385fdc79d59d0d47b4a81e349cd5c9 did apparently nothing. In

Re: [PATCH v5 05/21] virtio-scsi: stop using aio_disable_external() during unplug

2023-05-09 Thread Stefan Hajnoczi
On Tue, May 09, 2023 at 08:55:14PM +0200, Kevin Wolf wrote: > Am 04.05.2023 um 21:53 hat Stefan Hajnoczi geschrieben: > > This patch is part of an effort to remove the aio_disable_external() > > API because it does not fit in a multi-queue block layer world where > > many AioContexts may be

Re: [PATCH v6 00/16] x86/mtrr: fix handling with PAT but without MTRR

2023-05-09 Thread Borislav Petkov
On Tue, May 02, 2023 at 02:09:15PM +0200, Juergen Gross wrote: > This series tries to fix the rather special case of PAT being available > without having MTRRs (either due to CONFIG_MTRR being not set, or > because the feature has been disabled e.g. by a hypervisor). More weird stuff. With the

Re: [patch v3 08/36] x86/smpboot: Split up native_cpu_up() into separate phases and document them

2023-05-09 Thread Thomas Gleixner
On Tue, May 09 2023 at 12:04, Peter Zijlstra wrote: > On Mon, May 08, 2023 at 09:43:39PM +0200, Thomas Gleixner wrote: > Not to the detriment of this patch, but this barrier() and it's comment > seem weird vs smp_callin(). That function ends with an atomic bitop (it > has to, at the very least it

Re: xen cache colors in ARM

2023-05-09 Thread Stefano Stabellini
We test Xen Cache Coloring regularly on zcu102. Every Petalinux release (twice a year) is tested with cache coloring enabled. The last Petalinux release is 2023.1 and the kernel used is this: https://github.com/Xilinx/linux-xlnx/tree/xlnx_rebase_v6.1_LTS On Tue, 9 May 2023, Oleg Nikitenko wrote:

Re: [XEN v6 03/12] xen/arm: Introduce a wrapper for dt_device_get_address() to handle paddr_t

2023-05-09 Thread Julien Grall
Hi, On 03/05/2023 15:06, Ayan Kumar Halder wrote: On 03/05/2023 12:25, Julien Grall wrote: Hi Ayan, Hi Julien, On 28/04/2023 18:55, Ayan Kumar Halder wrote: dt_device_get_address() can accept uint64_t only for address and size. However, the address/size denotes physical addresses. Thus,

Re: [PATCH v5 14/14] tools/xenstore: switch quota management to be table based

2023-05-09 Thread Julien Grall
Hi Juergen, On 08/05/2023 12:47, Juergen Gross wrote: @@ -2714,15 +2710,19 @@ static unsigned int get_optval_uint(const char *arg) static bool what_matches(const char *arg, const char *what) { - unsigned int what_len = strlen(what); + unsigned int what_len; + + if

Re: [PATCH v5 13/14] tools/xenstore: switch get_optval_int() to get_optval_uint()

2023-05-09 Thread Julien Grall
Hi Juergen, On 08/05/2023 12:47, Juergen Gross wrote: Let get_optval_int() return an unsigned value and rename it accordingly. Signed-off-by: Juergen Gross Reviewed-by: Julien Grall Cheers, -- Julien Grall

Re: [PATCH v5 12/14] tools/xenstore: use generic accounting for remaining quotas

2023-05-09 Thread Julien Grall
Hi Juergen, On 08/05/2023 12:47, Juergen Gross wrote: The maxrequests, node size, number of node permissions, and path length quota are a little bit special, as they are either active in transactions only (maxrequests), or they are just per item instead of count values. Nevertheless being able

Re: [PATCH v5 00/21] block: remove aio_disable_external() API

2023-05-09 Thread Kevin Wolf
Am 04.05.2023 um 21:53 hat Stefan Hajnoczi geschrieben: > v5: > - Use atomic accesses for in_flight counter in vhost-user-server.c [Kevin] > - Stash SCSIDevice id/lun values for VIRTIO_SCSI_T_TRANSPORT_RESET event > before unrealizing the SCSIDevice [Kevin] > - Keep vhost-user-blk export

Re: [PATCH v5 05/21] virtio-scsi: stop using aio_disable_external() during unplug

2023-05-09 Thread Kevin Wolf
Am 04.05.2023 um 21:53 hat Stefan Hajnoczi geschrieben: > This patch is part of an effort to remove the aio_disable_external() > API because it does not fit in a multi-queue block layer world where > many AioContexts may be submitting requests to the same disk. > > The SCSI emulation code is

[qemu-mainline test] 180586: tolerable FAIL - PUSHED

2023-05-09 Thread osstest service owner
flight 180586 qemu-mainline real [real] flight 180591 qemu-mainline real-retest [real] http://logs.test-lab.xenproject.org/osstest/logs/180586/ http://logs.test-lab.xenproject.org/osstest/logs/180591/ Failures :-/ but no regressions. Tests which are failing intermittently (not blocking):

Re: [PATCH v5 10/14] tools/xenstore: switch transaction accounting to generic accounting

2023-05-09 Thread Julien Grall
Hi Juergen, On 08/05/2023 12:47, Juergen Gross wrote: As transaction accounting is active for unprivileged domains only, it can easily be added to the generic per-domain accounting. Signed-off-by: Juergen Gross --- V5: - use list_empty(>transaction_list) for detection of "no transaction

Re: [PATCH v5 07/14] tools/xenstore: use accounting data array for per-domain values

2023-05-09 Thread Julien Grall
On 08/05/2023 12:47, Juergen Gross wrote: Add the accounting of per-domain usage of Xenstore memory, watches, and outstanding requests to the array based mechanism. Signed-off-by: Juergen Gross Acked-by: Julien Grall --- V5: - drop domid parameter from domain_outstanding_inc() (Julien

Re: [PATCH v5 05/14] tools/xenstore: use accounting buffering for node accounting

2023-05-09 Thread Julien Grall
Hi Juergen, On 08/05/2023 12:47, Juergen Gross wrote: Add the node accounting to the accounting information buffering in order to avoid having to undo it in case of failure. This requires to call domain_nbentry_dec() before any changes to the data base, as it can return an error now.

Re: [PATCH v5 00/21] block: remove aio_disable_external() API

2023-05-09 Thread Kevin Wolf
Am 09.05.2023 um 19:51 hat Stefan Hajnoczi geschrieben: > On Thu, May 04, 2023 at 11:44:42PM +0200, Kevin Wolf wrote: > > Am 04.05.2023 um 21:53 hat Stefan Hajnoczi geschrieben: > > > v5: > > > - Use atomic accesses for in_flight counter in vhost-user-server.c [Kevin] > > > - Stash SCSIDevice

Re: [PATCH v5 04/14] tools/xenstore: add framework to commit accounting data on success only

2023-05-09 Thread Julien Grall
Hi Juergen, On 08/05/2023 12:47, Juergen Gross wrote: Instead of modifying accounting data and undo those modifications in case of an error during further processing, add a framework for collecting the needed changes and commit them only when the whole operation has succeeded. This scheme can

Re: [PATCH v8 0/7] Add pci_dev_for_each_resource() helper and update users

2023-05-09 Thread Bjorn Helgaas
On Tue, Apr 04, 2023 at 11:11:01AM -0500, Bjorn Helgaas wrote: > On Thu, Mar 30, 2023 at 07:24:27PM +0300, Andy Shevchenko wrote: > > Provide two new helper macros to iterate over PCI device resources and > > convert users. > Applied 2-7 to pci/resource for v6.4, thanks, I really like this! This

Re: [patch v3 08/36] x86/smpboot: Split up native_cpu_up() into separate phases and document them

2023-05-09 Thread Thomas Gleixner
On Tue, May 09 2023 at 12:19, Peter Zijlstra wrote: > Again, not really this patch, but since I had to look at this code > > On Mon, May 08, 2023 at 09:43:39PM +0200, Thomas Gleixner wrote: >> @@ -1048,60 +1066,89 @@ static int do_boot_cpu(int apicid, int c > > /* >* AP might

Re: [patch v3 08/36] x86/smpboot: Split up native_cpu_up() into separate phases and document them

2023-05-09 Thread Thomas Gleixner
On Tue, May 09 2023 at 14:07, Thomas Gleixner wrote: > On Tue, May 09 2023 at 12:04, Peter Zijlstra wrote: >> On Mon, May 08, 2023 at 09:43:39PM +0200, Thomas Gleixner wrote: >>> + /* >>> +* Sync point with wait_cpu_callin(). The AP doesn't wait here >>> +* but just sets the bit to let

Re: [PATCH v5 00/21] block: remove aio_disable_external() API

2023-05-09 Thread Stefan Hajnoczi
On Thu, May 04, 2023 at 11:44:42PM +0200, Kevin Wolf wrote: > Am 04.05.2023 um 21:53 hat Stefan Hajnoczi geschrieben: > > v5: > > - Use atomic accesses for in_flight counter in vhost-user-server.c [Kevin] > > - Stash SCSIDevice id/lun values for VIRTIO_SCSI_T_TRANSPORT_RESET event > > before

Re: [PATCH v1] tools: drop bogus and obsolete ptyfuncs.m4

2023-05-09 Thread Anthony PERARD
On Tue, May 02, 2023 at 08:48:00PM +, Olaf Hering wrote: > According to openpty(3) it is required to include to get the > prototypes for openpty() and login_tty(). But this is not what the > function AX_CHECK_PTYFUNCS actually does. It makes no attempt to include > the required header. > >

[PATCH v2 3/3] x86: Add support for CpuidUserDis

2023-05-09 Thread Alejandro Vallejo
Because CpuIdUserDis is reported in CPUID itself, the extended leaf containing that bit must be retrieved before calling c_early_init() Signed-off-by: Alejandro Vallejo --- v2: * Style fixes * MSR index inlined in rdmsr/wrmsr * Swapped Intel's conditional guard so typically true condition

[PATCH v2 1/3] x86: Add AMD's CpuidUserDis bit definitions

2023-05-09 Thread Alejandro Vallejo
AMD reports support for CpuidUserDis in CPUID and provides the toggle in HWCR. This patch adds the positions of both of those bits to both xen and tools. No functional change. Signed-off-by: Alejandro Vallejo --- tools/libs/light/libxl_cpuid.c | 1 + tools/misc/xen-cpuid.c

[PATCH v2 2/3] x86: Refactor conditional guard in probe_cpuid_faulting()

2023-05-09 Thread Alejandro Vallejo
Move vendor-specific checks to the vendor-specific callers. No functional change. Signed-off-by: Alejandro Vallejo --- v2: * Patch factored out from patch2 of v1 --- xen/arch/x86/cpu/amd.c| 10 +- xen/arch/x86/cpu/common.c | 11 --- xen/arch/x86/cpu/intel.c | 9

[PATCH v2 0/3] Add CpuidUserDis support

2023-05-09 Thread Alejandro Vallejo
v2: * Style changes * Remove v1/patch3: HVM not to be addressed by this series * Adds one patch between v1/patch1 and v1/patch2 with the vendor-specific refactor of probe_cpuid_faulting() Nowadays AMD supports trapping the CPUID instruction from ring>0 to ring0, (CpuidUserDis) akin to

[linux-linus test] 180587: regressions - FAIL

2023-05-09 Thread osstest service owner
flight 180587 linux-linus real [real] http://logs.test-lab.xenproject.org/osstest/logs/180587/ Regressions :-( Tests which did not succeed and are blocking, including tests which could not be run: test-armhf-armhf-xl-credit1 8 xen-boot fail REGR. vs. 180278 build-arm64-pvops

Re: [PATCH] x86/iommu: fix wrong iterator type in arch_iommu_hwdom_init()

2023-05-09 Thread Jan Beulich
On 09.05.2023 13:03, Roger Pau Monne wrote: > The 'i' iterator index stores a pdx, not a pfn, and hence the initial > assignation of start (which stores a pfn) needs a conversion from pfn > to pdx. Strictly speaking: Yes. But pdx compression skips the bottom MAX_ORDER bits, so ... > ---

Re: [PATCH 1/6] x86/cpu-policy: Drop build time cross-checks of featureset sizes

2023-05-09 Thread Jan Beulich
On 09.05.2023 17:59, Andrew Cooper wrote: > On 09/05/2023 3:28 pm, Jan Beulich wrote: >> On 09.05.2023 15:04, Andrew Cooper wrote: >>> On 08/05/2023 7:47 am, Jan Beulich wrote: On 04.05.2023 21:39, Andrew Cooper wrote: > These BUILD_BUG_ON()s exist to cover the curious absence of a

Re: xenstored: EACCESS error accessing control/feature-balloon 1

2023-05-09 Thread zithro
On 09 May 2023 10:50, Yann Dirson wrote: On 5/4/23 20:04, zithro wrote: On 04 May 2023 17:59, Yann Dirson wrote: On 5/4/23 15:58, zithro wrote: Hi, [ snipped for brevity, report summary: XAPI daemon in domU tries to write to a non-existent xenstore node in a non-XAPI dom0 ] On 12 Apr 2023

[PATCH v4 2/3] tools: Use new xc function for some xc_domain_getinfo() calls

2023-05-09 Thread Alejandro Vallejo
Move calls that require a information about a single precisely identified domain to the new xc_domain_getinfo_single(). Signed-off-by: Alejandro Vallejo Reviewed-by: Andrew Cooper --- Cc: Andrew Cooper Cc: Wei Liu Cc: Anthony PERARD Cc: Tim Deegan Cc: George Dunlap Cc: Juergen Gross v4:

[PATCH v4 3/3] domctl: Modify XEN_DOMCTL_getdomaininfo to fail if domid is not found

2023-05-09 Thread Alejandro Vallejo
It previously mimicked the getdomaininfo sysctl semantics by returning the first domid higher than the requested domid that does exist. This unintuitive behaviour causes quite a few mistakes and makes the call needlessly slow in its error path. This patch removes the fallback search, returning

[PATCH v4 1/3] tools: Modify single-domid callers of xc_domain_getinfolist()

2023-05-09 Thread Alejandro Vallejo
xc_domain_getinfolist() internally relies on a sysctl that performs a linear search for the domids. Many callers of xc_domain_getinfolist() who require information about a precise domid are much better off calling xc_domain_getinfo_single() instead, that will use the getdomaininfo domctl instead

[PATCH v4 0/3] Rationalize usage of xc_domain_getinfo{,list}()

2023-05-09 Thread Alejandro Vallejo
The first 4 patches of v2 already made it to staging. v4 includes a fix so libxl preserves its previous error handling behaviour and a style change Original cover letter: xc_domain_getinfo() returns the list of domains with domid >= first_domid. It does so by repeatedly invoking

Re: [PATCH] iommu/vtd: fix address translation for superpages

2023-05-09 Thread Jan Beulich
On 09.05.2023 12:41, Roger Pau Monne wrote: > When translating an address that falls inside of a superpage in the > IOMMU page tables the fetching of the PTE physical address field > wasn't using dma_pte_addr(), which caused the returned data to be > corrupt as it would contain bits not related to

Re: [PATCH 1/6] x86/cpu-policy: Drop build time cross-checks of featureset sizes

2023-05-09 Thread Andrew Cooper
On 09/05/2023 3:28 pm, Jan Beulich wrote: > On 09.05.2023 15:04, Andrew Cooper wrote: >> On 08/05/2023 7:47 am, Jan Beulich wrote: >>> On 04.05.2023 21:39, Andrew Cooper wrote: These BUILD_BUG_ON()s exist to cover the curious absence of a diagnostic for code which looks like:

Re: [PATCH] xen/evtchn: Introduce new IOCTL to bind static evtchn

2023-05-09 Thread Rahul Singh
Hi Stefano, Thanks for the review. On 6 May 2023, at 1:52 am, Stefano Stabellini wrote: On Fri, 28 Apr 2023, Rahul Singh wrote: Xen 4.17 supports the creation of static evtchns. To allow user space application to bind static evtchns introduce new ioctl "IOCTL_EVTCHN_BIND_STATIC". Existing

Re: [PATCH] libxl: arm: Allow grant mappings for backends running on Dom0

2023-05-09 Thread Anthony PERARD
On Fri, May 05, 2023 at 03:08:35PM +0530, Viresh Kumar wrote: > Hi Anthony, > > On 02-05-23, 15:44, Anthony PERARD wrote: > > > diff --git a/tools/libs/light/libxl_virtio.c > > > b/tools/libs/light/libxl_virtio.c > > > index faada49e184e..e1f15344ef97 100644 > > > ---

Re: [PATCH 3/3] x86: Use CpuidUserDis if an AMD HVM guest toggles CPUID faulting

2023-05-09 Thread Alejandro Vallejo
On Tue, May 09, 2023 at 04:41:49PM +0200, Jan Beulich wrote: > > I asked Alejandro to do it like this. > > > > Advertising this to guests requires plumbing another MSR into the > > infrastructure which isn't quite set up properly let, and is in flux > > from my work. > > > > For now, this just

Re: [XEN][PATCH v6 15/19] xen/arm: Implement device tree node removal functionalities

2023-05-09 Thread Andrew Cooper
On 09/05/2023 3:30 pm, Michal Orzel wrote: > On 03/05/2023 01:36, Vikram Garhwal wrote: >> diff --git a/xen/include/xen/dt-overlay.h b/xen/include/xen/dt-overlay.h >> new file mode 100644 >> index 00..5b369f8eb7 >> --- /dev/null >> +++ b/xen/include/xen/dt-overlay.h >> @@ -0,0 +1,58 @@ >>

Re: [PATCH 3/3] x86: Use CpuidUserDis if an AMD HVM guest toggles CPUID faulting

2023-05-09 Thread Jan Beulich
On 09.05.2023 12:05, Andrew Cooper wrote: > On 08/05/2023 2:18 pm, Jan Beulich wrote: >> On 05.05.2023 19:57, Alejandro Vallejo wrote: >>> This is in order to aid guests of AMD hardware that we have exposed >>> CPUID faulting to. If they try to modify the Intel MSR that enables >>> the feature,

Re: [PATCH v6 2/4] xen/riscv: introduce setup_initial_pages

2023-05-09 Thread Jan Beulich
On 09.05.2023 14:59, Oleksii wrote: > On Mon, 2023-05-08 at 10:58 +0200, Jan Beulich wrote: >> On 03.05.2023 18:31, Oleksii Kurochko wrote: >>> --- /dev/null >>> +++ b/xen/arch/riscv/include/asm/page.h >>> @@ -0,0 +1,62 @@ >>> +#ifndef _ASM_RISCV_PAGE_H >>> +#define _ASM_RISCV_PAGE_H >>> + >>>

Re: [XEN][PATCH v6 15/19] xen/arm: Implement device tree node removal functionalities

2023-05-09 Thread Michal Orzel
On 03/05/2023 01:36, Vikram Garhwal wrote: > Introduce sysctl XEN_SYSCTL_dt_overlay to remove device-tree nodes added using > device tree overlay. > > xl dt-overlay remove file.dtbo: > Removes all the nodes in a given dtbo. > First, removes IRQ permissions and MMIO accesses. Next, it

Re: [PATCH 1/6] x86/cpu-policy: Drop build time cross-checks of featureset sizes

2023-05-09 Thread Jan Beulich
On 09.05.2023 15:04, Andrew Cooper wrote: > On 08/05/2023 7:47 am, Jan Beulich wrote: >> On 04.05.2023 21:39, Andrew Cooper wrote: >>> These BUILD_BUG_ON()s exist to cover the curious absence of a diagnostic for >>> code which looks like: >>> >>> uint32_t foo[1] = { 1, 2, 3 }; >>> >>> However,

Re: [PATCH 5/6] x86/cpu-policy: Disentangle X86_NR_FEAT and FEATURESET_NR_ENTRIES

2023-05-09 Thread Jan Beulich
On 09.05.2023 16:03, Andrew Cooper wrote: > On 08/05/2023 8:45 am, Jan Beulich wrote: >> On 04.05.2023 21:39, Andrew Cooper wrote: >>> When adding new words to a featureset, there is a reasonable amount of >>> boilerplate and it is preforable to split the addition into multiple >>> patches. >>>

Re: [PATCH 5/6] x86/cpu-policy: Disentangle X86_NR_FEAT and FEATURESET_NR_ENTRIES

2023-05-09 Thread Andrew Cooper
On 08/05/2023 8:45 am, Jan Beulich wrote: > On 04.05.2023 21:39, Andrew Cooper wrote: >> When adding new words to a featureset, there is a reasonable amount of >> boilerplate and it is preforable to split the addition into multiple patches. >> >> GCC 12 spotted a real (transient) error which

Re: [patch v3 35/36] x86/smpboot: Support parallel startup of secondary CPUs

2023-05-09 Thread Peter Zijlstra
On Mon, May 08, 2023 at 09:44:23PM +0200, Thomas Gleixner wrote: > + /* APIC ID not found in the table. Drop the trampoline lock and bail. > */ > + movqtrampoline_lock(%rip), %rax Again: movl$0, (%rax) is sufficient for unlock. > + lock > + btrl$0, (%rax)

Re: [patch v3 34/36] x86/smpboot: Implement a bit spinlock to protect the realmode stack

2023-05-09 Thread Thomas Gleixner
On Tue, May 09 2023 at 15:13, Peter Zijlstra wrote: > On Mon, May 08, 2023 at 09:44:22PM +0200, Thomas Gleixner wrote: > > Do we really care about performance here; or should we pick the simpler > form? Also, 'lock' is a prefix, not an instruction. Right. KISS is the way to go.

Re: [PATCH v2] Fix install.sh for systemd

2023-05-09 Thread Olaf Hering
Tue, 9 May 2023 13:47:11 +0100 Andrew Cooper : > > +++ b/tools/hotplug/Linux/init.d/xendriverdomain.in > > @@ -49,6 +49,7 @@ fi > > > > do_start () { > > echo Starting xl devd... > > + mkdir -m700 -p @XEN_RUN_DIR@ > > Why is this 700, and the others just using regular perms? I think

[xen-unstable test] 180584: tolerable FAIL

2023-05-09 Thread osstest service owner
flight 180584 xen-unstable real [real] http://logs.test-lab.xenproject.org/osstest/logs/180584/ Failures :-/ but no regressions. Tests which are failing intermittently (not blocking): test-amd64-i386-libvirt-raw 7 xen-install fail in 180580 pass in 180584 test-amd64-i386-pair 11

Re: [patch v3 34/36] x86/smpboot: Implement a bit spinlock to protect the realmode stack

2023-05-09 Thread Peter Zijlstra
On Mon, May 08, 2023 at 09:44:22PM +0200, Thomas Gleixner wrote: > @@ -252,6 +252,17 @@ SYM_INNER_LABEL(secondary_startup_64_no_ > movqTASK_threadsp(%rax), %rsp > > /* > + * Now that this CPU is running on its own stack, drop the realmode > + * protection. For the boot

Re: [PATCH 1/6] x86/cpu-policy: Drop build time cross-checks of featureset sizes

2023-05-09 Thread Andrew Cooper
On 08/05/2023 7:47 am, Jan Beulich wrote: > On 04.05.2023 21:39, Andrew Cooper wrote: >> These BUILD_BUG_ON()s exist to cover the curious absence of a diagnostic for >> code which looks like: >> >> uint32_t foo[1] = { 1, 2, 3 }; >> >> However, GCC 12 at least does now warn for this: >> >>

Re: [PATCH v6 2/4] xen/riscv: introduce setup_initial_pages

2023-05-09 Thread Oleksii
On Mon, 2023-05-08 at 10:58 +0200, Jan Beulich wrote: > On 03.05.2023 18:31, Oleksii Kurochko wrote: > > --- a/xen/arch/riscv/include/asm/config.h > > +++ b/xen/arch/riscv/include/asm/config.h > > @@ -70,12 +70,23 @@ > >    name: > >  #endif > >   > > -#define XEN_VIRT_START  _AT(UL, 0x8020) >

Re: [PATCH v2] Fix install.sh for systemd

2023-05-09 Thread Andrew Cooper
On 08/05/2023 6:14 pm, Olaf Hering wrote: > On a fedora system, if you run `sudo sh install.sh` you break your > system. The installation clobbers /var/run, a symlink to /run. A > subsequent boot fails when /var/run and /run are different since > accesses through /var/run can't find items that

[xen-unstable-smoke test] 180588: tolerable all pass - PUSHED

2023-05-09 Thread osstest service owner
flight 180588 xen-unstable-smoke real [real] http://logs.test-lab.xenproject.org/osstest/logs/180588/ Failures :-/ but no regressions. Tests which did not succeed, but are not blocking: test-amd64-amd64-libvirt 15 migrate-support-checkfail never pass test-arm64-arm64-xl-xsm

Re: [patch v3 18/36] [patch V2 18/38] cpu/hotplug: Add CPU state tracking and synchronization

2023-05-09 Thread Thomas Gleixner
On Tue, May 09 2023 at 13:07, Peter Zijlstra wrote: > On Mon, May 08, 2023 at 09:43:55PM +0200, Thomas Gleixner wrote: > >> +static inline void cpuhp_ap_update_sync_state(enum cpuhp_sync_state state) >> +{ >> +atomic_t *st = this_cpu_ptr(_state.ap_sync_state); >> +int sync =

Re: [patch v3 14/36] [patch V2 14/38] cpu/hotplug: Rework sparse_irq locking in bringup_cpu()

2023-05-09 Thread Thomas Gleixner
On Tue, May 09 2023 at 13:02, Peter Zijlstra wrote: > On Mon, May 08, 2023 at 09:43:49PM +0200, Thomas Gleixner wrote: >> From: Thomas Gleixner >> >> There is no harm to hold sparse_irq lock until the upcoming CPU completes >> in cpuhp_online_idle(). This allows to remove cpu_online()

Re: [patch v3 13/36] x86/smpboot: Remove cpu_callin_mask

2023-05-09 Thread Thomas Gleixner
On Tue, May 09 2023 at 12:49, Peter Zijlstra wrote: > On Mon, May 08, 2023 at 09:43:47PM +0200, Thomas Gleixner wrote: >> -/* >> - * Sync point with wait_cpu_callin(). The AP doesn't wait here >> - * but just sets the bit to let the controlling CPU (BSP) know that >> - * it's got

Re: [patch v3 08/36] x86/smpboot: Split up native_cpu_up() into separate phases and document them

2023-05-09 Thread Thomas Gleixner
On Tue, May 09 2023 at 12:31, Peter Zijlstra wrote: > On Mon, May 08, 2023 at 09:43:39PM +0200, Thomas Gleixner wrote: >> +/* >> + * Wait for the AP to mark itself online, so the core caller >> + * can drop sparse_irq_lock. >> + */ >> +while (!cpu_online(cpu)) >> +

Re: [patch v3 08/36] x86/smpboot: Split up native_cpu_up() into separate phases and document them

2023-05-09 Thread Thomas Gleixner
On Tue, May 09 2023 at 12:19, Peter Zijlstra wrote: > On Mon, May 08, 2023 at 09:43:39PM +0200, Thomas Gleixner wrote: >> @@ -1048,60 +1066,89 @@ static int do_boot_cpu(int apicid, int c > > /* >* AP might wait on cpu_callout_mask in cpu_init() with >* cpu_initialized_mask

Re: [patch v3 08/36] x86/smpboot: Split up native_cpu_up() into separate phases and document them

2023-05-09 Thread Thomas Gleixner
On Tue, May 09 2023 at 12:04, Peter Zijlstra wrote: > On Mon, May 08, 2023 at 09:43:39PM +0200, Thomas Gleixner wrote: >> +/* >> + * Sync point with wait_cpu_callin(). The AP doesn't wait here >> + * but just sets the bit to let the controlling CPU (BSP) know that >> + * it's got

Re: [patch v3 18/36] [patch V2 18/38] cpu/hotplug: Add CPU state tracking and synchronization

2023-05-09 Thread Peter Zijlstra
On Tue, May 09, 2023 at 01:07:23PM +0200, Peter Zijlstra wrote: > On Mon, May 08, 2023 at 09:43:55PM +0200, Thomas Gleixner wrote: > > > +static inline void cpuhp_ap_update_sync_state(enum cpuhp_sync_state state) > > +{ > > + atomic_t *st = this_cpu_ptr(_state.ap_sync_state); > > + int sync =

Re: [XEN][PATCH v6 08/19] xen/device-tree: Add device_tree_find_node_by_path() to find nodes in device tree

2023-05-09 Thread Michal Orzel
On 04/05/2023 06:23, Henry Wang wrote: > > > Hi Vikram, > >> -Original Message- >> Subject: [XEN][PATCH v6 08/19] xen/device-tree: Add >> device_tree_find_node_by_path() to find nodes in device tree >> >> Add device_tree_find_node_by_path() to find a matching node with path for >> a

Re: [patch v3 18/36] [patch V2 18/38] cpu/hotplug: Add CPU state tracking and synchronization

2023-05-09 Thread Peter Zijlstra
On Mon, May 08, 2023 at 09:43:55PM +0200, Thomas Gleixner wrote: > +static inline void cpuhp_ap_update_sync_state(enum cpuhp_sync_state state) > +{ > + atomic_t *st = this_cpu_ptr(_state.ap_sync_state); > + int sync = atomic_read(st); > + > + while (!atomic_try_cmpxchg(st, , state));

[PATCH] x86/iommu: fix wrong iterator type in arch_iommu_hwdom_init()

2023-05-09 Thread Roger Pau Monne
The 'i' iterator index stores a pdx, not a pfn, and hence the initial assignation of start (which stores a pfn) needs a conversion from pfn to pdx. Fixes: 6b4f6a31ace1 ('x86/PVH: de-duplicate mappings for first Mb of Dom0 memory') Signed-off-by: Roger Pau Monné ---

Re: [patch v3 14/36] [patch V2 14/38] cpu/hotplug: Rework sparse_irq locking in bringup_cpu()

2023-05-09 Thread Peter Zijlstra
On Mon, May 08, 2023 at 09:43:49PM +0200, Thomas Gleixner wrote: > From: Thomas Gleixner > > There is no harm to hold sparse_irq lock until the upcoming CPU completes > in cpuhp_online_idle(). This allows to remove cpu_online() synchronization > from architecture code. Uhh.. damn. Can you

Re: [XEN][PATCH v6 05/19] xen/arm: Add CONFIG_OVERLAY_DTB

2023-05-09 Thread Michal Orzel
On 04/05/2023 06:11, Henry Wang wrote: > > > Hi Vikram, > >> -Original Message- >> Subject: [XEN][PATCH v6 05/19] xen/arm: Add CONFIG_OVERLAY_DTB >> >> Introduce a config option where the user can enable support for >> adding/removing >> device tree nodes using a device tree binary

Re: [patch v3 13/36] x86/smpboot: Remove cpu_callin_mask

2023-05-09 Thread Peter Zijlstra
On Mon, May 08, 2023 at 09:43:47PM +0200, Thomas Gleixner wrote: > --- a/arch/x86/kernel/smpboot.c > +++ b/arch/x86/kernel/smpboot.c > @@ -167,21 +166,16 @@ static inline void smpboot_restore_warm_ > */ > static void smp_callin(void) > { > - int cpuid; > + int cpuid =

[PATCH] iommu/vtd: fix address translation for superpages

2023-05-09 Thread Roger Pau Monne
When translating an address that falls inside of a superpage in the IOMMU page tables the fetching of the PTE physical address field wasn't using dma_pte_addr(), which caused the returned data to be corrupt as it would contain bits not related to the address field. Fix this by re-using the value

Re: [patch v3 08/36] x86/smpboot: Split up native_cpu_up() into separate phases and document them

2023-05-09 Thread Peter Zijlstra
And since I'm commenting on existing things anyway, let me continue... On Mon, May 08, 2023 at 09:43:39PM +0200, Thomas Gleixner wrote: > +static int wait_cpu_cpumask(unsigned int cpu, const struct cpumask *mask) > +{ > + unsigned long timeout; > > + /* > + * Wait up to 10s for

[PATCH] docs: fix xenstore-paths doc structure

2023-05-09 Thread Yann Dirson
We currently have "Per Domain Paths" as an empty section, whereas it looks like "General Paths" was not indended to include all the following sections. Signed-off-by: Yann Dirson --- docs/misc/xenstore-paths.pandoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

Re: [patch v3 08/36] x86/smpboot: Split up native_cpu_up() into separate phases and document them

2023-05-09 Thread Peter Zijlstra
Again, not really this patch, but since I had to look at this code On Mon, May 08, 2023 at 09:43:39PM +0200, Thomas Gleixner wrote: > @@ -1048,60 +1066,89 @@ static int do_boot_cpu(int apicid, int c /* * AP might wait on cpu_callout_mask in cpu_init() with *

Re: [patch v3 08/36] x86/smpboot: Split up native_cpu_up() into separate phases and document them

2023-05-09 Thread Peter Zijlstra
On Mon, May 08, 2023 at 09:43:39PM +0200, Thomas Gleixner wrote: > @@ -233,14 +237,31 @@ static void notrace start_secondary(void > load_cr3(swapper_pg_dir); > __flush_tlb_all(); > #endif > + /* > + * Sync point with wait_cpu_initialized(). Before proceeding through > +

Re: [PATCH 3/3] x86: Use CpuidUserDis if an AMD HVM guest toggles CPUID faulting

2023-05-09 Thread Andrew Cooper
On 08/05/2023 2:18 pm, Jan Beulich wrote: > On 05.05.2023 19:57, Alejandro Vallejo wrote: >> This is in order to aid guests of AMD hardware that we have exposed >> CPUID faulting to. If they try to modify the Intel MSR that enables >> the feature, trigger levelling so AMD's version of it

Re: [PATCH] docs/man: fix xenstore-write synopsis

2023-05-09 Thread Andrew Cooper
On 09/05/2023 10:01 am, Yann Dirson wrote: > Reported-by: zithro > Signed-off-by: Yann Dirson Oops. Reviewed-by: Andrew Cooper

Re: [patch v3 33/36] x86/apic: Save the APIC virtual base address

2023-05-09 Thread Sergey Shtylyov
Hello! On 5/8/23 10:44 PM, Thomas Gleixner wrote: > From: Thomas Gleixner > > For parallel CPU brinugp it's required to read the APIC ID in the low level > startup code. The virtual APIC base address is a constant because its a > fix-mapped address. Exposing that constant which is composed via

[PATCH] docs/man: fix xenstore-write synopsis

2023-05-09 Thread Yann Dirson
Reported-by: zithro Signed-off-by: Yann Dirson --- docs/man/xenstore-write.1.pod | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/man/xenstore-write.1.pod b/docs/man/xenstore-write.1.pod index a0b1bca333..74f80f7b1b 100644 --- a/docs/man/xenstore-write.1.pod +++

Re: xenstored: EACCESS error accessing control/feature-balloon 1

2023-05-09 Thread Yann Dirson
On 5/4/23 20:04, zithro wrote: > On 04 May 2023 17:59, Yann Dirson wrote: >> >> On 5/4/23 15:58, zithro wrote: >>> Hi, >>> >>> [ snipped for brevity, report summary: >>> XAPI daemon in domU tries to write to a non-existent xenstore node in >>> a non-XAPI dom0 ] >>> >>> On 12 Apr 2023 18:41, Yann

[linux-linus test] 180582: regressions - FAIL

2023-05-09 Thread osstest service owner
flight 180582 linux-linus real [real] flight 180585 linux-linus real-retest [real] http://logs.test-lab.xenproject.org/osstest/logs/180582/ http://logs.test-lab.xenproject.org/osstest/logs/180585/ Regressions :-( Tests which did not succeed and are blocking, including tests which could not be

Re: [PATCH v2] tools: convert bitfields to unsigned type

2023-05-09 Thread Juergen Gross
On 08.05.23 18:46, Olaf Hering wrote: clang complains about the signed type: implicit truncation from 'int' to a one-bit wide bit-field changes value from 1 to -1 [-Wsingle-bit-bitfield-constant-conversion] The potential ABI change in libxenvchan is covered by the Xen version based SONAME.