* [Qemu-devel] [PULL v2 00/46] First batch of s390x patches for 2.12
@ 2017-12-15 11:03 Cornelia Huck
2017-12-15 11:03 ` [Qemu-devel] [PULL v2 46/46] s390-ccw-virtio: allow for systems larger that 7.999TB Cornelia Huck
2017-12-15 13:48 ` [Qemu-devel] [PULL v2 00/46] First batch of s390x patches for 2.12 Peter Maydell
0 siblings, 2 replies; 3+ messages in thread
From: Cornelia Huck @ 2017-12-15 11:03 UTC (permalink / raw)
To: peter.maydell
Cc: qemu-devel, qemu-s390x, rth, agraf, thuth, borntraeger, david,
Cornelia Huck
The following changes since commit 0ef0583d5adceb9138bdb47494dabd1549ac5b6d:
Merge remote-tracking branch 'remotes/dgilbert/tags/pull-hmp-20171214' into staging (2017-12-14 15:32:32 +0000)
are available in the git repository at:
git://github.com/cohuck/qemu tags/s390x-20171215-v2
for you to fetch changes up to bb223055b9b327ec66e1f6d2fbaebaee0b8f3dbe:
s390-ccw-virtio: allow for systems larger that 7.999TB (2017-12-15 11:54:52 +0100)
----------------------------------------------------------------
s390x changes for 2.12:
- Lots of tcg improvements: ccw hotplug is now working and we can run
a Linux kernel built for z12 under tcg
- zPCI improvements to get virtio-pci working
- get rid of the cssid restrictions for virtual and non-virtual channel
devices
- we now support 8TB+ systems
- 2.12 compat machine
- fixes and cleanups
----------------------------------------------------------------
Christian Borntraeger (3):
s390x/migration: use zero flag parameter
pc-bios/s390-ccw: zero out bss section
s390-ccw-virtio: allow for systems larger that 7.999TB
Cornelia Huck (4):
pc-bios/s390-ccw.img: update image
s390x: introduce 2.12 compat machine
target/s390x: nuke DPRINTF in helper.c
s390x/css: attach css bridge
David Hildenbrand (30):
s390x/tcg: introduce and use s390_program_interrupt()
s390x/tcg: get rid of runtime_exception()
s390x/tcg: rip out dead tpi code
s390x/ioinst: pass the retaddr to all IO instructions
s390x/pci: pass the retaddr to all PCI instructions
s390x/diag: pass the retaddr into handle_diag_308()
s390x: handle exceptions during s390_cpu_virt_mem_rw() correctly (TCG)
s390x/tcg: don't exit the cpu loop in s390_cpu_virt_mem_rw()
s390x/tcg: io instructions don't need potential_page_fault()
s390x/tcg: use s390_program_interrupt() in SCLP Service Call
s390x/tcg: use s390_program_interrupt() in DIAG
s390x/tcg: use s390_program_interrupt() in per_check_exception()
s390x/tcg: use s390_program_interrupt() in SACF
s390x/tcg: use s390_program_interrupt() in STSI
s390x/tcg: drop program_interrupt()
s390x/tcg: drop potential_page_fault()
s390x/kvm: factor out build_channel_report_mcic() into cpu.h
s390x/tcg: fix and cleanup mcck injection
s390x/tcg: implement SET CLOCK PROGRAMMABLE FIELD
s390x/tcg: indicate value of TODPR in STCKE
s390x/tcg: wire up STORE CHANNEL REPORT WORD
s390x/tcg: ASI/ASGI/ALSI/ALSGI are atomic with Interlocked-acccess
facility 1
s390x/tcg: implement Interlocked-Access Facility 2
s390x/tcg: wire up SET ADDRESS LIMIT
s390x/tcg: wire up SET CHANNEL MONITOR
s390x/tcg: Implement STORE CHANNEL PATH STATUS
s390x/tcg: Implement SIGNAL ADAPTER instruction
s390x/tcg: implement extract-CPU-time facility
s390x/tcg: we already implement the Set-Program-Parameter facility
s390x: change the QEMU cpu model to a stripped down z12
Halil Pasic (2):
s390x/css: unrestrict cssids
s390x: deprecate s390-squash-mcss machine prop
Pierre Morel (7):
s390x/pci: factor out endianess conversion
s390x/pci: rework PCI STORE
s390x/pci: rework PCI LOAD
s390x/pci: rework PCI STORE BLOCK
s390x/pci: move the memory region read from pcilg
s390x/pci: move the memory region write from pcistg
s390x/pci: search for subregion inside the BARs
hw/s390x/3270-ccw.c | 2 +-
hw/s390x/css-bridge.c | 13 ++
hw/s390x/css.c | 34 +----
hw/s390x/s390-ccw.c | 2 +-
hw/s390x/s390-pci-bus.h | 1 +
hw/s390x/s390-pci-inst.c | 337 +++++++++++++++++++++++++------------------
hw/s390x/s390-pci-inst.h | 22 ++-
hw/s390x/s390-virtio-ccw.c | 59 +++++++-
hw/s390x/virtio-ccw.c | 2 +-
include/hw/compat.h | 3 +
include/hw/s390x/css.h | 13 +-
pc-bios/s390-ccw.img | Bin 26416 -> 26416 bytes
pc-bios/s390-ccw/start.S | 30 +++-
qemu-doc.texi | 8 +
qemu-options.hx | 8 +-
target/s390x/cc_helper.c | 2 +-
target/s390x/cpu.h | 31 +++-
target/s390x/cpu_models.c | 103 ++++++-------
target/s390x/cpu_models.h | 1 +
target/s390x/crypto_helper.c | 7 +-
target/s390x/diag.c | 14 +-
target/s390x/excp_helper.c | 17 +--
target/s390x/fpu_helper.c | 2 +-
target/s390x/gen-features.c | 88 +++++++++++
target/s390x/helper.c | 18 ---
target/s390x/helper.h | 6 +-
target/s390x/insn-data.def | 29 ++--
target/s390x/int_helper.c | 14 +-
target/s390x/internal.h | 41 +++---
target/s390x/interrupt.c | 9 +-
target/s390x/ioinst.c | 113 +++++++--------
target/s390x/kvm.c | 84 ++++-------
target/s390x/mem_helper.c | 35 ++---
target/s390x/misc_helper.c | 111 ++++++++------
target/s390x/mmu_helper.c | 23 ++-
target/s390x/translate.c | 191 ++++++++++++++++++++----
36 files changed, 928 insertions(+), 545 deletions(-)
--
2.13.6
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Qemu-devel] [PULL v2 46/46] s390-ccw-virtio: allow for systems larger that 7.999TB
2017-12-15 11:03 [Qemu-devel] [PULL v2 00/46] First batch of s390x patches for 2.12 Cornelia Huck
@ 2017-12-15 11:03 ` Cornelia Huck
2017-12-15 13:48 ` [Qemu-devel] [PULL v2 00/46] First batch of s390x patches for 2.12 Peter Maydell
1 sibling, 0 replies; 3+ messages in thread
From: Cornelia Huck @ 2017-12-15 11:03 UTC (permalink / raw)
To: peter.maydell
Cc: qemu-devel, qemu-s390x, rth, agraf, thuth, borntraeger, david,
Cornelia Huck
From: Christian Borntraeger <borntraeger@de.ibm.com>
KVM does not allow memory regions > KVM_MEM_MAX_NR_PAGES, basically
limiting the memory per slot to 8TB-4k. As memory slots on s390/kvm must
be a multiple of 1MB we need start a new memory region if we cross
8TB-1M.
With that (and optimistic overcommitment in the kernel) I was able to
start a 24TB guest on a 1TB system.
Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
Message-Id: <20171211122146.162430-1-borntraeger@de.ibm.com>
Reviewed-by: David Hildenbrand <david@redhat.com>
[CH: 1UL -> 1ULL in KVM_MEM_MAX_NR_PAGES; build fix on 32 bit hosts]
Signed-off-by: Cornelia Huck <cohuck@redhat.com>
---
hw/s390x/s390-virtio-ccw.c | 30 +++++++++++++++++++++++++++---
1 file changed, 27 insertions(+), 3 deletions(-)
diff --git a/hw/s390x/s390-virtio-ccw.c b/hw/s390x/s390-virtio-ccw.c
index 466e45343c..35df7e19c5 100644
--- a/hw/s390x/s390-virtio-ccw.c
+++ b/hw/s390x/s390-virtio-ccw.c
@@ -152,14 +152,38 @@ static void virtio_ccw_register_hcalls(void)
virtio_ccw_hcall_early_printk);
}
+/*
+ * KVM does only support memory slots up to KVM_MEM_MAX_NR_PAGES pages
+ * as the dirty bitmap must be managed by bitops that take an int as
+ * position indicator. If we have a guest beyond that we will split off
+ * new subregions. The split must happen on a segment boundary (1MB).
+ */
+#define KVM_MEM_MAX_NR_PAGES ((1ULL << 31) - 1)
+#define SEG_MSK (~0xfffffULL)
+#define KVM_SLOT_MAX_BYTES ((KVM_MEM_MAX_NR_PAGES * TARGET_PAGE_SIZE) & SEG_MSK)
static void s390_memory_init(ram_addr_t mem_size)
{
MemoryRegion *sysmem = get_system_memory();
- MemoryRegion *ram = g_new(MemoryRegion, 1);
+ ram_addr_t chunk, offset = 0;
+ unsigned int number = 0;
+ gchar *name;
/* allocate RAM for core */
- memory_region_allocate_system_memory(ram, NULL, "s390.ram", mem_size);
- memory_region_add_subregion(sysmem, 0, ram);
+ name = g_strdup_printf("s390.ram");
+ while (mem_size) {
+ MemoryRegion *ram = g_new(MemoryRegion, 1);
+ uint64_t size = mem_size;
+
+ /* KVM does not allow memslots >= 8 TB */
+ chunk = MIN(size, KVM_SLOT_MAX_BYTES);
+ memory_region_allocate_system_memory(ram, NULL, name, chunk);
+ memory_region_add_subregion(sysmem, offset, ram);
+ mem_size -= chunk;
+ offset += chunk;
+ g_free(name);
+ name = g_strdup_printf("s390.ram.%u", ++number);
+ }
+ g_free(name);
/* Initialize storage key device */
s390_skeys_init();
--
2.13.6
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [Qemu-devel] [PULL v2 00/46] First batch of s390x patches for 2.12
2017-12-15 11:03 [Qemu-devel] [PULL v2 00/46] First batch of s390x patches for 2.12 Cornelia Huck
2017-12-15 11:03 ` [Qemu-devel] [PULL v2 46/46] s390-ccw-virtio: allow for systems larger that 7.999TB Cornelia Huck
@ 2017-12-15 13:48 ` Peter Maydell
1 sibling, 0 replies; 3+ messages in thread
From: Peter Maydell @ 2017-12-15 13:48 UTC (permalink / raw)
To: Cornelia Huck
Cc: QEMU Developers, qemu-s390x, Richard Henderson, Alexander Graf,
Thomas Huth, Christian Borntraeger, David Hildenbrand
On 15 December 2017 at 11:03, Cornelia Huck <cohuck@redhat.com> wrote:
> The following changes since commit 0ef0583d5adceb9138bdb47494dabd1549ac5b6d:
>
> Merge remote-tracking branch 'remotes/dgilbert/tags/pull-hmp-20171214' into staging (2017-12-14 15:32:32 +0000)
>
> are available in the git repository at:
>
> git://github.com/cohuck/qemu tags/s390x-20171215-v2
>
> for you to fetch changes up to bb223055b9b327ec66e1f6d2fbaebaee0b8f3dbe:
>
> s390-ccw-virtio: allow for systems larger that 7.999TB (2017-12-15 11:54:52 +0100)
>
> ----------------------------------------------------------------
> s390x changes for 2.12:
> - Lots of tcg improvements: ccw hotplug is now working and we can run
> a Linux kernel built for z12 under tcg
> - zPCI improvements to get virtio-pci working
> - get rid of the cssid restrictions for virtual and non-virtual channel
> devices
> - we now support 8TB+ systems
> - 2.12 compat machine
> - fixes and cleanups
Applied, thanks.
-- PMM
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2017-12-15 13:48 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-12-15 11:03 [Qemu-devel] [PULL v2 00/46] First batch of s390x patches for 2.12 Cornelia Huck
2017-12-15 11:03 ` [Qemu-devel] [PULL v2 46/46] s390-ccw-virtio: allow for systems larger that 7.999TB Cornelia Huck
2017-12-15 13:48 ` [Qemu-devel] [PULL v2 00/46] First batch of s390x patches for 2.12 Peter Maydell
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).