From: David Hildenbrand <david@redhat.com>
To: Cornelia Huck <cohuck@redhat.com>
Cc: qemu-s390x@nongnu.org, qemu-devel@nongnu.org,
Christian Borntraeger <borntraeger@de.ibm.com>,
Richard Henderson <rth@twiddle.net>,
Alexander Graf <agraf@suse.de>, Thomas Huth <thuth@redhat.com>
Subject: Re: [Qemu-devel] [PATCH v1 for-2.12 9/9] s390x: change the QEMU cpu model to a stripped down z12
Date: Tue, 5 Dec 2017 17:34:23 +0100 [thread overview]
Message-ID: <977ac4ff-331d-ad0c-9e30-4fbb80bc539d@redhat.com> (raw)
In-Reply-To: <20171205162408.31ccdf1f.cohuck@redhat.com>
On 05.12.2017 16:24, Cornelia Huck wrote:
> On Mon, 4 Dec 2017 15:01:50 +0100
> David Hildenbrand <david@redhat.com> wrote:
>
>> We are good enough to boot upstream Linux kernels / Fedora 26/27. That
>> should be suficient for now.
>
> s/suficient/sufficient/
>
>>
>> As the QEMU CPU model is migration safe, let's add compatibility code.
>> Generate the feature list to reduce the trouble of messing things up in the
>> future.
>
> So we can mess up things effortlessly? :)
See, what I care about :P
s/trouble/chance/
>
>>
>> Signed-off-by: David Hildenbrand <david@redhat.com>
>> ---
>> hw/s390x/s390-virtio-ccw.c | 6 +++
>> target/s390x/cpu.h | 3 ++
>> target/s390x/cpu_models.c | 100 ++++++++++++++++++--------------------------
>> target/s390x/cpu_models.h | 1 +
>> target/s390x/gen-features.c | 87 ++++++++++++++++++++++++++++++++++++++
>> 5 files changed, 138 insertions(+), 59 deletions(-)
>>
>> diff --git a/hw/s390x/s390-virtio-ccw.c b/hw/s390x/s390-virtio-ccw.c
>> index a23b8aec9f..edd18b7fac 100644
>> --- a/hw/s390x/s390-virtio-ccw.c
>> +++ b/hw/s390x/s390-virtio-ccw.c
>> @@ -721,6 +721,9 @@ bool css_migration_enabled(void)
>>
>> static void ccw_machine_2_12_instance_options(MachineState *machine)
>> {
>> + const S390FeatBitmap qemu_cpu_feat = { S390_FEAT_LIST_QEMU_V2_12 };
>> +
>> + s390_set_qemu_cpu_model(0x2827, 12, 2, qemu_cpu_feat);
>
> Does this want a comment?
Yes, will add comments to both.
[...]
>> +
>> + /* TCG emulates some features that can usually not be enabled with
>> + * the emulated machine generation. Make sure they can be enabled
>> + * when using the QEMU model by adding them to full_feat. We have
>> + * to copy the definition to do that.
>> + */
>> + memcpy(&s390_qemu_cpu_def, def, sizeof(s390_qemu_cpu_def));
>> + bitmap_or(s390_qemu_cpu_def.full_feat, s390_qemu_cpu_def.full_feat,
>> + qemu_max_cpu_feat, S390_FEAT_MAX);
>> +
>
> So is this the place to e.g. enable zpci? Or does this need to go into
> the feature definitions?
It will go into target/s390x/gen-features.c under:
1. "qemu_V2_12" if you want it to always be active with "-cpu qemu"
2. "qemu_MAX" if you only want to be able to enable it via "-cpu
qemu,zpci=on"
Thanks!
--
Thanks,
David / dhildenb
next prev parent reply other threads:[~2017-12-05 16:34 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-12-04 14:01 [Qemu-devel] [PATCH v1 for-2.12 0/9] s390x/tcg: facilitites and instructions David Hildenbrand
2017-12-04 14:01 ` [Qemu-devel] [PATCH v1 for-2.12 1/9] s390x/tcg: ALSI/ALSGI are atomic with interlocked-acccess facility 1 David Hildenbrand
2017-12-04 14:01 ` [Qemu-devel] [PATCH v1 for-2.12 2/9] s390x/tcg: implement Interlocked-Access Facility 2 David Hildenbrand
2017-12-04 14:01 ` [Qemu-devel] [PATCH v1 for-2.12 3/9] s390x/tcg: wire up SET ADDRESS LIMIT David Hildenbrand
2017-12-05 14:56 ` Cornelia Huck
2017-12-05 16:24 ` David Hildenbrand
2017-12-04 14:01 ` [Qemu-devel] [PATCH v1 for-2.12 4/9] s390x/tcg: wire up SET CHANNEL MONITOR David Hildenbrand
2017-12-04 17:24 ` Cornelia Huck
2017-12-04 17:27 ` David Hildenbrand
2017-12-04 17:32 ` Cornelia Huck
2017-12-04 17:39 ` David Hildenbrand
2017-12-04 14:01 ` [Qemu-devel] [PATCH v1 for-2.12 5/9] s390x/tcg: Implement STORE CHANNEL PATH STATUS David Hildenbrand
2017-12-05 15:04 ` Cornelia Huck
2017-12-04 14:01 ` [Qemu-devel] [PATCH v1 for-2.12 6/9] s390x/tcg: Implement SIGA instruction David Hildenbrand
2017-12-04 17:29 ` Cornelia Huck
2017-12-04 14:01 ` [Qemu-devel] [PATCH v1 for-2.12 7/9] s390x/tcg: implement extract-CPU-time facility David Hildenbrand
2017-12-05 15:14 ` Cornelia Huck
2017-12-05 16:28 ` David Hildenbrand
2017-12-04 14:01 ` [Qemu-devel] [PATCH v1 for-2.12 8/9] s390x/tcg: we already implement the Set-Program-Parameter facility David Hildenbrand
2017-12-05 15:17 ` Cornelia Huck
2017-12-04 14:01 ` [Qemu-devel] [PATCH v1 for-2.12 9/9] s390x: change the QEMU cpu model to a stripped down z12 David Hildenbrand
2017-12-05 15:24 ` Cornelia Huck
2017-12-05 16:34 ` David Hildenbrand [this message]
2017-12-04 14:05 ` [Qemu-devel] [PATCH v1 for-2.12 01/10] s390x/tcg: ASI/ASGI are atomic with interlocked-acccess facility 1 David Hildenbrand
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=977ac4ff-331d-ad0c-9e30-4fbb80bc539d@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 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).