On Wed, 8 Jul 2020 20:51:33 +0200 David Hildenbrand <da...@redhat.com> wrote:
> Let's allocate the device memory information and setup the device > memory address space. Expose the maximum ramsize via SCLP and the actual > initial ramsize via diag260. > > Signed-off-by: David Hildenbrand <da...@redhat.com> > --- > hw/s390x/s390-virtio-ccw.c | 43 ++++++++++++++++++++++++++++++ > hw/s390x/sclp.c | 12 +++++++-- > include/hw/s390x/s390-virtio-ccw.h | 3 +++ > target/s390x/diag.c | 4 +-- > 4 files changed, 58 insertions(+), 4 deletions(-) (...) > diff --git a/target/s390x/diag.c b/target/s390x/diag.c > index c3b1e24b2c..6b33eb0efc 100644 > --- a/target/s390x/diag.c > +++ b/target/s390x/diag.c > @@ -32,8 +32,8 @@ void handle_diag_260(CPUS390XState *env, uint64_t r1, > uint64_t r3, uintptr_t ra) > ram_addr_t addr, length; > uint64_t tmp; > > - /* TODO: Unlock with new QEMU machine. */ > - if (false) { > + /* Support for diag260 is glued to support for memory devices. */ I'm wondering why you need to do this... sure, the availability of a new diagnose could be perceived as a guest-visible change, but does the information presented change anything? Without memory devices, it will just duplicate the information already reported via SCLP, IIUC? > + if (!memory_devices_allowed()) { > s390_program_interrupt(env, PGM_OPERATION, ra); > return; > }