* [PULL 0/1] vfio-ccw fix for 5.3
@ 2019-07-05 6:21 Cornelia Huck
2019-07-05 6:21 ` [PULL 1/1] vfio-ccw: Fix the conversion of Format-0 CCWs to Format-1 Cornelia Huck
2019-07-05 12:20 ` [PULL 0/1] vfio-ccw fix for 5.3 Vasily Gorbik
0 siblings, 2 replies; 3+ messages in thread
From: Cornelia Huck @ 2019-07-05 6:21 UTC (permalink / raw)
To: Heiko Carstens, Vasily Gorbik, Christian Borntraeger
Cc: Farhan Ali, Eric Farman, Halil Pasic, linux-s390, kvm,
Cornelia Huck
The following changes since commit 05f31e3bf6b34fe6e4922868d132f6455f81d5bf:
s390: ap: kvm: Enable PQAP/AQIC facility for the guest (2019-07-02 16:00:28 +0200)
are available in the Git repository at:
https://git.kernel.org/pub/scm/linux/kernel/git/kvms390/vfio-ccw.git tags/vfio-ccw-20190705
for you to fetch changes up to c382cbc6dbf513d73cf896ad43a3789ad42c2e2f:
vfio-ccw: Fix the conversion of Format-0 CCWs to Format-1 (2019-07-05 07:58:53 +0200)
----------------------------------------------------------------
Fix a bug introduced in the refactoring.
----------------------------------------------------------------
Eric Farman (1):
vfio-ccw: Fix the conversion of Format-0 CCWs to Format-1
drivers/s390/cio/vfio_ccw_cp.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--
2.20.1
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PULL 1/1] vfio-ccw: Fix the conversion of Format-0 CCWs to Format-1
2019-07-05 6:21 [PULL 0/1] vfio-ccw fix for 5.3 Cornelia Huck
@ 2019-07-05 6:21 ` Cornelia Huck
2019-07-05 12:20 ` [PULL 0/1] vfio-ccw fix for 5.3 Vasily Gorbik
1 sibling, 0 replies; 3+ messages in thread
From: Cornelia Huck @ 2019-07-05 6:21 UTC (permalink / raw)
To: Heiko Carstens, Vasily Gorbik, Christian Borntraeger
Cc: Farhan Ali, Eric Farman, Halil Pasic, linux-s390, kvm,
Cornelia Huck
From: Eric Farman <farman@linux.ibm.com>
When processing Format-0 CCWs, we use the "len" variable as the
number of CCWs to convert to Format-1. But that variable
contains zero here, and is not a meaningful CCW count until
ccwchain_calc_length() returns. Since that routine requires and
expects Format-1 CCWs to identify the chaining behavior, the
format conversion must be done first.
Convert the 2KB we copied even if it's more than we need.
Fixes: 7f8e89a8f2fd ("vfio-ccw: Factor out the ccw0-to-ccw1 transition")
Reported-by: Farhan Ali <alifm@linux.ibm.com>
Signed-off-by: Eric Farman <farman@linux.ibm.com>
Reviewed-by: Cornelia Huck <cohuck@redhat.com>
Message-Id: <20190702180928.18113-1-farman@linux.ibm.com>
Signed-off-by: Cornelia Huck <cohuck@redhat.com>
---
drivers/s390/cio/vfio_ccw_cp.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/s390/cio/vfio_ccw_cp.c b/drivers/s390/cio/vfio_ccw_cp.c
index a7b9dfd5b464..1d4c893ead23 100644
--- a/drivers/s390/cio/vfio_ccw_cp.c
+++ b/drivers/s390/cio/vfio_ccw_cp.c
@@ -431,7 +431,7 @@ static int ccwchain_handle_ccw(u32 cda, struct channel_program *cp)
/* Convert any Format-0 CCWs to Format-1 */
if (!cp->orb.cmd.fmt)
- convert_ccw0_to_ccw1(cp->guest_cp, len);
+ convert_ccw0_to_ccw1(cp->guest_cp, CCWCHAIN_LEN_MAX);
/* Count the CCWs in the current chain */
len = ccwchain_calc_length(cda, cp);
--
2.20.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PULL 0/1] vfio-ccw fix for 5.3
2019-07-05 6:21 [PULL 0/1] vfio-ccw fix for 5.3 Cornelia Huck
2019-07-05 6:21 ` [PULL 1/1] vfio-ccw: Fix the conversion of Format-0 CCWs to Format-1 Cornelia Huck
@ 2019-07-05 12:20 ` Vasily Gorbik
1 sibling, 0 replies; 3+ messages in thread
From: Vasily Gorbik @ 2019-07-05 12:20 UTC (permalink / raw)
To: Cornelia Huck
Cc: Heiko Carstens, Vasily Gorbik, Christian Borntraeger, Farhan Ali,
Eric Farman, Halil Pasic, linux-s390, kvm
On Fri, Jul 05, 2019 at 08:21:31AM +0200, Cornelia Huck wrote:
> The following changes since commit 05f31e3bf6b34fe6e4922868d132f6455f81d5bf:
>
> s390: ap: kvm: Enable PQAP/AQIC facility for the guest (2019-07-02 16:00:28 +0200)
>
> are available in the Git repository at:
>
> https://git.kernel.org/pub/scm/linux/kernel/git/kvms390/vfio-ccw.git tags/vfio-ccw-20190705
>
> for you to fetch changes up to c382cbc6dbf513d73cf896ad43a3789ad42c2e2f:
>
> vfio-ccw: Fix the conversion of Format-0 CCWs to Format-1 (2019-07-05 07:58:53 +0200)
>
> ----------------------------------------------------------------
> Fix a bug introduced in the refactoring.
>
> ----------------------------------------------------------------
>
> Eric Farman (1):
> vfio-ccw: Fix the conversion of Format-0 CCWs to Format-1
>
> drivers/s390/cio/vfio_ccw_cp.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> --
> 2.20.1
>
Applied, thanks.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2019-07-05 12:20 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-07-05 6:21 [PULL 0/1] vfio-ccw fix for 5.3 Cornelia Huck
2019-07-05 6:21 ` [PULL 1/1] vfio-ccw: Fix the conversion of Format-0 CCWs to Format-1 Cornelia Huck
2019-07-05 12:20 ` [PULL 0/1] vfio-ccw fix for 5.3 Vasily Gorbik
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox