From: David Hildenbrand <david@redhat.com>
To: Janosch Frank <frankja@linux.ibm.com>, qemu-devel@nongnu.org
Cc: borntraeger@de.ibm.com, qemu-s390x@nongnu.org, cohuck@redhat.com
Subject: Re: [PATCH v8 2/2] s390x: protvirt: Support unpack facility
Date: Tue, 10 Mar 2020 10:28:21 +0100 [thread overview]
Message-ID: <f832133b-8933-ee50-29aa-2e95dd264b3a@redhat.com> (raw)
In-Reply-To: <a7f478fa-3181-63fc-ce65-4006d64098b0@linux.ibm.com>
>>> + case S390_RESET_PV: /* Subcode 10 */
>>> + subsystem_reset();
>>> + s390_crypto_reset();
>>> +
>>> + CPU_FOREACH(t) {
>>> + if (t == cs) {
>>> + continue;
>>> + }
>>> + run_on_cpu(t, s390_do_cpu_full_reset, RUN_ON_CPU_NULL);
>>> + }
>>> + run_on_cpu(cs, s390_do_cpu_reset, RUN_ON_CPU_NULL);
>>> +
>>> + if (s390_machine_protect(ms)) {
>>> + s390_machine_inject_pv_error(cs);
>>> + /*
>>> + * Continue after the diag308 so the guest knows something
>>> + * went wrong.
>>> + */
>>> + s390_cpu_set_state(S390_CPU_STATE_OPERATING, cpu);
>>> + return;
>>
>> Didn't you want to squash in that hunk from the other patch? (I remember
>> seeing a goto)
>
> I chose to leave it this way so we don't jump around with the goto
Fine with me as long as the other patch won't touch this code anymore ;)
>>> #if !defined(CONFIG_USER_ONLY)
>>> uint32_t core_id; /* PoP "CPU address", same as cpu_index */
>>> diff --git a/target/s390x/cpu_features_def.inc.h b/target/s390x/cpu_features_def.inc.h
>>> index 31dff0d84e..60db28351d 100644
>>> --- a/target/s390x/cpu_features_def.inc.h
>>> +++ b/target/s390x/cpu_features_def.inc.h
>>> @@ -107,6 +107,7 @@ DEF_FEAT(DEFLATE_BASE, "deflate-base", STFL, 151, "Deflate-conversion facility (
>>> DEF_FEAT(VECTOR_PACKED_DECIMAL_ENH, "vxpdeh", STFL, 152, "Vector-Packed-Decimal-Enhancement Facility")
>>> DEF_FEAT(MSA_EXT_9, "msa9-base", STFL, 155, "Message-security-assist-extension-9 facility (excluding subfunctions)")
>>> DEF_FEAT(ETOKEN, "etoken", STFL, 156, "Etoken facility")
>>> +DEF_FEAT(UNPACK, "unpack", STFL, 161, "Unpack facility")
>>
>> Random thought: The naming of that facility could have been improved to
>> something that gives users/readers an idea what it's actually doing.
>
> That's the name from our specifications and with those feature bits we
> normally use the facility names from those docs, no?
> Something like "protected guest boot facility" would certainly have been
> better to understand.
Yeah, I was not talking about bad naming from the HW/FW folks for that
facility. Not your fault.
>> [...]
>>
>>> @@ -128,17 +142,31 @@ out:
>>> g_free(iplb);
>>> return;
>>> case DIAG308_STORE:
>>> + case DIAG308_PV_STORE:
>>> if (diag308_parm_check(env, r1, addr, ra, true)) {
>>> return;
>>> }
>>> - iplb = s390_ipl_get_iplb();
>>> + if (subcode == DIAG308_PV_STORE) {
>>> + iplb = s390_ipl_get_iplb_pv();
>>> + } else {
>>> + iplb = s390_ipl_get_iplb();
>>> + }
>>> if (iplb) {
>>> cpu_physical_memory_write(addr, iplb, be32_to_cpu(iplb->len));
>>> env->regs[r1 + 1] = DIAG_308_RC_OK;
>>> } else {
>>> env->regs[r1 + 1] = DIAG_308_RC_NO_CONF;
>>> }
>>> - return;
>>> + break;
>>
>> return->break is unrelated, but we do have a wild mixture already.
>
> I removed it here and in the move diag structures over SIDA patch.
> After this has been merged I can do a cleanup patch if wanted.
Whatever you prefer.
--
Thanks,
David / dhildenb
next prev parent reply other threads:[~2020-03-10 9:32 UTC|newest]
Thread overview: 45+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-03-09 11:21 [PATCH v7 00/15] s390x: Protected Virtualization support Janosch Frank
2020-03-09 11:21 ` [PATCH v7 01/15] Sync pv Janosch Frank
2020-03-09 11:21 ` [PATCH v7 02/15] s390x: protvirt: Support unpack facility Janosch Frank
2020-03-09 13:37 ` David Hildenbrand
2020-03-09 14:40 ` Christian Borntraeger
2020-03-09 14:42 ` David Hildenbrand
2020-03-10 9:27 ` Christian Borntraeger
2020-03-09 15:42 ` Janosch Frank
2020-03-09 15:48 ` David Hildenbrand
2020-03-10 8:32 ` [PATCH v8 1/2] s390x: ipl: Consolidate iplb validity check into one function Janosch Frank
2020-03-10 8:32 ` [PATCH v8 2/2] s390x: protvirt: Support unpack facility Janosch Frank
2020-03-10 9:00 ` David Hildenbrand
2020-03-10 9:23 ` Janosch Frank
2020-03-10 9:28 ` David Hildenbrand [this message]
2020-03-10 9:24 ` Christian Borntraeger
2020-03-10 8:40 ` [PATCH v8 1/2] s390x: ipl: Consolidate iplb validity check into one function David Hildenbrand
2020-03-10 9:05 ` Christian Borntraeger
2020-03-10 9:09 ` [PATCH v8] " Janosch Frank
2020-03-10 9:11 ` Christian Borntraeger
2020-03-10 9:20 ` David Hildenbrand
2020-03-10 9:21 ` Christian Borntraeger
2020-03-09 14:28 ` [PATCH v7 02/15] s390x: protvirt: Support unpack facility Viktor Mihajlovski
2020-03-09 14:46 ` Janosch Frank
2020-03-09 11:21 ` [PATCH v7 03/15] s390x: protvirt: Add migration blocker Janosch Frank
2020-03-09 13:41 ` David Hildenbrand
2020-03-09 13:51 ` Janosch Frank
2020-03-09 14:15 ` David Hildenbrand
2020-03-09 11:21 ` [PATCH v7 04/15] s390x: protvirt: Inhibit balloon when switching to protected mode Janosch Frank
2020-03-09 13:42 ` David Hildenbrand
2020-03-09 14:00 ` Janosch Frank
2020-03-09 11:21 ` [PATCH v7 05/15] s390x: protvirt: KVM intercept changes Janosch Frank
2020-03-09 11:21 ` [PATCH v7 06/15] s390x: Add SIDA memory ops Janosch Frank
2020-03-09 11:21 ` [PATCH v7 07/15] s390x: protvirt: Move STSI data over SIDAD Janosch Frank
2020-03-09 11:21 ` [PATCH v7 08/15] s390x: protvirt: SCLP interpretation Janosch Frank
2020-03-09 15:27 ` David Hildenbrand
2020-03-09 16:05 ` Janosch Frank
2020-03-10 8:42 ` [PATCH v8] " Janosch Frank
2020-03-10 9:01 ` David Hildenbrand
2020-03-09 11:22 ` [PATCH v7 09/15] s390x: protvirt: Set guest IPL PSW Janosch Frank
2020-03-09 11:22 ` [PATCH v7 10/15] s390x: protvirt: Move diag 308 data over SIDA Janosch Frank
2020-03-09 11:22 ` [PATCH v7 11/15] s390x: protvirt: Disable address checks for PV guest IO emulation Janosch Frank
2020-03-09 11:22 ` [PATCH v7 12/15] s390x: protvirt: Move IO control structures over SIDA Janosch Frank
2020-03-09 11:22 ` [PATCH v7 13/15] s390x: protvirt: Handle SIGP store status correctly Janosch Frank
2020-03-09 11:22 ` [PATCH v7 14/15] docs: Add protvirt docs Janosch Frank
2020-03-09 11:22 ` [PATCH v7 15/15] s390x: Add unpack facility feature to GA1 Janosch Frank
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=f832133b-8933-ee50-29aa-2e95dd264b3a@redhat.com \
--to=david@redhat.com \
--cc=borntraeger@de.ibm.com \
--cc=cohuck@redhat.com \
--cc=frankja@linux.ibm.com \
--cc=qemu-devel@nongnu.org \
--cc=qemu-s390x@nongnu.org \
/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).