From: David Hildenbrand <david@redhat.com>
To: qemu-s390x@nongnu.org
Cc: qemu-devel@nongnu.org, Richard Henderson <rth@twiddle.net>,
Alexander Graf <agraf@suse.de>, Cornelia Huck <cohuck@redhat.com>,
Christian Borntraeger <borntraeger@de.ibm.com>,
Thomas Huth <thuth@redhat.com>,
David Hildenbrand <david@redhat.com>
Subject: [Qemu-devel] [PATCH v3 0/9] s390x: TOD refactoring + TCG CPU hotplug support
Date: Mon, 25 Jun 2018 13:53:43 +0200 [thread overview]
Message-ID: <20180625115352.6889-1-david@redhat.com> (raw)
The TOD in TCG is not handled correctly:
- each CPU has its own TOD based on CPU creation time vs. a system TOD
- TOD is not migrated
- TOD timer is not restarted during migration
- CKC interrupts/TOD timer is not cleared when resetting the CKC
This (and a cpu creation problem for single threaded TCG) currently made
CPU hotplug under TCG not work. Now it's working
The third patch also refactors TOD handling for KVM (moved into a new
TOD device). The second patch makes sure that we can use a const pointer
for the new TOD clock struct.
v2 -> v3:
- added "s390x/tcg: avoid overflows in time2tod/tod2time"
- added "s390x/kvm: pass values instead of pointers to kvm_s390_set_clock_*()"
- "s390x/tod: factor out TOD into separate device"
-- Use "const" for parameters in function definitions
-- Use "s390-tod-qemu" and "s390-tod-kvm" as type names
-- Drop hotpluggable=false
- "s390x/tcg: properly implement the TOD"
-- s390_get_tod() -> s390_get_todstate()
-- use error_abort
- "s390x/tcg: SET CLOCK COMPARATOR can clear CKC interrupts"
-- Add a comment for the -1ULL check
- "s390x/tcg: implement SET CLOCK"
-- use error_abort
- "s390x/tcg: fix CPU hotplug with single-threaded TCG"
-- add a comment describing the run_on_cpu() difference
v1 -> v2:
- "s390x/tcg: properly implement the TOD"
-- introduce "tcg_s390x.h" similar to "kvm_s390x.h"
-- dropped one unnecessary include introduction
- "s390x/tcg: rearm the CKC timer during migration"
-- introduce "tcg-stub.c" similar to "kvm-stub.c"
David Hildenbrand (9):
s390x/tcg: avoid overflows in time2tod/tod2time
s390x/kvm: pass values instead of pointers to kvm_s390_set_clock_*()
s390x/tod: factor out TOD into separate device
s390x/tcg: drop tod_basetime
s390x/tcg: properly implement the TOD
s390x/tcg: SET CLOCK COMPARATOR can clear CKC interrupts
s390x/tcg: implement SET CLOCK
s390x/tcg: rearm the CKC timer during migration
s390x/tcg: fix CPU hotplug with single-threaded TCG
hw/s390x/Makefile.objs | 3 +
hw/s390x/s390-virtio-ccw.c | 57 +---------------
hw/s390x/tod-kvm.c | 64 ++++++++++++++++++
hw/s390x/tod-qemu.c | 87 +++++++++++++++++++++++++
hw/s390x/tod.c | 130 +++++++++++++++++++++++++++++++++++++
include/hw/s390x/tod.h | 65 +++++++++++++++++++
target/s390x/Makefile.objs | 1 +
target/s390x/cpu.c | 57 ++++------------
target/s390x/cpu.h | 4 --
target/s390x/helper.h | 1 +
target/s390x/insn-data.def | 3 +-
target/s390x/internal.h | 15 -----
target/s390x/kvm-stub.c | 4 +-
target/s390x/kvm.c | 12 ++--
target/s390x/kvm_s390x.h | 6 +-
target/s390x/machine.c | 6 ++
target/s390x/misc_helper.c | 55 ++++++++++++++--
target/s390x/tcg-stub.c | 20 ++++++
target/s390x/tcg_s390x.h | 18 +++++
target/s390x/translate.c | 9 +++
20 files changed, 480 insertions(+), 137 deletions(-)
create mode 100644 hw/s390x/tod-kvm.c
create mode 100644 hw/s390x/tod-qemu.c
create mode 100644 hw/s390x/tod.c
create mode 100644 include/hw/s390x/tod.h
create mode 100644 target/s390x/tcg-stub.c
create mode 100644 target/s390x/tcg_s390x.h
--
2.17.1
next reply other threads:[~2018-06-25 11:54 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-06-25 11:53 David Hildenbrand [this message]
2018-06-25 11:53 ` [Qemu-devel] [PATCH v3 1/9] s390x/tcg: avoid overflows in time2tod/tod2time David Hildenbrand
2018-06-26 10:04 ` Thomas Huth
2018-06-25 11:53 ` [Qemu-devel] [PATCH v3 2/9] s390x/kvm: pass values instead of pointers to kvm_s390_set_clock_*() David Hildenbrand
2018-06-25 15:50 ` Cornelia Huck
2018-06-25 15:54 ` David Hildenbrand
2018-06-25 16:03 ` Cornelia Huck
2018-06-26 9:54 ` [Qemu-devel] [qemu-s390x] " David Hildenbrand
2018-06-26 9:57 ` Cornelia Huck
2018-06-25 11:53 ` [Qemu-devel] [PATCH v3 3/9] s390x/tod: factor out TOD into separate device David Hildenbrand
2018-06-25 11:53 ` [Qemu-devel] [PATCH v3 4/9] s390x/tcg: drop tod_basetime David Hildenbrand
2018-06-25 11:53 ` [Qemu-devel] [PATCH v3 5/9] s390x/tcg: properly implement the TOD David Hildenbrand
2018-06-26 10:34 ` [Qemu-devel] [qemu-s390x] " Thomas Huth
2018-06-26 12:06 ` David Hildenbrand
2018-06-26 12:27 ` Cornelia Huck
2018-06-26 12:28 ` David Hildenbrand
2018-06-26 12:29 ` Cornelia Huck
2018-06-25 11:53 ` [Qemu-devel] [PATCH v3 6/9] s390x/tcg: SET CLOCK COMPARATOR can clear CKC interrupts David Hildenbrand
2018-06-26 12:30 ` Cornelia Huck
2018-06-27 11:15 ` [Qemu-devel] [qemu-s390x] " Thomas Huth
2018-06-25 11:53 ` [Qemu-devel] [PATCH v3 7/9] s390x/tcg: implement SET CLOCK David Hildenbrand
2018-06-27 11:17 ` [Qemu-devel] [qemu-s390x] " Thomas Huth
2018-06-25 11:53 ` [Qemu-devel] [PATCH v3 8/9] s390x/tcg: rearm the CKC timer during migration David Hildenbrand
2018-06-25 11:53 ` [Qemu-devel] [PATCH v3 9/9] s390x/tcg: fix CPU hotplug with single-threaded TCG David Hildenbrand
2018-06-26 12:33 ` Cornelia Huck
2018-06-27 11:19 ` [Qemu-devel] [qemu-s390x] " Thomas Huth
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20180625115352.6889-1-david@redhat.com \
--to=david@redhat.com \
--cc=agraf@suse.de \
--cc=borntraeger@de.ibm.com \
--cc=cohuck@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=qemu-s390x@nongnu.org \
--cc=rth@twiddle.net \
--cc=thuth@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.