Skip to contentSkip to conversation

virtio fixes

GIT PULL Rusty Russell 1 participant 1 message Jun 23, 2010

lore
Share & tools
lore

Rusty Russell

author Acked-by Amit Shah Tested-by Vivek Goyal Acked-by Jesse Barnes
#0 lore raw

(There are two net fixes which depend on this which will go via DaveM, so
please pull soon).

The following changes since commit 7e27d6e778cd87b6f2415515d7127eba53fe5d02:
Linus Torvalds (1):

        Linux 2.6.35-rc3

are available in the git repository at:

ssh://master.kernel.org/pub/scm/linux/kernel/git/rusty/linux-2.6.git virtio

Michael S. Tsirkin (2):
virtio: return ENOMEM on out of memory
virtio-pci: disable msi at startup

 drivers/pci/pci.c            |    1 +
 drivers/virtio/virtio_pci.c  |    3 +++
 drivers/virtio/virtio_ring.c |    2 +-
 3 files changed, 5 insertions(+), 1 deletions(-)

commit 686d363786a53ed28ee875b84ef24e6d5126ef6f

Author: Michael S. Tsirkin <[email protected]>
Date:   Thu Jun 10 18:16:11 2010 +0300

virtio: return ENOMEM on out of memory

add_buf returns ring size on out of memory,
this is not what devices expect.

 drivers/virtio/virtio_ring.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

commit b03214d559471359e2a85ae256686381d0672f29

Author: Michael S. Tsirkin <[email protected]>
Date:   Wed Jun 23 22:49:06 2010 -0600

virtio-pci: disable msi at startup

virtio-pci resets the device at startup by writing to the status register, but this does not clear the pci config space, specifically msi enable status which affects register layout.

This breaks things like kdump when they try to use e.g. virtio-blk.

Fix by forcing msi off at startup. Since pci.c already has a routine to do this, we export and use it instead of duplicating code.

 drivers/pci/pci.c           |    1 +
 drivers/virtio/virtio_pci.c |    3 +++
 2 files changed, 4 insertions(+), 0 deletions(-)