qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3 0/3] hyperv: vmbus: ACPI various corrections
@ 2020-06-18  3:00 Jon Doron
  2020-06-18  3:00 ` [PATCH v3 1/3] hyperv: vmbus: Remove the 2nd IRQ Jon Doron
                   ` (4 more replies)
  0 siblings, 5 replies; 14+ messages in thread
From: Jon Doron @ 2020-06-18  3:00 UTC (permalink / raw)
  To: qemu-devel; +Cc: mail, Jon Doron, rvkagan, imammedo, pbonzini, vkuznets

After doing further tests and looking at the latest HyperV ACPI DSDT.
Do minor fix to our VMBus ACPI entry.

v3:
Removed accidental change for the dct submodule head

v2:
Renamed irq0 to irq now that there is a single IRQ required

Jon Doron (3):
  hyperv: vmbus: Remove the 2nd IRQ
  i386: acpi: vmbus: Add _ADR definition
  acpi: i386: Move VMBus DSDT entry to SB

 hw/hyperv/vmbus.c                |  3 +--
 hw/i386/acpi-build.c             | 17 +++++++++--------
 include/hw/hyperv/vmbus-bridge.h |  3 +--
 3 files changed, 11 insertions(+), 12 deletions(-)

-- 
2.24.1



^ permalink raw reply	[flat|nested] 14+ messages in thread

* [PATCH v3 1/3] hyperv: vmbus: Remove the 2nd IRQ
  2020-06-18  3:00 [PATCH v3 0/3] hyperv: vmbus: ACPI various corrections Jon Doron
@ 2020-06-18  3:00 ` Jon Doron
  2020-06-23 14:58   ` Igor Mammedov
  2020-06-18  3:00 ` [PATCH v3 2/3] i386: acpi: vmbus: Add _ADR definition Jon Doron
                   ` (3 subsequent siblings)
  4 siblings, 1 reply; 14+ messages in thread
From: Jon Doron @ 2020-06-18  3:00 UTC (permalink / raw)
  To: qemu-devel; +Cc: mail, Jon Doron, rvkagan, imammedo, pbonzini, vkuznets

It seems like Windows does not really require 2 IRQs to have a
functioning VMBus.

Signed-off-by: Jon Doron <arilou@gmail.com>
---
 hw/hyperv/vmbus.c                | 3 +--
 hw/i386/acpi-build.c             | 4 +---
 include/hw/hyperv/vmbus-bridge.h | 3 +--
 3 files changed, 3 insertions(+), 7 deletions(-)

diff --git a/hw/hyperv/vmbus.c b/hw/hyperv/vmbus.c
index f371240176..a8bcb41026 100644
--- a/hw/hyperv/vmbus.c
+++ b/hw/hyperv/vmbus.c
@@ -2741,8 +2741,7 @@ static const VMStateDescription vmstate_vmbus_bridge = {
 };
 
 static Property vmbus_bridge_props[] = {
-    DEFINE_PROP_UINT8("irq0", VMBusBridge, irq0, 7),
-    DEFINE_PROP_UINT8("irq1", VMBusBridge, irq1, 13),
+    DEFINE_PROP_UINT8("irq", VMBusBridge, irq, 7),
     DEFINE_PROP_END_OF_LIST()
 };
 
diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c
index 900f786d08..91af0d2d0d 100644
--- a/hw/i386/acpi-build.c
+++ b/hw/i386/acpi-build.c
@@ -1082,9 +1082,7 @@ static Aml *build_vmbus_device_aml(VMBusBridge *vmbus_bridge)
     aml_append(dev, aml_name_decl("_PS3", aml_int(0x0)));
 
     crs = aml_resource_template();
-    aml_append(crs, aml_irq_no_flags(vmbus_bridge->irq0));
-    /* FIXME: newer HyperV gets by with only one IRQ */
-    aml_append(crs, aml_irq_no_flags(vmbus_bridge->irq1));
+    aml_append(crs, aml_irq_no_flags(vmbus_bridge->irq));
     aml_append(dev, aml_name_decl("_CRS", crs));
 
     return dev;
diff --git a/include/hw/hyperv/vmbus-bridge.h b/include/hw/hyperv/vmbus-bridge.h
index c0a06d832c..33f93de64d 100644
--- a/include/hw/hyperv/vmbus-bridge.h
+++ b/include/hw/hyperv/vmbus-bridge.h
@@ -19,8 +19,7 @@ typedef struct VMBus VMBus;
 typedef struct VMBusBridge {
     SysBusDevice parent_obj;
 
-    uint8_t irq0;
-    uint8_t irq1;
+    uint8_t irq;
 
     VMBus *bus;
 } VMBusBridge;
-- 
2.24.1



^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH v3 2/3] i386: acpi: vmbus: Add _ADR definition
  2020-06-18  3:00 [PATCH v3 0/3] hyperv: vmbus: ACPI various corrections Jon Doron
  2020-06-18  3:00 ` [PATCH v3 1/3] hyperv: vmbus: Remove the 2nd IRQ Jon Doron
@ 2020-06-18  3:00 ` Jon Doron
  2020-06-23 15:06   ` Igor Mammedov
  2020-06-18  3:00 ` [PATCH v3 3/3] acpi: i386: Move VMBus DSDT entry to SB Jon Doron
                   ` (2 subsequent siblings)
  4 siblings, 1 reply; 14+ messages in thread
From: Jon Doron @ 2020-06-18  3:00 UTC (permalink / raw)
  To: qemu-devel; +Cc: mail, Jon Doron, rvkagan, imammedo, pbonzini, vkuznets

It seems like latest HyperV sets _ADR to 0 in the ACPI for the VMBS

Signed-off-by: Jon Doron <arilou@gmail.com>
---
 hw/i386/acpi-build.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c
index 91af0d2d0d..6d9df38e31 100644
--- a/hw/i386/acpi-build.c
+++ b/hw/i386/acpi-build.c
@@ -1061,6 +1061,7 @@ static Aml *build_vmbus_device_aml(VMBusBridge *vmbus_bridge)
 
     dev = aml_device("VMBS");
     aml_append(dev, aml_name_decl("STA", aml_int(0xF)));
+    aml_append(dev, aml_name_decl("_ADR", aml_int(0x0)));
     aml_append(dev, aml_name_decl("_HID", aml_string("VMBus")));
     aml_append(dev, aml_name_decl("_UID", aml_int(0x0)));
     aml_append(dev, aml_name_decl("_DDN", aml_string("VMBUS")));
-- 
2.24.1



^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH v3 3/3] acpi: i386: Move VMBus DSDT entry to SB
  2020-06-18  3:00 [PATCH v3 0/3] hyperv: vmbus: ACPI various corrections Jon Doron
  2020-06-18  3:00 ` [PATCH v3 1/3] hyperv: vmbus: Remove the 2nd IRQ Jon Doron
  2020-06-18  3:00 ` [PATCH v3 2/3] i386: acpi: vmbus: Add _ADR definition Jon Doron
@ 2020-06-18  3:00 ` Jon Doron
  2020-06-23 15:09   ` Igor Mammedov
  2020-06-18  3:23 ` [PATCH v3 0/3] hyperv: vmbus: ACPI various corrections no-reply
  2020-06-23 15:11 ` Igor Mammedov
  4 siblings, 1 reply; 14+ messages in thread
From: Jon Doron @ 2020-06-18  3:00 UTC (permalink / raw)
  To: qemu-devel; +Cc: mail, Jon Doron, rvkagan, imammedo, pbonzini, vkuznets

Signed-off-by: Jon Doron <arilou@gmail.com>
---
 hw/i386/acpi-build.c | 12 +++++++-----
 1 file changed, 7 insertions(+), 5 deletions(-)

diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c
index 6d9df38e31..38be9e5a58 100644
--- a/hw/i386/acpi-build.c
+++ b/hw/i386/acpi-build.c
@@ -1092,7 +1092,6 @@ static Aml *build_vmbus_device_aml(VMBusBridge *vmbus_bridge)
 static void build_isa_devices_aml(Aml *table)
 {
     ISADevice *fdc = pc_find_fdc0();
-    VMBusBridge *vmbus_bridge = vmbus_bridge_find();
     bool ambiguous;
 
     Aml *scope = aml_scope("_SB.PCI0.ISA");
@@ -1113,10 +1112,6 @@ static void build_isa_devices_aml(Aml *table)
         isa_build_aml(ISA_BUS(obj), scope);
     }
 
-    if (vmbus_bridge) {
-        aml_append(scope, build_vmbus_device_aml(vmbus_bridge));
-    }
-
     aml_append(table, scope);
 }
 
@@ -1661,6 +1656,7 @@ build_dsdt(GArray *table_data, BIOSLinker *linker,
     PCIBus *bus = NULL;
     TPMIf *tpm = tpm_find();
     int i;
+    VMBusBridge *vmbus_bridge = vmbus_bridge_find();
 
     dsdt = init_aml_allocator();
 
@@ -1675,6 +1671,9 @@ build_dsdt(GArray *table_data, BIOSLinker *linker,
         aml_append(dev, aml_name_decl("_ADR", aml_int(0)));
         aml_append(dev, aml_name_decl("_UID", aml_int(1)));
         aml_append(sb_scope, dev);
+        if (vmbus_bridge) {
+            aml_append(sb_scope, build_vmbus_device_aml(vmbus_bridge));
+        }
         aml_append(dsdt, sb_scope);
 
         build_hpet_aml(dsdt);
@@ -1692,6 +1691,9 @@ build_dsdt(GArray *table_data, BIOSLinker *linker,
         aml_append(dev, aml_name_decl("_UID", aml_int(1)));
         aml_append(dev, build_q35_osc_method());
         aml_append(sb_scope, dev);
+        if (vmbus_bridge) {
+            aml_append(sb_scope, build_vmbus_device_aml(vmbus_bridge));
+        }
         aml_append(dsdt, sb_scope);
 
         build_hpet_aml(dsdt);
-- 
2.24.1



^ permalink raw reply related	[flat|nested] 14+ messages in thread

* Re: [PATCH v3 0/3] hyperv: vmbus: ACPI various corrections
  2020-06-18  3:00 [PATCH v3 0/3] hyperv: vmbus: ACPI various corrections Jon Doron
                   ` (2 preceding siblings ...)
  2020-06-18  3:00 ` [PATCH v3 3/3] acpi: i386: Move VMBus DSDT entry to SB Jon Doron
@ 2020-06-18  3:23 ` no-reply
  2020-06-23 15:11 ` Igor Mammedov
  4 siblings, 0 replies; 14+ messages in thread
From: no-reply @ 2020-06-18  3:23 UTC (permalink / raw)
  To: arilou; +Cc: mail, arilou, qemu-devel, rvkagan, pbonzini, imammedo, vkuznets

Patchew URL: https://patchew.org/QEMU/20200618030027.759594-1-arilou@gmail.com/



Hi,

This series failed the asan build test. Please find the testing commands and
their output below. If you have Docker installed, you can probably reproduce it
locally.

=== TEST SCRIPT BEGIN ===
#!/bin/bash
export ARCH=x86_64
make docker-image-fedora V=1 NETWORK=1
time make docker-test-debug@fedora TARGET_LIST=x86_64-softmmu J=14 NETWORK=1
=== TEST SCRIPT END ===

  CC      qga/main.o
  CC      qga/commands-posix.o
  CC      qga/channel-posix.o
/usr/bin/ld: /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors_vfork.S.o): warning: common of `__interception::real_vfork' overridden by definition from /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors.cpp.o)
  CC      qga/qapi-generated/qga-qapi-types.o
  CC      qga/qapi-generated/qga-qapi-visit.o
  CC      qga/qapi-generated/qga-qapi-commands.o
---
  GEN     docs/interop/qemu-ga-ref.html
  GEN     docs/interop/qemu-ga-ref.txt
  GEN     docs/interop/qemu-ga-ref.7
/usr/bin/ld: /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors_vfork.S.o): warning: common of `__interception::real_vfork' overridden by definition from /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors.cpp.o)
  LINK    qemu-keymap
  LINK    ivshmem-client
/usr/bin/ld: /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors_vfork.S.o): warning: common of `__interception::real_vfork' overridden by definition from /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors.cpp.o)
  LINK    ivshmem-server
/usr/bin/ld: /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors_vfork.S.o): warning: common of `__interception::real_vfork' overridden by definition from /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors.cpp.o)
  AS      pc-bios/optionrom/linuxboot.o
  AS      pc-bios/optionrom/multiboot.o
/usr/bin/ld: /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors_vfork.S.o): warning: common of `__interception::real_vfork' overridden by definition from /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors.cpp.o)
  LINK    qemu-nbd
  CC      pc-bios/optionrom/linuxboot_dma.o
/usr/bin/ld: /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors_vfork.S.o): warning: common of `__interception::real_vfork' overridden by definition from /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors.cpp.o)
  AS      pc-bios/optionrom/kvmvapic.o
  AS      pc-bios/optionrom/pvh.o
  CC      pc-bios/optionrom/pvh_main.o
---
  BUILD   pc-bios/optionrom/kvmvapic.raw
  SIGN    pc-bios/optionrom/multiboot.bin
  SIGN    pc-bios/optionrom/linuxboot.bin
/usr/bin/ld: /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors_vfork.S.o): warning: common of `__interception::real_vfork' overridden by definition from /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors.cpp.o)
  LINK    qemu-img
  SIGN    pc-bios/optionrom/linuxboot_dma.bin
  SIGN    pc-bios/optionrom/kvmvapic.bin
/usr/bin/ld: /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors_vfork.S.o): warning: common of `__interception::real_vfork' overridden by definition from /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors.cpp.o)
  BUILD   pc-bios/optionrom/pvh.img
  BUILD   pc-bios/optionrom/pvh.raw
  SIGN    pc-bios/optionrom/pvh.bin
---
  LINK    qemu-edid
  LINK    fsdev/virtfs-proxy-helper
  LINK    scsi/qemu-pr-helper
/usr/bin/ld: /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors_vfork.S.o): warning: common of `__interception::real_vfork' overridden by definition from /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors.cpp.o)
  LINK    qemu-bridge-helper
/usr/bin/ld: /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors_vfork.S.o): warning: common of `__interception::real_vfork' overridden by definition from /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors.cpp.o)
/usr/bin/ld: /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors_vfork.S.o): warning: common of `__interception::real_vfork' overridden by definition from /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors.cpp.o)
/usr/bin/ld: /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors_vfork.S.o): warning: common of `__interception::real_vfork' overridden by definition from /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors.cpp.o)
  LINK    virtiofsd
/usr/bin/ld: /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors_vfork.S.o): warning: common of `__interception::real_vfork' overridden by definition from /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors.cpp.o)
  LINK    vhost-user-input
  LINK    qemu-ga
/usr/bin/ld: /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors_vfork.S.o): warning: common of `__interception::real_vfork' overridden by definition from /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors.cpp.o)
/usr/bin/ld: /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors_vfork.S.o): warning: common of `__interception::real_vfork' overridden by definition from /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors.cpp.o)
/usr/bin/ld: /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors_vfork.S.o): warning: common of `__interception::real_vfork' overridden by definition from /usr/lib64/clang/10.0.0/lib/linux/libclang_rt.asan-x86_64.a(asan_interceptors.cpp.o)
  GEN     x86_64-softmmu/hmp-commands.h
  GEN     x86_64-softmmu/hmp-commands-info.h
  GEN     x86_64-softmmu/config-devices.h
---
  CC      x86_64-softmmu/hw/virtio/vhost-user-vsock.o
  CC      x86_64-softmmu/hw/virtio/vhost-vsock-pci.o
  CC      x86_64-softmmu/hw/virtio/vhost-user-vsock-pci.o
/tmp/qemu-test/src/migration/ram.c:919:45: error: implicit conversion from 'unsigned long' to 'double' changes value from 18446744073709551615 to 18446744073709551616 [-Werror,-Wimplicit-int-float-conversion]
            xbzrle_counters.encoding_rate = UINT64_MAX;
                                          ~ ^~~~~~~~~~
/usr/include/stdint.h:130:23: note: expanded from macro 'UINT64_MAX'
---
18446744073709551615UL
^~~~~~~~~~~~~~~~~~~~~~
1 error generated.
make[1]: *** [/tmp/qemu-test/src/rules.mak:69: migration/ram.o] Error 1
make[1]: *** Waiting for unfinished jobs....
/tmp/qemu-test/src/fpu/softfloat.c:3365:13: error: bitwise negation of a boolean expression; did you mean logical negation? [-Werror,-Wbool-operation]
    absZ &= ~ ( ( ( roundBits ^ 0x40 ) == 0 ) & roundNearestEven );
            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
            !
/tmp/qemu-test/src/fpu/softfloat.c:3423:18: error: bitwise negation of a boolean expression; did you mean logical negation? [-Werror,-Wbool-operation]
        absZ0 &= ~ ( ( (uint64_t) ( absZ1<<1 ) == 0 ) & roundNearestEven );
                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                 !
/tmp/qemu-test/src/fpu/softfloat.c:3483:18: error: bitwise negation of a boolean expression; did you mean logical negation? [-Werror,-Wbool-operation]
        absZ0 &= ~(((uint64_t)(absZ1<<1) == 0) & roundNearestEven);
                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                 !
/tmp/qemu-test/src/fpu/softfloat.c:3606:13: error: bitwise negation of a boolean expression; did you mean logical negation? [-Werror,-Wbool-operation]
    zSig &= ~ ( ( ( roundBits ^ 0x40 ) == 0 ) & roundNearestEven );
            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
            !
/tmp/qemu-test/src/fpu/softfloat.c:3760:13: error: bitwise negation of a boolean expression; did you mean logical negation? [-Werror,-Wbool-operation]
    zSig &= ~ ( ( ( roundBits ^ 0x200 ) == 0 ) & roundNearestEven );
            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
            !
/tmp/qemu-test/src/fpu/softfloat.c:3987:21: error: bitwise negation of a boolean expression; did you mean logical negation? [-Werror,-Wbool-operation]
                    ~ ( ( (uint64_t) ( zSig1<<1 ) == 0 ) & roundNearestEven );
                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                    !
/tmp/qemu-test/src/fpu/softfloat.c:4003:22: error: bitwise negation of a boolean expression; did you mean logical negation? [-Werror,-Wbool-operation]
            zSig0 &= ~ ( ( (uint64_t) ( zSig1<<1 ) == 0 ) & roundNearestEven );
                     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                     !
/tmp/qemu-test/src/fpu/softfloat.c:4273:18: error: bitwise negation of a boolean expression; did you mean logical negation? [-Werror,-Wbool-operation]
        zSig1 &= ~ ( ( zSig2 + zSig2 == 0 ) & roundNearestEven );
                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                 !
8 errors generated.
make[1]: *** [/tmp/qemu-test/src/rules.mak:69: fpu/softfloat.o] Error 1
make: *** [Makefile:527: x86_64-softmmu/all] Error 2
Traceback (most recent call last):
  File "./tests/docker/docker.py", line 669, in <module>
    sys.exit(main())
---
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['sudo', '-n', 'docker', 'run', '--label', 'com.qemu.instance.uuid=aa32d68becef428e94caa403f9ce5618', '-u', '1003', '--security-opt', 'seccomp=unconfined', '--rm', '-e', 'TARGET_LIST=x86_64-softmmu', '-e', 'EXTRA_CONFIGURE_OPTS=', '-e', 'V=', '-e', 'J=14', '-e', 'DEBUG=', '-e', 'SHOW_ENV=', '-e', 'CCACHE_DIR=/var/tmp/ccache', '-v', '/home/patchew2/.cache/qemu-docker-ccache:/var/tmp/ccache:z', '-v', '/var/tmp/patchew-tester-tmp-zx2sxjzn/src/docker-src.2020-06-17-23.19.51.23843:/var/tmp/qemu:z,ro', 'qemu:fedora', '/var/tmp/qemu/run', 'test-debug']' returned non-zero exit status 2.
filter=--filter=label=com.qemu.instance.uuid=aa32d68becef428e94caa403f9ce5618
make[1]: *** [docker-run] Error 1
make[1]: Leaving directory `/var/tmp/patchew-tester-tmp-zx2sxjzn/src'
make: *** [docker-run-test-debug@fedora] Error 2

real    3m51.181s
user    0m8.409s


The full log is available at
http://patchew.org/logs/20200618030027.759594-1-arilou@gmail.com/testing.asan/?type=message.
---
Email generated automatically by Patchew [https://patchew.org/].
Please send your feedback to patchew-devel@redhat.com

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH v3 1/3] hyperv: vmbus: Remove the 2nd IRQ
  2020-06-18  3:00 ` [PATCH v3 1/3] hyperv: vmbus: Remove the 2nd IRQ Jon Doron
@ 2020-06-23 14:58   ` Igor Mammedov
  0 siblings, 0 replies; 14+ messages in thread
From: Igor Mammedov @ 2020-06-23 14:58 UTC (permalink / raw)
  To: Jon Doron; +Cc: rvkagan, pbonzini, vkuznets, mail, qemu-devel

On Thu, 18 Jun 2020 06:00:25 +0300
Jon Doron <arilou@gmail.com> wrote:

> It seems like Windows does not really require 2 IRQs to have a
> functioning VMBus.
> 
> Signed-off-by: Jon Doron <arilou@gmail.com>

Reviewed-by: Igor Mammedov <imammedo@redhat.com>

> ---
>  hw/hyperv/vmbus.c                | 3 +--
>  hw/i386/acpi-build.c             | 4 +---
>  include/hw/hyperv/vmbus-bridge.h | 3 +--
>  3 files changed, 3 insertions(+), 7 deletions(-)
> 
> diff --git a/hw/hyperv/vmbus.c b/hw/hyperv/vmbus.c
> index f371240176..a8bcb41026 100644
> --- a/hw/hyperv/vmbus.c
> +++ b/hw/hyperv/vmbus.c
> @@ -2741,8 +2741,7 @@ static const VMStateDescription vmstate_vmbus_bridge = {
>  };
>  
>  static Property vmbus_bridge_props[] = {
> -    DEFINE_PROP_UINT8("irq0", VMBusBridge, irq0, 7),
> -    DEFINE_PROP_UINT8("irq1", VMBusBridge, irq1, 13),
> +    DEFINE_PROP_UINT8("irq", VMBusBridge, irq, 7),
>      DEFINE_PROP_END_OF_LIST()
>  };
>  
> diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c
> index 900f786d08..91af0d2d0d 100644
> --- a/hw/i386/acpi-build.c
> +++ b/hw/i386/acpi-build.c
> @@ -1082,9 +1082,7 @@ static Aml *build_vmbus_device_aml(VMBusBridge *vmbus_bridge)
>      aml_append(dev, aml_name_decl("_PS3", aml_int(0x0)));
>  
>      crs = aml_resource_template();
> -    aml_append(crs, aml_irq_no_flags(vmbus_bridge->irq0));
> -    /* FIXME: newer HyperV gets by with only one IRQ */
> -    aml_append(crs, aml_irq_no_flags(vmbus_bridge->irq1));
> +    aml_append(crs, aml_irq_no_flags(vmbus_bridge->irq));
>      aml_append(dev, aml_name_decl("_CRS", crs));
>  
>      return dev;
> diff --git a/include/hw/hyperv/vmbus-bridge.h b/include/hw/hyperv/vmbus-bridge.h
> index c0a06d832c..33f93de64d 100644
> --- a/include/hw/hyperv/vmbus-bridge.h
> +++ b/include/hw/hyperv/vmbus-bridge.h
> @@ -19,8 +19,7 @@ typedef struct VMBus VMBus;
>  typedef struct VMBusBridge {
>      SysBusDevice parent_obj;
>  
> -    uint8_t irq0;
> -    uint8_t irq1;
> +    uint8_t irq;
>  
>      VMBus *bus;
>  } VMBusBridge;



^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH v3 2/3] i386: acpi: vmbus: Add _ADR definition
  2020-06-18  3:00 ` [PATCH v3 2/3] i386: acpi: vmbus: Add _ADR definition Jon Doron
@ 2020-06-23 15:06   ` Igor Mammedov
  2020-06-25  2:23     ` Jon Doron
  0 siblings, 1 reply; 14+ messages in thread
From: Igor Mammedov @ 2020-06-23 15:06 UTC (permalink / raw)
  To: Jon Doron; +Cc: rvkagan, pbonzini, vkuznets, mail, qemu-devel

On Thu, 18 Jun 2020 06:00:26 +0300
Jon Doron <arilou@gmail.com> wrote:

> It seems like latest HyperV sets _ADR to 0 in the ACPI for the VMBS

that's a hardly a good reason to add this.
To me looks like a pointless addition,
_ADR mostly is used when device resides on a bus with standard ennumeration
algorithm (i.e. PCI, ...).

Value is also wrong  for the bus it's placed currently,
and with the next patch it won't make a sense altogether.

Pls, drop this patch unless Windows refuses to work without it.
 
> 
> Signed-off-by: Jon Doron <arilou@gmail.com>
> ---
>  hw/i386/acpi-build.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c
> index 91af0d2d0d..6d9df38e31 100644
> --- a/hw/i386/acpi-build.c
> +++ b/hw/i386/acpi-build.c
> @@ -1061,6 +1061,7 @@ static Aml *build_vmbus_device_aml(VMBusBridge *vmbus_bridge)
>  
>      dev = aml_device("VMBS");
>      aml_append(dev, aml_name_decl("STA", aml_int(0xF)));
> +    aml_append(dev, aml_name_decl("_ADR", aml_int(0x0)));
>      aml_append(dev, aml_name_decl("_HID", aml_string("VMBus")));
>      aml_append(dev, aml_name_decl("_UID", aml_int(0x0)));
>      aml_append(dev, aml_name_decl("_DDN", aml_string("VMBUS")));



^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH v3 3/3] acpi: i386: Move VMBus DSDT entry to SB
  2020-06-18  3:00 ` [PATCH v3 3/3] acpi: i386: Move VMBus DSDT entry to SB Jon Doron
@ 2020-06-23 15:09   ` Igor Mammedov
  2020-06-25  2:25     ` Jon Doron
  0 siblings, 1 reply; 14+ messages in thread
From: Igor Mammedov @ 2020-06-23 15:09 UTC (permalink / raw)
  To: Jon Doron; +Cc: rvkagan, pbonzini, mail, qemu-devel, vkuznets

On Thu, 18 Jun 2020 06:00:27 +0300
Jon Doron <arilou@gmail.com> wrote:

> Signed-off-by: Jon Doron <arilou@gmail.com>
> ---
>  hw/i386/acpi-build.c | 12 +++++++-----
>  1 file changed, 7 insertions(+), 5 deletions(-)
> 
> diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c
> index 6d9df38e31..38be9e5a58 100644
> --- a/hw/i386/acpi-build.c
> +++ b/hw/i386/acpi-build.c
> @@ -1092,7 +1092,6 @@ static Aml *build_vmbus_device_aml(VMBusBridge *vmbus_bridge)
>  static void build_isa_devices_aml(Aml *table)
>  {
>      ISADevice *fdc = pc_find_fdc0();
> -    VMBusBridge *vmbus_bridge = vmbus_bridge_find();
>      bool ambiguous;
>  
>      Aml *scope = aml_scope("_SB.PCI0.ISA");
> @@ -1113,10 +1112,6 @@ static void build_isa_devices_aml(Aml *table)
>          isa_build_aml(ISA_BUS(obj), scope);
>      }
>  
> -    if (vmbus_bridge) {
> -        aml_append(scope, build_vmbus_device_aml(vmbus_bridge));
> -    }
> -
>      aml_append(table, scope);
>  }
>  
> @@ -1661,6 +1656,7 @@ build_dsdt(GArray *table_data, BIOSLinker *linker,
>      PCIBus *bus = NULL;
>      TPMIf *tpm = tpm_find();
>      int i;
> +    VMBusBridge *vmbus_bridge = vmbus_bridge_find();
>  
>      dsdt = init_aml_allocator();
>  
> @@ -1675,6 +1671,9 @@ build_dsdt(GArray *table_data, BIOSLinker *linker,
>          aml_append(dev, aml_name_decl("_ADR", aml_int(0)));
>          aml_append(dev, aml_name_decl("_UID", aml_int(1)));
>          aml_append(sb_scope, dev);
> +        if (vmbus_bridge) {
> +            aml_append(sb_scope, build_vmbus_device_aml(vmbus_bridge));
> +        }
>          aml_append(dsdt, sb_scope);
>  
>          build_hpet_aml(dsdt);
> @@ -1692,6 +1691,9 @@ build_dsdt(GArray *table_data, BIOSLinker *linker,
>          aml_append(dev, aml_name_decl("_UID", aml_int(1)));
>          aml_append(dev, build_q35_osc_method());
>          aml_append(sb_scope, dev);
> +        if (vmbus_bridge) {
> +            aml_append(sb_scope, build_vmbus_device_aml(vmbus_bridge));
> +        }
>          aml_append(dsdt, sb_scope);
>  
>          build_hpet_aml(dsdt);
why are you duplicating instead of putting one if () block after

if (misc->is_piix4) {
} else {
}

?



^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH v3 0/3] hyperv: vmbus: ACPI various corrections
  2020-06-18  3:00 [PATCH v3 0/3] hyperv: vmbus: ACPI various corrections Jon Doron
                   ` (3 preceding siblings ...)
  2020-06-18  3:23 ` [PATCH v3 0/3] hyperv: vmbus: ACPI various corrections no-reply
@ 2020-06-23 15:11 ` Igor Mammedov
  2020-06-23 15:45   ` Paolo Bonzini
  4 siblings, 1 reply; 14+ messages in thread
From: Igor Mammedov @ 2020-06-23 15:11 UTC (permalink / raw)
  To: Jon Doron; +Cc: rvkagan, pbonzini, mail, qemu-devel, vkuznets

On Thu, 18 Jun 2020 06:00:24 +0300
Jon Doron <arilou@gmail.com> wrote:

> After doing further tests and looking at the latest HyperV ACPI DSDT.
> Do minor fix to our VMBus ACPI entry.
> 
> v3:
> Removed accidental change for the dct submodule head
> 
> v2:
> Renamed irq0 to irq now that there is a single IRQ required
> 
> Jon Doron (3):
>   hyperv: vmbus: Remove the 2nd IRQ
>   i386: acpi: vmbus: Add _ADR definition
>   acpi: i386: Move VMBus DSDT entry to SB
> 
>  hw/hyperv/vmbus.c                |  3 +--
>  hw/i386/acpi-build.c             | 17 +++++++++--------
>  include/hw/hyperv/vmbus-bridge.h |  3 +--
>  3 files changed, 11 insertions(+), 12 deletions(-)
> 

only 1/3 is ready, the rest is not yet ready



^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH v3 0/3] hyperv: vmbus: ACPI various corrections
  2020-06-23 15:11 ` Igor Mammedov
@ 2020-06-23 15:45   ` Paolo Bonzini
  0 siblings, 0 replies; 14+ messages in thread
From: Paolo Bonzini @ 2020-06-23 15:45 UTC (permalink / raw)
  To: Igor Mammedov, Jon Doron; +Cc: rvkagan, vkuznets, mail, qemu-devel

On 23/06/20 17:11, Igor Mammedov wrote:
> On Thu, 18 Jun 2020 06:00:24 +0300
> Jon Doron <arilou@gmail.com> wrote:
> 
>> After doing further tests and looking at the latest HyperV ACPI DSDT.
>> Do minor fix to our VMBus ACPI entry.
>>
>> v3:
>> Removed accidental change for the dct submodule head
>>
>> v2:
>> Renamed irq0 to irq now that there is a single IRQ required
>>
>> Jon Doron (3):
>>   hyperv: vmbus: Remove the 2nd IRQ
>>   i386: acpi: vmbus: Add _ADR definition
>>   acpi: i386: Move VMBus DSDT entry to SB
>>
>>  hw/hyperv/vmbus.c                |  3 +--
>>  hw/i386/acpi-build.c             | 17 +++++++++--------
>>  include/hw/hyperv/vmbus-bridge.h |  3 +--
>>  3 files changed, 11 insertions(+), 12 deletions(-)
>>
> only 1/3 is ready, the rest is not yet ready
> 

Ok, saw this now.  Thanks.

Paolo



^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH v3 2/3] i386: acpi: vmbus: Add _ADR definition
  2020-06-23 15:06   ` Igor Mammedov
@ 2020-06-25  2:23     ` Jon Doron
  0 siblings, 0 replies; 14+ messages in thread
From: Jon Doron @ 2020-06-25  2:23 UTC (permalink / raw)
  To: Igor Mammedov; +Cc: rvkagan, pbonzini, vkuznets, mail, qemu-devel

On 23/06/2020, Igor Mammedov wrote:
>On Thu, 18 Jun 2020 06:00:26 +0300
>Jon Doron <arilou@gmail.com> wrote:
>
>> It seems like latest HyperV sets _ADR to 0 in the ACPI for the VMBS
>
>that's a hardly a good reason to add this.
>To me looks like a pointless addition,
>_ADR mostly is used when device resides on a bus with standard ennumeration
>algorithm (i.e. PCI, ...).
>
>Value is also wrong  for the bus it's placed currently,
>and with the next patch it won't make a sense altogether.
>
>Pls, drop this patch unless Windows refuses to work without it.
>

Windows seems to handle fine without this.

>>
>> Signed-off-by: Jon Doron <arilou@gmail.com>
>> ---
>>  hw/i386/acpi-build.c | 1 +
>>  1 file changed, 1 insertion(+)
>>
>> diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c
>> index 91af0d2d0d..6d9df38e31 100644
>> --- a/hw/i386/acpi-build.c
>> +++ b/hw/i386/acpi-build.c
>> @@ -1061,6 +1061,7 @@ static Aml *build_vmbus_device_aml(VMBusBridge *vmbus_bridge)
>>
>>      dev = aml_device("VMBS");
>>      aml_append(dev, aml_name_decl("STA", aml_int(0xF)));
>> +    aml_append(dev, aml_name_decl("_ADR", aml_int(0x0)));
>>      aml_append(dev, aml_name_decl("_HID", aml_string("VMBus")));
>>      aml_append(dev, aml_name_decl("_UID", aml_int(0x0)));
>>      aml_append(dev, aml_name_decl("_DDN", aml_string("VMBUS")));
>


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH v3 3/3] acpi: i386: Move VMBus DSDT entry to SB
  2020-06-23 15:09   ` Igor Mammedov
@ 2020-06-25  2:25     ` Jon Doron
  2020-06-25  4:46       ` Jon Doron
  2020-06-25 18:39       ` Igor Mammedov
  0 siblings, 2 replies; 14+ messages in thread
From: Jon Doron @ 2020-06-25  2:25 UTC (permalink / raw)
  To: Igor Mammedov; +Cc: rvkagan, pbonzini, mail, qemu-devel, vkuznets

On 23/06/2020, Igor Mammedov wrote:
>On Thu, 18 Jun 2020 06:00:27 +0300
>Jon Doron <arilou@gmail.com> wrote:
>
>> Signed-off-by: Jon Doron <arilou@gmail.com>
>> ---
>>  hw/i386/acpi-build.c | 12 +++++++-----
>>  1 file changed, 7 insertions(+), 5 deletions(-)
>>
>> diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c
>> index 6d9df38e31..38be9e5a58 100644
>> --- a/hw/i386/acpi-build.c
>> +++ b/hw/i386/acpi-build.c
>> @@ -1092,7 +1092,6 @@ static Aml *build_vmbus_device_aml(VMBusBridge *vmbus_bridge)
>>  static void build_isa_devices_aml(Aml *table)
>>  {
>>      ISADevice *fdc = pc_find_fdc0();
>> -    VMBusBridge *vmbus_bridge = vmbus_bridge_find();
>>      bool ambiguous;
>>
>>      Aml *scope = aml_scope("_SB.PCI0.ISA");
>> @@ -1113,10 +1112,6 @@ static void build_isa_devices_aml(Aml *table)
>>          isa_build_aml(ISA_BUS(obj), scope);
>>      }
>>
>> -    if (vmbus_bridge) {
>> -        aml_append(scope, build_vmbus_device_aml(vmbus_bridge));
>> -    }
>> -
>>      aml_append(table, scope);
>>  }
>>
>> @@ -1661,6 +1656,7 @@ build_dsdt(GArray *table_data, BIOSLinker *linker,
>>      PCIBus *bus = NULL;
>>      TPMIf *tpm = tpm_find();
>>      int i;
>> +    VMBusBridge *vmbus_bridge = vmbus_bridge_find();
>>
>>      dsdt = init_aml_allocator();
>>
>> @@ -1675,6 +1671,9 @@ build_dsdt(GArray *table_data, BIOSLinker *linker,
>>          aml_append(dev, aml_name_decl("_ADR", aml_int(0)));
>>          aml_append(dev, aml_name_decl("_UID", aml_int(1)));
>>          aml_append(sb_scope, dev);
>> +        if (vmbus_bridge) {
>> +            aml_append(sb_scope, build_vmbus_device_aml(vmbus_bridge));
>> +        }
>>          aml_append(dsdt, sb_scope);
>>
>>          build_hpet_aml(dsdt);
>> @@ -1692,6 +1691,9 @@ build_dsdt(GArray *table_data, BIOSLinker *linker,
>>          aml_append(dev, aml_name_decl("_UID", aml_int(1)));
>>          aml_append(dev, build_q35_osc_method());
>>          aml_append(sb_scope, dev);
>> +        if (vmbus_bridge) {
>> +            aml_append(sb_scope, build_vmbus_device_aml(vmbus_bridge));
>> +        }
>>          aml_append(dsdt, sb_scope);
>>
>>          build_hpet_aml(dsdt);
>why are you duplicating instead of putting one if () block after
>
>if (misc->is_piix4) {
>} else {
>}
>
>?
>

Well it seems like Windows is very "picky" about where you declare the 
VMBS not sure why if i had moved it to the suggested location as such

if (misc->is_piix4) {
} else {
}

if (vmbus_bridge) {
     aml_append(sb_scope, build_vmbus_device_aml(vmbus_bridge));
     aml_append(dsdt, sb_scope);
}

Windows would BSOD right away with ACPI error.

Same goes for declaring it before PCI0 device...

-- Jon.


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH v3 3/3] acpi: i386: Move VMBus DSDT entry to SB
  2020-06-25  2:25     ` Jon Doron
@ 2020-06-25  4:46       ` Jon Doron
  2020-06-25 18:39       ` Igor Mammedov
  1 sibling, 0 replies; 14+ messages in thread
From: Jon Doron @ 2020-06-25  4:46 UTC (permalink / raw)
  To: Igor Mammedov; +Cc: rvkagan, pbonzini, mail, qemu-devel, vkuznets

On 25/06/2020, Jon Doron wrote:
>On 23/06/2020, Igor Mammedov wrote:
>>On Thu, 18 Jun 2020 06:00:27 +0300
>>Jon Doron <arilou@gmail.com> wrote:
>>
>>>Signed-off-by: Jon Doron <arilou@gmail.com>
>>>---
>>> hw/i386/acpi-build.c | 12 +++++++-----
>>> 1 file changed, 7 insertions(+), 5 deletions(-)
>>>
>>>diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c
>>>index 6d9df38e31..38be9e5a58 100644
>>>--- a/hw/i386/acpi-build.c
>>>+++ b/hw/i386/acpi-build.c
>>>@@ -1092,7 +1092,6 @@ static Aml *build_vmbus_device_aml(VMBusBridge *vmbus_bridge)
>>> static void build_isa_devices_aml(Aml *table)
>>> {
>>>     ISADevice *fdc = pc_find_fdc0();
>>>-    VMBusBridge *vmbus_bridge = vmbus_bridge_find();
>>>     bool ambiguous;
>>>
>>>     Aml *scope = aml_scope("_SB.PCI0.ISA");
>>>@@ -1113,10 +1112,6 @@ static void build_isa_devices_aml(Aml *table)
>>>         isa_build_aml(ISA_BUS(obj), scope);
>>>     }
>>>
>>>-    if (vmbus_bridge) {
>>>-        aml_append(scope, build_vmbus_device_aml(vmbus_bridge));
>>>-    }
>>>-
>>>     aml_append(table, scope);
>>> }
>>>
>>>@@ -1661,6 +1656,7 @@ build_dsdt(GArray *table_data, BIOSLinker *linker,
>>>     PCIBus *bus = NULL;
>>>     TPMIf *tpm = tpm_find();
>>>     int i;
>>>+    VMBusBridge *vmbus_bridge = vmbus_bridge_find();
>>>
>>>     dsdt = init_aml_allocator();
>>>
>>>@@ -1675,6 +1671,9 @@ build_dsdt(GArray *table_data, BIOSLinker *linker,
>>>         aml_append(dev, aml_name_decl("_ADR", aml_int(0)));
>>>         aml_append(dev, aml_name_decl("_UID", aml_int(1)));
>>>         aml_append(sb_scope, dev);
>>>+        if (vmbus_bridge) {
>>>+            aml_append(sb_scope, build_vmbus_device_aml(vmbus_bridge));
>>>+        }
>>>         aml_append(dsdt, sb_scope);
>>>
>>>         build_hpet_aml(dsdt);
>>>@@ -1692,6 +1691,9 @@ build_dsdt(GArray *table_data, BIOSLinker *linker,
>>>         aml_append(dev, aml_name_decl("_UID", aml_int(1)));
>>>         aml_append(dev, build_q35_osc_method());
>>>         aml_append(sb_scope, dev);
>>>+        if (vmbus_bridge) {
>>>+            aml_append(sb_scope, build_vmbus_device_aml(vmbus_bridge));
>>>+        }
>>>         aml_append(dsdt, sb_scope);
>>>
>>>         build_hpet_aml(dsdt);
>>why are you duplicating instead of putting one if () block after
>>
>>if (misc->is_piix4) {
>>} else {
>>}
>>
>>?
>>
>
>Well it seems like Windows is very "picky" about where you declare the 
>VMBS not sure why if i had moved it to the suggested location as such
>
>if (misc->is_piix4) {
>} else {
>}
>
>if (vmbus_bridge) {
>    aml_append(sb_scope, build_vmbus_device_aml(vmbus_bridge));
>    aml_append(dsdt, sb_scope);
>}
>
>Windows would BSOD right away with ACPI error.
>
>Same goes for declaring it before PCI0 device...
>
>-- Jon.

Never mind did a silly mistake ill send a new set shortly


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH v3 3/3] acpi: i386: Move VMBus DSDT entry to SB
  2020-06-25  2:25     ` Jon Doron
  2020-06-25  4:46       ` Jon Doron
@ 2020-06-25 18:39       ` Igor Mammedov
  1 sibling, 0 replies; 14+ messages in thread
From: Igor Mammedov @ 2020-06-25 18:39 UTC (permalink / raw)
  To: Jon Doron; +Cc: rvkagan, pbonzini, mail, qemu-devel, vkuznets

On Thu, 25 Jun 2020 05:25:26 +0300
Jon Doron <arilou@gmail.com> wrote:

> On 23/06/2020, Igor Mammedov wrote:
> >On Thu, 18 Jun 2020 06:00:27 +0300
> >Jon Doron <arilou@gmail.com> wrote:
> >  
> >> Signed-off-by: Jon Doron <arilou@gmail.com>
> >> ---
> >>  hw/i386/acpi-build.c | 12 +++++++-----
> >>  1 file changed, 7 insertions(+), 5 deletions(-)
> >>
> >> diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c
> >> index 6d9df38e31..38be9e5a58 100644
> >> --- a/hw/i386/acpi-build.c
> >> +++ b/hw/i386/acpi-build.c
> >> @@ -1092,7 +1092,6 @@ static Aml *build_vmbus_device_aml(VMBusBridge *vmbus_bridge)
> >>  static void build_isa_devices_aml(Aml *table)
> >>  {
> >>      ISADevice *fdc = pc_find_fdc0();
> >> -    VMBusBridge *vmbus_bridge = vmbus_bridge_find();
> >>      bool ambiguous;
> >>
> >>      Aml *scope = aml_scope("_SB.PCI0.ISA");
> >> @@ -1113,10 +1112,6 @@ static void build_isa_devices_aml(Aml *table)
> >>          isa_build_aml(ISA_BUS(obj), scope);
> >>      }
> >>
> >> -    if (vmbus_bridge) {
> >> -        aml_append(scope, build_vmbus_device_aml(vmbus_bridge));
> >> -    }
> >> -
> >>      aml_append(table, scope);
> >>  }
> >>
> >> @@ -1661,6 +1656,7 @@ build_dsdt(GArray *table_data, BIOSLinker *linker,
> >>      PCIBus *bus = NULL;
> >>      TPMIf *tpm = tpm_find();
> >>      int i;
> >> +    VMBusBridge *vmbus_bridge = vmbus_bridge_find();
> >>
> >>      dsdt = init_aml_allocator();
> >>
> >> @@ -1675,6 +1671,9 @@ build_dsdt(GArray *table_data, BIOSLinker *linker,
> >>          aml_append(dev, aml_name_decl("_ADR", aml_int(0)));
> >>          aml_append(dev, aml_name_decl("_UID", aml_int(1)));
> >>          aml_append(sb_scope, dev);
> >> +        if (vmbus_bridge) {
> >> +            aml_append(sb_scope, build_vmbus_device_aml(vmbus_bridge));
> >> +        }
> >>          aml_append(dsdt, sb_scope);
> >>
> >>          build_hpet_aml(dsdt);
> >> @@ -1692,6 +1691,9 @@ build_dsdt(GArray *table_data, BIOSLinker *linker,
> >>          aml_append(dev, aml_name_decl("_UID", aml_int(1)));
> >>          aml_append(dev, build_q35_osc_method());
> >>          aml_append(sb_scope, dev);
> >> +        if (vmbus_bridge) {
> >> +            aml_append(sb_scope, build_vmbus_device_aml(vmbus_bridge));
> >> +        }
> >>          aml_append(dsdt, sb_scope);
> >>
> >>          build_hpet_aml(dsdt);  
> >why are you duplicating instead of putting one if () block after
> >
> >if (misc->is_piix4) {
> >} else {
> >}
> >
> >?
> >  
> 
> Well it seems like Windows is very "picky" about where you declare the 
> VMBS not sure why if i had moved it to the suggested location as such
> 
> if (misc->is_piix4) {
> } else {
> }
> 
> if (vmbus_bridge) {
>      aml_append(sb_scope, build_vmbus_device_aml(vmbus_bridge));
>      aml_append(dsdt, sb_scope);
> }
> 
> Windows would BSOD right away with ACPI error.
> 
> Same goes for declaring it before PCI0 device...

just FYI, Windows has ACPI debugger, so if you attach wingdb at early boot
you can set acpi breakpoint and after that enable all kind of debug info (see MSDN)
that usually say why exactly it doesn't like something in AML.

It used to require checked build and it is tricky to enable but once
you figured how, it works like charm.

> 
> -- Jon.
> 



^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2020-06-25 18:43 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-06-18  3:00 [PATCH v3 0/3] hyperv: vmbus: ACPI various corrections Jon Doron
2020-06-18  3:00 ` [PATCH v3 1/3] hyperv: vmbus: Remove the 2nd IRQ Jon Doron
2020-06-23 14:58   ` Igor Mammedov
2020-06-18  3:00 ` [PATCH v3 2/3] i386: acpi: vmbus: Add _ADR definition Jon Doron
2020-06-23 15:06   ` Igor Mammedov
2020-06-25  2:23     ` Jon Doron
2020-06-18  3:00 ` [PATCH v3 3/3] acpi: i386: Move VMBus DSDT entry to SB Jon Doron
2020-06-23 15:09   ` Igor Mammedov
2020-06-25  2:25     ` Jon Doron
2020-06-25  4:46       ` Jon Doron
2020-06-25 18:39       ` Igor Mammedov
2020-06-18  3:23 ` [PATCH v3 0/3] hyperv: vmbus: ACPI various corrections no-reply
2020-06-23 15:11 ` Igor Mammedov
2020-06-23 15:45   ` Paolo Bonzini

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).