From: David Hildenbrand <david@redhat.com>
To: Cornelia Huck <cohuck@redhat.com>
Cc: qemu-s390x@nongnu.org, qemu-devel@nongnu.org,
Richard Henderson <rth@twiddle.net>,
Alexander Graf <agraf@suse.de>,
Christian Borntraeger <borntraeger@de.ibm.com>,
Thomas Huth <thuth@redhat.com>,
Paolo Bonzini <pbonzini@redhat.com>
Subject: Re: [Qemu-devel] [PATCH RFC] s390x: refactor reset/reipl handling
Date: Mon, 23 Apr 2018 21:36:46 +0200 [thread overview]
Message-ID: <3bc9fc9c-0e05-df7b-1d5c-bf554147a51c@redhat.com> (raw)
In-Reply-To: <20180423124528.2eead1de.cohuck@redhat.com>
On 23.04.2018 12:45, Cornelia Huck wrote:
> On Wed, 18 Apr 2018 16:33:13 +0200
> David Hildenbrand <david@redhat.com> wrote:
>
>>> static void s390_ipl_class_init(ObjectClass *klass, void *data)
>>> diff --git a/hw/s390x/ipl.h b/hw/s390x/ipl.h
>>> index 0570d0ad75..102f1ea7af 100644
>>> --- a/hw/s390x/ipl.h
>>> +++ b/hw/s390x/ipl.h
>>> @@ -87,7 +87,17 @@ int s390_ipl_set_loadparm(uint8_t *loadparm);
>>> void s390_ipl_update_diag308(IplParameterBlock *iplb);
>>> void s390_ipl_prepare_cpu(S390CPU *cpu);
>>> IplParameterBlock *s390_ipl_get_iplb(void);
>>> -void s390_reipl_request(void);
>>> +
>>> +enum s390_reset {
>>> + /* default is a reset not triggered by a CPU e.g. issued by QMP */
>>> + S390_RESET_EXTERNAL = 0,
>>> + S390_RESET_REIPL,
>>> + S390_RESET_MODIFIED_CLEAR,
>>> + S390_RESET_LOAD_NORMAL,
>>> +};
>>> +void s390_ipl_reset_request(CPUState *cs, enum s390_reset reset_type);
>>> +void s390_ipl_get_reset_request(CPUState **cs, enum s390_reset *reset_type);
>>> +void s390_ipl_clear_reset_request(void);
>>>
>>> #define QIPL_ADDRESS 0xcc
>>>
>>> @@ -129,9 +139,11 @@ struct S390IPLState {
>>> bool enforce_bios;
>>> IplParameterBlock iplb;
>>> bool iplb_valid;
>>> - bool reipl_requested;
>>> bool netboot;
>>> QemuIplParameters qipl;
>>> + /* reset related properties don't have to be migrated or reset */
>>> + enum s390_reset reset_type;
>>> + CPUState *reset_cpu;
>>
>> Wondering if storing the cpu number would be nicer. Opinions?
>>
>
> Is there any difference in the number of QOM operations?
Not that it would matter much. Just another VCPU lookup by ID.
>
> Also, do you need to distinguish between 'specified cpu' and
> 'default/any cpu'? Should be deductible from the reset type, though.
>
Yes, I deduct that from the reset type.
--
Thanks,
David / dhildenb
next prev parent reply other threads:[~2018-04-23 19:37 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-04-12 19:26 [Qemu-devel] [PATCH RFC] s390x: refactor reset/reipl handling David Hildenbrand
2018-04-12 20:49 ` Paolo Bonzini
2018-04-18 14:08 ` Thomas Huth
2018-04-18 14:09 ` David Hildenbrand
2018-04-18 14:33 ` David Hildenbrand
2018-04-23 10:45 ` Cornelia Huck
2018-04-23 19:36 ` David Hildenbrand [this message]
2018-04-23 10:42 ` Cornelia Huck
2018-04-23 19:42 ` David Hildenbrand
2018-04-24 8:56 ` Christian Borntraeger
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=3bc9fc9c-0e05-df7b-1d5c-bf554147a51c@redhat.com \
--to=david@redhat.com \
--cc=agraf@suse.de \
--cc=borntraeger@de.ibm.com \
--cc=cohuck@redhat.com \
--cc=pbonzini@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).