[linux-linus test] 176053: regressions - FAIL

2023-01-22 Thread osstest service owner
flight 176053 linux-linus real [real]
http://logs.test-lab.xenproject.org/osstest/logs/176053/

Regressions :-(

Tests which did not succeed and are blocking,
including tests which could not be run:
 test-arm64-arm64-examine  8 reboot   fail REGR. vs. 173462
 test-arm64-arm64-xl-vhd   8 xen-boot fail REGR. vs. 173462
 test-arm64-arm64-libvirt-raw  8 xen-boot fail REGR. vs. 173462
 test-arm64-arm64-xl-seattle   8 xen-boot fail REGR. vs. 173462
 test-arm64-arm64-xl-xsm   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-xl-arndale   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-xl-credit2   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-xl-multivcpu  8 xen-bootfail REGR. vs. 173462
 test-armhf-armhf-xl   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-xl-credit1   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-xl-vhd   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-libvirt  8 xen-boot fail REGR. vs. 173462
 test-amd64-amd64-freebsd11-amd64 21 guest-start/freebsd.repeat fail REGR. vs. 
173462
 test-arm64-arm64-libvirt-xsm  8 xen-boot fail REGR. vs. 173462
 test-arm64-arm64-xl-credit2   8 xen-boot fail REGR. vs. 173462
 test-arm64-arm64-xl-credit1   8 xen-boot fail REGR. vs. 173462
 test-arm64-arm64-xl   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-examine  8 reboot   fail REGR. vs. 173462
 test-armhf-armhf-libvirt-qcow2  8 xen-boot   fail REGR. vs. 173462
 test-armhf-armhf-libvirt-raw  8 xen-boot fail REGR. vs. 173462

Regressions which are regarded as allowable (not blocking):
 test-armhf-armhf-xl-rtds  8 xen-boot fail REGR. vs. 173462

Tests which did not succeed, but are not blocking:
 test-amd64-amd64-xl-qemut-win7-amd64 19 guest-stopfail like 173462
 test-amd64-amd64-xl-qemuu-win7-amd64 19 guest-stopfail like 173462
 test-amd64-amd64-xl-qemuu-ws16-amd64 19 guest-stopfail like 173462
 test-amd64-amd64-qemuu-nested-amd 20 debian-hvm-install/l1/l2 fail like 173462
 test-amd64-amd64-xl-qemut-ws16-amd64 19 guest-stopfail like 173462
 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-thunderx 15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-thunderx 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-armhf-armhf-xl-cubietruck 15 migrate-support-checkfail never pass
 test-armhf-armhf-xl-cubietruck 16 saverestore-support-checkfail never pass

version targeted for testing:
 linux2475bf0250dee99b477e0c56d7dc9d7ac3f04117
baseline version:
 linux9d84bb40bcb30a7fa16f33baa967aeb9953dda78

Last test of basis   173462  2022-10-07 18:41:45 Z  107 days
Failing since173470  2022-10-08 06:21:34 Z  107 days  220 attempts
Testing same since   176053  2023-01-22 23:10:33 Z0 days1 attempts


3437 people touched revisions under test,
not listing them all

jobs:
 build-amd64-xsm  pass
 build-arm64-xsm  pass
 build-i386-xsm   pass
 build-amd64  pass
 build-arm64  pass
 build-armhf  pass
 build-i386   pass
 build-amd64-libvirt  pass
 build-arm64-libvirt  pass
 build-armhf-libvirt  pass
 build-i386-libvirt   pass
 build-amd64-pvopspass
 build-arm64-pvopspass
 build-armhf-pvopspass
 build-i386-pvops pass
 test-amd64-amd64-xl  pass
 test-amd64-coresched-amd64-xlpass
 test-arm64-arm64-xl  fail
 test-armhf-armhf-xl  fail   

Re: [PATCH v3 0/5] efi: Support ESRT under Xen

2023-01-22 Thread Ard Biesheuvel
On Thu, 19 Jan 2023 at 20:04, Demi Marie Obenour
 wrote:
>
> This patch series fixes handling of EFI tables when running under Xen.
> These fixes allow the ESRT to be loaded when running paravirtualized in
> dom0, making the use of EFI capsule updates possible.
>
> Demi Marie Obenour (5):
>   efi: memmap: Disregard bogus entries instead of returning them
>   efi: xen: Implement memory descriptor lookup based on hypercall
>   efi: Apply allowlist to EFI configuration tables when running under
> Xen
>   efi: Actually enable the ESRT under Xen
>   efi: Warn if trying to reserve memory under Xen
>

I have given these a spin on a system with a dodgy ESRT (the region in
question is not covered by the memory map at all), and things are
exactly as broken before, which is good.

I have queued these up in efi/next now, they should appear in -next tomorrow.


>  drivers/firmware/efi/efi.c  | 22 -
>  drivers/firmware/efi/esrt.c | 15 +++--
>  drivers/xen/efi.c   | 61 +
>  include/linux/efi.h |  3 ++
>  4 files changed, 90 insertions(+), 11 deletions(-)
>
> --
> Sincerely,
> Demi Marie Obenour (she/her/hers)
> Invisible Things Lab



[xen-unstable test] 176048: regressions - FAIL

2023-01-22 Thread osstest service owner
flight 176048 xen-unstable real [real]
http://logs.test-lab.xenproject.org/osstest/logs/176048/

Regressions :-(

Tests which did not succeed and are blocking,
including tests which could not be run:
 test-amd64-coresched-i386-xl 18 guest-localmigrate   fail REGR. vs. 175994
 test-amd64-i386-xl-xsm   18 guest-localmigrate   fail REGR. vs. 175994
 test-amd64-i386-xl   18 guest-localmigrate   fail REGR. vs. 175994
 test-amd64-i386-pair  26 guest-migrate/src_host/dst_host fail REGR. vs. 175994
 test-amd64-i386-xl-vhd   17 guest-localmigrate   fail REGR. vs. 175994
 test-amd64-i386-xl-shadow18 guest-localmigrate   fail REGR. vs. 175994
 test-amd64-i386-libvirt-pair 26 guest-migrate/src_host/dst_host fail REGR. vs. 
175994

Tests which are failing intermittently (not blocking):
 test-arm64-arm64-xl-vhd 17 guest-start/debian.repeat fail in 176042 pass in 
176048
 test-amd64-i386-libvirt-xsm   7 xen-installfail pass in 176042

Tests which did not succeed, but are not blocking:
 test-amd64-i386-libvirt-xsm 15 migrate-support-check fail in 176042 never pass
 test-armhf-armhf-libvirt 16 saverestore-support-checkfail  like 175987
 test-amd64-i386-xl-qemuu-ws16-amd64 19 guest-stop fail like 175987
 test-amd64-amd64-xl-qemuu-win7-amd64 19 guest-stopfail like 175987
 test-amd64-amd64-xl-qemut-win7-amd64 19 guest-stopfail like 175994
 test-amd64-i386-xl-qemuu-win7-amd64 19 guest-stop fail like 175994
 test-amd64-amd64-xl-qemuu-ws16-amd64 19 guest-stopfail like 175994
 test-amd64-amd64-qemuu-nested-amd 20 debian-hvm-install/l1/l2 fail like 175994
 test-amd64-i386-xl-qemut-win7-amd64 19 guest-stop fail like 175994
 test-amd64-i386-xl-qemut-ws16-amd64 19 guest-stop fail like 175994
 test-armhf-armhf-libvirt-qcow2 15 saverestore-support-check   fail like 175994
 test-armhf-armhf-libvirt-raw 15 saverestore-support-checkfail  like 175994
 test-amd64-amd64-xl-qemut-ws16-amd64 19 guest-stopfail like 175994
 test-arm64-arm64-xl-seattle  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-seattle  16 saverestore-support-checkfail   never pass
 test-amd64-amd64-libvirt 15 migrate-support-checkfail   never pass
 test-amd64-amd64-libvirt-xsm 15 migrate-support-checkfail   never pass
 test-amd64-i386-libvirt  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-credit2  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-xsm  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-credit2  16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-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-amd64-amd64-libvirt-qemuu-debianhvm-amd64-xsm 13 migrate-support-check 
fail 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-i386-libvirt-qemuu-debianhvm-amd64-xsm 13 migrate-support-check 
fail never pass
 test-amd64-i386-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-armhf-armhf-xl-cubietruck 15 migrate-support-checkfail never pass
 test-armhf-armhf-xl-cubietruck 16 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-xl-credit2  15 migrate-support-checkfail   never pass
 test-armhf-armhf-xl-credit2  16 saverestore-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-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  15 migrate-support-checkfail   never pass
 

[xen-unstable bisection] complete test-amd64-i386-libvirt-pair

2023-01-22 Thread osstest service owner
branch xen-unstable
xenbranch xen-unstable
job test-amd64-i386-libvirt-pair
testid guest-migrate/src_host/dst_host

Tree: libvirt git://xenbits.xen.org/libvirt.git
Tree: libvirt_keycodemapdb https://gitlab.com/keycodemap/keycodemapdb.git
Tree: linux git://xenbits.xen.org/linux-pvops.git
Tree: linuxfirmware git://xenbits.xen.org/osstest/linux-firmware.git
Tree: qemu git://xenbits.xen.org/qemu-xen-traditional.git
Tree: qemuu git://xenbits.xen.org/qemu-xen.git
Tree: xen git://xenbits.xen.org/xen.git

*** Found and reproduced problem changeset ***

  Bug is in tree:  xen git://xenbits.xen.org/xen.git
  Bug introduced:  1894049fa283308d5f90446370be1ade7afe8975
  Bug not present: 20279afd732371dd2534380d27aa6d1863d82d1f
  Last fail repro: http://logs.test-lab.xenproject.org/osstest/logs/176054/


  commit 1894049fa283308d5f90446370be1ade7afe8975
  Author: Jan Beulich 
  Date:   Fri Jan 20 09:17:33 2023 +0100
  
  x86/shadow: L2H shadow type is PV32-only
  
  Like for the various HVM-only types, save a little bit of code by suitably
  "masking" this type out when !PV32.
  
  Signed-off-by: Jan Beulich 
  Acked-by: Andrew Cooper 


For bisection revision-tuple graph see:
   
http://logs.test-lab.xenproject.org/osstest/results/bisect/xen-unstable/test-amd64-i386-libvirt-pair.guest-migrate--src_host--dst_host.html
Revision IDs in each graph node refer, respectively, to the Trees above.


Running cs-bisection-step 
--graph-out=/home/logs/results/bisect/xen-unstable/test-amd64-i386-libvirt-pair.guest-migrate--src_host--dst_host
 --summary-out=tmp/176054.bisection-summary --basis-template=175994 
--blessings=real,real-bisect,real-retry xen-unstable 
test-amd64-i386-libvirt-pair guest-migrate/src_host/dst_host
Searching for failure / basis pass:
 176042 fail [dst_host=debina1,src_host=debina0] / 175994 
[dst_host=albana0,src_host=albana1] 175987 [dst_host=pinot1,src_host=pinot0] 
175965 [dst_host=italia0,src_host=italia1] 175734 
[dst_host=elbling1,src_host=elbling0] 175726 
[dst_host=elbling0,src_host=elbling1] 175720 [dst_host=fiano0,src_host=fiano1] 
175714 [dst_host=huxelrebe0,src_host=huxelrebe1] 175694 
[dst_host=fiano1,src_host=fiano0] 175671 [dst_host=albana1,src_host=albana0] 
175651 [dst_host=debina0,src_host=debina1] 175635 [dst_hos\
 t=italia1,src_host=italia0] 175624 [dst_host=nobling1,src_host=nobling0] 
175612 [dst_host=nobling0,src_host=nobling1] 175601 
[dst_host=albana0,src_host=albana1] 175592 [dst_host=nocera0,src_host=nocera1] 
175573 [dst_host=italia0,src_host=italia1] 175569 
[dst_host=nocera1,src_host=nocera0] 175541 [dst_host=pinot1,src_host=pinot0] 
175534 [dst_host=pinot0,src_host=pinot1] 175526 ok.
Failure / basis pass flights: 176042 / 175526
(tree with no url: minios)
(tree with no url: ovmf)
(tree with no url: seabios)
Tree: libvirt git://xenbits.xen.org/libvirt.git
Tree: libvirt_keycodemapdb https://gitlab.com/keycodemap/keycodemapdb.git
Tree: linux git://xenbits.xen.org/linux-pvops.git
Tree: linuxfirmware git://xenbits.xen.org/osstest/linux-firmware.git
Tree: qemu git://xenbits.xen.org/qemu-xen-traditional.git
Tree: qemuu git://xenbits.xen.org/qemu-xen.git
Tree: xen git://xenbits.xen.org/xen.git
Latest 57b0678590708de081e4498e164b86d5c8c85024 
57ba70da5312170883a3d622cd2aa3fd0e2ec7ae 
c3038e718a19fc596f7b1baba0f83d5146dc7784 
c530a75c1e6a472b0eb9558310b518f0dfcd8860 
3d273dd05e51e5a1ffba3d98c7437ee84e8f8764 
625eb5e96dc96aa7fddef59a08edae215527f19c 
1d60c20260c7e82fe5344d06c20d718e0cc03b8b
Basis pass 0f2396751fccdc9f742230763880f70dbd977f3b 
57ba70da5312170883a3d622cd2aa3fd0e2ec7ae 
c3038e718a19fc596f7b1baba0f83d5146dc7784 
c530a75c1e6a472b0eb9558310b518f0dfcd8860 
3d273dd05e51e5a1ffba3d98c7437ee84e8f8764 
1cf02b05b27c48775a25699e61b93b814b9ae042 
7eef80e06ed2282bbcec3619d860c6aacb0515d8
Generating revisions with ./adhoc-revtuple-generator  
git://xenbits.xen.org/libvirt.git#0f2396751fccdc9f742230763880f70dbd977f3b-57b0678590708de081e4498e164b86d5c8c85024
 
https://gitlab.com/keycodemap/keycodemapdb.git#57ba70da5312170883a3d622cd2aa3fd0e2ec7ae-57ba70da5312170883a3d622cd2aa3fd0e2ec7ae
 
git://xenbits.xen.org/linux-pvops.git#c3038e718a19fc596f7b1baba0f83d5146dc7784-c3038e718a19fc596f7b1baba0f83d5146dc7784
 
git://xenbits.xen.org/osstest/linux-firmware.git#c530a75c1e6a472b0eb9558310b518f0\
 dfcd8860-c530a75c1e6a472b0eb9558310b518f0dfcd8860 
git://xenbits.xen.org/qemu-xen-traditional.git#3d273dd05e51e5a1ffba3d98c7437ee84e8f8764-3d273dd05e51e5a1ffba3d98c7437ee84e8f8764
 
git://xenbits.xen.org/qemu-xen.git#1cf02b05b27c48775a25699e61b93b814b9ae042-625eb5e96dc96aa7fddef59a08edae215527f19c
 
git://xenbits.xen.org/xen.git#7eef80e06ed2282bbcec3619d860c6aacb0515d8-1d60c20260c7e82fe5344d06c20d718e0cc03b8b
Loaded 15003 nodes in revision graph
Searching for test results:
 175592 [dst_host=nocera0,src_host=nocera1]
 175601 [dst_host=albana0,src_host=albana1]
 175612 [dst_host=nobling0,src_host=nobling1]
 175624 

Re: [PATCH v1 11/14] xen/riscv: introduce setup_trap_handler()

2023-01-22 Thread Alistair Francis
On Sat, Jan 21, 2023 at 1:00 AM Oleksii Kurochko
 wrote:
>
> Signed-off-by: Oleksii Kurochko 

Reviewed-by: Alistair Francis 

Alistair

> ---
>  xen/arch/riscv/setup.c | 11 +++
>  1 file changed, 11 insertions(+)
>
> diff --git a/xen/arch/riscv/setup.c b/xen/arch/riscv/setup.c
> index d09ffe1454..174e134c93 100644
> --- a/xen/arch/riscv/setup.c
> +++ b/xen/arch/riscv/setup.c
> @@ -1,16 +1,27 @@
>  #include 
>  #include 
>
> +#include 
>  #include 
> +#include 
>
>  /* Xen stack for bringing up the first CPU. */
>  unsigned char __initdata cpu0_boot_stack[STACK_SIZE]
>  __aligned(STACK_SIZE);
>
> +static void setup_trap_handler(void)
> +{
> +unsigned long addr = (unsigned long)_exception;
> +csr_write(CSR_STVEC, addr);
> +}
> +
>  void __init noreturn start_xen(void)
>  {
>  early_printk("Hello from C env\n");
>
> +setup_trap_handler();
> +early_printk("exception handler has been setup\n");
> +
>  for ( ;; )
>  asm volatile ("wfi");
>
> --
> 2.39.0
>
>



Re: [PATCH v1 10/14] xen/riscv: mask all interrupts

2023-01-22 Thread Alistair Francis
On Sat, Jan 21, 2023 at 1:00 AM Oleksii Kurochko
 wrote:
>
> Signed-off-by: Oleksii Kurochko 

Reviewed-by: Alistair Francis 

Alistair

> ---
>  xen/arch/riscv/riscv64/head.S | 5 +
>  1 file changed, 5 insertions(+)
>
> diff --git a/xen/arch/riscv/riscv64/head.S b/xen/arch/riscv/riscv64/head.S
> index d444dd8aad..ffd95f9f89 100644
> --- a/xen/arch/riscv/riscv64/head.S
> +++ b/xen/arch/riscv/riscv64/head.S
> @@ -1,6 +1,11 @@
> +#include 
> +
>  .section .text.header, "ax", %progbits
>
>  ENTRY(start)
> +/* Mask all interrupts */
> +csrwCSR_SIE, zero
> +
>  la  sp, cpu0_boot_stack
>  li  t0, STACK_SIZE
>  add sp, sp, t0
> --
> 2.39.0
>
>



Re: [PATCH v1 09/14] xen/riscv: introduce do_unexpected_trap()

2023-01-22 Thread Alistair Francis
On Sat, Jan 21, 2023 at 1:00 AM Oleksii Kurochko
 wrote:
>
> The patch introduces the function the purpose of which is to print
> a cause of an exception and call "wfi" instruction.
>
> Signed-off-by: Oleksii Kurochko 
> ---
>  xen/arch/riscv/traps.c | 14 +-
>  1 file changed, 13 insertions(+), 1 deletion(-)
>
> diff --git a/xen/arch/riscv/traps.c b/xen/arch/riscv/traps.c
> index dd64f053a5..fc25138a4b 100644
> --- a/xen/arch/riscv/traps.c
> +++ b/xen/arch/riscv/traps.c
> @@ -95,7 +95,19 @@ const char *decode_cause(unsigned long cause)
>  return decode_trap_cause(cause);
>  }
>
> -void __handle_exception(struct cpu_user_regs *cpu_regs)
> +static void do_unexpected_trap(const struct cpu_user_regs *regs)
>  {
> +unsigned long cause = csr_read(CSR_SCAUSE);
> +
> +early_printk("Unhandled exception: ");
> +early_printk(decode_cause(cause));
> +early_printk("\n");
> +
> +// kind of die...
>  wait_for_interrupt();

We could put this in a loop, to ensure we never progress

Alistair

>  }
> +
> +void __handle_exception(struct cpu_user_regs *cpu_regs)
> +{
> +do_unexpected_trap(cpu_regs);
> +}
> --
> 2.39.0
>
>



Re: [PATCH v1 08/14] xen/riscv: introduce decode_cause() stuff

2023-01-22 Thread Alistair Francis
On Sat, Jan 21, 2023 at 1:00 AM Oleksii Kurochko
 wrote:
>
> The patch introduces stuff needed to decode a reason of an
> exception.
>
> Signed-off-by: Oleksii Kurochko 

Reviewed-by: Alistair Francis 

Alistair

> ---
>  xen/arch/riscv/traps.c | 88 ++
>  1 file changed, 88 insertions(+)
>
> diff --git a/xen/arch/riscv/traps.c b/xen/arch/riscv/traps.c
> index 3201b851ef..dd64f053a5 100644
> --- a/xen/arch/riscv/traps.c
> +++ b/xen/arch/riscv/traps.c
> @@ -4,8 +4,96 @@
>   *
>   * RISC-V Trap handlers
>   */
> +#include 
> +#include 
>  #include 
>  #include 
> +#include 
> +
> +const char *decode_trap_cause(unsigned long cause)
> +{
> +switch ( cause )
> +{
> +case CAUSE_MISALIGNED_FETCH:
> +return "Instruction Address Misaligned";
> +case CAUSE_FETCH_ACCESS:
> +return "Instruction Access Fault";
> +case CAUSE_ILLEGAL_INSTRUCTION:
> +return "Illegal Instruction";
> +case CAUSE_BREAKPOINT:
> +return "Breakpoint";
> +case CAUSE_MISALIGNED_LOAD:
> +return "Load Address Misaligned";
> +case CAUSE_LOAD_ACCESS:
> +return "Load Access Fault";
> +case CAUSE_MISALIGNED_STORE:
> +return "Store/AMO Address Misaligned";
> +case CAUSE_STORE_ACCESS:
> +return "Store/AMO Access Fault";
> +case CAUSE_USER_ECALL:
> +return "Environment Call from U-Mode";
> +case CAUSE_SUPERVISOR_ECALL:
> +return "Environment Call from S-Mode";
> +case CAUSE_MACHINE_ECALL:
> +return "Environment Call from M-Mode";
> +case CAUSE_FETCH_PAGE_FAULT:
> +return "Instruction Page Fault";
> +case CAUSE_LOAD_PAGE_FAULT:
> +return "Load Page Fault";
> +case CAUSE_STORE_PAGE_FAULT:
> +return "Store/AMO Page Fault";
> +case CAUSE_FETCH_GUEST_PAGE_FAULT:
> +return "Instruction Guest Page Fault";
> +case CAUSE_LOAD_GUEST_PAGE_FAULT:
> +return "Load Guest Page Fault";
> +case CAUSE_VIRTUAL_INST_FAULT:
> +return "Virtualized Instruction Fault";
> +case CAUSE_STORE_GUEST_PAGE_FAULT:
> +return "Guest Store/AMO Page Fault";
> +default:
> +return "UNKNOWN";
> +}
> +}
> +
> +const char *decode_reserved_interrupt_cause(unsigned long irq_cause)
> +{
> +switch ( irq_cause )
> +{
> +case IRQ_M_SOFT:
> +return "M-mode Software Interrupt";
> +case IRQ_M_TIMER:
> +return "M-mode TIMER Interrupt";
> +case IRQ_M_EXT:
> +return "M-mode TIMER Interrupt";
> +default:
> +return "UNKNOWN IRQ type";
> +}
> +}
> +
> +const char *decode_interrupt_cause(unsigned long cause)
> +{
> +unsigned long irq_cause = cause & ~CAUSE_IRQ_FLAG;
> +
> +switch ( irq_cause )
> +{
> +case IRQ_S_SOFT:
> +return "Supervisor Software Interrupt";
> +case IRQ_S_TIMER:
> +return "Supervisor Timer Interrupt";
> +case IRQ_S_EXT:
> +return "Supervisor External Interrupt";
> +default:
> +return decode_reserved_interrupt_cause(irq_cause);
> +}
> +}
> +
> +const char *decode_cause(unsigned long cause)
> +{
> +if ( cause & CAUSE_IRQ_FLAG )
> +return decode_interrupt_cause(cause);
> +
> +return decode_trap_cause(cause);
> +}
>
>  void __handle_exception(struct cpu_user_regs *cpu_regs)
>  {
> --
> 2.39.0
>
>



Re: [PATCH v1 07/14] xen/riscv: introduce exception handlers implementation

2023-01-22 Thread Alistair Francis
On Sat, Jan 21, 2023 at 1:00 AM Oleksii Kurochko
 wrote:
>
> The patch introduces an implementation of basic exception handlers:
> - to save/restore context
> - to handle an exception itself. The handler calls wait_for_interrupt
>   now, nothing more.
>
> Signed-off-by: Oleksii Kurochko 

Reviewed-by: Alistair Francis 

Alistair

> ---
>  xen/arch/riscv/Makefile|  2 +
>  xen/arch/riscv/entry.S | 97 ++
>  xen/arch/riscv/include/asm/traps.h | 13 
>  xen/arch/riscv/traps.c | 13 
>  4 files changed, 125 insertions(+)
>  create mode 100644 xen/arch/riscv/entry.S
>  create mode 100644 xen/arch/riscv/include/asm/traps.h
>  create mode 100644 xen/arch/riscv/traps.c
>
> diff --git a/xen/arch/riscv/Makefile b/xen/arch/riscv/Makefile
> index 1a4f1a6015..443f6bf15f 100644
> --- a/xen/arch/riscv/Makefile
> +++ b/xen/arch/riscv/Makefile
> @@ -1,7 +1,9 @@
>  obj-$(CONFIG_EARLY_PRINTK) += early_printk.o
> +obj-y += entry.o
>  obj-$(CONFIG_RISCV_64) += riscv64/
>  obj-y += sbi.o
>  obj-y += setup.o
> +obj-y += traps.o
>
>  $(TARGET): $(TARGET)-syms
> $(OBJCOPY) -O binary -S $< $@
> diff --git a/xen/arch/riscv/entry.S b/xen/arch/riscv/entry.S
> new file mode 100644
> index 00..f7d46f42bb
> --- /dev/null
> +++ b/xen/arch/riscv/entry.S
> @@ -0,0 +1,97 @@
> +#include 
> +#include 
> +#include 
> +#include 
> +
> +.global handle_exception
> +.align 4
> +
> +handle_exception:
> +
> +/* Exceptions from xen */
> +save_to_stack:
> +/* Save context to stack */
> +REG_S   sp, (RISCV_CPU_USER_REGS_OFFSET(sp) - 
> RISCV_CPU_USER_REGS_SIZE) (sp)
> +addisp, sp, -RISCV_CPU_USER_REGS_SIZE
> +REG_S   t0, RISCV_CPU_USER_REGS_OFFSET(t0)(sp)
> +j   save_context
> +
> +save_context:
> +/* Save registers */
> +REG_S   ra, RISCV_CPU_USER_REGS_OFFSET(ra)(sp)
> +REG_S   gp, RISCV_CPU_USER_REGS_OFFSET(gp)(sp)
> +REG_S   t1, RISCV_CPU_USER_REGS_OFFSET(t1)(sp)
> +REG_S   t2, RISCV_CPU_USER_REGS_OFFSET(t2)(sp)
> +REG_S   s0, RISCV_CPU_USER_REGS_OFFSET(s0)(sp)
> +REG_S   s1, RISCV_CPU_USER_REGS_OFFSET(s1)(sp)
> +REG_S   a0, RISCV_CPU_USER_REGS_OFFSET(a0)(sp)
> +REG_S   a1, RISCV_CPU_USER_REGS_OFFSET(a1)(sp)
> +REG_S   a2, RISCV_CPU_USER_REGS_OFFSET(a2)(sp)
> +REG_S   a3, RISCV_CPU_USER_REGS_OFFSET(a3)(sp)
> +REG_S   a4, RISCV_CPU_USER_REGS_OFFSET(a4)(sp)
> +REG_S   a5, RISCV_CPU_USER_REGS_OFFSET(a5)(sp)
> +REG_S   a6, RISCV_CPU_USER_REGS_OFFSET(a6)(sp)
> +REG_S   a7, RISCV_CPU_USER_REGS_OFFSET(a7)(sp)
> +REG_S   s2, RISCV_CPU_USER_REGS_OFFSET(s2)(sp)
> +REG_S   s3, RISCV_CPU_USER_REGS_OFFSET(s3)(sp)
> +REG_S   s4, RISCV_CPU_USER_REGS_OFFSET(s4)(sp)
> +REG_S   s5, RISCV_CPU_USER_REGS_OFFSET(s5)(sp)
> +REG_S   s6, RISCV_CPU_USER_REGS_OFFSET(s6)(sp)
> +REG_S   s7, RISCV_CPU_USER_REGS_OFFSET(s7)(sp)
> +REG_S   s8, RISCV_CPU_USER_REGS_OFFSET(s8)(sp)
> +REG_S   s9, RISCV_CPU_USER_REGS_OFFSET(s9)(sp)
> +REG_S   s10, RISCV_CPU_USER_REGS_OFFSET(s10)(sp)
> +REG_S   s11, RISCV_CPU_USER_REGS_OFFSET(s11)(sp)
> +REG_S   t3, RISCV_CPU_USER_REGS_OFFSET(t3)(sp)
> +REG_S   t4, RISCV_CPU_USER_REGS_OFFSET(t4)(sp)
> +REG_S   t5, RISCV_CPU_USER_REGS_OFFSET(t5)(sp)
> +REG_S   t6, RISCV_CPU_USER_REGS_OFFSET(t6)(sp)
> +csrrt0, CSR_SEPC
> +REG_S   t0, RISCV_CPU_USER_REGS_OFFSET(sepc)(sp)
> +csrrt0, CSR_SSTATUS
> +REG_S   t0, RISCV_CPU_USER_REGS_OFFSET(sstatus)(sp)
> +
> +mv  a0, sp
> +jal __handle_exception
> +
> +restore_registers:
> +/* Restore stack_cpu_regs */
> +REG_L   t0, RISCV_CPU_USER_REGS_OFFSET(sepc)(sp)
> +csrwCSR_SEPC, t0
> +REG_L   t0, RISCV_CPU_USER_REGS_OFFSET(sstatus)(sp)
> +csrwCSR_SSTATUS, t0
> +
> +REG_L   ra, RISCV_CPU_USER_REGS_OFFSET(ra)(sp)
> +REG_L   gp, RISCV_CPU_USER_REGS_OFFSET(gp)(sp)
> +REG_L   t0, RISCV_CPU_USER_REGS_OFFSET(t0)(sp)
> +REG_L   t1, RISCV_CPU_USER_REGS_OFFSET(t1)(sp)
> +REG_L   t2, RISCV_CPU_USER_REGS_OFFSET(t2)(sp)
> +REG_L   s0, RISCV_CPU_USER_REGS_OFFSET(s0)(sp)
> +REG_L   s1, RISCV_CPU_USER_REGS_OFFSET(s1)(sp)
> +REG_L   a0, RISCV_CPU_USER_REGS_OFFSET(a0)(sp)
> +REG_L   a1, RISCV_CPU_USER_REGS_OFFSET(a1)(sp)
> +REG_L   a2, RISCV_CPU_USER_REGS_OFFSET(a2)(sp)
> +REG_L   a3, RISCV_CPU_USER_REGS_OFFSET(a3)(sp)
> +REG_L   a4, RISCV_CPU_USER_REGS_OFFSET(a4)(sp)
> +REG_L   a5, RISCV_CPU_USER_REGS_OFFSET(a5)(sp)
> +REG_L   a6, RISCV_CPU_USER_REGS_OFFSET(a6)(sp)
> +REG_L   a7, RISCV_CPU_USER_REGS_OFFSET(a7)(sp)
> +REG_L   s2, RISCV_CPU_USER_REGS_OFFSET(s2)(sp)
> +REG_L   s3, RISCV_CPU_USER_REGS_OFFSET(s3)(sp)
> +   

Re: [PATCH v1 04/14] xen/riscv: add header

2023-01-22 Thread Alistair Francis
On Sat, Jan 21, 2023 at 1:00 AM Oleksii Kurochko
 wrote:
>
> Signed-off-by: Oleksii Kurochko 

Reviewed-by: Alistair Francis 

Alistair

> ---
>  xen/arch/riscv/include/asm/csr.h | 82 
>  1 file changed, 82 insertions(+)
>  create mode 100644 xen/arch/riscv/include/asm/csr.h
>
> diff --git a/xen/arch/riscv/include/asm/csr.h 
> b/xen/arch/riscv/include/asm/csr.h
> new file mode 100644
> index 00..1a879c6c4d
> --- /dev/null
> +++ b/xen/arch/riscv/include/asm/csr.h
> @@ -0,0 +1,82 @@
> +/*
> + * Take from Linux.
> + *
> + * SPDX-License-Identifier: GPL-2.0-only
> + *
> + * Copyright (C) 2015 Regents of the University of California
> + */
> +
> +#ifndef _ASM_RISCV_CSR_H
> +#define _ASM_RISCV_CSR_H
> +
> +#include 
> +#include 
> +#include 
> +
> +#ifndef __ASSEMBLY__
> +
> +#define csr_read(csr)  \
> +({ \
> +   register unsigned long __v; \
> +   __asm__ __volatile__ ("csrr %0, " __ASM_STR(csr)\
> + : "=r" (__v) :\
> + : "memory");  \
> +   __v;\
> +})
> +
> +#define csr_write(csr, val)\
> +({ \
> +   unsigned long __v = (unsigned long)(val);   \
> +   __asm__ __volatile__ ("csrw " __ASM_STR(csr) ", %0" \
> + : : "rK" (__v)\
> + : "memory");  \
> +})
> +
> +/*
> +#define csr_swap(csr, val) \
> +({ \
> +   unsigned long __v = (unsigned long)(val);   \
> +   __asm__ __volatile__ ("csrrw %0, " __ASM_STR(csr) ", %1"\
> + : "=r" (__v) : "rK" (__v) \
> + : "memory");  \
> +   __v;\
> +})
> +
> +#define csr_read_set(csr, val) \
> +({ \
> +   unsigned long __v = (unsigned long)(val);   \
> +   __asm__ __volatile__ ("csrrs %0, " __ASM_STR(csr) ", %1"\
> + : "=r" (__v) : "rK" (__v) \
> + : "memory");  \
> +   __v;\
> +})
> +
> +#define csr_set(csr, val)  \
> +({ \
> +   unsigned long __v = (unsigned long)(val);   \
> +   __asm__ __volatile__ ("csrs " __ASM_STR(csr) ", %0" \
> + : : "rK" (__v)\
> + : "memory");  \
> +})
> +
> +#define csr_read_clear(csr, val)   \
> +({ \
> +   unsigned long __v = (unsigned long)(val);   \
> +   __asm__ __volatile__ ("csrrc %0, " __ASM_STR(csr) ", %1"\
> + : "=r" (__v) : "rK" (__v) \
> + : "memory");  \
> +   __v;\
> +})
> +
> +#define csr_clear(csr, val)\
> +({ \
> +   unsigned long __v = (unsigned long)(val);   \
> +   __asm__ __volatile__ ("csrc " __ASM_STR(csr) ", %0" \
> + : : "rK" (__v)\
> + : "memory");  \
> +})
> +*/
> +
> +#endif /* __ASSEMBLY__ */
> +
> +#endif /* _ASM_RISCV_CSR_H */
> --
> 2.39.0
>
>



Re: [PATCH v1 03/14] xen/riscv: add

2023-01-22 Thread Alistair Francis
On Sat, Jan 21, 2023 at 1:01 AM Oleksii Kurochko
 wrote:
>
> Signed-off-by: Oleksii Kurochko 

Reviewed-by: Alistair Francis 

Alistair

> ---
>  xen/arch/riscv/include/asm/riscv_encoding.h | 945 
>  1 file changed, 945 insertions(+)
>  create mode 100644 xen/arch/riscv/include/asm/riscv_encoding.h
>
> diff --git a/xen/arch/riscv/include/asm/riscv_encoding.h 
> b/xen/arch/riscv/include/asm/riscv_encoding.h
> new file mode 100644
> index 00..8a43d49f7a
> --- /dev/null
> +++ b/xen/arch/riscv/include/asm/riscv_encoding.h
> @@ -0,0 +1,945 @@
> +/* SPDX-License-Identifier: (GPL-2.0-or-later OR BSD-2-Clause) */
> +/*
> + * Copyright (c) 2019 Western Digital Corporation or its affiliates.
> + *
> + * Authors:
> + *   Anup Patel 
> + *
> + * The source has been largely adapted from OpenSBI:
> + * include/sbi/riscv_encodnig.h
> + *
> + */
> +
> +#ifndef __RISCV_ENCODING_H__
> +#define __RISCV_ENCODING_H__
> +
> +#define _UL(X) _AC(X, UL)
> +#define _ULL(X) _AC(X, ULL)
> +
> +/* clang-format off */
> +#define MSTATUS_SIE_UL(0x0002)
> +#define MSTATUS_MIE_UL(0x0008)
> +#define MSTATUS_SPIE_SHIFT 5
> +#define MSTATUS_SPIE   (_UL(1) << MSTATUS_SPIE_SHIFT)
> +#define MSTATUS_UBE_UL(0x0040)
> +#define MSTATUS_MPIE   _UL(0x0080)
> +#define MSTATUS_SPP_SHIFT  8
> +#define MSTATUS_SPP(_UL(1) << MSTATUS_SPP_SHIFT)
> +#define MSTATUS_MPP_SHIFT  11
> +#define MSTATUS_MPP(_UL(3) << MSTATUS_MPP_SHIFT)
> +#define MSTATUS_FS _UL(0x6000)
> +#define MSTATUS_FS_OFF _UL(0x)
> +#define MSTATUS_FS_INITIAL _UL(0x2000)
> +#define MSTATUS_FS_CLEAN   _UL(0x4000)
> +#define MSTATUS_FS_DIRTY   _UL(0x6000)
> +#define MSTATUS_XS _UL(0x00018000)
> +#define MSTATUS_XS_OFF _UL(0x)
> +#define MSTATUS_XS_INITIAL _UL(0x8000)
> +#define MSTATUS_XS_CLEAN   _UL(0x0001)
> +#define MSTATUS_XS_DIRTY   _UL(0x00018000)
> +#define MSTATUS_VS _UL(0x0180)
> +#define MSTATUS_VS_OFF _UL(0x)
> +#define MSTATUS_VS_INITIAL _UL(0x0080)
> +#define MSTATUS_VS_CLEAN   _UL(0x0100)
> +#define MSTATUS_VS_DIRTY   _UL(0x0180)
> +#define MSTATUS_MPRV   _UL(0x0002)
> +#define MSTATUS_SUM_UL(0x0004)
> +#define MSTATUS_MXR_UL(0x0008)
> +#define MSTATUS_TVM_UL(0x0010)
> +#define MSTATUS_TW _UL(0x0020)
> +#define MSTATUS_TSR_UL(0x0040)
> +#define MSTATUS32_SD   _UL(0x8000)
> +#if __riscv_xlen == 64
> +#define MSTATUS_UXL_ULL(0x0003)
> +#define MSTATUS_SXL_ULL(0x000C)
> +#define MSTATUS_SBE_ULL(0x0010)
> +#define MSTATUS_MBE_ULL(0x0020)
> +#define MSTATUS_MPV_ULL(0x0080)
> +#else
> +#define MSTATUSH_SBE   _UL(0x0010)
> +#define MSTATUSH_MBE   _UL(0x0020)
> +#define MSTATUSH_MPV   _UL(0x0080)
> +#endif
> +#define MSTATUS32_SD   _UL(0x8000)
> +#define MSTATUS64_SD   _ULL(0x8000)
> +
> +#define SSTATUS_SIEMSTATUS_SIE
> +#define SSTATUS_SPIE_SHIFT MSTATUS_SPIE_SHIFT
> +#define SSTATUS_SPIE   MSTATUS_SPIE
> +#define SSTATUS_SPP_SHIFT  MSTATUS_SPP_SHIFT
> +#define SSTATUS_SPPMSTATUS_SPP
> +#define SSTATUS_FS MSTATUS_FS
> +#define SSTATUS_FS_OFF MSTATUS_FS_OFF
> +#define SSTATUS_FS_INITIAL MSTATUS_FS_INITIAL
> +#define SSTATUS_FS_CLEAN   MSTATUS_FS_CLEAN
> +#define SSTATUS_FS_DIRTY   MSTATUS_FS_DIRTY
> +#define SSTATUS_XS MSTATUS_XS
> +#define SSTATUS_XS_OFF MSTATUS_XS_OFF
> +#define SSTATUS_XS_INITIAL MSTATUS_XS_INITIAL
> +#define SSTATUS_XS_CLEAN   MSTATUS_XS_CLEAN
> +#define SSTATUS_XS_DIRTY   MSTATUS_XS_DIRTY
> +#define SSTATUS_VS MSTATUS_VS
> +#define SSTATUS_VS_OFF MSTATUS_VS_OFF
> +#define SSTATUS_VS_INITIAL MSTATUS_VS_INITIAL
> +#define SSTATUS_VS_CLEAN   MSTATUS_VS_CLEAN
> +#define SSTATUS_VS_DIRTY   MSTATUS_VS_DIRTY
> +#define SSTATUS_SUMMSTATUS_SUM
> +#define SSTATUS_MXRMSTATUS_MXR
> +#define SSTATUS32_SD   MSTATUS32_SD
> +#define SSTATUS64_UXL  MSTATUS_UXL
> +#define SSTATUS64_SD   MSTATUS64_SD
> 

Re: [PATCH v1 02/14] xen/riscv: add header

2023-01-22 Thread Alistair Francis
On Sat, Jan 21, 2023 at 1:00 AM Oleksii Kurochko
 wrote:
>
> Signed-off-by: Oleksii Kurochko 

Reviewed-by: Alistair Francis 

Alistair

> ---
>  xen/arch/riscv/include/asm/asm.h | 54 
>  1 file changed, 54 insertions(+)
>  create mode 100644 xen/arch/riscv/include/asm/asm.h
>
> diff --git a/xen/arch/riscv/include/asm/asm.h 
> b/xen/arch/riscv/include/asm/asm.h
> new file mode 100644
> index 00..6d426ecea7
> --- /dev/null
> +++ b/xen/arch/riscv/include/asm/asm.h
> @@ -0,0 +1,54 @@
> +/* SPDX-License-Identifier: (GPL-2.0-only) */
> +/*
> + * Copyright (C) 2015 Regents of the University of California
> + */
> +
> +#ifndef _ASM_RISCV_ASM_H
> +#define _ASM_RISCV_ASM_H
> +
> +#ifdef __ASSEMBLY__
> +#define __ASM_STR(x)   x
> +#else
> +#define __ASM_STR(x)   #x
> +#endif
> +
> +#if __riscv_xlen == 64
> +#define __REG_SEL(a, b)__ASM_STR(a)
> +#elif __riscv_xlen == 32
> +#define __REG_SEL(a, b)__ASM_STR(b)
> +#else
> +#error "Unexpected __riscv_xlen"
> +#endif
> +
> +#define REG_L  __REG_SEL(ld, lw)
> +#define REG_S  __REG_SEL(sd, sw)
> +
> +#if __SIZEOF_POINTER__ == 8
> +#ifdef __ASSEMBLY__
> +#define RISCV_PTR  .dword
> +#else
> +#define RISCV_PTR  ".dword"
> +#endif
> +#elif __SIZEOF_POINTER__ == 4
> +#ifdef __ASSEMBLY__
> +#define RISCV_PTR  .word
> +#else
> +#define RISCV_PTR  ".word"
> +#endif
> +#else
> +#error "Unexpected __SIZEOF_POINTER__"
> +#endif
> +
> +#if (__SIZEOF_INT__ == 4)
> +#define RISCV_INT  __ASM_STR(.word)
> +#else
> +#error "Unexpected __SIZEOF_INT__"
> +#endif
> +
> +#if (__SIZEOF_SHORT__ == 2)
> +#define RISCV_SHORT__ASM_STR(.half)
> +#else
> +#error "Unexpected __SIZEOF_SHORT__"
> +#endif
> +
> +#endif /* _ASM_RISCV_ASM_H */
> --
> 2.39.0
>
>



[linux-linus test] 176046: regressions - FAIL

2023-01-22 Thread osstest service owner
flight 176046 linux-linus real [real]
http://logs.test-lab.xenproject.org/osstest/logs/176046/

Regressions :-(

Tests which did not succeed and are blocking,
including tests which could not be run:
 test-arm64-arm64-examine  8 reboot   fail REGR. vs. 173462
 test-arm64-arm64-xl-vhd   8 xen-boot fail REGR. vs. 173462
 test-arm64-arm64-libvirt-raw  8 xen-boot fail REGR. vs. 173462
 test-arm64-arm64-xl-seattle   8 xen-boot fail REGR. vs. 173462
 test-arm64-arm64-xl-xsm   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-xl-arndale   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-xl-credit2   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-xl-multivcpu  8 xen-bootfail REGR. vs. 173462
 test-armhf-armhf-xl   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-xl-credit1   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-xl-vhd   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-libvirt  8 xen-boot fail REGR. vs. 173462
 test-arm64-arm64-libvirt-xsm  8 xen-boot fail REGR. vs. 173462
 test-arm64-arm64-xl-credit2   8 xen-boot fail REGR. vs. 173462
 test-arm64-arm64-xl-credit1   8 xen-boot fail REGR. vs. 173462
 test-arm64-arm64-xl   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-examine  8 reboot   fail REGR. vs. 173462
 test-armhf-armhf-libvirt-qcow2  8 xen-boot   fail REGR. vs. 173462
 test-armhf-armhf-libvirt-raw  8 xen-boot fail REGR. vs. 173462
 build-arm64-pvops 6 kernel-build   fail in 176040 REGR. vs. 173462

Tests which are failing intermittently (not blocking):
 test-amd64-amd64-xl-qemut-debianhvm-i386-xsm 12 debian-hvm-install fail pass 
in 176040

Regressions which are regarded as allowable (not blocking):
 test-armhf-armhf-xl-rtds  8 xen-boot fail REGR. vs. 173462

Tests which did not succeed, but are not blocking:
 test-arm64-arm64-xl   1 build-check(1)   blocked in 176040 n/a
 test-arm64-arm64-xl-xsm   1 build-check(1)   blocked in 176040 n/a
 test-arm64-arm64-examine  1 build-check(1)   blocked in 176040 n/a
 test-arm64-arm64-xl-seattle   1 build-check(1)   blocked in 176040 n/a
 test-arm64-arm64-xl-credit2   1 build-check(1)   blocked in 176040 n/a
 test-arm64-arm64-xl-credit1   1 build-check(1)   blocked in 176040 n/a
 test-arm64-arm64-xl-thunderx  1 build-check(1)   blocked in 176040 n/a
 test-arm64-arm64-xl-vhd   1 build-check(1)   blocked in 176040 n/a
 test-arm64-arm64-libvirt-xsm  1 build-check(1)   blocked in 176040 n/a
 test-arm64-arm64-libvirt-raw  1 build-check(1)   blocked in 176040 n/a
 test-amd64-amd64-xl-qemut-win7-amd64 19 guest-stopfail like 173462
 test-amd64-amd64-xl-qemuu-win7-amd64 19 guest-stopfail like 173462
 test-amd64-amd64-xl-qemuu-ws16-amd64 19 guest-stopfail like 173462
 test-amd64-amd64-qemuu-nested-amd 20 debian-hvm-install/l1/l2 fail like 173462
 test-amd64-amd64-xl-qemut-ws16-amd64 19 guest-stopfail like 173462
 test-amd64-amd64-libvirt-xsm 15 migrate-support-checkfail   never pass
 test-amd64-amd64-libvirt 15 migrate-support-checkfail   never pass
 test-amd64-amd64-libvirt-raw 14 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-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-armhf-armhf-xl-cubietruck 15 migrate-support-checkfail never pass
 test-armhf-armhf-xl-cubietruck 16 saverestore-support-checkfail never pass

version targeted for testing:
 linux2241ab53cbb5cdb08a6b2d4688feb13971058f65
baseline version:
 linux9d84bb40bcb30a7fa16f33baa967aeb9953dda78

Last test of basis   173462  2022-10-07 18:41:45 Z  107 days
Failing since173470  2022-10-08 06:21:34 Z  106 days  219 attempts
Testing same since   176040  2023-01-22 08:42:55 Z0 days2 attempts


3434 people touched revisions under test,
not listing them all

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

[xen-unstable test] 176042: regressions - FAIL

2023-01-22 Thread osstest service owner
flight 176042 xen-unstable real [real]
http://logs.test-lab.xenproject.org/osstest/logs/176042/

Regressions :-(

Tests which did not succeed and are blocking,
including tests which could not be run:
 test-amd64-coresched-i386-xl 18 guest-localmigrate   fail REGR. vs. 175994
 test-amd64-i386-xl-xsm   18 guest-localmigrate   fail REGR. vs. 175994
 test-amd64-i386-xl   18 guest-localmigrate   fail REGR. vs. 175994
 test-amd64-i386-pair  26 guest-migrate/src_host/dst_host fail REGR. vs. 175994
 test-amd64-i386-xl-vhd   17 guest-localmigrate   fail REGR. vs. 175994
 test-amd64-i386-xl-shadow18 guest-localmigrate   fail REGR. vs. 175994
 test-amd64-i386-libvirt-pair 26 guest-migrate/src_host/dst_host fail REGR. vs. 
175994

Tests which are failing intermittently (not blocking):
 test-amd64-amd64-libvirt-vhd 19 guest-start/debian.repeat fail in 176035 pass 
in 176042
 test-amd64-amd64-xl-qcow2 21 guest-start/debian.repeat fail in 176035 pass in 
176042
 test-arm64-arm64-xl-vhd  17 guest-start/debian.repeat  fail pass in 176035

Tests which did not succeed, but are not blocking:
 test-armhf-armhf-libvirt 16 saverestore-support-checkfail  like 175987
 test-amd64-i386-xl-qemuu-ws16-amd64 19 guest-stop fail like 175987
 test-amd64-amd64-xl-qemuu-win7-amd64 19 guest-stopfail like 175987
 test-amd64-amd64-xl-qemut-win7-amd64 19 guest-stopfail like 175994
 test-amd64-i386-xl-qemuu-win7-amd64 19 guest-stop fail like 175994
 test-amd64-amd64-xl-qemuu-ws16-amd64 19 guest-stopfail like 175994
 test-amd64-amd64-qemuu-nested-amd 20 debian-hvm-install/l1/l2 fail like 175994
 test-amd64-i386-xl-qemut-win7-amd64 19 guest-stop fail like 175994
 test-amd64-i386-xl-qemut-ws16-amd64 19 guest-stop fail like 175994
 test-armhf-armhf-libvirt-qcow2 15 saverestore-support-check   fail like 175994
 test-armhf-armhf-libvirt-raw 15 saverestore-support-checkfail  like 175994
 test-amd64-amd64-xl-qemut-ws16-amd64 19 guest-stopfail like 175994
 test-amd64-i386-libvirt-xsm  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-seattle  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-seattle  16 saverestore-support-checkfail   never pass
 test-amd64-amd64-libvirt-xsm 15 migrate-support-checkfail   never pass
 test-amd64-amd64-libvirt 15 migrate-support-checkfail   never pass
 test-amd64-i386-xl-pvshim14 guest-start  fail   never pass
 test-amd64-i386-libvirt  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-xl-credit2  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-xsm  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-credit2  16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-xsm  16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-credit1  15 migrate-support-checkfail   never pass
 test-arm64-arm64-libvirt-xsm 15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-credit1  16 saverestore-support-checkfail   never pass
 test-arm64-arm64-libvirt-xsm 16 saverestore-support-checkfail   never pass
 test-amd64-amd64-libvirt-qemuu-debianhvm-amd64-xsm 13 migrate-support-check 
fail 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-i386-libvirt-qemuu-debianhvm-amd64-xsm 13 migrate-support-check 
fail never pass
 test-amd64-i386-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-armhf-armhf-xl-cubietruck 15 migrate-support-checkfail never pass
 test-armhf-armhf-xl-cubietruck 16 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-xl-credit2  15 migrate-support-checkfail   never pass
 test-armhf-armhf-xl-credit2  16 saverestore-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-arm64-arm64-xl-vhd  14 migrate-support-checkfail   never 

Re: [PATCH v11] xen/pt: reserve PCI slot 2 for Intel igd-passthru

2023-01-22 Thread Chuck Zmudzinski
On 1/22/23 3:40 AM, Michael S. Tsirkin wrote:
> On Sat, Jan 21, 2023 at 07:57:02PM -0500, Chuck Zmudzinski wrote:
>> Intel specifies that the Intel IGD must occupy slot 2 on the PCI bus,
>> as noted in docs/igd-assign.txt in the Qemu source code.
>> 
>> Currently, when the xl toolstack is used to configure a Xen HVM guest with
>> Intel IGD passthrough to the guest with the Qemu upstream device model,
>> a Qemu emulated PCI device will occupy slot 2 and the Intel IGD will occupy
>> a different slot. This problem often prevents the guest from booting.
>> 
>> The only available workarounds are not good: Configure Xen HVM guests to
>> use the old and no longer maintained Qemu traditional device model
>> available from xenbits.xen.org which does reserve slot 2 for the Intel
>> IGD or use the "pc" machine type instead of the "xenfv" machine type and
>> add the xen platform device at slot 3 using a command line option
>> instead of patching qemu to fix the "xenfv" machine type directly. The
>> second workaround causes some degredation in startup performance such as
>> a longer boot time and reduced resolution of the grub menu that is
>> displayed on the monitor. This patch avoids that reduced startup
>> performance when using the Qemu upstream device model for Xen HVM guests
>> configured with the igd-passthru=on option.
>> 
>> To implement this feature in the Qemu upstream device model for Xen HVM
>> guests, introduce the following new functions, types, and macros:
>> 
>> * XEN_PT_DEVICE_CLASS declaration, based on the existing TYPE_XEN_PT_DEVICE
>> * XEN_PT_DEVICE_GET_CLASS macro helper function for XEN_PT_DEVICE_CLASS
>> * typedef XenPTQdevRealize function pointer
>> * XEN_PCI_IGD_SLOT_MASK, the value of slot_reserved_mask to reserve slot 2
>> * xen_igd_reserve_slot and xen_igd_clear_slot functions
>> 
>> Michael Tsirkin:
>> * Introduce XEN_PCI_IGD_DOMAIN, XEN_PCI_IGD_BUS, XEN_PCI_IGD_DEV, and
>>   XEN_PCI_IGD_FN - use them to compute the value of XEN_PCI_IGD_SLOT_MASK
>> 
>> The new xen_igd_reserve_slot function uses the existing slot_reserved_mask
>> member of PCIBus to reserve PCI slot 2 for Xen HVM guests configured using
>> the xl toolstack with the gfx_passthru option enabled, which sets the
>> igd-passthru=on option to Qemu for the Xen HVM machine type.
>> 
>> The new xen_igd_reserve_slot function also needs to be implemented in
>> hw/xen/xen_pt_stub.c to prevent FTBFS during the link stage for the case
>> when Qemu is configured with --enable-xen and --disable-xen-pci-passthrough,
>> in which case it does nothing.
>> 
>> The new xen_igd_clear_slot function overrides qdev->realize of the parent
>> PCI device class to enable the Intel IGD to occupy slot 2 on the PCI bus
>> since slot 2 was reserved by xen_igd_reserve_slot when the PCI bus was
>> created in hw/i386/pc_piix.c for the case when igd-passthru=on.
>> 
>> Move the call to xen_host_pci_device_get, and the associated error
>> handling, from xen_pt_realize to the new xen_igd_clear_slot function to
>> initialize the device class and vendor values which enables the checks for
>> the Intel IGD to succeed. The verification that the host device is an
>> Intel IGD to be passed through is done by checking the domain, bus, slot,
>> and function values as well as by checking that gfx_passthru is enabled,
>> the device class is VGA, and the device vendor in Intel.
>> 
>> Signed-off-by: Chuck Zmudzinski 
>> ---
>> Notes that might be helpful to reviewers of patched code in hw/xen:
>> 
>> The new functions and types are based on recommendations from Qemu docs:
>> https://qemu.readthedocs.io/en/latest/devel/qom.html
>> 
>> Notes that might be helpful to reviewers of patched code in hw/i386:
>> 
>> The small patch to hw/i386/pc_piix.c is protected by CONFIG_XEN so it does
>> not affect builds that do not have CONFIG_XEN defined.
>> 
>> xen_igd_gfx_pt_enabled() in the patched hw/i386/pc_piix.c file is an
>> existing function that is only true when Qemu is built with
>> xen-pci-passthrough enabled and the administrator has configured the Xen
>> HVM guest with Qemu's igd-passthru=on option.
>> 
>> v2: Remove From:  tag at top of commit message
>> 
>> v3: Changed the test for the Intel IGD in xen_igd_clear_slot:
>> 
>> if (is_igd_vga_passthrough(>real_device) &&
>> (s->real_device.vendor_id == PCI_VENDOR_ID_INTEL)) {
>> 
>> is changed to
>> 
>> if (xen_igd_gfx_pt_enabled() && (s->hostaddr.slot == 2)
>> && (s->hostaddr.function == 0)) {
>> 
>> I hoped that I could use the test in v2, since it matches the
>> other tests for the Intel IGD in Qemu and Xen, but those tests
>> do not work because the necessary data structures are not set with
>> their values yet. So instead use the test that the administrator
>> has enabled gfx_passthru and the device address on the host is
>> 02.0. This test does detect the Intel IGD correctly.
>> 
>> v4: Use brchu...@aol.com instead of brchu...@netscape.net for the author's
>> 

[linux-linus test] 176040: regressions - FAIL

2023-01-22 Thread osstest service owner
flight 176040 linux-linus real [real]
http://logs.test-lab.xenproject.org/osstest/logs/176040/

Regressions :-(

Tests which did not succeed and are blocking,
including tests which could not be run:
 test-armhf-armhf-xl-arndale   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-xl-credit2   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-xl   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-xl-multivcpu  8 xen-bootfail REGR. vs. 173462
 test-armhf-armhf-xl-credit1   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-xl-vhd   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-libvirt  8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-examine  8 reboot   fail REGR. vs. 173462
 test-armhf-armhf-libvirt-qcow2  8 xen-boot   fail REGR. vs. 173462
 test-armhf-armhf-libvirt-raw  8 xen-boot fail REGR. vs. 173462
 build-arm64-pvops 6 kernel-build fail REGR. vs. 173462

Regressions which are regarded as allowable (not blocking):
 test-armhf-armhf-xl-rtds  8 xen-boot fail REGR. vs. 173462

Tests which did not succeed, but are not blocking:
 test-arm64-arm64-xl-credit1   1 build-check(1)   blocked  n/a
 test-arm64-arm64-xl-credit2   1 build-check(1)   blocked  n/a
 test-arm64-arm64-xl-seattle   1 build-check(1)   blocked  n/a
 test-arm64-arm64-xl-thunderx  1 build-check(1)   blocked  n/a
 test-arm64-arm64-xl-vhd   1 build-check(1)   blocked  n/a
 test-arm64-arm64-xl-xsm   1 build-check(1)   blocked  n/a
 test-arm64-arm64-examine  1 build-check(1)   blocked  n/a
 test-arm64-arm64-libvirt-raw  1 build-check(1)   blocked  n/a
 test-arm64-arm64-libvirt-xsm  1 build-check(1)   blocked  n/a
 test-arm64-arm64-xl   1 build-check(1)   blocked  n/a
 test-amd64-amd64-xl-qemut-win7-amd64 19 guest-stopfail like 173462
 test-amd64-amd64-xl-qemuu-win7-amd64 19 guest-stopfail like 173462
 test-amd64-amd64-xl-qemuu-ws16-amd64 19 guest-stopfail like 173462
 test-amd64-amd64-qemuu-nested-amd 20 debian-hvm-install/l1/l2 fail like 173462
 test-amd64-amd64-xl-qemut-ws16-amd64 19 guest-stopfail like 173462
 test-amd64-amd64-libvirt-xsm 15 migrate-support-checkfail   never pass
 test-amd64-amd64-libvirt 15 migrate-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-qemuu-debianhvm-amd64-xsm 13 migrate-support-check 
fail never pass
 test-armhf-armhf-xl-cubietruck 15 migrate-support-checkfail never pass
 test-armhf-armhf-xl-cubietruck 16 saverestore-support-checkfail never pass

version targeted for testing:
 linux2241ab53cbb5cdb08a6b2d4688feb13971058f65
baseline version:
 linux9d84bb40bcb30a7fa16f33baa967aeb9953dda78

Last test of basis   173462  2022-10-07 18:41:45 Z  106 days
Failing since173470  2022-10-08 06:21:34 Z  106 days  218 attempts
Testing same since   176040  2023-01-22 08:42:55 Z0 days1 attempts


3434 people touched revisions under test,
not listing them all

jobs:
 build-amd64-xsm  pass
 build-arm64-xsm  pass
 build-i386-xsm   pass
 build-amd64  pass
 build-arm64  pass
 build-armhf  pass
 build-i386   pass
 build-amd64-libvirt  pass
 build-arm64-libvirt  pass
 build-armhf-libvirt  pass
 build-i386-libvirt   pass
 build-amd64-pvopspass
 build-arm64-pvopsfail
 build-armhf-pvopspass
 build-i386-pvops pass
 test-amd64-amd64-xl  pass
 test-amd64-coresched-amd64-xlpass
 test-arm64-arm64-xl  blocked 
 test-armhf-armhf-xl  fail
 test-amd64-amd64-libvirt-qemuu-debianhvm-amd64-xsm   pass
 test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64-xsm

[xen-unstable test] 176035: regressions - FAIL

2023-01-22 Thread osstest service owner
flight 176035 xen-unstable real [real]
http://logs.test-lab.xenproject.org/osstest/logs/176035/

Regressions :-(

Tests which did not succeed and are blocking,
including tests which could not be run:
 test-amd64-coresched-i386-xl 18 guest-localmigrate   fail REGR. vs. 175994
 test-amd64-i386-xl-xsm   18 guest-localmigrate   fail REGR. vs. 175994
 test-amd64-i386-xl   18 guest-localmigrate   fail REGR. vs. 175994
 test-amd64-i386-pair  26 guest-migrate/src_host/dst_host fail REGR. vs. 175994
 test-amd64-i386-xl-vhd   17 guest-localmigrate   fail REGR. vs. 175994
 test-amd64-i386-xl-shadow18 guest-localmigrate   fail REGR. vs. 175994
 test-amd64-i386-libvirt-pair 26 guest-migrate/src_host/dst_host fail REGR. vs. 
175994

Tests which are failing intermittently (not blocking):
 test-amd64-amd64-qemuu-freebsd11-amd64 19 guest-localmigrate/x10 fail in 
176025 pass in 176035
 test-amd64-amd64-libvirt-vhd 19 guest-start/debian.repeat  fail pass in 176025
 test-amd64-amd64-xl-qcow221 guest-start/debian.repeat  fail pass in 176025

Tests which did not succeed, but are not blocking:
 test-amd64-amd64-xl-qemuu-win7-amd64 12 windows-install fail in 176025 like 
175994
 test-armhf-armhf-libvirt 16 saverestore-support-checkfail  like 175987
 test-amd64-i386-xl-qemuu-ws16-amd64 19 guest-stop fail like 175987
 test-amd64-amd64-xl-qemuu-win7-amd64 19 guest-stopfail like 175987
 test-amd64-amd64-xl-qemut-win7-amd64 19 guest-stopfail like 175994
 test-amd64-i386-xl-qemuu-win7-amd64 19 guest-stop fail like 175994
 test-amd64-amd64-xl-qemuu-ws16-amd64 19 guest-stopfail like 175994
 test-amd64-amd64-qemuu-nested-amd 20 debian-hvm-install/l1/l2 fail like 175994
 test-amd64-i386-xl-qemut-win7-amd64 19 guest-stop fail like 175994
 test-amd64-i386-xl-qemut-ws16-amd64 19 guest-stop fail like 175994
 test-armhf-armhf-libvirt-qcow2 15 saverestore-support-check   fail like 175994
 test-armhf-armhf-libvirt-raw 15 saverestore-support-checkfail  like 175994
 test-amd64-amd64-xl-qemut-ws16-amd64 19 guest-stopfail like 175994
 test-amd64-i386-libvirt-xsm  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-seattle  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-seattle  16 saverestore-support-checkfail   never pass
 test-amd64-amd64-libvirt-xsm 15 migrate-support-checkfail   never pass
 test-amd64-amd64-libvirt 15 migrate-support-checkfail   never pass
 test-amd64-i386-xl-pvshim14 guest-start  fail   never pass
 test-amd64-i386-libvirt  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-xl-credit2  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-xsm  15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-credit2  16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-xsm  16 saverestore-support-checkfail   never pass
 test-arm64-arm64-xl-credit1  15 migrate-support-checkfail   never pass
 test-arm64-arm64-libvirt-xsm 15 migrate-support-checkfail   never pass
 test-arm64-arm64-xl-credit1  16 saverestore-support-checkfail   never pass
 test-arm64-arm64-libvirt-xsm 16 saverestore-support-checkfail   never pass
 test-amd64-amd64-libvirt-qemuu-debianhvm-amd64-xsm 13 migrate-support-check 
fail 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-i386-libvirt-qemuu-debianhvm-amd64-xsm 13 migrate-support-check 
fail never pass
 test-amd64-i386-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-armhf-armhf-xl-credit2  15 migrate-support-checkfail   never pass
 test-armhf-armhf-xl-cubietruck 15 migrate-support-checkfail never pass
 test-armhf-armhf-xl-credit2  16 saverestore-support-checkfail   never pass
 test-armhf-armhf-xl-cubietruck 16 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-xl-multivcpu 15 migrate-support-checkfail  never pass
 test-armhf-armhf-xl-multivcpu 16 saverestore-support-checkfail  

Re: [PATCH v11] xen/pt: reserve PCI slot 2 for Intel igd-passthru

2023-01-22 Thread Michael S. Tsirkin
On Sat, Jan 21, 2023 at 07:57:02PM -0500, Chuck Zmudzinski wrote:
> Intel specifies that the Intel IGD must occupy slot 2 on the PCI bus,
> as noted in docs/igd-assign.txt in the Qemu source code.
> 
> Currently, when the xl toolstack is used to configure a Xen HVM guest with
> Intel IGD passthrough to the guest with the Qemu upstream device model,
> a Qemu emulated PCI device will occupy slot 2 and the Intel IGD will occupy
> a different slot. This problem often prevents the guest from booting.
> 
> The only available workarounds are not good: Configure Xen HVM guests to
> use the old and no longer maintained Qemu traditional device model
> available from xenbits.xen.org which does reserve slot 2 for the Intel
> IGD or use the "pc" machine type instead of the "xenfv" machine type and
> add the xen platform device at slot 3 using a command line option
> instead of patching qemu to fix the "xenfv" machine type directly. The
> second workaround causes some degredation in startup performance such as
> a longer boot time and reduced resolution of the grub menu that is
> displayed on the monitor. This patch avoids that reduced startup
> performance when using the Qemu upstream device model for Xen HVM guests
> configured with the igd-passthru=on option.
> 
> To implement this feature in the Qemu upstream device model for Xen HVM
> guests, introduce the following new functions, types, and macros:
> 
> * XEN_PT_DEVICE_CLASS declaration, based on the existing TYPE_XEN_PT_DEVICE
> * XEN_PT_DEVICE_GET_CLASS macro helper function for XEN_PT_DEVICE_CLASS
> * typedef XenPTQdevRealize function pointer
> * XEN_PCI_IGD_SLOT_MASK, the value of slot_reserved_mask to reserve slot 2
> * xen_igd_reserve_slot and xen_igd_clear_slot functions
> 
> Michael Tsirkin:
> * Introduce XEN_PCI_IGD_DOMAIN, XEN_PCI_IGD_BUS, XEN_PCI_IGD_DEV, and
>   XEN_PCI_IGD_FN - use them to compute the value of XEN_PCI_IGD_SLOT_MASK
> 
> The new xen_igd_reserve_slot function uses the existing slot_reserved_mask
> member of PCIBus to reserve PCI slot 2 for Xen HVM guests configured using
> the xl toolstack with the gfx_passthru option enabled, which sets the
> igd-passthru=on option to Qemu for the Xen HVM machine type.
> 
> The new xen_igd_reserve_slot function also needs to be implemented in
> hw/xen/xen_pt_stub.c to prevent FTBFS during the link stage for the case
> when Qemu is configured with --enable-xen and --disable-xen-pci-passthrough,
> in which case it does nothing.
> 
> The new xen_igd_clear_slot function overrides qdev->realize of the parent
> PCI device class to enable the Intel IGD to occupy slot 2 on the PCI bus
> since slot 2 was reserved by xen_igd_reserve_slot when the PCI bus was
> created in hw/i386/pc_piix.c for the case when igd-passthru=on.
> 
> Move the call to xen_host_pci_device_get, and the associated error
> handling, from xen_pt_realize to the new xen_igd_clear_slot function to
> initialize the device class and vendor values which enables the checks for
> the Intel IGD to succeed. The verification that the host device is an
> Intel IGD to be passed through is done by checking the domain, bus, slot,
> and function values as well as by checking that gfx_passthru is enabled,
> the device class is VGA, and the device vendor in Intel.
> 
> Signed-off-by: Chuck Zmudzinski 
> ---
> Notes that might be helpful to reviewers of patched code in hw/xen:
> 
> The new functions and types are based on recommendations from Qemu docs:
> https://qemu.readthedocs.io/en/latest/devel/qom.html
> 
> Notes that might be helpful to reviewers of patched code in hw/i386:
> 
> The small patch to hw/i386/pc_piix.c is protected by CONFIG_XEN so it does
> not affect builds that do not have CONFIG_XEN defined.
> 
> xen_igd_gfx_pt_enabled() in the patched hw/i386/pc_piix.c file is an
> existing function that is only true when Qemu is built with
> xen-pci-passthrough enabled and the administrator has configured the Xen
> HVM guest with Qemu's igd-passthru=on option.
> 
> v2: Remove From:  tag at top of commit message
> 
> v3: Changed the test for the Intel IGD in xen_igd_clear_slot:
> 
> if (is_igd_vga_passthrough(>real_device) &&
> (s->real_device.vendor_id == PCI_VENDOR_ID_INTEL)) {
> 
> is changed to
> 
> if (xen_igd_gfx_pt_enabled() && (s->hostaddr.slot == 2)
> && (s->hostaddr.function == 0)) {
> 
> I hoped that I could use the test in v2, since it matches the
> other tests for the Intel IGD in Qemu and Xen, but those tests
> do not work because the necessary data structures are not set with
> their values yet. So instead use the test that the administrator
> has enabled gfx_passthru and the device address on the host is
> 02.0. This test does detect the Intel IGD correctly.
> 
> v4: Use brchu...@aol.com instead of brchu...@netscape.net for the author's
> email address to match the address used by the same author in commits
> be9c61da and c0e86b76
> 
> Change variable for 

[linux-linus test] 176029: regressions - trouble: broken/fail/pass

2023-01-22 Thread osstest service owner
flight 176029 linux-linus real [real]
http://logs.test-lab.xenproject.org/osstest/logs/176029/

Regressions :-(

Tests which did not succeed and are blocking,
including tests which could not be run:
 test-amd64-amd64-libvirt-xsm broken
 test-amd64-amd64-libvirt-xsm  5 host-install(5)broken REGR. vs. 173462
 test-arm64-arm64-examine  8 reboot   fail REGR. vs. 173462
 test-arm64-arm64-xl-vhd   8 xen-boot fail REGR. vs. 173462
 test-arm64-arm64-libvirt-raw  8 xen-boot fail REGR. vs. 173462
 test-arm64-arm64-xl-seattle   8 xen-boot fail REGR. vs. 173462
 test-arm64-arm64-xl-xsm   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-xl-arndale   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-xl-credit2   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-xl   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-xl-multivcpu  8 xen-bootfail REGR. vs. 173462
 test-armhf-armhf-xl-credit1   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-xl-vhd   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-libvirt  8 xen-boot fail REGR. vs. 173462
 test-arm64-arm64-libvirt-xsm  8 xen-boot fail REGR. vs. 173462
 test-arm64-arm64-xl-credit2   8 xen-boot fail REGR. vs. 173462
 test-arm64-arm64-xl-credit1   8 xen-boot fail REGR. vs. 173462
 test-arm64-arm64-xl   8 xen-boot fail REGR. vs. 173462
 test-armhf-armhf-examine  8 reboot   fail REGR. vs. 173462
 test-armhf-armhf-libvirt-qcow2  8 xen-boot   fail REGR. vs. 173462
 test-armhf-armhf-libvirt-raw  8 xen-boot fail REGR. vs. 173462

Regressions which are regarded as allowable (not blocking):
 test-armhf-armhf-xl-rtds  8 xen-boot fail REGR. vs. 173462

Tests which did not succeed, but are not blocking:
 test-amd64-amd64-xl-qemut-win7-amd64 19 guest-stopfail like 173462
 test-amd64-amd64-xl-qemuu-win7-amd64 19 guest-stopfail like 173462
 test-amd64-amd64-xl-qemuu-ws16-amd64 19 guest-stopfail like 173462
 test-amd64-amd64-qemuu-nested-amd 20 debian-hvm-install/l1/l2 fail like 173462
 test-amd64-amd64-xl-qemut-ws16-amd64 19 guest-stopfail like 173462
 test-amd64-amd64-libvirt 15 migrate-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-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-qemuu-debianhvm-amd64-xsm 13 migrate-support-check 
fail never pass
 test-armhf-armhf-xl-cubietruck 15 migrate-support-checkfail never pass
 test-armhf-armhf-xl-cubietruck 16 saverestore-support-checkfail never pass

version targeted for testing:
 linuxf67144022885344375ad03593e7a290cc614da34
baseline version:
 linux9d84bb40bcb30a7fa16f33baa967aeb9953dda78

Last test of basis   173462  2022-10-07 18:41:45 Z  106 days
Failing since173470  2022-10-08 06:21:34 Z  106 days  217 attempts
Testing same since   176029  2023-01-21 22:42:32 Z0 days1 attempts


3434 people touched revisions under test,
not listing them all

jobs:
 build-amd64-xsm  pass
 build-arm64-xsm  pass
 build-i386-xsm   pass
 build-amd64  pass
 build-arm64  pass
 build-armhf  pass
 build-i386   pass
 build-amd64-libvirt  pass
 build-arm64-libvirt  pass
 build-armhf-libvirt  pass
 build-i386-libvirt   pass
 build-amd64-pvopspass
 build-arm64-pvopspass
 build-armhf-pvopspass
 build-i386-pvops pass
 test-amd64-amd64-xl  pass
 test-amd64-coresched-amd64-xlpass
 test-arm64-arm64-xl  fail
 test-armhf-armhf-xl  fail