mirror of https://github.com/xemu-project/xemu.git
* Small fixes for the s390x PCI code
* Fix reset handling of the diag318 data * Ease timeout problem of the new msys2-64bit job -----BEGIN PGP SIGNATURE----- iQJFBAABCAAvFiEEJ7iIR+7gJQEY8+q5LtnXdP5wLbUFAmG8YAkRHHRodXRoQHJl ZGhhdC5jb20ACgkQLtnXdP5wLbVNqRAAqoIa/unpbXFCaqEzV/T3+SBzAlLeFLr1 6ayaMr8cHQcsOXVMfLw1utmwElAwYiuNmivuYTDIGId2/FOxP5GUN3kp2AtwqTBK rQ1N/3445QOgMvusHp47HdNHOF3MWJRwjHzz4ZDI3cCjjrRRvI3YVvSaMJ8WdHw4 o4iDZje/2SJ/YMDC1PqgLsWZCqJ5pQXf4kK4qhSIHohjD/T9svsi0D6RxkGxyU0f awJpG+Yt2sIyOres3ovasCiozJg8EzMCCZX3KJyS3jUli/z8xyZ3IgnmNqe1GslH 2Uvi8TFeAgmxE242aQafCP55vkiN0grRCxUmUXihqexgYonHupRY0nEiKvamptpU Rh8vlbzEW3pjnLT+qtrdYA2FI+NJnpxs7ugyka6dWtyUg94RbBQwJEL44WLWnAbK r6tRegNcr5EQcmRFWHwLEkgIz7QLP8UUfU28DP+g/YDPPVENNuIX+G+WCnrsCp9U oHgJrYf2bx74TLLZyS9UMYMt1FMCxYcWW7D7QdWe5YSqzLQObTRC4oggqoDWS9rw Zmf6psQE66mxL3OUmc/IdAYYbevZ7t0+GcUpEh9Ch3Z3m9NJ6jP/lis8mdcOFlr1 0lqZw/zjHBDTT8xPA/sflyapptUiCppfEaoW005EqFt76AesrzbiBIHcSokD1Vyh G5fBmb5JIQ8= =+Byb -----END PGP SIGNATURE----- Merge tag 's390x-2021-12-17' of https://gitlab.com/thuth/qemu into staging * Small fixes for the s390x PCI code * Fix reset handling of the diag318 data * Ease timeout problem of the new msys2-64bit job # gpg: Signature made Fri 17 Dec 2021 02:01:45 AM PST # gpg: using RSA key 27B88847EEE0250118F3EAB92ED9D774FE702DB5 # gpg: issuer "thuth@redhat.com" # gpg: Good signature from "Thomas Huth <th.huth@gmx.de>" [unknown] # gpg: aka "Thomas Huth <thuth@redhat.com>" [unknown] # gpg: aka "Thomas Huth <th.huth@posteo.de>" [unknown] # gpg: aka "Thomas Huth <huth@tuxfamily.org>" [unknown] # gpg: WARNING: This key is not certified with a trusted signature! # gpg: There is no indication that the signature belongs to the owner. # Primary key fingerprint: 27B8 8847 EEE0 2501 18F3 EAB9 2ED9 D774 FE70 2DB5 * tag 's390x-2021-12-17' of https://gitlab.com/thuth/qemu: gitlab-ci: Speed up the msys2-64bit job by using --without-default-devices s390x/pci: add supported DT information to clp response s390x/pci: use the passthrough measurement update interval s390x/pci: don't use hard-coded dma range in reg_ioat s390x/pci: use a reserved ID for the default PCI group MAINTAINERS: update email address of Christian Borntraeger s390: kvm: adjust diag318 resets to retain data Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
This commit is contained in:
commit
48c03a0e13
|
@ -58,7 +58,7 @@ msys2-64bit:
|
|||
- $env:CHERE_INVOKING = 'yes' # Preserve the current working directory
|
||||
- $env:MSYSTEM = 'MINGW64' # Start a 64 bit Mingw environment
|
||||
- .\msys64\usr\bin\bash -lc './configure --target-list=x86_64-softmmu
|
||||
--enable-capstone=system'
|
||||
--enable-capstone=system --without-default-devices'
|
||||
- .\msys64\usr\bin\bash -lc "sed -i '/^ROMS=/d' build/config-host.mak"
|
||||
- .\msys64\usr\bin\bash -lc 'make -j2'
|
||||
- .\msys64\usr\bin\bash -lc 'make check'
|
||||
|
|
1
.mailmap
1
.mailmap
|
@ -50,6 +50,7 @@ Aleksandar Rikalo <aleksandar.rikalo@syrmia.com> <arikalo@wavecomp.com>
|
|||
Aleksandar Rikalo <aleksandar.rikalo@syrmia.com> <aleksandar.rikalo@rt-rk.com>
|
||||
Alexander Graf <agraf@csgraf.de> <agraf@suse.de>
|
||||
Anthony Liguori <anthony@codemonkey.ws> Anthony Liguori <aliguori@us.ibm.com>
|
||||
Christian Borntraeger <borntraeger@linux.ibm.com> <borntraeger@de.ibm.com>
|
||||
Filip Bozuta <filip.bozuta@syrmia.com> <filip.bozuta@rt-rk.com.com>
|
||||
Frederic Konrad <konrad@adacore.com> <fred.konrad@greensocs.com>
|
||||
Greg Kurz <groug@kaod.org> <gkurz@linux.vnet.ibm.com>
|
||||
|
|
|
@ -393,7 +393,7 @@ F: target/ppc/kvm.c
|
|||
|
||||
S390 KVM CPUs
|
||||
M: Halil Pasic <pasic@linux.ibm.com>
|
||||
M: Christian Borntraeger <borntraeger@de.ibm.com>
|
||||
M: Christian Borntraeger <borntraeger@linux.ibm.com>
|
||||
S: Supported
|
||||
F: target/s390x/kvm/
|
||||
F: target/s390x/ioinst.[ch]
|
||||
|
@ -1527,7 +1527,7 @@ S390 Machines
|
|||
-------------
|
||||
S390 Virtio-ccw
|
||||
M: Halil Pasic <pasic@linux.ibm.com>
|
||||
M: Christian Borntraeger <borntraeger@de.ibm.com>
|
||||
M: Christian Borntraeger <borntraeger@linux.ibm.com>
|
||||
S: Supported
|
||||
F: hw/char/sclp*.[hc]
|
||||
F: hw/char/terminal3270.c
|
||||
|
@ -1541,7 +1541,7 @@ T: git https://github.com/borntraeger/qemu.git s390-next
|
|||
L: qemu-s390x@nongnu.org
|
||||
|
||||
S390-ccw boot
|
||||
M: Christian Borntraeger <borntraeger@de.ibm.com>
|
||||
M: Christian Borntraeger <borntraeger@linux.ibm.com>
|
||||
M: Thomas Huth <thuth@redhat.com>
|
||||
S: Supported
|
||||
F: hw/s390x/ipl.*
|
||||
|
|
|
@ -782,6 +782,7 @@ static void s390_pci_init_default_group(void)
|
|||
resgrp->i = 128;
|
||||
resgrp->maxstbl = 128;
|
||||
resgrp->version = 0;
|
||||
resgrp->dtsm = ZPCI_DTSM;
|
||||
}
|
||||
|
||||
static void set_pbdev_info(S390PCIBusDevice *pbdev)
|
||||
|
|
|
@ -329,6 +329,7 @@ int clp_service_call(S390CPU *cpu, uint8_t r2, uintptr_t ra)
|
|||
stw_p(&resgrp->i, group->zpci_group.i);
|
||||
stw_p(&resgrp->maxstbl, group->zpci_group.maxstbl);
|
||||
resgrp->version = group->zpci_group.version;
|
||||
resgrp->dtsm = group->zpci_group.dtsm;
|
||||
stw_p(&resgrp->hdr.rsp, CLP_RC_OK);
|
||||
break;
|
||||
}
|
||||
|
@ -916,9 +917,10 @@ int pci_dereg_irqs(S390PCIBusDevice *pbdev)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static int reg_ioat(CPUS390XState *env, S390PCIIOMMU *iommu, ZpciFib fib,
|
||||
static int reg_ioat(CPUS390XState *env, S390PCIBusDevice *pbdev, ZpciFib fib,
|
||||
uintptr_t ra)
|
||||
{
|
||||
S390PCIIOMMU *iommu = pbdev->iommu;
|
||||
uint64_t pba = ldq_p(&fib.pba);
|
||||
uint64_t pal = ldq_p(&fib.pal);
|
||||
uint64_t g_iota = ldq_p(&fib.iota);
|
||||
|
@ -927,7 +929,7 @@ static int reg_ioat(CPUS390XState *env, S390PCIIOMMU *iommu, ZpciFib fib,
|
|||
|
||||
pba &= ~0xfff;
|
||||
pal |= 0xfff;
|
||||
if (pba > pal || pba < ZPCI_SDMA_ADDR || pal > ZPCI_EDMA_ADDR) {
|
||||
if (pba > pal || pba < pbdev->zpci_fn.sdma || pal > pbdev->zpci_fn.edma) {
|
||||
s390_program_interrupt(env, PGM_OPERAND, ra);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
@ -1045,7 +1047,7 @@ static void fmb_update(void *opaque)
|
|||
sizeof(pbdev->fmb.last_update))) {
|
||||
return;
|
||||
}
|
||||
timer_mod(pbdev->fmb_timer, t + DEFAULT_MUI);
|
||||
timer_mod(pbdev->fmb_timer, t + pbdev->pci_group->zpci_group.mui);
|
||||
}
|
||||
|
||||
int mpcifc_service_call(S390CPU *cpu, uint8_t r1, uint64_t fiba, uint8_t ar,
|
||||
|
@ -1125,7 +1127,7 @@ int mpcifc_service_call(S390CPU *cpu, uint8_t r1, uint64_t fiba, uint8_t ar,
|
|||
} else if (pbdev->iommu->enabled) {
|
||||
cc = ZPCI_PCI_LS_ERR;
|
||||
s390_set_status_code(env, r1, ZPCI_MOD_ST_SEQUENCE);
|
||||
} else if (reg_ioat(env, pbdev->iommu, fib, ra)) {
|
||||
} else if (reg_ioat(env, pbdev, fib, ra)) {
|
||||
cc = ZPCI_PCI_LS_ERR;
|
||||
s390_set_status_code(env, r1, ZPCI_MOD_ST_INSUF_RES);
|
||||
}
|
||||
|
@ -1150,7 +1152,7 @@ int mpcifc_service_call(S390CPU *cpu, uint8_t r1, uint64_t fiba, uint8_t ar,
|
|||
s390_set_status_code(env, r1, ZPCI_MOD_ST_SEQUENCE);
|
||||
} else {
|
||||
pci_dereg_ioat(pbdev->iommu);
|
||||
if (reg_ioat(env, pbdev->iommu, fib, ra)) {
|
||||
if (reg_ioat(env, pbdev, fib, ra)) {
|
||||
cc = ZPCI_PCI_LS_ERR;
|
||||
s390_set_status_code(env, r1, ZPCI_MOD_ST_INSUF_RES);
|
||||
}
|
||||
|
@ -1203,7 +1205,8 @@ int mpcifc_service_call(S390CPU *cpu, uint8_t r1, uint64_t fiba, uint8_t ar,
|
|||
}
|
||||
pbdev->fmb_addr = fmb_addr;
|
||||
timer_mod(pbdev->fmb_timer,
|
||||
qemu_clock_get_ms(QEMU_CLOCK_VIRTUAL) + DEFAULT_MUI);
|
||||
qemu_clock_get_ms(QEMU_CLOCK_VIRTUAL) +
|
||||
pbdev->pci_group->zpci_group.mui);
|
||||
break;
|
||||
}
|
||||
default:
|
||||
|
|
|
@ -160,6 +160,7 @@ static void s390_pci_read_group(S390PCIBusDevice *pbdev,
|
|||
resgrp->i = cap->noi;
|
||||
resgrp->maxstbl = cap->maxstbl;
|
||||
resgrp->version = cap->version;
|
||||
resgrp->dtsm = ZPCI_DTSM;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -37,6 +37,7 @@
|
|||
#define ZPCI_MAX_UID 0xffff
|
||||
#define UID_UNDEFINED 0
|
||||
#define UID_CHECKING_ENABLED 0x01
|
||||
#define ZPCI_DTSM 0x40
|
||||
|
||||
OBJECT_DECLARE_SIMPLE_TYPE(S390pciState, S390_PCI_HOST_BRIDGE)
|
||||
OBJECT_DECLARE_SIMPLE_TYPE(S390PCIBus, S390_PCI_BUS)
|
||||
|
@ -313,7 +314,7 @@ typedef struct ZpciFmb {
|
|||
} ZpciFmb;
|
||||
QEMU_BUILD_BUG_MSG(offsetof(ZpciFmb, fmt0) != 48, "padding in ZpciFmb");
|
||||
|
||||
#define ZPCI_DEFAULT_FN_GRP 0x20
|
||||
#define ZPCI_DEFAULT_FN_GRP 0xFF
|
||||
typedef struct S390PCIGroup {
|
||||
ClpRspQueryPciGrp zpci_group;
|
||||
int id;
|
||||
|
|
|
@ -163,7 +163,8 @@ typedef struct ClpRspQueryPciGrp {
|
|||
uint8_t fr;
|
||||
uint16_t maxstbl;
|
||||
uint16_t mui;
|
||||
uint64_t reserved3;
|
||||
uint8_t dtsm;
|
||||
uint8_t reserved3[7];
|
||||
uint64_t dasm; /* dma address space mask */
|
||||
uint64_t msia; /* MSI address */
|
||||
uint64_t reserved4;
|
||||
|
|
|
@ -63,6 +63,8 @@ struct CPUS390XState {
|
|||
uint64_t etoken; /* etoken */
|
||||
uint64_t etoken_extension; /* etoken extension */
|
||||
|
||||
uint64_t diag318_info;
|
||||
|
||||
/* Fields up to this point are not cleared by initial CPU reset */
|
||||
struct {} start_initial_reset_fields;
|
||||
|
||||
|
@ -118,8 +120,6 @@ struct CPUS390XState {
|
|||
uint16_t external_call_addr;
|
||||
DECLARE_BITMAP(emergency_signals, S390_MAX_CPUS);
|
||||
|
||||
uint64_t diag318_info;
|
||||
|
||||
#if !defined(CONFIG_USER_ONLY)
|
||||
uint64_t tlb_fill_tec; /* translation exception code during tlb_fill */
|
||||
int tlb_fill_exc; /* exception number seen during tlb_fill */
|
||||
|
|
|
@ -1585,6 +1585,10 @@ void kvm_s390_set_diag318(CPUState *cs, uint64_t diag318_info)
|
|||
env->diag318_info = diag318_info;
|
||||
cs->kvm_run->s.regs.diag318 = diag318_info;
|
||||
cs->kvm_run->kvm_dirty_regs |= KVM_SYNC_DIAG318;
|
||||
/*
|
||||
* diag 318 info is zeroed during a clear reset and
|
||||
* diag 308 IPL subcodes.
|
||||
*/
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue