[linux-6.1 test] 185859: regressions - FAIL

2024-04-28 Thread osstest service owner
flight 185859 linux-6.1 real [real]
http://logs.test-lab.xenproject.org/osstest/logs/185859/

Regressions :-(

Tests which did not succeed and are blocking,
including tests which could not be run:
 build-armhf-pvops 6 kernel-build fail REGR. vs. 185746

Tests which did not succeed, but are not blocking:
 test-armhf-armhf-examine  1 build-check(1)   blocked  n/a
 test-armhf-armhf-libvirt  1 build-check(1)   blocked  n/a
 test-armhf-armhf-libvirt-vhd  1 build-check(1)   blocked  n/a
 test-armhf-armhf-xl   1 build-check(1)   blocked  n/a
 test-armhf-armhf-xl-arndale   1 build-check(1)   blocked  n/a
 test-armhf-armhf-xl-credit1   1 build-check(1)   blocked  n/a
 test-armhf-armhf-xl-credit2   1 build-check(1)   blocked  n/a
 test-armhf-armhf-xl-multivcpu  1 build-check(1)   blocked  n/a
 test-armhf-armhf-xl-qcow2 1 build-check(1)   blocked  n/a
 test-armhf-armhf-xl-raw   1 build-check(1)   blocked  n/a
 test-armhf-armhf-xl-rtds  1 build-check(1)   blocked  n/a
 test-amd64-amd64-xl-qemuu-win7-amd64 19 guest-stopfail like 185746
 test-amd64-amd64-xl-qemuu-ws16-amd64 19 guest-stopfail like 185746
 test-amd64-amd64-xl-qemut-win7-amd64 19 guest-stopfail like 185746
 test-amd64-amd64-xl-qemut-ws16-amd64 19 guest-stopfail like 185746
 test-amd64-amd64-qemuu-nested-amd 20 debian-hvm-install/l1/l2 fail like 185746
 test-amd64-amd64-libvirt 15 migrate-support-checkfail   never pass
 test-amd64-amd64-libvirt-xsm 15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-thunderx 15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-thunderx 16 saverestore-support-checkfail   never pass
 test-arm64-arm64-libvirt-xsm 15 migrate-support-checkfail   never pass
 test-arm64-arm64-libvirt-xsm 16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl  16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-credit1  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-credit1  16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-credit2  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-credit2  16 saverestore-support-checkfail   never pass
 test-amd64-amd64-libvirt-qemuu-debianhvm-amd64-xsm 13 migrate-support-check 
fail never pass
 test-arm64-arm64-xl-xsm  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-xsm  16 saverestore-support-checkfail   never pass
 test-amd64-amd64-libvirt-qcow2 14 migrate-support-checkfail never pass
 test-amd64-amd64-libvirt-raw 14 migrate-support-checkfail   never pass
 test-amd64-amd64-libvirt-vhd 14 migrate-support-checkfail   never pass
 test-arm64-arm64-libvirt-raw 14 migrate-support-checkfail   never pass
 test-arm64-arm64-libvirt-raw 15 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-vhd  14 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-vhd  15 saverestore-support-checkfail   never pass

version targeted for testing:
 linuxf2295faba5e8249ae4082791bfc1664c88fff83a
baseline version:
 linux6741e066ec7633450d3186946035c1f80c4226b8

Last test of basis   185746  2024-04-20 18:14:28 Z8 days
Testing same since   185832  2024-04-27 15:44:00 Z1 days4 attempts


People who touched revisions under test:
  Ai Chao 
  Alan Stern 
  Alex Deucher 
  Alexander Gordeev 
  Alexander Usyskin 
  Alexey Izbyshev 
  Alvaro Karsz 
  Andi Shyti 
  Andrew Morton 
  AngeloGioacchino Del Regno 
  Ard Biesheuvel 
  Arnd Bergmann 
  Arınç ÜNAL 
  Bjorn Helgaas 
  bolan wang 
  Borislav Petkov (AMD) 
  Borislav Petkov 
  Brenton Simpson 
  Carlos Llamas 
  Carolina Jubran 
  Catalin Marinas 
  Chinmoy Ghosh 
  Christophe JAILLET 
  Chuanhong Guo 
  Chuck Lever 
  Coia Prant 
  Daniel Golle 
  Daniele Palmas 
  Danilo Krummrich 
  Dave Airlie 
  Dave Hansen 
  David S. Miller 
  David Yang 
  Dillon Varone 
  Dmitry Baryshkov 
  Dmitry Torokhov 
  Emil Kronborg 
  Eric Biggers 
  Finn Thain 
  Florian Fainelli 
  Florian Westphal 
  Geoffrey D. Bennett 
  Gil Fine 
  Greg Kroah-Hartman 
  H. Peter Anvin (Intel) 
  Hamza Mahfooz 
  Hans de Goede 
  Hardik Gajjar 
  Hawking Zhang 
  Hou Wenlong 
  Ilpo Järvinen 
  Ingo Molnar 
  Jakub Kicinski 
  Janusz Krzysztofik 
  Jarkko Nikula 
  Jason A. Donenfeld 
  Jason Wang 
  Jens Axboe 
  Jeongjun Park 
  Jerry Meng 
  Jiri Kosina 
  Johan Hovold 
  Johan Hovold 
  Jose Ignacio Tornos Martinez 
  Josh Poimboeuf 
  Kai-Heng Feng 
  Kelvin Cao 
  kernelci.org bot 
  Konrad Dybcio 
  Kuniyuki Iwashima 
  Lei Chen 

[linux-linus test] 185858: tolerable FAIL - PUSHED

2024-04-28 Thread osstest service owner
flight 185858 linux-linus real [real]
flight 185861 linux-linus real-retest [real]
http://logs.test-lab.xenproject.org/osstest/logs/185858/
http://logs.test-lab.xenproject.org/osstest/logs/185861/

Failures :-/ but no regressions.

Tests which are failing intermittently (not blocking):
 test-armhf-armhf-xl-qcow2 8 xen-bootfail pass in 185861-retest
 test-armhf-armhf-xl-credit1   8 xen-bootfail pass in 185861-retest
 test-armhf-armhf-examine  8 reboot  fail pass in 185861-retest

Tests which did not succeed, but are not blocking:
 test-armhf-armhf-xl-credit1 15 migrate-support-check fail in 185861 never pass
 test-armhf-armhf-xl-credit1 16 saverestore-support-check fail in 185861 never 
pass
 test-armhf-armhf-xl-qcow2   14 migrate-support-check fail in 185861 never pass
 test-armhf-armhf-xl-qcow2 15 saverestore-support-check fail in 185861 never 
pass
 test-amd64-amd64-xl-qemut-win7-amd64 19 guest-stopfail like 185845
 test-amd64-amd64-xl-qemuu-win7-amd64 19 guest-stopfail like 185845
 test-amd64-amd64-xl-qemuu-ws16-amd64 19 guest-stopfail like 185845
 test-armhf-armhf-libvirt 16 saverestore-support-checkfail  like 185845
 test-amd64-amd64-qemuu-nested-amd 20 debian-hvm-install/l1/l2 fail like 185845
 test-amd64-amd64-xl-qemut-ws16-amd64 19 guest-stopfail like 185845
 test-amd64-amd64-libvirt 15 migrate-support-checkfail   never pass
 test-amd64-amd64-libvirt-xsm 15 migrate-support-checkfail   never pass
 test-amd64-amd64-libvirt-qemuu-debianhvm-amd64-xsm 13 migrate-support-check 
fail never pass
 test-arm64-arm64-libvirt-xsm 15 migrate-support-checkfail   never pass
 test-arm64-arm64-libvirt-xsm 16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-credit1  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-xsm  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-credit1  16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-xsm  16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-thunderx 15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-thunderx 16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-credit2  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-credit2  16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl  16 saverestore-support-checkfail   never pass
 test-armhf-armhf-xl  15 migrate-support-checkfail   never pass
 test-armhf-armhf-xl  16 saverestore-support-checkfail   never pass
 test-amd64-amd64-libvirt-qcow2 14 migrate-support-checkfail never pass
 test-amd64-amd64-libvirt-raw 14 migrate-support-checkfail   never pass
 test-armhf-armhf-xl-multivcpu 15 migrate-support-checkfail  never pass
 test-armhf-armhf-xl-multivcpu 16 saverestore-support-checkfail  never pass
 test-armhf-armhf-xl-arndale  15 migrate-support-checkfail   never pass
 test-armhf-armhf-xl-arndale  16 saverestore-support-checkfail   never pass
 test-amd64-amd64-libvirt-vhd 14 migrate-support-checkfail   never pass
 test-arm64-arm64-libvirt-raw 14 migrate-support-checkfail   never pass
 test-arm64-arm64-libvirt-raw 15 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-vhd  14 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-vhd  15 saverestore-support-checkfail   never pass
 test-armhf-armhf-libvirt-vhd 14 migrate-support-checkfail   never pass
 test-armhf-armhf-libvirt-vhd 15 saverestore-support-checkfail   never pass
 test-armhf-armhf-xl-raw  14 migrate-support-checkfail   never pass
 test-armhf-armhf-xl-raw  15 saverestore-support-checkfail   never pass
 test-armhf-armhf-xl-rtds 15 migrate-support-checkfail   never pass
 test-armhf-armhf-xl-rtds 16 saverestore-support-checkfail   never pass
 test-armhf-armhf-xl-credit2  15 migrate-support-checkfail   never pass
 test-armhf-armhf-xl-credit2  16 saverestore-support-checkfail   never pass
 test-armhf-armhf-libvirt 15 migrate-support-checkfail   never pass

version targeted for testing:
 linux245c8e81741b51fe1281964e4a6525311be6858f
baseline version:
 linux2c8159388952f530bd260e097293ccc0209240be

Last test of basis   185845  2024-04-28 04:00:20 Z1 days
Testing same since   185858  2024-04-28 19:42:05 Z0 days1 attempts


People who touched revisions under test:
  Borislav Petkov (AMD) 
  Chen Yu 
  Dave Hansen 
  David Kaplan 
  Frederic Weisbecker 
  Guanrui Huang 
  Ingo Molnar 
  Josh Poimboeuf 
  K Prateek Nayak 
  Kirill A. Shutemov 
  Linus Torvalds 
  Oleg Nesterov 
  

Re: [PATCH 07/15] xen/overlay: Enable device tree overlay assignment to running domains

2024-04-28 Thread Henry Wang

Hi Jan, Julien, Stefano,

On 4/24/2024 2:05 PM, Jan Beulich wrote:

On 24.04.2024 05:34, Henry Wang wrote:

--- a/xen/include/public/sysctl.h
+++ b/xen/include/public/sysctl.h
@@ -1197,7 +1197,9 @@ struct xen_sysctl_dt_overlay {
  #define XEN_SYSCTL_DT_OVERLAY_ADD   1
  #define XEN_SYSCTL_DT_OVERLAY_REMOVE2
  uint8_t overlay_op; /* IN: Add or remove. */
-uint8_t pad[3]; /* IN: Must be zero. */
+bool domain_mapping;/* IN: True of False. */
+uint8_t pad[2]; /* IN: Must be zero. */
+uint32_t domain_id;
  };

If you merely re-purposed padding fields, all would be fine without
bumping the interface version. Yet you don't, albeit for an unclear
reason: Why uint32_t rather than domid_t? And on top of that - why a
separate boolean when you could use e.g. DOMID_INVALID to indicate
"no domain mapping"?


I think both of your suggestion make great sense. I will follow the 
suggestion in v2.



That said - anything taking a domain ID is certainly suspicious in a
sysctl. Judging from the description you really mean this to be a
domctl. Anything else will require extra justification.


I also think a domctl is better. I had a look at the history of the 
already merged series, it looks like in the first version of merged part 
1 [1], the hypercall was implemented as the domctl in the beginning but 
later in v2 changed to sysctl. I think this makes sense as the scope of 
that time is just to make Xen aware of the device tree node via Xen 
device tree.


However this is now a problem for the current part where the scope (and 
the end goal) is extended to assign the added device to Linux Dom0/DomU 
via device tree overlays. I am not sure which way is better, should we 
repurposing the sysctl to domctl or maybe add another domctl (I am 
worrying about the duplication because basically we need the same sysctl 
functionality but now with a domid in it)? What do you think?


@Stefano: Since I am not 100% if I understand the whole story behind 
this feature, would you mind checking if I am providing correct 
information above and sharing your opinions on this? Thank you very much!


[1] 
https://lore.kernel.org/xen-devel/13240b69-f7bb-6a64-b89c-b7c2cbb7e...@xen.org/


Kind regards,
Henry


Jan





[linux-6.1 test] 185849: regressions - FAIL

2024-04-28 Thread osstest service owner
flight 185849 linux-6.1 real [real]
http://logs.test-lab.xenproject.org/osstest/logs/185849/

Regressions :-(

Tests which did not succeed and are blocking,
including tests which could not be run:
 build-armhf-pvops 6 kernel-build fail REGR. vs. 185746

Tests which are failing intermittently (not blocking):
 test-amd64-amd64-xl-qemuu-debianhvm-amd64-shadow 17 guest-saverestore.2 fail 
in 185835 pass in 185849
 test-amd64-amd64-xl-qemut-debianhvm-amd64 20 guest-start/debianhvm.repeat fail 
pass in 185835

Tests which did not succeed, but are not blocking:
 test-armhf-armhf-examine  1 build-check(1)   blocked  n/a
 test-armhf-armhf-libvirt  1 build-check(1)   blocked  n/a
 test-armhf-armhf-libvirt-vhd  1 build-check(1)   blocked  n/a
 test-armhf-armhf-xl   1 build-check(1)   blocked  n/a
 test-armhf-armhf-xl-arndale   1 build-check(1)   blocked  n/a
 test-armhf-armhf-xl-credit1   1 build-check(1)   blocked  n/a
 test-armhf-armhf-xl-credit2   1 build-check(1)   blocked  n/a
 test-armhf-armhf-xl-multivcpu  1 build-check(1)   blocked  n/a
 test-armhf-armhf-xl-qcow2 1 build-check(1)   blocked  n/a
 test-armhf-armhf-xl-raw   1 build-check(1)   blocked  n/a
 test-armhf-armhf-xl-rtds  1 build-check(1)   blocked  n/a
 test-amd64-amd64-xl-qemuu-win7-amd64 19 guest-stopfail like 185746
 test-amd64-amd64-xl-qemuu-ws16-amd64 19 guest-stopfail like 185746
 test-amd64-amd64-xl-qemut-win7-amd64 19 guest-stopfail like 185746
 test-amd64-amd64-xl-qemut-ws16-amd64 19 guest-stopfail like 185746
 test-amd64-amd64-qemuu-nested-amd 20 debian-hvm-install/l1/l2 fail like 185746
 test-amd64-amd64-libvirt 15 migrate-support-checkfail   never pass
 test-amd64-amd64-libvirt-xsm 15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-thunderx 15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-thunderx 16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl  16 saverestore-support-checkfail   never pass
 test-arm64-arm64-libvirt-xsm 15 migrate-support-checkfail   never pass
 test-arm64-arm64-libvirt-xsm 16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-credit1  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-credit1  16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-xsm  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-xsm  16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-credit2  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-credit2  16 saverestore-support-checkfail   never pass
 test-amd64-amd64-libvirt-qemuu-debianhvm-amd64-xsm 13 migrate-support-check 
fail never pass
 test-amd64-amd64-libvirt-qcow2 14 migrate-support-checkfail never pass
 test-amd64-amd64-libvirt-raw 14 migrate-support-checkfail   never pass
 test-amd64-amd64-libvirt-vhd 14 migrate-support-checkfail   never pass
 test-arm64-arm64-libvirt-raw 14 migrate-support-checkfail   never pass
 test-arm64-arm64-libvirt-raw 15 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-vhd  14 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-vhd  15 saverestore-support-checkfail   never pass

version targeted for testing:
 linuxf2295faba5e8249ae4082791bfc1664c88fff83a
baseline version:
 linux6741e066ec7633450d3186946035c1f80c4226b8

Last test of basis   185746  2024-04-20 18:14:28 Z8 days
Testing same since   185832  2024-04-27 15:44:00 Z1 days3 attempts


People who touched revisions under test:
  Ai Chao 
  Alan Stern 
  Alex Deucher 
  Alexander Gordeev 
  Alexander Usyskin 
  Alexey Izbyshev 
  Alvaro Karsz 
  Andi Shyti 
  Andrew Morton 
  AngeloGioacchino Del Regno 
  Ard Biesheuvel 
  Arnd Bergmann 
  Arınç ÜNAL 
  Bjorn Helgaas 
  bolan wang 
  Borislav Petkov (AMD) 
  Borislav Petkov 
  Brenton Simpson 
  Carlos Llamas 
  Carolina Jubran 
  Catalin Marinas 
  Chinmoy Ghosh 
  Christophe JAILLET 
  Chuanhong Guo 
  Chuck Lever 
  Coia Prant 
  Daniel Golle 
  Daniele Palmas 
  Danilo Krummrich 
  Dave Airlie 
  Dave Hansen 
  David S. Miller 
  David Yang 
  Dillon Varone 
  Dmitry Baryshkov 
  Dmitry Torokhov 
  Emil Kronborg 
  Eric Biggers 
  Finn Thain 
  Florian Fainelli 
  Florian Westphal 
  Geoffrey D. Bennett 
  Gil Fine 
  Greg Kroah-Hartman 
  H. Peter Anvin (Intel) 
  Hamza Mahfooz 
  Hans de Goede 
  Hardik Gajjar 
  Hawking Zhang 
  Hou Wenlong 
  Ilpo Järvinen 
  Ingo Molnar 
  Jakub Kicinski 
  Janusz Krzysztofik 
  Jarkko Nikula 
  Jason A. Donenfeld 

[linux-linus test] 185845: tolerable FAIL - PUSHED

2024-04-28 Thread osstest service owner
flight 185845 linux-linus real [real]
flight 185857 linux-linus real-retest [real]
http://logs.test-lab.xenproject.org/osstest/logs/185845/
http://logs.test-lab.xenproject.org/osstest/logs/185857/

Failures :-/ but no regressions.

Tests which are failing intermittently (not blocking):
 test-armhf-armhf-xl-multivcpu  8 xen-boot   fail pass in 185857-retest
 test-armhf-armhf-xl-raw   8 xen-bootfail pass in 185857-retest
 test-armhf-armhf-xl-arndale   8 xen-bootfail pass in 185857-retest
 test-amd64-amd64-libvirt-raw 19 guest-start/debian.repeat fail pass in 
185857-retest

Tests which did not succeed, but are not blocking:
 test-armhf-armhf-xl-multivcpu 15 migrate-support-check fail in 185857 never 
pass
 test-armhf-armhf-xl-multivcpu 16 saverestore-support-check fail in 185857 
never pass
 test-armhf-armhf-xl-arndale 15 migrate-support-check fail in 185857 never pass
 test-armhf-armhf-xl-arndale 16 saverestore-support-check fail in 185857 never 
pass
 test-armhf-armhf-xl-raw 14 migrate-support-check fail in 185857 never pass
 test-armhf-armhf-xl-raw 15 saverestore-support-check fail in 185857 never pass
 test-amd64-amd64-xl-qemut-win7-amd64 19 guest-stopfail like 185833
 test-amd64-amd64-xl-qemuu-win7-amd64 19 guest-stopfail like 185833
 test-amd64-amd64-xl-qemuu-ws16-amd64 19 guest-stopfail like 185833
 test-armhf-armhf-libvirt 16 saverestore-support-checkfail  like 185833
 test-amd64-amd64-qemuu-nested-amd 20 debian-hvm-install/l1/l2 fail like 185833
 test-amd64-amd64-xl-qemut-ws16-amd64 19 guest-stopfail like 185833
 test-amd64-amd64-libvirt 15 migrate-support-checkfail   never pass
 test-amd64-amd64-libvirt-xsm 15 migrate-support-checkfail   never pass
 test-amd64-amd64-libvirt-qemuu-debianhvm-amd64-xsm 13 migrate-support-check 
fail never pass
 test-arm64-arm64-libvirt-xsm 15 migrate-support-checkfail   never pass
 test-arm64-arm64-libvirt-xsm 16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-credit1  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-xsm  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-credit1  16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-xsm  16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-thunderx 15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-thunderx 16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-credit2  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-credit2  16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl  16 saverestore-support-checkfail   never pass
 test-armhf-armhf-xl  15 migrate-support-checkfail   never pass
 test-armhf-armhf-xl  16 saverestore-support-checkfail   never pass
 test-amd64-amd64-libvirt-qcow2 14 migrate-support-checkfail never pass
 test-amd64-amd64-libvirt-raw 14 migrate-support-checkfail   never pass
 test-amd64-amd64-libvirt-vhd 14 migrate-support-checkfail   never pass
 test-armhf-armhf-xl-credit1  15 migrate-support-checkfail   never pass
 test-armhf-armhf-xl-credit1  16 saverestore-support-checkfail   never pass
 test-arm64-arm64-libvirt-raw 14 migrate-support-checkfail   never pass
 test-arm64-arm64-libvirt-raw 15 saverestore-support-checkfail   never pass
 test-armhf-armhf-xl-qcow214 migrate-support-checkfail   never pass
 test-armhf-armhf-xl-qcow215 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-vhd  14 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-vhd  15 saverestore-support-checkfail   never pass
 test-armhf-armhf-libvirt-vhd 14 migrate-support-checkfail   never pass
 test-armhf-armhf-libvirt-vhd 15 saverestore-support-checkfail   never pass
 test-armhf-armhf-xl-rtds 15 migrate-support-checkfail   never pass
 test-armhf-armhf-xl-rtds 16 saverestore-support-checkfail   never pass
 test-armhf-armhf-xl-credit2  15 migrate-support-checkfail   never pass
 test-armhf-armhf-xl-credit2  16 saverestore-support-checkfail   never pass
 test-armhf-armhf-libvirt 15 migrate-support-checkfail   never pass

version targeted for testing:
 linux2c8159388952f530bd260e097293ccc0209240be
baseline version:
 linux5d12ed4bea4343ca3adbe3c23c8d149485de5010

Last test of basis   185833  2024-04-27 18:43:42 Z0 days
Testing same since   185845  2024-04-28 04:00:20 Z0 days1 attempts


People who touched revisions under test:
  Alice Ryhl 
  Andrew Jones 
  Aswin Unnikrishnan 
  Ben Zong-You Xie 
  Benno Lossin 
  Bo-Wei Chen 
  Christoph Müllner 
  

[PATCH v2 2/7] tools/xl: Add max_altp2m parameter

2024-04-28 Thread Petr Beneš
From: Petr Beneš 

Introduce a new max_altp2m parameter to control the maximum number of altp2m
views a domain can use. By default, if max_altp2m is unspecified and altp2m is
enabled, the value is set to 10, reflecting the legacy behavior.

This change is preparatory; it establishes the groundwork for the feature but
does not activate it.

Signed-off-by: Petr Beneš 
---
Changed since v1:
  * Removed the change of xen/include/public/domctl.h (moved into future commit)
  * Removed corresponding assignment of xen_domctl_createdomain::max_altp2m
in libxl_create.c (moved into future commit)
  * Clarify in commit message that this change is preparatory

 tools/golang/xenlight/helpers.gen.go | 2 ++
 tools/golang/xenlight/types.gen.go   | 1 +
 tools/include/libxl.h| 8 
 tools/libs/light/libxl_create.c  | 8 
 tools/libs/light/libxl_types.idl | 1 +
 tools/xl/xl_parse.c  | 4 
 6 files changed, 24 insertions(+)

diff --git a/tools/golang/xenlight/helpers.gen.go 
b/tools/golang/xenlight/helpers.gen.go
index 78bdb08b15..4458d5bcbb 100644
--- a/tools/golang/xenlight/helpers.gen.go
+++ b/tools/golang/xenlight/helpers.gen.go
@@ -1158,6 +1158,7 @@ if err := 
x.ArchX86.MsrRelaxed.fromC(_x86.msr_relaxed);err != nil {
 return fmt.Errorf("converting field ArchX86.MsrRelaxed: %v", err)
 }
 x.Altp2M = Altp2MMode(xc.altp2m)
+x.MaxAltp2M = uint32(xc.max_altp2m)
 x.VmtraceBufKb = int(xc.vmtrace_buf_kb)
 if err := x.Vpmu.fromC();err != nil {
 return fmt.Errorf("converting field Vpmu: %v", err)
@@ -1674,6 +1675,7 @@ if err := 
x.ArchX86.MsrRelaxed.toC(_x86.msr_relaxed); err != nil {
 return fmt.Errorf("converting field ArchX86.MsrRelaxed: %v", err)
 }
 xc.altp2m = C.libxl_altp2m_mode(x.Altp2M)
+xc.max_altp2m = C.uint32_t(x.MaxAltp2M)
 xc.vmtrace_buf_kb = C.int(x.VmtraceBufKb)
 if err := x.Vpmu.toC(); err != nil {
 return fmt.Errorf("converting field Vpmu: %v", err)
diff --git a/tools/golang/xenlight/types.gen.go 
b/tools/golang/xenlight/types.gen.go
index ccfe18019e..7139bcf324 100644
--- a/tools/golang/xenlight/types.gen.go
+++ b/tools/golang/xenlight/types.gen.go
@@ -602,6 +602,7 @@ ArchX86 struct {
 MsrRelaxed Defbool
 }
 Altp2M Altp2MMode
+MaxAltp2M uint32
 VmtraceBufKb int
 Vpmu Defbool
 }
diff --git a/tools/include/libxl.h b/tools/include/libxl.h
index 62cb07dea6..c73d9f2ff1 100644
--- a/tools/include/libxl.h
+++ b/tools/include/libxl.h
@@ -1239,6 +1239,14 @@ typedef struct libxl__ctx libxl_ctx;
  */
 #define LIBXL_HAVE_ALTP2M 1

+/*
+ * LIBXL_HAVE_MAX_ALTP2M
+ * If this is defined, then libxl supports setting the maximum number of
+ * alternate p2m tables.
+ */
+#define LIBXL_HAVE_MAX_ALTP2M 1
+#define LIBXL_MAX_ALTP2M_DEFAULT (~(uint32_t)0)
+
 /*
  * LIBXL_HAVE_REMUS
  * If this is defined, then libxl supports remus.
diff --git a/tools/libs/light/libxl_create.c b/tools/libs/light/libxl_create.c
index 41252ec553..801f704a02 100644
--- a/tools/libs/light/libxl_create.c
+++ b/tools/libs/light/libxl_create.c
@@ -483,6 +483,14 @@ int libxl__domain_build_info_setdefault(libxl__gc *gc,
 return -ERROR_INVAL;
 }

+if (b_info->max_altp2m == LIBXL_MAX_ALTP2M_DEFAULT) {
+if ((libxl_defbool_val(b_info->u.hvm.altp2m) ||
+b_info->altp2m != LIBXL_ALTP2M_MODE_DISABLED))
+b_info->max_altp2m = 10;
+else
+b_info->max_altp2m = 0;
+}
+
 /* Assume that providing a bootloader user implies enabling restrict. */
 libxl_defbool_setdefault(_info->bootloader_restrict,
  !!b_info->bootloader_user);
diff --git a/tools/libs/light/libxl_types.idl b/tools/libs/light/libxl_types.idl
index 470122e768..c887d8ea8c 100644
--- a/tools/libs/light/libxl_types.idl
+++ b/tools/libs/light/libxl_types.idl
@@ -728,6 +728,7 @@ libxl_domain_build_info = Struct("domain_build_info",[
 # Alternate p2m is not bound to any architecture or guest type, as it is
 # supported by x86 HVM and ARM support is planned.
 ("altp2m", libxl_altp2m_mode),
+("max_altp2m", uint32, {'init_val': 'LIBXL_MAX_ALTP2M_DEFAULT'}),

 # Size of preallocated vmtrace trace buffers (in KBYTES).
 # Use zero value to disable this feature.
diff --git a/tools/xl/xl_parse.c b/tools/xl/xl_parse.c
index ab09d0288b..741668e10a 100644
--- a/tools/xl/xl_parse.c
+++ b/tools/xl/xl_parse.c
@@ -2061,6 +2061,10 @@ void parse_config_data(const char *config_source,
 }
 }

+if (!xlu_cfg_get_long(config, "max_altp2m", , 1)) {
+b_info->max_altp2m = l;
+}
+
 if (!xlu_cfg_get_long(config, "vmtrace_buf_kb", , 1) && l) {
 b_info->vmtrace_buf_kb = l;
 }
--
2.34.1




[PATCH v2 6/7] tools/ocaml: Add max_altp2m parameter

2024-04-28 Thread Petr Beneš
From: Petr Beneš 

Allow developers using the OCaml bindings to set the max_altp2m parameter.

Signed-off-by: Petr Beneš 
Acked-by: Christian Lindig 
---
Changed since v1:
  * Moved this commit AFTER Xen changes (where 
xen_domctl_createdomain::max_altp2m field
is introduced) to avoid breaking the build

 tools/ocaml/libs/xc/xenctrl.ml  |  1 +
 tools/ocaml/libs/xc/xenctrl.mli |  1 +
 tools/ocaml/libs/xc/xenctrl_stubs.c | 17 ++---
 3 files changed, 12 insertions(+), 7 deletions(-)

diff --git a/tools/ocaml/libs/xc/xenctrl.ml b/tools/ocaml/libs/xc/xenctrl.ml
index 55923857ec..ed851bb071 100644
--- a/tools/ocaml/libs/xc/xenctrl.ml
+++ b/tools/ocaml/libs/xc/xenctrl.ml
@@ -82,6 +82,7 @@ type domctl_create_config =
 iommu_opts: domain_create_iommu_opts list;
 max_vcpus: int;
 max_evtchn_port: int;
+max_altp2m: int;
 max_grant_frames: int;
 max_maptrack_frames: int;
 max_grant_version: int;
diff --git a/tools/ocaml/libs/xc/xenctrl.mli b/tools/ocaml/libs/xc/xenctrl.mli
index 9b4b45db3a..971b269d85 100644
--- a/tools/ocaml/libs/xc/xenctrl.mli
+++ b/tools/ocaml/libs/xc/xenctrl.mli
@@ -74,6 +74,7 @@ type domctl_create_config = {
   iommu_opts: domain_create_iommu_opts list;
   max_vcpus: int;
   max_evtchn_port: int;
+  max_altp2m: int;
   max_grant_frames: int;
   max_maptrack_frames: int;
   max_grant_version: int;
diff --git a/tools/ocaml/libs/xc/xenctrl_stubs.c 
b/tools/ocaml/libs/xc/xenctrl_stubs.c
index 2b6d3c09df..0b70cc9b08 100644
--- a/tools/ocaml/libs/xc/xenctrl_stubs.c
+++ b/tools/ocaml/libs/xc/xenctrl_stubs.c
@@ -207,12 +207,13 @@ CAMLprim value stub_xc_domain_create(value xch_val, value 
wanted_domid, value co
 #define VAL_IOMMU_OPTS  Field(config, 3)
 #define VAL_MAX_VCPUS   Field(config, 4)
 #define VAL_MAX_EVTCHN_PORT Field(config, 5)
-#define VAL_MAX_GRANT_FRAMESField(config, 6)
-#define VAL_MAX_MAPTRACK_FRAMES Field(config, 7)
-#define VAL_MAX_GRANT_VERSION   Field(config, 8)
-#define VAL_VMTRACE_BUF_KB  Field(config, 9)
-#define VAL_CPUPOOL_ID  Field(config, 10)
-#define VAL_ARCHField(config, 11)
+#define VAL_MAX_ALTP2M  Field(config, 6)
+#define VAL_MAX_GRANT_FRAMESField(config, 7)
+#define VAL_MAX_MAPTRACK_FRAMES Field(config, 8)
+#define VAL_MAX_GRANT_VERSION   Field(config, 9)
+#define VAL_VMTRACE_BUF_KB  Field(config, 10)
+#define VAL_CPUPOOL_ID  Field(config, 11)
+#define VAL_ARCHField(config, 12)

uint32_t domid = Int_val(wanted_domid);
uint64_t vmtrace_size = Int32_val(VAL_VMTRACE_BUF_KB);
@@ -226,6 +227,7 @@ CAMLprim value stub_xc_domain_create(value xch_val, value 
wanted_domid, value co
.ssidref = Int32_val(VAL_SSIDREF),
.max_vcpus = Int_val(VAL_MAX_VCPUS),
.max_evtchn_port = Int_val(VAL_MAX_EVTCHN_PORT),
+   .max_altp2m = Int_val(VAL_MAX_ALTP2M),
.max_grant_frames = Int_val(VAL_MAX_GRANT_FRAMES),
.max_maptrack_frames = Int_val(VAL_MAX_MAPTRACK_FRAMES),
.grant_opts =
@@ -257,7 +259,7 @@ CAMLprim value stub_xc_domain_create(value xch_val, value 
wanted_domid, value co
 #if defined(__i386__) || defined(__x86_64__)

/* Quick & dirty check for ABI changes. */
-   BUILD_BUG_ON(sizeof(cfg) != 64);
+   BUILD_BUG_ON(sizeof(cfg) != 68);

 /* Mnemonics for the named fields inside xen_x86_arch_domainconfig */
 #define VAL_EMUL_FLAGS  Field(arch_domconfig, 0)
@@ -291,6 +293,7 @@ CAMLprim value stub_xc_domain_create(value xch_val, value 
wanted_domid, value co
 #undef VAL_MAX_GRANT_VERSION
 #undef VAL_MAX_MAPTRACK_FRAMES
 #undef VAL_MAX_GRANT_FRAMES
+#undef VAL_MAX_ALTP2M
 #undef VAL_MAX_EVTCHN_PORT
 #undef VAL_MAX_VCPUS
 #undef VAL_IOMMU_OPTS
--
2.34.1




[PATCH v2 0/7] x86: Make MAX_ALTP2M configurable

2024-04-28 Thread Petr Beneš
From: Petr Beneš 

This series introduces the ability to configure the maximum number of altp2m
tables during domain creation. Previously, the limits were hardcoded to a
maximum of 10. This change allows for greater flexibility in environments that
require more or fewer altp2m views.

Adjustments include:
- "Prepare" commits with style changes.
- Adding a new `max_altp2m` parameter to xl.
- Adding a new `max_altp2m` parameter to the OCaml bindings.
- Adding a new `max_altp2m` parameter to the xl.cfg manual.
- Adding a new `max_altp2m` field into the `xen_domctl_createdomain`, which,
  after sanity checks, is stored in newly introduced `max_altp2m` field of
  `struct domain` - leaving room for other architectures to implement the
  altp2m feature.
- Replacing MAX_ALTP2M macro occurrences with `domain->max_altp2m`.
- Finally, adjusting the initial allocation of pages in `hap_enable` from 256
  to 1024 pages to accommodate potentially larger `max_altp2m` values (i.e.,
  maximum of 512).

This enhancement is particularly relevant for users leveraging Xen's features
for virtual machine introspection.

Petr Beneš (7):
  x86/p2m: Add braces for better code clarity
  tools/xl: Add max_altp2m parameter
  docs/man: Add max_altp2m parameter to the xl.cfg manual
  x86: Make the maximum number of altp2m views configurable
  tools/libxl: Activate the max_altp2m feature
  tools/ocaml: Add max_altp2m parameter
  x86/hap: Increase the number of initial mempool_size to 1024 pages

 docs/man/xl.cfg.5.pod.in  | 14 +
 tools/golang/xenlight/helpers.gen.go  |  2 +
 tools/golang/xenlight/types.gen.go|  1 +
 tools/include/libxl.h |  8 +++
 tools/libs/light/libxl_create.c   |  9 
 tools/libs/light/libxl_types.idl  |  1 +
 tools/ocaml/libs/xc/xenctrl.ml|  1 +
 tools/ocaml/libs/xc/xenctrl.mli   |  1 +
 tools/ocaml/libs/xc/xenctrl_stubs.c   | 17 +++---
 .../paging-mempool/test-paging-mempool.c  |  2 +-
 tools/xl/xl_parse.c   |  4 ++
 xen/arch/x86/domain.c |  6 +++
 xen/arch/x86/hvm/hvm.c|  8 ++-
 xen/arch/x86/hvm/vmx/vmx.c|  2 +-
 xen/arch/x86/include/asm/domain.h |  7 ++-
 xen/arch/x86/include/asm/p2m.h|  4 +-
 xen/arch/x86/mm/altp2m.c  | 27 +-
 xen/arch/x86/mm/hap/hap.c |  8 +--
 xen/arch/x86/mm/mem_access.c  | 14 ++---
 xen/arch/x86/mm/mem_sharing.c |  2 +-
 xen/arch/x86/mm/p2m-ept.c |  6 +--
 xen/arch/x86/mm/p2m.c | 54 ++-
 xen/common/domain.c   |  7 +++
 xen/include/public/domctl.h   |  3 +-
 xen/include/xen/sched.h   |  2 +
 25 files changed, 151 insertions(+), 59 deletions(-)

--
2.34.1




[PATCH v2 5/7] tools/libxl: Activate the max_altp2m feature

2024-04-28 Thread Petr Beneš
From: Petr Beneš 

This commit activates the previously introduced max_altp2m parameter,
establishing the connection between libxl and Xen.

Signed-off-by: Petr Beneš 
---
Changed since v1:
  * This is a new commit in the series

 tools/libs/light/libxl_create.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/tools/libs/light/libxl_create.c b/tools/libs/light/libxl_create.c
index 801f704a02..6ccc1fa158 100644
--- a/tools/libs/light/libxl_create.c
+++ b/tools/libs/light/libxl_create.c
@@ -653,6 +653,7 @@ int libxl__domain_make(libxl__gc *gc, libxl_domain_config 
*d_config,
 .ssidref = info->ssidref,
 .max_vcpus = b_info->max_vcpus,
 .max_evtchn_port = b_info->event_channels,
+.max_altp2m = b_info->max_altp2m,
 .max_grant_frames = b_info->max_grant_frames,
 .max_maptrack_frames = b_info->max_maptrack_frames,
 .grant_opts = XEN_DOMCTL_GRANT_version(b_info->max_grant_version),
--
2.34.1




[PATCH v2 7/7] x86/hap: Increase the number of initial mempool_size to 1024 pages

2024-04-28 Thread Petr Beneš
From: Petr Beneš 

This change anticipates scenarios where `max_altp2m` is set to its maximum
supported value (i.e., 512), ensuring sufficient memory is allocated upfront
to accommodate all altp2m tables without initialization failure.

The necessity for this increase arises from the current mechanism where altp2m
tables are allocated at initialization, requiring one page from the mempool
for each altp2m view.

Signed-off-by: Petr Beneš 
---
 tools/tests/paging-mempool/test-paging-mempool.c | 2 +-
 xen/arch/x86/mm/hap/hap.c| 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/tools/tests/paging-mempool/test-paging-mempool.c 
b/tools/tests/paging-mempool/test-paging-mempool.c
index 1ebc13455a..91b06fa0cf 100644
--- a/tools/tests/paging-mempool/test-paging-mempool.c
+++ b/tools/tests/paging-mempool/test-paging-mempool.c
@@ -35,7 +35,7 @@ static struct xen_domctl_createdomain create = {
 
 static uint64_t default_mempool_size_bytes =
 #if defined(__x86_64__) || defined(__i386__)
-256 << 12; /* Only x86 HAP for now.  x86 Shadow needs more work. */
+1024 << 12; /* Only x86 HAP for now.  x86 Shadow needs more work. */
 #elif defined (__arm__) || defined(__aarch64__)
 16 << 12;
 #endif
diff --git a/xen/arch/x86/mm/hap/hap.c b/xen/arch/x86/mm/hap/hap.c
index 7aff5fa664..fab7e256a4 100644
--- a/xen/arch/x86/mm/hap/hap.c
+++ b/xen/arch/x86/mm/hap/hap.c
@@ -468,7 +468,7 @@ int hap_enable(struct domain *d, u32 mode)
 if ( old_pages == 0 )
 {
 paging_lock(d);
-rv = hap_set_allocation(d, 256, NULL);
+rv = hap_set_allocation(d, 1024, NULL);
 if ( rv != 0 )
 {
 hap_set_allocation(d, 0, NULL);
-- 
2.34.1




[PATCH v2 4/7] x86: Make the maximum number of altp2m views configurable

2024-04-28 Thread Petr Beneš
From: Petr Beneš 

This commit introduces the ability to configure the maximum number of altp2m
tables during domain creation. Previously, the limits were hardcoded to a
maximum of 10. This change allows for greater flexibility in environments that
require more or fewer altp2m views.

The maximum configurable limit for max_altp2m on x86 is now set to MAX_EPTP
(512). This cap is linked to the architectural limit of the EPTP-switching
VMFUNC, which supports up to 512 entries. Despite there being no inherent need
for limiting max_altp2m in scenarios not utilizing VMFUNC, decoupling these
components would necessitate substantial code changes.

Signed-off-by: Petr Beneš 
---
Changed since v1:
  * Added xen_domctl_createdomain::max_altp2m field to 
xen/include/public/domctl.h
  * Bumped the XEN_DOMCTL_INTERFACE_VERSION
  * More elaborate commit message

 xen/arch/x86/domain.c |  6 
 xen/arch/x86/hvm/hvm.c|  8 -
 xen/arch/x86/hvm/vmx/vmx.c|  2 +-
 xen/arch/x86/include/asm/domain.h |  7 ++---
 xen/arch/x86/include/asm/p2m.h|  4 +--
 xen/arch/x86/mm/altp2m.c  | 27 +++--
 xen/arch/x86/mm/hap/hap.c |  6 ++--
 xen/arch/x86/mm/mem_access.c  | 14 -
 xen/arch/x86/mm/mem_sharing.c |  2 +-
 xen/arch/x86/mm/p2m-ept.c |  6 ++--
 xen/arch/x86/mm/p2m.c | 50 +++
 xen/common/domain.c   |  7 +
 xen/include/public/domctl.h   |  3 +-
 xen/include/xen/sched.h   |  2 ++
 14 files changed, 94 insertions(+), 50 deletions(-)

diff --git a/xen/arch/x86/domain.c b/xen/arch/x86/domain.c
index 20e83cf38b..6b458f330c 100644
--- a/xen/arch/x86/domain.c
+++ b/xen/arch/x86/domain.c
@@ -685,6 +685,12 @@ int arch_sanitise_domain_config(struct 
xen_domctl_createdomain *config)
 return -EINVAL;
 }

+if ( config->max_altp2m > MAX_EPTP )
+{
+dprintk(XENLOG_INFO, "max_altp2m must be <= %u\n", MAX_EPTP);
+return -EINVAL;
+}
+
 if ( config->vmtrace_size )
 {
 unsigned int size = config->vmtrace_size;
diff --git a/xen/arch/x86/hvm/hvm.c b/xen/arch/x86/hvm/hvm.c
index 0ce45b177c..9b70fe7cfc 100644
--- a/xen/arch/x86/hvm/hvm.c
+++ b/xen/arch/x86/hvm/hvm.c
@@ -4633,6 +4633,12 @@ static int do_altp2m_op(
 goto out;
 }

+if ( d->max_altp2m == 0 )
+{
+rc = -EINVAL;
+goto out;
+}
+
 if ( (rc = xsm_hvm_altp2mhvm_op(XSM_OTHER, d, mode, a.cmd)) )
 goto out;

@@ -5222,7 +5228,7 @@ void hvm_fast_singlestep(struct vcpu *v, uint16_t p2midx)
 if ( !hvm_is_singlestep_supported() )
 return;

-if ( p2midx >= MAX_ALTP2M )
+if ( p2midx >= v->domain->max_altp2m )
 return;

 v->arch.hvm.single_step = true;
diff --git a/xen/arch/x86/hvm/vmx/vmx.c b/xen/arch/x86/hvm/vmx/vmx.c
index 5f67a48592..8f57f3a7f5 100644
--- a/xen/arch/x86/hvm/vmx/vmx.c
+++ b/xen/arch/x86/hvm/vmx/vmx.c
@@ -4888,7 +4888,7 @@ bool asmlinkage vmx_vmenter_helper(const struct 
cpu_user_regs *regs)
 {
 unsigned int i;

-for ( i = 0; i < MAX_ALTP2M; ++i )
+for ( i = 0; i < currd->max_altp2m; ++i )
 {
 if ( currd->arch.altp2m_eptp[i] == mfn_x(INVALID_MFN) )
 continue;
diff --git a/xen/arch/x86/include/asm/domain.h 
b/xen/arch/x86/include/asm/domain.h
index f5daeb182b..5bb0bcae81 100644
--- a/xen/arch/x86/include/asm/domain.h
+++ b/xen/arch/x86/include/asm/domain.h
@@ -258,11 +258,10 @@ struct paging_vcpu {
 struct shadow_vcpu shadow;
 };

+#define INVALID_ALTP2M  0x
+#define MAX_EPTP((unsigned int)(PAGE_SIZE / sizeof(uint64_t)))
 #define MAX_NESTEDP2M 10

-#define MAX_ALTP2M  10 /* arbitrary */
-#define INVALID_ALTP2M  0x
-#define MAX_EPTP(PAGE_SIZE / sizeof(uint64_t))
 struct p2m_domain;
 struct time_scale {
 int shift;
@@ -353,7 +352,7 @@ struct arch_domain

 /* altp2m: allow multiple copies of host p2m */
 bool altp2m_active;
-struct p2m_domain *altp2m_p2m[MAX_ALTP2M];
+struct p2m_domain **altp2m_p2m;
 mm_lock_t altp2m_list_lock;
 uint64_t *altp2m_eptp;
 uint64_t *altp2m_visible_eptp;
diff --git a/xen/arch/x86/include/asm/p2m.h b/xen/arch/x86/include/asm/p2m.h
index 111badf89a..2086bcb633 100644
--- a/xen/arch/x86/include/asm/p2m.h
+++ b/xen/arch/x86/include/asm/p2m.h
@@ -881,7 +881,7 @@ static inline struct p2m_domain *p2m_get_altp2m(struct vcpu 
*v)
 if ( index == INVALID_ALTP2M )
 return NULL;

-BUG_ON(index >= MAX_ALTP2M);
+BUG_ON(index >= v->domain->max_altp2m);

 return v->domain->arch.altp2m_p2m[index];
 }
@@ -891,7 +891,7 @@ static inline bool p2m_set_altp2m(struct vcpu *v, unsigned 
int idx)
 {
 struct p2m_domain *orig;

-BUG_ON(idx >= MAX_ALTP2M);
+BUG_ON(idx >= v->domain->max_altp2m);

 if ( idx == vcpu_altp2m(v).p2midx )
 return false;
diff --git a/xen/arch/x86/mm/altp2m.c 

[PATCH v2 1/7] x86/p2m: Add braces for better code clarity

2024-04-28 Thread Petr Beneš
From: Petr Beneš 

No functional change.

Signed-off-by: Petr Beneš 
---
 xen/arch/x86/mm/p2m.c | 4 
 1 file changed, 4 insertions(+)

diff --git a/xen/arch/x86/mm/p2m.c b/xen/arch/x86/mm/p2m.c
index ce742c12e0..eb7996170d 100644
--- a/xen/arch/x86/mm/p2m.c
+++ b/xen/arch/x86/mm/p2m.c
@@ -106,6 +106,7 @@ void p2m_change_entry_type_global(struct domain *d,
 unsigned int i;
 
 for ( i = 0; i < MAX_ALTP2M; i++ )
+{
 if ( d->arch.altp2m_eptp[i] != mfn_x(INVALID_MFN) )
 {
 struct p2m_domain *altp2m = d->arch.altp2m_p2m[i];
@@ -114,6 +115,7 @@ void p2m_change_entry_type_global(struct domain *d,
 change_entry_type_global(altp2m, ot, nt);
 p2m_unlock(altp2m);
 }
+}
 }
 
 p2m_unlock(hostp2m);
@@ -139,6 +141,7 @@ void p2m_memory_type_changed(struct domain *d)
 unsigned int i;
 
 for ( i = 0; i < MAX_ALTP2M; i++ )
+{
 if ( d->arch.altp2m_eptp[i] != mfn_x(INVALID_MFN) )
 {
 struct p2m_domain *altp2m = d->arch.altp2m_p2m[i];
@@ -147,6 +150,7 @@ void p2m_memory_type_changed(struct domain *d)
 _memory_type_changed(altp2m);
 p2m_unlock(altp2m);
 }
+}
 }
 
 p2m_unlock(hostp2m);
-- 
2.34.1




[PATCH v2 3/7] docs/man: Add max_altp2m parameter to the xl.cfg manual

2024-04-28 Thread Petr Beneš
From: Petr Beneš 

Update manual pages to include detailed information about the max_altp2m
configuration parameter.

Signed-off-by: Petr Beneš 
---
 docs/man/xl.cfg.5.pod.in | 14 ++
 1 file changed, 14 insertions(+)

diff --git a/docs/man/xl.cfg.5.pod.in b/docs/man/xl.cfg.5.pod.in
index 8f2b375ce9..2d4ea35736 100644
--- a/docs/man/xl.cfg.5.pod.in
+++ b/docs/man/xl.cfg.5.pod.in
@@ -2039,6 +2039,20 @@ a single guest HVM domain. B: While the option "altp2mhvm" is deprecated, legacy applications for
 x86 systems will continue to work using it.
 
+=item B
+
+Specifies the maximum number of alternate-p2m views available to the guest.
+This setting is crucial in domain introspection scenarios that require
+multiple physical-to-machine (p2m) memory mappings to be established
+simultaneously.
+
+Enabling multiple p2m views may increase memory usage. It is advisable to
+review and adjust the B setting as necessary to accommodate
+the additional memory requirements.
+
+B: This option is ignored if B is disabled. The default value
+is 10.
+
 =item B
 
 Enable or disables guest access to hardware virtualisation features,
-- 
2.34.1




[linux-6.1 bisection] complete build-armhf-pvops

2024-04-28 Thread osstest service owner
branch xen-unstable
xenbranch xen-unstable
job build-armhf-pvops
testid kernel-build

Tree: linux 
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git
Tree: linuxfirmware git://xenbits.xen.org/osstest/linux-firmware.git

*** Found and reproduced problem changeset ***

  Bug is in tree:  linux 
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git
  Bug introduced:  0f4048e1a0c6e9d3d31ce5b684600fd137cebfca
  Bug not present: e2b8480b709d48ca1723eed7258f26a0df9a1965
  Last fail repro: http://logs.test-lab.xenproject.org/osstest/logs/185856/


  commit 0f4048e1a0c6e9d3d31ce5b684600fd137cebfca
  Author: Linus Walleij 
  Date:   Tue Sep 26 15:25:32 2023 +0200
  
  ASoC: ti: Convert Pandora ASoC to GPIO descriptors
  
  [ Upstream commit 319e6ac143b9e9048e527ab9dd2aabb8fdf3d60f ]
  
  The Pandora uses GPIO descriptors pretty much exclusively, but not
  for ASoC, so let's fix it. Register the pins in a descriptor table
  in the machine since the ASoC device is not using device tree.
  
  Use static locals for the GPIO descriptors because I'm not able
  to experient with better state storage on any real hardware. Others
  using the Pandora can come afterwards and improve this.
  
  Signed-off-by: Linus Walleij 
  Acked-by: Jarkko Nikula 
  Link: 
https://lore.kernel.org/r/20230926-descriptors-asoc-ti-v1-4-60cf4f8ad...@linaro.org
  Signed-off-by: Mark Brown 
  Signed-off-by: Sasha Levin 


For bisection revision-tuple graph see:
   
http://logs.test-lab.xenproject.org/osstest/results/bisect/linux-6.1/build-armhf-pvops.kernel-build.html
Revision IDs in each graph node refer, respectively, to the Trees above.


Running cs-bisection-step 
--graph-out=/home/logs/results/bisect/linux-6.1/build-armhf-pvops.kernel-build 
--summary-out=tmp/185856.bisection-summary --basis-template=185746 
--blessings=real,real-bisect,real-retry linux-6.1 build-armhf-pvops kernel-build
Searching for failure / basis pass:
 185835 fail [host=debina1] / 185746 [host=himrod2] 185434 [host=godello1] 
185299 [host=himrod2] 185231 [host=himrod2] 185227 [host=himrod0] 185167 
[host=elbling0] 185053 [host=himrod2] 184922 [host=himrod0] 184841 
[host=himrod2] 184831 [host=himrod2] 184734 [host=albana0] 184687 
[host=himrod2] 184595 [host=himrod2] 184570 [host=himrod0] 184563 
[host=himrod0] 184549 [host=godello0] template as basis? using template as 
basis.
Failure / basis pass flights: 185835 / 185746
Tree: linux 
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git
Tree: linuxfirmware git://xenbits.xen.org/osstest/linux-firmware.git
Latest f2295faba5e8249ae4082791bfc1664c88fff83a 
c530a75c1e6a472b0eb9558310b518f0dfcd8860
Basis pass 6741e066ec7633450d3186946035c1f80c4226b8 
c530a75c1e6a472b0eb9558310b518f0dfcd8860
Generating revisions with ./adhoc-revtuple-generator  
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git#6741e066ec7633450d3186946035c1f80c4226b8-f2295faba5e8249ae4082791bfc1664c88fff83a
 
git://xenbits.xen.org/osstest/linux-firmware.git#c530a75c1e6a472b0eb9558310b518f0dfcd8860-c530a75c1e6a472b0eb9558310b518f0dfcd8860
Loaded 5001 nodes in revision graph
Searching for test results:
 185746 [host=himrod2]
 185837 pass 6741e066ec7633450d3186946035c1f80c4226b8 
c530a75c1e6a472b0eb9558310b518f0dfcd8860
 185832 fail f2295faba5e8249ae4082791bfc1664c88fff83a 
c530a75c1e6a472b0eb9558310b518f0dfcd8860
 185838 fail f2295faba5e8249ae4082791bfc1664c88fff83a 
c530a75c1e6a472b0eb9558310b518f0dfcd8860
 185856 fail 0f4048e1a0c6e9d3d31ce5b684600fd137cebfca 
c530a75c1e6a472b0eb9558310b518f0dfcd8860
 185840 pass 6741e066ec7633450d3186946035c1f80c4226b8 
c530a75c1e6a472b0eb9558310b518f0dfcd8860
 185842 fail f2295faba5e8249ae4082791bfc1664c88fff83a 
c530a75c1e6a472b0eb9558310b518f0dfcd8860
 185843 fail b928cde9c07cf031a9a5bffbfb94048f340d34ee 
c530a75c1e6a472b0eb9558310b518f0dfcd8860
 185844 pass 8d56bad42ac4c43c6c72ddd6a654a2628bf839c5 
c530a75c1e6a472b0eb9558310b518f0dfcd8860
 185846 pass beb3ff19a55d78d3c70f9284458c9d155818ae27 
c530a75c1e6a472b0eb9558310b518f0dfcd8860
 185847 pass 4b7ed2400e0d895a9920c80d63646728bb389baa 
c530a75c1e6a472b0eb9558310b518f0dfcd8860
 185835 fail f2295faba5e8249ae4082791bfc1664c88fff83a 
c530a75c1e6a472b0eb9558310b518f0dfcd8860
 185848 pass 87709f7ecdb884ab75e3de6f951dffe500ee95b2 
c530a75c1e6a472b0eb9558310b518f0dfcd8860
 185850 pass 4d74cb9cdfd51e6d854f8da54113e716335cb2ca 
c530a75c1e6a472b0eb9558310b518f0dfcd8860
 185851 pass e2b8480b709d48ca1723eed7258f26a0df9a1965 
c530a75c1e6a472b0eb9558310b518f0dfcd8860
 185852 fail 0f4048e1a0c6e9d3d31ce5b684600fd137cebfca 
c530a75c1e6a472b0eb9558310b518f0dfcd8860
 185853 pass e2b8480b709d48ca1723eed7258f26a0df9a1965 
c530a75c1e6a472b0eb9558310b518f0dfcd8860
 185854 fail 0f4048e1a0c6e9d3d31ce5b684600fd137cebfca 
c530a75c1e6a472b0eb9558310b518f0dfcd8860
 185855 pass e2b8480b709d48ca1723eed7258f26a0df9a1965 

[xen-unstable test] 185839: tolerable FAIL

2024-04-28 Thread osstest service owner
flight 185839 xen-unstable real [real]
http://logs.test-lab.xenproject.org/osstest/logs/185839/

Failures :-/ but no regressions.

Tests which are failing intermittently (not blocking):
 test-amd64-amd64-xl-qemuu-debianhvm-i386-xsm 12 debian-hvm-install fail pass 
in 185830
 test-armhf-armhf-xl-rtds  8 xen-boot   fail pass in 185830

Tests which did not succeed, but are not blocking:
 test-armhf-armhf-xl-rtds15 migrate-support-check fail in 185830 never pass
 test-armhf-armhf-xl-rtds 16 saverestore-support-check fail in 185830 never pass
 test-armhf-armhf-libvirt 16 saverestore-support-checkfail  like 185830
 test-amd64-amd64-xl-qemut-win7-amd64 19 guest-stopfail like 185830
 test-amd64-amd64-xl-qemuu-ws16-amd64 19 guest-stopfail like 185830
 test-amd64-amd64-xl-qemuu-win7-amd64 19 guest-stopfail like 185830
 test-amd64-amd64-xl-qemut-ws16-amd64 19 guest-stopfail like 185830
 test-amd64-amd64-qemuu-nested-amd 20 debian-hvm-install/l1/l2 fail like 185830
 test-amd64-amd64-libvirt-xsm 15 migrate-support-checkfail   never pass
 test-amd64-amd64-libvirt 15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-xsm  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-xsm  16 saverestore-support-checkfail   never pass
 test-arm64-arm64-libvirt-xsm 15 migrate-support-checkfail   never pass
 test-arm64-arm64-libvirt-xsm 16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl  16 saverestore-support-checkfail   never pass
 test-amd64-amd64-libvirt-qemuu-debianhvm-amd64-xsm 13 migrate-support-check 
fail never pass
 test-arm64-arm64-xl-credit2  15 migrate-support-checkfail   never pass
 test-armhf-armhf-xl-multivcpu 15 migrate-support-checkfail  never pass
 test-arm64-arm64-xl-credit2  16 saverestore-support-checkfail   never pass
 test-armhf-armhf-xl-multivcpu 16 saverestore-support-checkfail  never pass
 test-arm64-arm64-xl-thunderx 15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-thunderx 16 saverestore-support-checkfail   never pass
 test-amd64-amd64-libvirt-qcow2 14 migrate-support-checkfail never pass
 test-armhf-armhf-xl-credit2  15 migrate-support-checkfail   never pass
 test-armhf-armhf-xl-credit2  16 saverestore-support-checkfail   never pass
 test-amd64-amd64-libvirt-raw 14 migrate-support-checkfail   never pass
 test-armhf-armhf-libvirt 15 migrate-support-checkfail   never pass
 test-armhf-armhf-xl-arndale  15 migrate-support-checkfail   never pass
 test-armhf-armhf-xl-arndale  16 saverestore-support-checkfail   never pass
 test-armhf-armhf-xl  15 migrate-support-checkfail   never pass
 test-armhf-armhf-xl  16 saverestore-support-checkfail   never pass
 test-amd64-amd64-libvirt-vhd 14 migrate-support-checkfail   never pass
 test-arm64-arm64-libvirt-raw 14 migrate-support-checkfail   never pass
 test-arm64-arm64-libvirt-raw 15 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-credit1  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-credit1  16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-vhd  14 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-vhd  15 saverestore-support-checkfail   never pass
 test-armhf-armhf-xl-qcow214 migrate-support-checkfail   never pass
 test-armhf-armhf-xl-qcow215 saverestore-support-checkfail   never pass
 test-armhf-armhf-xl-credit1  15 migrate-support-checkfail   never pass
 test-armhf-armhf-xl-credit1  16 saverestore-support-checkfail   never pass
 test-armhf-armhf-libvirt-vhd 14 migrate-support-checkfail   never pass
 test-armhf-armhf-libvirt-vhd 15 saverestore-support-checkfail   never pass
 test-armhf-armhf-xl-raw  14 migrate-support-checkfail   never pass
 test-armhf-armhf-xl-raw  15 saverestore-support-checkfail   never pass

version targeted for testing:
 xen  be5b08dd6ea6ef0f01caf537bdae125fa66a2230
baseline version:
 xen  be5b08dd6ea6ef0f01caf537bdae125fa66a2230

Last test of basis   185839  2024-04-28 01:51:57 Z0 days
Testing same since  (not found) 0 attempts

jobs:
 build-amd64-xsm  pass
 build-arm64-xsm  pass
 build-i386-xsm   pass
 build-amd64-xtf  pass
 build-amd64  pass
 build-arm64  pass
 build-armhf  pass
 

[linux-6.1 test] 185835: regressions - FAIL

2024-04-28 Thread osstest service owner
flight 185835 linux-6.1 real [real]
http://logs.test-lab.xenproject.org/osstest/logs/185835/

Regressions :-(

Tests which did not succeed and are blocking,
including tests which could not be run:
 build-armhf-pvops 6 kernel-build fail REGR. vs. 185746

Tests which are failing intermittently (not blocking):
 test-amd64-amd64-dom0pvh-xl-amd 14 guest-start   fail in 185832 pass in 185835
 test-amd64-amd64-xl-qemuu-debianhvm-i386-xsm 12 debian-hvm-install fail in 
185832 pass in 185835
 test-amd64-amd64-xl-qemut-debianhvm-i386-xsm 12 debian-hvm-install fail in 
185832 pass in 185835
 test-amd64-amd64-xl-qemuu-debianhvm-amd64-shadow 17 guest-saverestore.2 fail 
pass in 185832

Tests which did not succeed, but are not blocking:
 test-armhf-armhf-examine  1 build-check(1)   blocked  n/a
 test-armhf-armhf-libvirt  1 build-check(1)   blocked  n/a
 test-armhf-armhf-libvirt-vhd  1 build-check(1)   blocked  n/a
 test-armhf-armhf-xl   1 build-check(1)   blocked  n/a
 test-armhf-armhf-xl-arndale   1 build-check(1)   blocked  n/a
 test-armhf-armhf-xl-credit1   1 build-check(1)   blocked  n/a
 test-armhf-armhf-xl-credit2   1 build-check(1)   blocked  n/a
 test-armhf-armhf-xl-multivcpu  1 build-check(1)   blocked  n/a
 test-armhf-armhf-xl-qcow2 1 build-check(1)   blocked  n/a
 test-armhf-armhf-xl-raw   1 build-check(1)   blocked  n/a
 test-armhf-armhf-xl-rtds  1 build-check(1)   blocked  n/a
 test-amd64-amd64-xl-qemuu-win7-amd64 19 guest-stopfail like 185746
 test-amd64-amd64-xl-qemuu-ws16-amd64 19 guest-stopfail like 185746
 test-amd64-amd64-xl-qemut-win7-amd64 19 guest-stopfail like 185746
 test-amd64-amd64-xl-qemut-ws16-amd64 19 guest-stopfail like 185746
 test-amd64-amd64-qemuu-nested-amd 20 debian-hvm-install/l1/l2 fail like 185746
 test-amd64-amd64-libvirt 15 migrate-support-checkfail   never pass
 test-amd64-amd64-libvirt-xsm 15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-thunderx 15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-thunderx 16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl  16 saverestore-support-checkfail   never pass
 test-arm64-arm64-libvirt-xsm 15 migrate-support-checkfail   never pass
 test-arm64-arm64-libvirt-xsm 16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-credit1  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-credit1  16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-xsm  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-xsm  16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-credit2  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-credit2  16 saverestore-support-checkfail   never pass
 test-amd64-amd64-libvirt-qemuu-debianhvm-amd64-xsm 13 migrate-support-check 
fail never pass
 test-amd64-amd64-libvirt-qcow2 14 migrate-support-checkfail never pass
 test-amd64-amd64-libvirt-raw 14 migrate-support-checkfail   never pass
 test-amd64-amd64-libvirt-vhd 14 migrate-support-checkfail   never pass
 test-arm64-arm64-libvirt-raw 14 migrate-support-checkfail   never pass
 test-arm64-arm64-libvirt-raw 15 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-vhd  14 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-vhd  15 saverestore-support-checkfail   never pass

version targeted for testing:
 linuxf2295faba5e8249ae4082791bfc1664c88fff83a
baseline version:
 linux6741e066ec7633450d3186946035c1f80c4226b8

Last test of basis   185746  2024-04-20 18:14:28 Z7 days
Testing same since   185832  2024-04-27 15:44:00 Z0 days2 attempts


People who touched revisions under test:
  Ai Chao 
  Alan Stern 
  Alex Deucher 
  Alexander Gordeev 
  Alexander Usyskin 
  Alexey Izbyshev 
  Alvaro Karsz 
  Andi Shyti 
  Andrew Morton 
  AngeloGioacchino Del Regno 
  Ard Biesheuvel 
  Arnd Bergmann 
  Arınç ÜNAL 
  Bjorn Helgaas 
  bolan wang 
  Borislav Petkov (AMD) 
  Borislav Petkov 
  Brenton Simpson 
  Carlos Llamas 
  Carolina Jubran 
  Catalin Marinas 
  Chinmoy Ghosh 
  Christophe JAILLET 
  Chuanhong Guo 
  Chuck Lever 
  Coia Prant 
  Daniel Golle 
  Daniele Palmas 
  Danilo Krummrich 
  Dave Airlie 
  Dave Hansen 
  David S. Miller 
  David Yang 
  Dillon Varone 
  Dmitry Baryshkov 
  Dmitry Torokhov 
  Emil Kronborg 
  Eric Biggers 
  Finn Thain 
  Florian Fainelli 
  Florian Westphal 
  Geoffrey D. Bennett 
  Gil Fine 
  Greg Kroah-Hartman 
  H. Peter Anvin (Intel) 
  Hamza Mahfooz