* [kvm-unit-tests PULL 00/12] s390x and Travis CI updates
@ 2019-11-18 10:07 David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 01/12] s390x: Use loop to save and restore fprs David Hildenbrand
` (13 more replies)
0 siblings, 14 replies; 18+ messages in thread
From: David Hildenbrand @ 2019-11-18 10:07 UTC (permalink / raw)
To: kvm
Cc: Paolo Bonzini, Radim Krčmář,
Thomas Huth, Christian Borntraeger, Cornelia Huck, Janosch Frank,
David Hildenbrand
Hi Paolo,
The following changes since commit af8dfe97b47d03876041506e8b38f718914aeea4:
x86/unittests.cfg: Increase the timeout of the sieve test to 180s (2019-11-15 15:56:19 +0100)
are available in the Git repository at:
https://github.com/davidhildenbrand/kvm-unit-tests.git tags/s390x-2019-11-18
for you to fetch changes up to c71d8a9fab524269785d688eb0db7f6391b5510c:
travis.yml: Expect that at least one test succeeds (2019-11-18 10:47:27 +0100)
----------------------------------------------------------------
Cleanups and bugfixes (especially to make the tests run natively under
LPAR). Travis CI improvements (e.g., x86 support, KVM support on x86_64).
----------------------------------------------------------------
Claudio Imbrenda (3):
s390x: remove redundant defines
s390x: improve error reporting for interrupts
s390x: sclp: expose ram_size and max_ram_size
Janosch Frank (4):
s390x: Use loop to save and restore fprs
s390x: Fix initial cr0 load comments
s390x: Add CR save area
s390x: Load reset psw on diag308 reset
Thomas Huth (5):
travis.yml: Re-arrange the test matrix
travis.yml: Install only the required packages for each entry in the
matrix
travis.yml: Test with KVM instead of TCG (on x86)
travis.yml: Test the i386 build, too
travis.yml: Expect that at least one test succeeds
.travis.yml | 156 ++++++++++++++++++++++++++-------------
lib/s390x/asm-offsets.c | 3 +-
lib/s390x/asm/arch_def.h | 6 +-
lib/s390x/interrupt.c | 8 +-
lib/s390x/sclp.c | 10 +++
lib/s390x/sclp.h | 4 +-
lib/s390x/smp.c | 2 +-
s390x/cstart64.S | 76 ++++++++-----------
8 files changed, 158 insertions(+), 107 deletions(-)
--
2.21.0
^ permalink raw reply [flat|nested] 18+ messages in thread
* [kvm-unit-tests PULL 01/12] s390x: Use loop to save and restore fprs
2019-11-18 10:07 [kvm-unit-tests PULL 00/12] s390x and Travis CI updates David Hildenbrand
@ 2019-11-18 10:07 ` David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 02/12] s390x: remove redundant defines David Hildenbrand
` (12 subsequent siblings)
13 siblings, 0 replies; 18+ messages in thread
From: David Hildenbrand @ 2019-11-18 10:07 UTC (permalink / raw)
To: kvm
Cc: Paolo Bonzini, Radim Krčmář,
Thomas Huth, Christian Borntraeger, Cornelia Huck, Janosch Frank,
David Hildenbrand
From: Janosch Frank <frankja@linux.ibm.com>
Let's save some lines in the assembly by using a loop to save and
restore the fprs.
Tested-by: Thomas Huth <thuth@redhat.com>
Signed-off-by: Janosch Frank <frankja@linux.ibm.com>
Message-Id: <20191104085533.2892-1-frankja@linux.ibm.com>
Signed-off-by: David Hildenbrand <david@redhat.com>
---
s390x/cstart64.S | 38 ++++++--------------------------------
1 file changed, 6 insertions(+), 32 deletions(-)
diff --git a/s390x/cstart64.S b/s390x/cstart64.S
index 5dc1577..8e2b21e 100644
--- a/s390x/cstart64.S
+++ b/s390x/cstart64.S
@@ -99,44 +99,18 @@ memsetxc:
lctlg %c0, %c0, 0(%r1)
/* save fprs 0-15 + fpc */
la %r1, GEN_LC_SW_INT_FPRS
- std %f0, 0(%r1)
- std %f1, 8(%r1)
- std %f2, 16(%r1)
- std %f3, 24(%r1)
- std %f4, 32(%r1)
- std %f5, 40(%r1)
- std %f6, 48(%r1)
- std %f7, 56(%r1)
- std %f8, 64(%r1)
- std %f9, 72(%r1)
- std %f10, 80(%r1)
- std %f11, 88(%r1)
- std %f12, 96(%r1)
- std %f13, 104(%r1)
- std %f14, 112(%r1)
- std %f15, 120(%r1)
+ .irp i, 0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15
+ std \i, \i * 8(%r1)
+ .endr
stfpc GEN_LC_SW_INT_FPC
.endm
.macro RESTORE_REGS
/* restore fprs 0-15 + fpc */
la %r1, GEN_LC_SW_INT_FPRS
- ld %f0, 0(%r1)
- ld %f1, 8(%r1)
- ld %f2, 16(%r1)
- ld %f3, 24(%r1)
- ld %f4, 32(%r1)
- ld %f5, 40(%r1)
- ld %f6, 48(%r1)
- ld %f7, 56(%r1)
- ld %f8, 64(%r1)
- ld %f9, 72(%r1)
- ld %f10, 80(%r1)
- ld %f11, 88(%r1)
- ld %f12, 96(%r1)
- ld %f13, 104(%r1)
- ld %f14, 112(%r1)
- ld %f15, 120(%r1)
+ .irp i, 0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15
+ ld \i, \i * 8(%r1)
+ .endr
lfpc GEN_LC_SW_INT_FPC
/* restore cr0 */
lctlg %c0, %c0, GEN_LC_SW_INT_CR0
--
2.21.0
^ permalink raw reply related [flat|nested] 18+ messages in thread
* [kvm-unit-tests PULL 02/12] s390x: remove redundant defines
2019-11-18 10:07 [kvm-unit-tests PULL 00/12] s390x and Travis CI updates David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 01/12] s390x: Use loop to save and restore fprs David Hildenbrand
@ 2019-11-18 10:07 ` David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 03/12] s390x: improve error reporting for interrupts David Hildenbrand
` (11 subsequent siblings)
13 siblings, 0 replies; 18+ messages in thread
From: David Hildenbrand @ 2019-11-18 10:07 UTC (permalink / raw)
To: kvm
Cc: Paolo Bonzini, Radim Krčmář,
Thomas Huth, Christian Borntraeger, Cornelia Huck, Janosch Frank,
Claudio Imbrenda, David Hildenbrand
From: Claudio Imbrenda <imbrenda@linux.ibm.com>
Signed-off-by: Claudio Imbrenda <imbrenda@linux.ibm.com>
Reviewed-by: Christian Borntraeger <borntraeger@de.ibm.com>
Reviewed-by: Janosch Frank <frankja@linux.ibm.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Reviewed-by: David Hildenbrand <david@redhat.com>
Message-Id: <1572023194-14370-2-git-send-email-imbrenda@linux.ibm.com>
Signed-off-by: David Hildenbrand <david@redhat.com>
---
lib/s390x/sclp.h | 2 --
1 file changed, 2 deletions(-)
diff --git a/lib/s390x/sclp.h b/lib/s390x/sclp.h
index 4e69845..f00c3df 100644
--- a/lib/s390x/sclp.h
+++ b/lib/s390x/sclp.h
@@ -27,8 +27,6 @@
#define SCLP_ASSIGN_STORAGE 0x000D0001
#define SCLP_CMD_READ_EVENT_DATA 0x00770005
#define SCLP_CMD_WRITE_EVENT_DATA 0x00760005
-#define SCLP_CMD_READ_EVENT_DATA 0x00770005
-#define SCLP_CMD_WRITE_EVENT_DATA 0x00760005
#define SCLP_CMD_WRITE_EVENT_MASK 0x00780005
/* SCLP Memory hotplug codes */
--
2.21.0
^ permalink raw reply related [flat|nested] 18+ messages in thread
* [kvm-unit-tests PULL 03/12] s390x: improve error reporting for interrupts
2019-11-18 10:07 [kvm-unit-tests PULL 00/12] s390x and Travis CI updates David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 01/12] s390x: Use loop to save and restore fprs David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 02/12] s390x: remove redundant defines David Hildenbrand
@ 2019-11-18 10:07 ` David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 04/12] s390x: sclp: expose ram_size and max_ram_size David Hildenbrand
` (10 subsequent siblings)
13 siblings, 0 replies; 18+ messages in thread
From: David Hildenbrand @ 2019-11-18 10:07 UTC (permalink / raw)
To: kvm
Cc: Paolo Bonzini, Radim Krčmář,
Thomas Huth, Christian Borntraeger, Cornelia Huck, Janosch Frank,
Claudio Imbrenda, David Hildenbrand
From: Claudio Imbrenda <imbrenda@linux.ibm.com>
Improve error reporting for unexpected external interrupts to also
print the received external interrupt code.
Signed-off-by: Claudio Imbrenda <imbrenda@linux.ibm.com>
Reviewed-by: Janosch Frank <frankja@linux.ibm.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Reviewed-by: David Hildenbrand <david@redhat.com>
Acked-by: Christian Borntraeger <borntraeger@de.ibm.com>
Message-Id: <1572023194-14370-3-git-send-email-imbrenda@linux.ibm.com>
Signed-off-by: David Hildenbrand <david@redhat.com>
---
lib/s390x/interrupt.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/lib/s390x/interrupt.c b/lib/s390x/interrupt.c
index 5cade23..1636207 100644
--- a/lib/s390x/interrupt.c
+++ b/lib/s390x/interrupt.c
@@ -118,8 +118,8 @@ void handle_ext_int(void)
{
if (!ext_int_expected &&
lc->ext_int_code != EXT_IRQ_SERVICE_SIG) {
- report_abort("Unexpected external call interrupt: at %#lx",
- lc->ext_old_psw.addr);
+ report_abort("Unexpected external call interrupt (code %#x): at %#lx",
+ lc->ext_int_code, lc->ext_old_psw.addr);
return;
}
--
2.21.0
^ permalink raw reply related [flat|nested] 18+ messages in thread
* [kvm-unit-tests PULL 04/12] s390x: sclp: expose ram_size and max_ram_size
2019-11-18 10:07 [kvm-unit-tests PULL 00/12] s390x and Travis CI updates David Hildenbrand
` (2 preceding siblings ...)
2019-11-18 10:07 ` [kvm-unit-tests PULL 03/12] s390x: improve error reporting for interrupts David Hildenbrand
@ 2019-11-18 10:07 ` David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 05/12] s390x: Fix initial cr0 load comments David Hildenbrand
` (9 subsequent siblings)
13 siblings, 0 replies; 18+ messages in thread
From: David Hildenbrand @ 2019-11-18 10:07 UTC (permalink / raw)
To: kvm
Cc: Paolo Bonzini, Radim Krčmář,
Thomas Huth, Christian Borntraeger, Cornelia Huck, Janosch Frank,
Claudio Imbrenda, David Hildenbrand
From: Claudio Imbrenda <imbrenda@linux.ibm.com>
Expose ram_size and max_ram_size through accessor functions.
We only use get_ram_size in an upcoming patch, but having an accessor
for the other one does not hurt.
Signed-off-by: Claudio Imbrenda <imbrenda@linux.ibm.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Reviewed-by: David Hildenbrand <david@redhat.com>
Acked-by: Christian Borntraeger <borntraeger@de.ibm.com>
Reviewed-by: Janosch Frank <frankja@linux.ibm.com>
Message-Id: <1572023194-14370-4-git-send-email-imbrenda@linux.ibm.com>
Signed-off-by: David Hildenbrand <david@redhat.com>
---
lib/s390x/sclp.c | 10 ++++++++++
lib/s390x/sclp.h | 2 ++
2 files changed, 12 insertions(+)
diff --git a/lib/s390x/sclp.c b/lib/s390x/sclp.c
index 56fca0c..7798f04 100644
--- a/lib/s390x/sclp.c
+++ b/lib/s390x/sclp.c
@@ -167,3 +167,13 @@ void sclp_memory_setup(void)
mem_init(ram_size);
}
+
+uint64_t get_ram_size(void)
+{
+ return ram_size;
+}
+
+uint64_t get_max_ram_size(void)
+{
+ return max_ram_size;
+}
diff --git a/lib/s390x/sclp.h b/lib/s390x/sclp.h
index f00c3df..6d40fb7 100644
--- a/lib/s390x/sclp.h
+++ b/lib/s390x/sclp.h
@@ -272,5 +272,7 @@ void sclp_console_setup(void);
void sclp_print(const char *str);
int sclp_service_call(unsigned int command, void *sccb);
void sclp_memory_setup(void);
+uint64_t get_ram_size(void);
+uint64_t get_max_ram_size(void);
#endif /* SCLP_H */
--
2.21.0
^ permalink raw reply related [flat|nested] 18+ messages in thread
* [kvm-unit-tests PULL 05/12] s390x: Fix initial cr0 load comments
2019-11-18 10:07 [kvm-unit-tests PULL 00/12] s390x and Travis CI updates David Hildenbrand
` (3 preceding siblings ...)
2019-11-18 10:07 ` [kvm-unit-tests PULL 04/12] s390x: sclp: expose ram_size and max_ram_size David Hildenbrand
@ 2019-11-18 10:07 ` David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 06/12] s390x: Add CR save area David Hildenbrand
` (8 subsequent siblings)
13 siblings, 0 replies; 18+ messages in thread
From: David Hildenbrand @ 2019-11-18 10:07 UTC (permalink / raw)
To: kvm
Cc: Paolo Bonzini, Radim Krčmář,
Thomas Huth, Christian Borntraeger, Cornelia Huck, Janosch Frank,
David Hildenbrand
From: Janosch Frank <frankja@linux.ibm.com>
We need to load cr0 to have access to all fprs during save and restore
of fprs. Saving conditionally on basis of the CR0 AFP bit would be a
pain.
Reviewed-by: Thomas Huth <thuth@redhat.com>
Signed-off-by: Janosch Frank <frankja@linux.ibm.com>
Message-Id: <20191111153345.22505-2-frankja@linux.ibm.com>
Signed-off-by: David Hildenbrand <david@redhat.com>
---
s390x/cstart64.S | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/s390x/cstart64.S b/s390x/cstart64.S
index 8e2b21e..043e34a 100644
--- a/s390x/cstart64.S
+++ b/s390x/cstart64.S
@@ -94,7 +94,7 @@ memsetxc:
stmg %r0, %r15, GEN_LC_SW_INT_GRS
/* save cr0 */
stctg %c0, %c0, GEN_LC_SW_INT_CR0
- /* load initial cr0 again */
+ /* load a cr0 that has the AFP control bit which enables all FPRs */
larl %r1, initial_cr0
lctlg %c0, %c0, 0(%r1)
/* save fprs 0-15 + fpc */
@@ -139,7 +139,7 @@ diag308_load_reset:
xgr %r2, %r2
br %r14
/* Success path */
- /* We lost cr0 due to the reset */
+ /* load a cr0 that has the AFP control bit which enables all FPRs */
0: larl %r1, initial_cr0
lctlg %c0, %c0, 0(%r1)
RESTORE_REGS
--
2.21.0
^ permalink raw reply related [flat|nested] 18+ messages in thread
* [kvm-unit-tests PULL 06/12] s390x: Add CR save area
2019-11-18 10:07 [kvm-unit-tests PULL 00/12] s390x and Travis CI updates David Hildenbrand
` (4 preceding siblings ...)
2019-11-18 10:07 ` [kvm-unit-tests PULL 05/12] s390x: Fix initial cr0 load comments David Hildenbrand
@ 2019-11-18 10:07 ` David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 07/12] s390x: Load reset psw on diag308 reset David Hildenbrand
` (7 subsequent siblings)
13 siblings, 0 replies; 18+ messages in thread
From: David Hildenbrand @ 2019-11-18 10:07 UTC (permalink / raw)
To: kvm
Cc: Paolo Bonzini, Radim Krčmář,
Thomas Huth, Christian Borntraeger, Cornelia Huck, Janosch Frank,
David Hildenbrand
From: Janosch Frank <frankja@linux.ibm.com>
If we run with DAT enabled and do a reset, we need to save the CRs to
backup our ASCEs on a diag308 for example.
Reviewed-by: Thomas Huth <thuth@redhat.com>
Signed-off-by: Janosch Frank <frankja@linux.ibm.com>
Message-Id: <20191111153345.22505-3-frankja@linux.ibm.com>
Signed-off-by: David Hildenbrand <david@redhat.com>
---
lib/s390x/asm-offsets.c | 2 +-
lib/s390x/asm/arch_def.h | 4 ++--
lib/s390x/interrupt.c | 4 ++--
lib/s390x/smp.c | 2 +-
s390x/cstart64.S | 10 +++++-----
5 files changed, 11 insertions(+), 11 deletions(-)
diff --git a/lib/s390x/asm-offsets.c b/lib/s390x/asm-offsets.c
index 6e2d259..4b213f8 100644
--- a/lib/s390x/asm-offsets.c
+++ b/lib/s390x/asm-offsets.c
@@ -57,7 +57,7 @@ int main(void)
OFFSET(GEN_LC_SW_INT_GRS, lowcore, sw_int_grs);
OFFSET(GEN_LC_SW_INT_FPRS, lowcore, sw_int_fprs);
OFFSET(GEN_LC_SW_INT_FPC, lowcore, sw_int_fpc);
- OFFSET(GEN_LC_SW_INT_CR0, lowcore, sw_int_cr0);
+ OFFSET(GEN_LC_SW_INT_CRS, lowcore, sw_int_crs);
OFFSET(GEN_LC_MCCK_EXT_SA_ADDR, lowcore, mcck_ext_sa_addr);
OFFSET(GEN_LC_FPRS_SA, lowcore, fprs_sa);
OFFSET(GEN_LC_GRS_SA, lowcore, grs_sa);
diff --git a/lib/s390x/asm/arch_def.h b/lib/s390x/asm/arch_def.h
index 96cca2e..07d4e5e 100644
--- a/lib/s390x/asm/arch_def.h
+++ b/lib/s390x/asm/arch_def.h
@@ -78,8 +78,8 @@ struct lowcore {
uint64_t sw_int_fprs[16]; /* 0x0280 */
uint32_t sw_int_fpc; /* 0x0300 */
uint8_t pad_0x0304[0x0308 - 0x0304]; /* 0x0304 */
- uint64_t sw_int_cr0; /* 0x0308 */
- uint8_t pad_0x0310[0x11b0 - 0x0310]; /* 0x0310 */
+ uint64_t sw_int_crs[16]; /* 0x0308 */
+ uint8_t pad_0x0310[0x11b0 - 0x0388]; /* 0x0388 */
uint64_t mcck_ext_sa_addr; /* 0x11b0 */
uint8_t pad_0x11b8[0x1200 - 0x11b8]; /* 0x11b8 */
uint64_t fprs_sa[16]; /* 0x1200 */
diff --git a/lib/s390x/interrupt.c b/lib/s390x/interrupt.c
index 1636207..3e07867 100644
--- a/lib/s390x/interrupt.c
+++ b/lib/s390x/interrupt.c
@@ -124,13 +124,13 @@ void handle_ext_int(void)
}
if (lc->ext_int_code == EXT_IRQ_SERVICE_SIG) {
- lc->sw_int_cr0 &= ~(1UL << 9);
+ lc->sw_int_crs[0] &= ~(1UL << 9);
sclp_handle_ext();
} else {
ext_int_expected = false;
}
- if (!(lc->sw_int_cr0 & CR0_EXTM_MASK))
+ if (!(lc->sw_int_crs[0] & CR0_EXTM_MASK))
lc->ext_old_psw.mask &= ~PSW_MASK_EXT;
}
diff --git a/lib/s390x/smp.c b/lib/s390x/smp.c
index 7602886..f57f420 100644
--- a/lib/s390x/smp.c
+++ b/lib/s390x/smp.c
@@ -189,7 +189,7 @@ int smp_cpu_setup(uint16_t addr, struct psw psw)
cpu->lowcore->sw_int_grs[15] = (uint64_t)cpu->stack + (PAGE_SIZE * 4);
lc->restart_new_psw.mask = 0x0000000180000000UL;
lc->restart_new_psw.addr = (uint64_t)smp_cpu_setup_state;
- lc->sw_int_cr0 = 0x0000000000040000UL;
+ lc->sw_int_crs[0] = 0x0000000000040000UL;
/* Start processing */
rc = sigp_retry(cpu->addr, SIGP_RESTART, 0, NULL);
diff --git a/s390x/cstart64.S b/s390x/cstart64.S
index 043e34a..4be20fc 100644
--- a/s390x/cstart64.S
+++ b/s390x/cstart64.S
@@ -92,8 +92,8 @@ memsetxc:
.macro SAVE_REGS
/* save grs 0-15 */
stmg %r0, %r15, GEN_LC_SW_INT_GRS
- /* save cr0 */
- stctg %c0, %c0, GEN_LC_SW_INT_CR0
+ /* save crs 0-15 */
+ stctg %c0, %c15, GEN_LC_SW_INT_CRS
/* load a cr0 that has the AFP control bit which enables all FPRs */
larl %r1, initial_cr0
lctlg %c0, %c0, 0(%r1)
@@ -112,8 +112,8 @@ memsetxc:
ld \i, \i * 8(%r1)
.endr
lfpc GEN_LC_SW_INT_FPC
- /* restore cr0 */
- lctlg %c0, %c0, GEN_LC_SW_INT_CR0
+ /* restore crs 0-15 */
+ lctlg %c0, %c15, GEN_LC_SW_INT_CRS
/* restore grs 0-15 */
lmg %r0, %r15, GEN_LC_SW_INT_GRS
.endm
@@ -150,7 +150,7 @@ diag308_load_reset:
smp_cpu_setup_state:
xgr %r1, %r1
lmg %r0, %r15, GEN_LC_SW_INT_GRS
- lctlg %c0, %c0, GEN_LC_SW_INT_CR0
+ lctlg %c0, %c0, GEN_LC_SW_INT_CRS
br %r14
pgm_int:
--
2.21.0
^ permalink raw reply related [flat|nested] 18+ messages in thread
* [kvm-unit-tests PULL 07/12] s390x: Load reset psw on diag308 reset
2019-11-18 10:07 [kvm-unit-tests PULL 00/12] s390x and Travis CI updates David Hildenbrand
` (5 preceding siblings ...)
2019-11-18 10:07 ` [kvm-unit-tests PULL 06/12] s390x: Add CR save area David Hildenbrand
@ 2019-11-18 10:07 ` David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 08/12] travis.yml: Re-arrange the test matrix David Hildenbrand
` (6 subsequent siblings)
13 siblings, 0 replies; 18+ messages in thread
From: David Hildenbrand @ 2019-11-18 10:07 UTC (permalink / raw)
To: kvm
Cc: Paolo Bonzini, Radim Krčmář,
Thomas Huth, Christian Borntraeger, Cornelia Huck, Janosch Frank,
David Hildenbrand
From: Janosch Frank <frankja@linux.ibm.com>
On a diag308 subcode 0 CRs will be reset, so we need a PSW mask
without DAT. Also we need to set the short psw indication to be
compliant with the architecture.
Let's therefore define a reset PSW mask with 64 bit addressing and
short PSW indication that is compliant with architecture and use it.
Signed-off-by: Janosch Frank <frankja@linux.ibm.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Message-Id: <20191113112403.7664-1-frankja@linux.ibm.com>
Signed-off-by: David Hildenbrand <david@redhat.com>
---
lib/s390x/asm-offsets.c | 1 +
lib/s390x/asm/arch_def.h | 4 +++-
s390x/cstart64.S | 24 +++++++++++++++++-------
3 files changed, 21 insertions(+), 8 deletions(-)
diff --git a/lib/s390x/asm-offsets.c b/lib/s390x/asm-offsets.c
index 4b213f8..61d2658 100644
--- a/lib/s390x/asm-offsets.c
+++ b/lib/s390x/asm-offsets.c
@@ -58,6 +58,7 @@ int main(void)
OFFSET(GEN_LC_SW_INT_FPRS, lowcore, sw_int_fprs);
OFFSET(GEN_LC_SW_INT_FPC, lowcore, sw_int_fpc);
OFFSET(GEN_LC_SW_INT_CRS, lowcore, sw_int_crs);
+ OFFSET(GEN_LC_SW_INT_PSW, lowcore, sw_int_psw);
OFFSET(GEN_LC_MCCK_EXT_SA_ADDR, lowcore, mcck_ext_sa_addr);
OFFSET(GEN_LC_FPRS_SA, lowcore, fprs_sa);
OFFSET(GEN_LC_GRS_SA, lowcore, grs_sa);
diff --git a/lib/s390x/asm/arch_def.h b/lib/s390x/asm/arch_def.h
index 07d4e5e..cf6e1ca 100644
--- a/lib/s390x/asm/arch_def.h
+++ b/lib/s390x/asm/arch_def.h
@@ -79,7 +79,8 @@ struct lowcore {
uint32_t sw_int_fpc; /* 0x0300 */
uint8_t pad_0x0304[0x0308 - 0x0304]; /* 0x0304 */
uint64_t sw_int_crs[16]; /* 0x0308 */
- uint8_t pad_0x0310[0x11b0 - 0x0388]; /* 0x0388 */
+ struct psw sw_int_psw; /* 0x0388 */
+ uint8_t pad_0x0310[0x11b0 - 0x0398]; /* 0x0398 */
uint64_t mcck_ext_sa_addr; /* 0x11b0 */
uint8_t pad_0x11b8[0x1200 - 0x11b8]; /* 0x11b8 */
uint64_t fprs_sa[16]; /* 0x1200 */
@@ -98,6 +99,7 @@ struct lowcore {
uint8_t pad_0x1400[0x1800 - 0x1400]; /* 0x1400 */
uint8_t pgm_int_tdb[0x1900 - 0x1800]; /* 0x1800 */
} __attribute__ ((__packed__));
+_Static_assert(sizeof(struct lowcore) == 0x1900, "Lowcore size");
#define PGM_INT_CODE_OPERATION 0x01
#define PGM_INT_CODE_PRIVILEGED_OPERATION 0x02
diff --git a/s390x/cstart64.S b/s390x/cstart64.S
index 4be20fc..86dd4c4 100644
--- a/s390x/cstart64.S
+++ b/s390x/cstart64.S
@@ -126,13 +126,18 @@ memsetxc:
.globl diag308_load_reset
diag308_load_reset:
SAVE_REGS
- /* Save the first PSW word to the IPL PSW */
+ /* Backup current PSW mask, as we have to restore it on success */
epsw %r0, %r1
- st %r0, 0
- /* Store the address and the bit for 31 bit addressing */
- larl %r0, 0f
- oilh %r0, 0x8000
- st %r0, 0x4
+ st %r0, GEN_LC_SW_INT_PSW
+ st %r1, GEN_LC_SW_INT_PSW + 4
+ /* Load reset psw mask (short psw, 64 bit) */
+ lg %r0, reset_psw
+ /* Load the success label address */
+ larl %r1, 0f
+ /* Or it to the mask */
+ ogr %r0, %r1
+ /* Store it at the reset PSW location (real 0x0) */
+ stg %r0, 0
/* Do the reset */
diag %r0,%r2,0x308
/* Failure path */
@@ -144,7 +149,10 @@ diag308_load_reset:
lctlg %c0, %c0, 0(%r1)
RESTORE_REGS
lhi %r2, 1
- br %r14
+ larl %r0, 1f
+ stg %r0, GEN_LC_SW_INT_PSW + 8
+ lpswe GEN_LC_SW_INT_PSW
+1: br %r14
.globl smp_cpu_setup_state
smp_cpu_setup_state:
@@ -184,6 +192,8 @@ svc_int:
lpswe GEN_LC_SVC_OLD_PSW
.align 8
+reset_psw:
+ .quad 0x0008000180000000
initial_psw:
.quad 0x0000000180000000, clear_bss_start
pgm_int_psw:
--
2.21.0
^ permalink raw reply related [flat|nested] 18+ messages in thread
* [kvm-unit-tests PULL 08/12] travis.yml: Re-arrange the test matrix
2019-11-18 10:07 [kvm-unit-tests PULL 00/12] s390x and Travis CI updates David Hildenbrand
` (6 preceding siblings ...)
2019-11-18 10:07 ` [kvm-unit-tests PULL 07/12] s390x: Load reset psw on diag308 reset David Hildenbrand
@ 2019-11-18 10:07 ` David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 09/12] travis.yml: Install only the required packages for each entry in the matrix David Hildenbrand
` (5 subsequent siblings)
13 siblings, 0 replies; 18+ messages in thread
From: David Hildenbrand @ 2019-11-18 10:07 UTC (permalink / raw)
To: kvm
Cc: Paolo Bonzini, Radim Krčmář,
Thomas Huth, Christian Borntraeger, Cornelia Huck, Janosch Frank,
Alex Bennée, David Hildenbrand
From: Thomas Huth <thuth@redhat.com>
We will soon need more control over the individual test matrix
entries, so we should not limit the matrix to "env" sections,
i.e. put the "matrix:" keyword on the top, not the "env:".
Signed-off-by: Thomas Huth <thuth@redhat.com>
Reviewed-by: Alex Bennée <alex.bennee@linaro.org>
Message-Id: <20191113112649.14322-2-thuth@redhat.com>
Signed-off-by: David Hildenbrand <david@redhat.com>
---
.travis.yml | 92 ++++++++++++++++++++++++++++++++---------------------
1 file changed, 56 insertions(+), 36 deletions(-)
diff --git a/.travis.yml b/.travis.yml
index 6c14953..611bbdc 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -16,44 +16,64 @@ addons:
- qemu-system
git:
submodules: false
-env:
- matrix:
- - CONFIG=""
- BUILD_DIR="."
- TESTS="vmexit_cpuid vmexit_mov_from_cr8 vmexit_mov_to_cr8 vmexit_ipi
+
+matrix:
+ include:
+ - env:
+ - CONFIG=""
+ - BUILD_DIR="."
+ - TESTS="vmexit_cpuid vmexit_mov_from_cr8 vmexit_mov_to_cr8 vmexit_ipi
vmexit_ple_round_robin vmexit_tscdeadline vmexit_tscdeadline_immed"
- - CONFIG=""
- BUILD_DIR="x86-builddir"
- TESTS="ioapic-split ioapic smptest smptest3 eventinj msr port80 syscall
+
+ - env:
+ - CONFIG=""
+ - BUILD_DIR="x86-builddir"
+ - TESTS="ioapic-split ioapic smptest smptest3 eventinj msr port80 syscall
tsc rmap_chain umip intel_iommu vmexit_inl_pmtimer vmexit_ipi_halt"
- - CONFIG="--arch=arm --cross-prefix=arm-linux-gnueabihf-"
- BUILD_DIR="."
- TESTS="selftest-vectors-kernel selftest-vectors-user selftest-smp"
- - CONFIG="--arch=arm --cross-prefix=arm-linux-gnueabihf-"
- BUILD_DIR="arm-buildir"
- TESTS="pci-test pmu gicv2-active gicv3-active psci selftest-setup"
- - CONFIG="--arch=arm64 --cross-prefix=aarch64-linux-gnu-"
- BUILD_DIR="."
- TESTS="selftest-vectors-kernel selftest-vectors-user selftest-smp"
- - CONFIG="--arch=arm64 --cross-prefix=aarch64-linux-gnu-"
- BUILD_DIR="arm64-buildir"
- TESTS="pci-test pmu gicv2-active gicv3-active psci timer selftest-setup"
- - CONFIG="--arch=ppc64 --endian=little --cross-prefix=powerpc64le-linux-gnu-"
- BUILD_DIR="."
- TESTS="spapr_hcall emulator rtas-set-time-of-day"
- ACCEL="tcg,cap-htm=off"
- - CONFIG="--arch=ppc64 --endian=little --cross-prefix=powerpc64le-linux-gnu-"
- BUILD_DIR="ppc64le-buildir"
- TESTS="rtas-get-time-of-day rtas-get-time-of-day-base"
- ACCEL="tcg,cap-htm=off"
- - CONFIG="--arch=s390x --cross-prefix=s390x-linux-gnu-"
- BUILD_DIR="."
- TESTS="diag10 diag308"
- ACCEL="tcg,firmware=s390x/run"
- - CONFIG="--arch=s390x --cross-prefix=s390x-linux-gnu-"
- BUILD_DIR="s390x-builddir"
- TESTS="sieve"
- ACCEL="tcg,firmware=s390x/run"
+
+ - env:
+ - CONFIG="--arch=arm --cross-prefix=arm-linux-gnueabihf-"
+ - BUILD_DIR="."
+ - TESTS="selftest-vectors-kernel selftest-vectors-user selftest-smp"
+
+ - env:
+ - CONFIG="--arch=arm --cross-prefix=arm-linux-gnueabihf-"
+ - BUILD_DIR="arm-buildir"
+ - TESTS="pci-test pmu gicv2-active gicv3-active psci selftest-setup"
+
+ - env:
+ - CONFIG="--arch=arm64 --cross-prefix=aarch64-linux-gnu-"
+ - BUILD_DIR="."
+ - TESTS="selftest-vectors-kernel selftest-vectors-user selftest-smp"
+
+ - env:
+ - CONFIG="--arch=arm64 --cross-prefix=aarch64-linux-gnu-"
+ - BUILD_DIR="arm64-buildir"
+ - TESTS="pci-test pmu gicv2-active gicv3-active psci timer selftest-setup"
+
+ - env:
+ - CONFIG="--arch=ppc64 --endian=little --cross-prefix=powerpc64le-linux-gnu-"
+ - BUILD_DIR="."
+ - TESTS="spapr_hcall emulator rtas-set-time-of-day"
+ - ACCEL="tcg,cap-htm=off"
+
+ - env:
+ - CONFIG="--arch=ppc64 --endian=little --cross-prefix=powerpc64le-linux-gnu-"
+ - BUILD_DIR="ppc64le-buildir"
+ - TESTS="rtas-get-time-of-day rtas-get-time-of-day-base"
+ - ACCEL="tcg,cap-htm=off"
+
+ - env:
+ - CONFIG="--arch=s390x --cross-prefix=s390x-linux-gnu-"
+ - BUILD_DIR="."
+ - TESTS="diag10 diag308"
+ - ACCEL="tcg,firmware=s390x/run"
+
+ - env:
+ - CONFIG="--arch=s390x --cross-prefix=s390x-linux-gnu-"
+ - BUILD_DIR="s390x-builddir"
+ - TESTS="sieve"
+ - ACCEL="tcg,firmware=s390x/run"
before_script:
- mkdir -p $BUILD_DIR && cd $BUILD_DIR
--
2.21.0
^ permalink raw reply related [flat|nested] 18+ messages in thread
* [kvm-unit-tests PULL 09/12] travis.yml: Install only the required packages for each entry in the matrix
2019-11-18 10:07 [kvm-unit-tests PULL 00/12] s390x and Travis CI updates David Hildenbrand
` (7 preceding siblings ...)
2019-11-18 10:07 ` [kvm-unit-tests PULL 08/12] travis.yml: Re-arrange the test matrix David Hildenbrand
@ 2019-11-18 10:07 ` David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 10/12] travis.yml: Test with KVM instead of TCG (on x86) David Hildenbrand
` (4 subsequent siblings)
13 siblings, 0 replies; 18+ messages in thread
From: David Hildenbrand @ 2019-11-18 10:07 UTC (permalink / raw)
To: kvm
Cc: Paolo Bonzini, Radim Krčmář,
Thomas Huth, Christian Borntraeger, Cornelia Huck, Janosch Frank,
Alex Bennée, David Hildenbrand
From: Thomas Huth <thuth@redhat.com>
We don't need all cross compiler and QEMU versions for each and every entry
in the test matrix, only the ones for the current target architecture.
So let's speed up the installation process a little bit by only installing
the packages that we really need.
Signed-off-by: Thomas Huth <thuth@redhat.com>
Reviewed-by: Alex Bennée <alex.bennee@linaro.org>
Message-Id: <20191113112649.14322-3-thuth@redhat.com>
Signed-off-by: David Hildenbrand <david@redhat.com>
---
.travis.yml | 53 +++++++++++++++++++++++++++++++----------------------
1 file changed, 31 insertions(+), 22 deletions(-)
diff --git a/.travis.yml b/.travis.yml
index 611bbdc..3f5b5ee 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -1,75 +1,84 @@
sudo: false
dist: bionic
language: c
-compiler:
- - gcc
cache: ccache
-addons:
- apt:
- packages:
- # Cross Toolchains
- - gcc-arm-linux-gnueabihf
- - gcc-aarch64-linux-gnu
- - gcc-powerpc64le-linux-gnu
- - gcc-s390x-linux-gnu
- # Run dependencies
- - qemu-system
git:
submodules: false
matrix:
include:
- - env:
+
+ - addons:
+ apt_packages: gcc qemu-system-x86
+ env:
- CONFIG=""
- BUILD_DIR="."
- TESTS="vmexit_cpuid vmexit_mov_from_cr8 vmexit_mov_to_cr8 vmexit_ipi
vmexit_ple_round_robin vmexit_tscdeadline vmexit_tscdeadline_immed"
- - env:
+ - addons:
+ apt_packages: gcc qemu-system-x86
+ env:
- CONFIG=""
- BUILD_DIR="x86-builddir"
- TESTS="ioapic-split ioapic smptest smptest3 eventinj msr port80 syscall
tsc rmap_chain umip intel_iommu vmexit_inl_pmtimer vmexit_ipi_halt"
- - env:
+ - addons:
+ apt_packages: gcc-arm-linux-gnueabihf qemu-system-arm
+ env:
- CONFIG="--arch=arm --cross-prefix=arm-linux-gnueabihf-"
- BUILD_DIR="."
- TESTS="selftest-vectors-kernel selftest-vectors-user selftest-smp"
- - env:
+ - addons:
+ apt_packages: gcc-arm-linux-gnueabihf qemu-system-arm
+ env:
- CONFIG="--arch=arm --cross-prefix=arm-linux-gnueabihf-"
- BUILD_DIR="arm-buildir"
- TESTS="pci-test pmu gicv2-active gicv3-active psci selftest-setup"
- - env:
+ - addons:
+ apt_packages: gcc-aarch64-linux-gnu qemu-system-aarch64
+ env:
- CONFIG="--arch=arm64 --cross-prefix=aarch64-linux-gnu-"
- BUILD_DIR="."
- TESTS="selftest-vectors-kernel selftest-vectors-user selftest-smp"
- - env:
+ - addons:
+ apt_packages: gcc-aarch64-linux-gnu qemu-system-aarch64
+ env:
- CONFIG="--arch=arm64 --cross-prefix=aarch64-linux-gnu-"
- BUILD_DIR="arm64-buildir"
- TESTS="pci-test pmu gicv2-active gicv3-active psci timer selftest-setup"
- - env:
+ - addons:
+ apt_packages: gcc-powerpc64le-linux-gnu qemu-system-ppc
+ env:
- CONFIG="--arch=ppc64 --endian=little --cross-prefix=powerpc64le-linux-gnu-"
- BUILD_DIR="."
- TESTS="spapr_hcall emulator rtas-set-time-of-day"
- ACCEL="tcg,cap-htm=off"
- - env:
+ - addons:
+ apt_packages: gcc-powerpc64le-linux-gnu qemu-system-ppc
+ env:
- CONFIG="--arch=ppc64 --endian=little --cross-prefix=powerpc64le-linux-gnu-"
- BUILD_DIR="ppc64le-buildir"
- TESTS="rtas-get-time-of-day rtas-get-time-of-day-base"
- ACCEL="tcg,cap-htm=off"
- - env:
+ - addons:
+ apt_packages: gcc-s390x-linux-gnu qemu-system-s390x
+ env:
- CONFIG="--arch=s390x --cross-prefix=s390x-linux-gnu-"
- BUILD_DIR="."
- TESTS="diag10 diag308"
- ACCEL="tcg,firmware=s390x/run"
- - env:
+ - addons:
+ apt_packages: gcc-s390x-linux-gnu qemu-system-s390x
+ env:
- CONFIG="--arch=s390x --cross-prefix=s390x-linux-gnu-"
- BUILD_DIR="s390x-builddir"
- TESTS="sieve"
--
2.21.0
^ permalink raw reply related [flat|nested] 18+ messages in thread
* [kvm-unit-tests PULL 10/12] travis.yml: Test with KVM instead of TCG (on x86)
2019-11-18 10:07 [kvm-unit-tests PULL 00/12] s390x and Travis CI updates David Hildenbrand
` (8 preceding siblings ...)
2019-11-18 10:07 ` [kvm-unit-tests PULL 09/12] travis.yml: Install only the required packages for each entry in the matrix David Hildenbrand
@ 2019-11-18 10:07 ` David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 11/12] travis.yml: Test the i386 build, too David Hildenbrand
` (3 subsequent siblings)
13 siblings, 0 replies; 18+ messages in thread
From: David Hildenbrand @ 2019-11-18 10:07 UTC (permalink / raw)
To: kvm
Cc: Paolo Bonzini, Radim Krčmář,
Thomas Huth, Christian Borntraeger, Cornelia Huck, Janosch Frank,
David Hildenbrand
From: Thomas Huth <thuth@redhat.com>
Travis nowadays supports KVM in their CI pipelines, so we can finally
run the kvm-unit-tests with KVM instead of TCG here. Unfortunately, there
are some quirks:
First, /dev/kvm is not accessible on Ubuntu by default. You have to be
"root" or in the "kvm" group to access it. But changing the group of the
current user is not taking into account for the current shell process, so
that would need some indirections in the yml file. Thus the yml script now
rather changes the group and "g+s" permission of the qemu binary instead.
Second, not all x86 tests are working in this environment, so we still
have to manually select the test set here (but the amount of tests is
definitely higher now than what we were able to run with TCG before).
Signed-off-by: Thomas Huth <thuth@redhat.com>
Message-Id: <20191113174842.20759-1-thuth@redhat.com>
Signed-off-by: David Hildenbrand <david@redhat.com>
---
.travis.yml | 19 ++++++++++++++-----
1 file changed, 14 insertions(+), 5 deletions(-)
diff --git a/.travis.yml b/.travis.yml
index 3f5b5ee..89c50fe 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -1,4 +1,4 @@
-sudo: false
+sudo: true
dist: bionic
language: c
cache: ccache
@@ -13,16 +13,21 @@ matrix:
env:
- CONFIG=""
- BUILD_DIR="."
- - TESTS="vmexit_cpuid vmexit_mov_from_cr8 vmexit_mov_to_cr8 vmexit_ipi
- vmexit_ple_round_robin vmexit_tscdeadline vmexit_tscdeadline_immed"
+ - TESTS="access asyncpf debug emulator ept hypercall hyperv_stimer
+ hyperv_synic idt_test intel_iommu ioapic ioapic-split
+ kvmclock_test msr pcid rdpru realmode rmap_chain s3 umip"
+ - ACCEL="kvm"
- addons:
apt_packages: gcc qemu-system-x86
env:
- CONFIG=""
- BUILD_DIR="x86-builddir"
- - TESTS="ioapic-split ioapic smptest smptest3 eventinj msr port80 syscall
- tsc rmap_chain umip intel_iommu vmexit_inl_pmtimer vmexit_ipi_halt"
+ - TESTS="smptest smptest3 tsc tsc_adjust xsave vmexit_cpuid vmexit_vmcall
+ sieve vmexit_inl_pmtimer vmexit_ipi_halt vmexit_mov_from_cr8
+ vmexit_mov_to_cr8 vmexit_ple_round_robin vmexit_tscdeadline
+ vmexit_tscdeadline_immed vmx_apic_passthrough_thread syscall"
+ - ACCEL="kvm"
- addons:
apt_packages: gcc-arm-linux-gnueabihf qemu-system-arm
@@ -85,6 +90,10 @@ matrix:
- ACCEL="tcg,firmware=s390x/run"
before_script:
+ - if [ "$ACCEL" = "kvm" ]; then
+ sudo chgrp kvm /usr/bin/qemu-system-* ;
+ sudo chmod g+s /usr/bin/qemu-system-* ;
+ fi
- mkdir -p $BUILD_DIR && cd $BUILD_DIR
- if [ -e ./configure ]; then ./configure $CONFIG ; fi
- if [ -e ../configure ]; then ../configure $CONFIG ; fi
--
2.21.0
^ permalink raw reply related [flat|nested] 18+ messages in thread
* [kvm-unit-tests PULL 11/12] travis.yml: Test the i386 build, too
2019-11-18 10:07 [kvm-unit-tests PULL 00/12] s390x and Travis CI updates David Hildenbrand
` (9 preceding siblings ...)
2019-11-18 10:07 ` [kvm-unit-tests PULL 10/12] travis.yml: Test with KVM instead of TCG (on x86) David Hildenbrand
@ 2019-11-18 10:07 ` David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 12/12] travis.yml: Expect that at least one test succeeds David Hildenbrand
` (2 subsequent siblings)
13 siblings, 0 replies; 18+ messages in thread
From: David Hildenbrand @ 2019-11-18 10:07 UTC (permalink / raw)
To: kvm
Cc: Paolo Bonzini, Radim Krčmář,
Thomas Huth, Christian Borntraeger, Cornelia Huck, Janosch Frank,
Alex Bennée, David Hildenbrand
From: Thomas Huth <thuth@redhat.com>
After installing gcc-multilib, we can also test the 32-bit builds
on Travis.
Signed-off-by: Thomas Huth <thuth@redhat.com>
Reviewed-by: Alex Bennée <alex.bennee@linaro.org>
Message-Id: <20191113112649.14322-5-thuth@redhat.com>
Signed-off-by: David Hildenbrand <david@redhat.com>
---
.travis.yml | 15 +++++++++++++++
1 file changed, 15 insertions(+)
diff --git a/.travis.yml b/.travis.yml
index 89c50fe..6858c3a 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -29,6 +29,21 @@ matrix:
vmexit_tscdeadline_immed vmx_apic_passthrough_thread syscall"
- ACCEL="kvm"
+ - addons:
+ apt_packages: gcc gcc-multilib qemu-system-x86
+ env:
+ - CONFIG="--arch=i386"
+ - BUILD_DIR="."
+ - TESTS="eventinj port80 sieve tsc taskswitch umip vmexit_ple_round_robin"
+
+ - addons:
+ apt_packages: gcc gcc-multilib qemu-system-x86
+ env:
+ - CONFIG="--arch=i386"
+ - BUILD_DIR="i386-builddir"
+ - TESTS="vmexit_mov_from_cr8 vmexit_ipi vmexit_ipi_halt vmexit_mov_to_cr8
+ vmexit_cpuid vmexit_tscdeadline vmexit_tscdeadline_immed"
+
- addons:
apt_packages: gcc-arm-linux-gnueabihf qemu-system-arm
env:
--
2.21.0
^ permalink raw reply related [flat|nested] 18+ messages in thread
* [kvm-unit-tests PULL 12/12] travis.yml: Expect that at least one test succeeds
2019-11-18 10:07 [kvm-unit-tests PULL 00/12] s390x and Travis CI updates David Hildenbrand
` (10 preceding siblings ...)
2019-11-18 10:07 ` [kvm-unit-tests PULL 11/12] travis.yml: Test the i386 build, too David Hildenbrand
@ 2019-11-18 10:07 ` David Hildenbrand
2019-11-18 10:18 ` [kvm-unit-tests PULL 00/12] s390x and Travis CI updates Paolo Bonzini
2019-11-18 11:11 ` Christian Borntraeger
13 siblings, 0 replies; 18+ messages in thread
From: David Hildenbrand @ 2019-11-18 10:07 UTC (permalink / raw)
To: kvm
Cc: Paolo Bonzini, Radim Krčmář,
Thomas Huth, Christian Borntraeger, Cornelia Huck, Janosch Frank,
Alex Bennée, David Hildenbrand
From: Thomas Huth <thuth@redhat.com>
While working on the travis.yml file, I've run into cases where
all tests are reported as "SKIP" by the run_test.sh script (e.g.
when QEMU could not be started). This should not result in a
successful test run, so mark it as failed if not at least one
test passed.
Signed-off-by: Thomas Huth <thuth@redhat.com>
Reviewed-by: Alex Bennée <alex.bennee@linaro.org>
Message-Id: <20191113112649.14322-6-thuth@redhat.com>
Signed-off-by: David Hildenbrand <david@redhat.com>
---
.travis.yml | 1 +
1 file changed, 1 insertion(+)
diff --git a/.travis.yml b/.travis.yml
index 6858c3a..4162366 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -116,3 +116,4 @@ script:
- make -j3
- ACCEL="${ACCEL:-tcg}" ./run_tests.sh -v $TESTS | tee results.txt
- if grep -q FAIL results.txt ; then exit 1 ; fi
+ - if ! grep -q PASS results.txt ; then exit 1 ; fi
--
2.21.0
^ permalink raw reply related [flat|nested] 18+ messages in thread
* Re: [kvm-unit-tests PULL 00/12] s390x and Travis CI updates
2019-11-18 10:07 [kvm-unit-tests PULL 00/12] s390x and Travis CI updates David Hildenbrand
` (11 preceding siblings ...)
2019-11-18 10:07 ` [kvm-unit-tests PULL 12/12] travis.yml: Expect that at least one test succeeds David Hildenbrand
@ 2019-11-18 10:18 ` Paolo Bonzini
2019-11-18 11:11 ` Christian Borntraeger
13 siblings, 0 replies; 18+ messages in thread
From: Paolo Bonzini @ 2019-11-18 10:18 UTC (permalink / raw)
To: David Hildenbrand, kvm
Cc: Radim Krčmář,
Thomas Huth, Christian Borntraeger, Cornelia Huck, Janosch Frank
On 18/11/19 11:07, David Hildenbrand wrote:
> https://github.com/davidhildenbrand/kvm-unit-tests.git tags/s390x-2019-11-18
Pulled, thanks.
Paolo
^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [kvm-unit-tests PULL 00/12] s390x and Travis CI updates
2019-11-18 10:07 [kvm-unit-tests PULL 00/12] s390x and Travis CI updates David Hildenbrand
` (12 preceding siblings ...)
2019-11-18 10:18 ` [kvm-unit-tests PULL 00/12] s390x and Travis CI updates Paolo Bonzini
@ 2019-11-18 11:11 ` Christian Borntraeger
2019-11-18 11:21 ` Thomas Huth
13 siblings, 1 reply; 18+ messages in thread
From: Christian Borntraeger @ 2019-11-18 11:11 UTC (permalink / raw)
To: David Hildenbrand, kvm
Cc: Paolo Bonzini, Radim Krčmář,
Thomas Huth, Cornelia Huck, Janosch Frank
For what its worth (maybe a future patch) travis has now alpha s390x build support
https://docs.travis-ci.com/user/multi-cpu-architectures
I think the number of instances for s390 is still limited, but it works for open
source software.
On 18.11.19 11:07, David Hildenbrand wrote:
> Hi Paolo,
>
> The following changes since commit af8dfe97b47d03876041506e8b38f718914aeea4:
>
> x86/unittests.cfg: Increase the timeout of the sieve test to 180s (2019-11-15 15:56:19 +0100)
>
> are available in the Git repository at:
>
> https://github.com/davidhildenbrand/kvm-unit-tests.git tags/s390x-2019-11-18
>
> for you to fetch changes up to c71d8a9fab524269785d688eb0db7f6391b5510c:
>
> travis.yml: Expect that at least one test succeeds (2019-11-18 10:47:27 +0100)
>
> ----------------------------------------------------------------
> Cleanups and bugfixes (especially to make the tests run natively under
> LPAR). Travis CI improvements (e.g., x86 support, KVM support on x86_64).
>
> ----------------------------------------------------------------
> Claudio Imbrenda (3):
> s390x: remove redundant defines
> s390x: improve error reporting for interrupts
> s390x: sclp: expose ram_size and max_ram_size
>
> Janosch Frank (4):
> s390x: Use loop to save and restore fprs
> s390x: Fix initial cr0 load comments
> s390x: Add CR save area
> s390x: Load reset psw on diag308 reset
>
> Thomas Huth (5):
> travis.yml: Re-arrange the test matrix
> travis.yml: Install only the required packages for each entry in the
> matrix
> travis.yml: Test with KVM instead of TCG (on x86)
> travis.yml: Test the i386 build, too
> travis.yml: Expect that at least one test succeeds
>
> .travis.yml | 156 ++++++++++++++++++++++++++-------------
> lib/s390x/asm-offsets.c | 3 +-
> lib/s390x/asm/arch_def.h | 6 +-
> lib/s390x/interrupt.c | 8 +-
> lib/s390x/sclp.c | 10 +++
> lib/s390x/sclp.h | 4 +-
> lib/s390x/smp.c | 2 +-
> s390x/cstart64.S | 76 ++++++++-----------
> 8 files changed, 158 insertions(+), 107 deletions(-)
>
^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [kvm-unit-tests PULL 00/12] s390x and Travis CI updates
2019-11-18 11:11 ` Christian Borntraeger
@ 2019-11-18 11:21 ` Thomas Huth
2019-11-18 11:32 ` Christian Borntraeger
0 siblings, 1 reply; 18+ messages in thread
From: Thomas Huth @ 2019-11-18 11:21 UTC (permalink / raw)
To: Christian Borntraeger, David Hildenbrand, kvm
Cc: Paolo Bonzini, Radim Krčmář, Cornelia Huck, Janosch Frank
On 18/11/2019 12.11, Christian Borntraeger wrote:
> For what its worth (maybe a future patch) travis has now alpha s390x build support
> https://docs.travis-ci.com/user/multi-cpu-architectures
>
> I think the number of instances for s390 is still limited, but it works for open
> source software.
I already tried that... Unfortunately the LXD containers that they use
on s390x (and ppc64 and arm64) are rather limited - you can't use KVM
here on Travis, unlike with x86.
So the only advantage of adding a s390x build here is that we'd check
native builds instead of using the cross compiler... not sure whether
that gives us that much more of test coverage for the kvm-unit-tests...
Thomas
^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [kvm-unit-tests PULL 00/12] s390x and Travis CI updates
2019-11-18 11:21 ` Thomas Huth
@ 2019-11-18 11:32 ` Christian Borntraeger
2019-11-18 11:36 ` Thomas Huth
0 siblings, 1 reply; 18+ messages in thread
From: Christian Borntraeger @ 2019-11-18 11:32 UTC (permalink / raw)
To: Thomas Huth, David Hildenbrand, kvm
Cc: Paolo Bonzini, Radim Krčmář, Cornelia Huck, Janosch Frank
On 18.11.19 12:21, Thomas Huth wrote:
> On 18/11/2019 12.11, Christian Borntraeger wrote:
>> For what its worth (maybe a future patch) travis has now alpha s390x build support
>> https://docs.travis-ci.com/user/multi-cpu-architectures
>>
>> I think the number of instances for s390 is still limited, but it works for open
>> source software.
>
> I already tried that... Unfortunately the LXD containers that they use
> on s390x (and ppc64 and arm64) are rather limited - you can't use KVM
> here on Travis, unlike with x86.
>
> So the only advantage of adding a s390x build here is that we'd check
> native builds instead of using the cross compiler... not sure whether
> that gives us that much more of test coverage for the kvm-unit-tests...
Right. It might be more useful for the qemu travis build?
^ permalink raw reply [flat|nested] 18+ messages in thread
* Re: [kvm-unit-tests PULL 00/12] s390x and Travis CI updates
2019-11-18 11:32 ` Christian Borntraeger
@ 2019-11-18 11:36 ` Thomas Huth
0 siblings, 0 replies; 18+ messages in thread
From: Thomas Huth @ 2019-11-18 11:36 UTC (permalink / raw)
To: Christian Borntraeger, David Hildenbrand, kvm
Cc: Paolo Bonzini, Radim Krčmář, Cornelia Huck, Janosch Frank
On 18/11/2019 12.32, Christian Borntraeger wrote:
>
>
> On 18.11.19 12:21, Thomas Huth wrote:
>> On 18/11/2019 12.11, Christian Borntraeger wrote:
>>> For what its worth (maybe a future patch) travis has now alpha s390x build support
>>> https://docs.travis-ci.com/user/multi-cpu-architectures
>>>
>>> I think the number of instances for s390 is still limited, but it works for open
>>> source software.
>>
>> I already tried that... Unfortunately the LXD containers that they use
>> on s390x (and ppc64 and arm64) are rather limited - you can't use KVM
>> here on Travis, unlike with x86.
>>
>> So the only advantage of adding a s390x build here is that we'd check
>> native builds instead of using the cross compiler... not sure whether
>> that gives us that much more of test coverage for the kvm-unit-tests...
>
> Right. It might be more useful for the qemu travis build?
Yes, it might be useful for QEMU. But there are some issues to be solved
first, e.g. some tests of QEMU are failing there in very weird ways (I
guess it's because some system calls are blocked in the LXD container).
Thomas
^ permalink raw reply [flat|nested] 18+ messages in thread
end of thread, other threads:[~2019-11-18 11:36 UTC | newest]
Thread overview: 18+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-18 10:07 [kvm-unit-tests PULL 00/12] s390x and Travis CI updates David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 01/12] s390x: Use loop to save and restore fprs David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 02/12] s390x: remove redundant defines David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 03/12] s390x: improve error reporting for interrupts David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 04/12] s390x: sclp: expose ram_size and max_ram_size David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 05/12] s390x: Fix initial cr0 load comments David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 06/12] s390x: Add CR save area David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 07/12] s390x: Load reset psw on diag308 reset David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 08/12] travis.yml: Re-arrange the test matrix David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 09/12] travis.yml: Install only the required packages for each entry in the matrix David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 10/12] travis.yml: Test with KVM instead of TCG (on x86) David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 11/12] travis.yml: Test the i386 build, too David Hildenbrand
2019-11-18 10:07 ` [kvm-unit-tests PULL 12/12] travis.yml: Expect that at least one test succeeds David Hildenbrand
2019-11-18 10:18 ` [kvm-unit-tests PULL 00/12] s390x and Travis CI updates Paolo Bonzini
2019-11-18 11:11 ` Christian Borntraeger
2019-11-18 11:21 ` Thomas Huth
2019-11-18 11:32 ` Christian Borntraeger
2019-11-18 11:36 ` Thomas Huth
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).