From: Cornelia Huck <cohuck@redhat.com>
To: Claudio Imbrenda <imbrenda@linux.vnet.ibm.com>
Cc: qemu-s390x@nongnu.org, qemu-devel@nongnu.org, borntraeger@de.ibm.com
Subject: Re: [Qemu-devel] [PATCH v2 1/3] s390x/sclp: proper support of larger send and receive masks
Date: Fri, 23 Feb 2018 11:31:46 +0100 [thread overview]
Message-ID: <20180223113146.5121ca64.cohuck@redhat.com> (raw)
In-Reply-To: <1519316579-7162-2-git-send-email-imbrenda@linux.vnet.ibm.com>
On Thu, 22 Feb 2018 17:22:57 +0100
Claudio Imbrenda <imbrenda@linux.vnet.ibm.com> wrote:
> Until 67915de9f0383ccf4a ("s390x/event-facility: variable-length event masks")
> we only supported sclp event masks of size exactly 4 bytes, even though
s/of size/of a size of/
> the archiecture allows the guests to set up sclp event masks from 1 to
s/archiecture/architecture/
> 1021 bytes in length.
> After that patch, the behaviour was almost compliant, but some issues
> were still remaining, in particular regarding the handling of selective
> reads and migration.
>
> When setting the sclp event mask, a mask size is also specified. Until
> now we only considered the size in order to decide which bits to save
> in the internal state. On the other hand, when a guest performs a
> selective read, it sends a mask, but it does not specify a size; the
> implied size is the size of the last mask that has been set.
>
> Specifying bits in the mask of selective read that are not available in
> the internal mask should return an error, and bits past the end of the
> mask should obviously be ignored. This can only be achieved by keeping
> track of the lenght of the mask.
>
> The mask length is thus now part of the internal state that needs to be
> migrated.
>
> This patch fixes the handling of selective reads, whose size will now
> match the length of the event mask, as per architecture.
>
> While the default behaviour is to be compliant with the architecture,
> when using older machine models the old broken behaviour is selected
> (allowing only masks of size exactly 4), in order to be able to migrate
> toward older versions.
>
> Fixes: 67915de9f0383ccf4a ("s390x/event-facility: variable-length event masks")
> Signed-off-by: Claudio Imbrenda <imbrenda@linux.vnet.ibm.com>
> ---
> hw/s390x/event-facility.c | 91 +++++++++++++++++++++++++++++++++++++++-------
> hw/s390x/s390-virtio-ccw.c | 8 +++-
> 2 files changed, 85 insertions(+), 14 deletions(-)
Looks reasonable.
next prev parent reply other threads:[~2018-02-23 10:32 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-02-22 16:22 [Qemu-devel] [PATCH v2 0/3] s390x/sclp: 64 bit event masks Claudio Imbrenda
2018-02-22 16:22 ` [Qemu-devel] [PATCH v2 1/3] s390x/sclp: proper support of larger send and receive masks Claudio Imbrenda
2018-02-23 10:31 ` Cornelia Huck [this message]
2018-02-23 11:18 ` Claudio Imbrenda
2018-02-22 16:22 ` [Qemu-devel] [PATCH v2 2/3] s390x/sclp: clean up sclp masks Claudio Imbrenda
2018-02-22 16:22 ` [Qemu-devel] [PATCH v2 3/3] s390x/sclp: extend SCLP event masks to 64 bits Claudio Imbrenda
2018-02-23 10:37 ` [Qemu-devel] [PATCH v2 0/3] s390x/sclp: 64 bit event masks Cornelia Huck
2018-02-23 11:19 ` Claudio Imbrenda
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=20180223113146.5121ca64.cohuck@redhat.com \
--to=cohuck@redhat.com \
--cc=borntraeger@de.ibm.com \
--cc=imbrenda@linux.vnet.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 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.