[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[qemu-s390x] [PATCH v3 2/6] spapr: support memory unplug for qtest
From: |
David Hildenbrand |
Subject: |
[qemu-s390x] [PATCH v3 2/6] spapr: support memory unplug for qtest |
Date: |
Mon, 18 Feb 2019 10:21:58 +0100 |
Fake availability of OV5_HP_EVT, so we can test memory unplug in qtest.
Reviewed-by: Michael S. Tsirkin <address@hidden>
Reviewed-by: Greg Kurz <address@hidden>
Acked-by: David Gibson <address@hidden>
Signed-off-by: David Hildenbrand <address@hidden>
---
hw/ppc/spapr_ovec.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/hw/ppc/spapr_ovec.c b/hw/ppc/spapr_ovec.c
index 318bf33de4..12510b236a 100644
--- a/hw/ppc/spapr_ovec.c
+++ b/hw/ppc/spapr_ovec.c
@@ -16,6 +16,7 @@
#include "qemu/bitmap.h"
#include "exec/address-spaces.h"
#include "qemu/error-report.h"
+#include "sysemu/qtest.h"
#include "trace.h"
#include <libfdt.h>
@@ -131,6 +132,11 @@ bool spapr_ovec_test(sPAPROptionVector *ov, long bitnr)
g_assert(ov);
g_assert(bitnr < OV_MAXBITS);
+ /* support memory unplug for qtest */
+ if (qtest_enabled() && bitnr == OV5_HP_EVT) {
+ return true;
+ }
+
return test_bit(bitnr, ov->bitmap) ? true : false;
}
--
2.17.2
- [qemu-s390x] [PATCH v3 0/6] tests: Add device unplug tests, David Hildenbrand, 2019/02/18
- [qemu-s390x] [PATCH v3 1/6] cpus: Properly release the iothread lock when killing a dummy VCPU, David Hildenbrand, 2019/02/18
- [qemu-s390x] [PATCH v3 2/6] spapr: support memory unplug for qtest,
David Hildenbrand <=
- [qemu-s390x] [PATCH v3 6/6] tests/device-plug: Add memory unplug request test for spapr, David Hildenbrand, 2019/02/18
- [qemu-s390x] [PATCH v3 4/6] tests/device-plug: Add CCW unplug test for s390x, David Hildenbrand, 2019/02/18
- [qemu-s390x] [PATCH v3 5/6] tests/device-plug: Add CPU core unplug request test for spapr, David Hildenbrand, 2019/02/18
- [qemu-s390x] [PATCH v3 3/6] tests/device-plug: Add a simple PCI unplug request test, David Hildenbrand, 2019/02/18
- Re: [qemu-s390x] [PATCH v3 0/6] tests: Add device unplug tests, David Gibson, 2019/02/18