Linux KVM/arm64 development list
 help / color / mirror / Atom feed
From: Julien Thierry <julien.thierry@arm.com>
To: Gerd Hoffmann <kraxel@redhat.com>
Cc: will.deacon@arm.com, kvmarm@lists.cs.columbia.edu, kvm@vger.kernel.org
Subject: Re: [PATCH kvmtool 00/13] Implement reset of virtio devices
Date: Wed, 5 Dec 2018 09:10:33 +0000	[thread overview]
Message-ID: <8cc53cd8-1ab3-d7e1-6f21-e40a0447a0fd@arm.com> (raw)
In-Reply-To: <20181205082111.j6vxu7k7daxhgurw@sirius.home.kraxel.org>



On 05/12/18 08:21, Gerd Hoffmann wrote:
> On Tue, Dec 04, 2018 at 11:08:33AM +0000, Julien Thierry wrote:
>> Hi,
>>
>> This series was developped by Jean-Philippe and is needed for a series
>> I'll be posting shortly after to load firmwares on arm kvmtool.
>>
>> Currently, when a guest tries to reset a device, a lot of ressources
>> aren't reset (threads keep running, virtio queue keep their state, etc).
>>
>> When the guest only does the reset to initialize the device and there
>> were no previous users, there is no noticeable issue. But when a guest
>> has a firmare + Linux, if the firmware uses a virtio device, Linux will
>> fail to probe that device.
>>
>> This series aim to properly reset the virtio resources when the guests
>> requests it.
>>
>> Reset of net vhost is unsupported for now.
>>
>> Patch 1 is a bug fix on ioeventfd
>> Patch 2-6 provide the core support so devices can implement their reset
>> Patch 7-13 implements the reset for the various virtio devices
> 
> Fails to build:
> 
> kraxel@sirius ~/projects/kvmtool (virtio)# make 
> Makefile:323: Skipping optional libraries: vncserver
>   CC       virtio/core.o
> In file included from virtio/core.c:8:0:
> virtio/core.c: In function ‘virtio_notify_status’:
> include/kvm/virtio.h:37:3: error: ‘VIRTIO_CONFIG_S_NEEDS_RESET’
> undeclared (first use in this function)
>    VIRTIO_CONFIG_S_NEEDS_RESET | \
>    ^
> virtio/core.c:232:19: note: in expansion of macro ‘VIRTIO_CONFIG_S_MASK’
>   vdev->status &= ~VIRTIO_CONFIG_S_MASK;
> 
> Yes, it is an older machine (rhel-7), VIRTIO_CONFIG_S_NEEDS_RESET isn't
> in the system headers (IIRC this bit was added with virtio-1.0).
> 

Thanks for reporting the issue. I think this series was initially
developed with the intent of supporting virtio-1.0 but then reset and
virtio-1.0 were split into two series.

I think here I can just remove that bit from the config mask while
virtio-1.0 is not supported, and things should work.

Thanks,

-- 
Julien Thierry
_______________________________________________
kvmarm mailing list
kvmarm@lists.cs.columbia.edu
https://lists.cs.columbia.edu/mailman/listinfo/kvmarm

  reply	other threads:[~2018-12-05  9:10 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-12-04 11:08 [PATCH kvmtool 00/13] Implement reset of virtio devices Julien Thierry
2018-12-04 11:08 ` [PATCH kvmtool 01/13] ioeventfd: Fix removal of ioeventfd Julien Thierry
2018-12-04 11:08 ` [PATCH kvmtool 02/13] virtio: Implement notify_status Julien Thierry
2018-12-04 11:08 ` [PATCH kvmtool 03/13] virtio: Add get_vq_count() callback Julien Thierry
2018-12-04 11:08 ` [PATCH kvmtool 04/13] virtio: Add get_vq() callback Julien Thierry
2018-12-04 11:08 ` [PATCH kvmtool 05/13] virtio: Add exit_vq() callback Julien Thierry
2018-12-04 11:08 ` [PATCH kvmtool 06/13] virtio: Add reset() callback Julien Thierry
2018-12-04 11:08 ` [PATCH kvmtool 07/13] net/uip: Add exit function Julien Thierry
2018-12-04 11:08 ` [PATCH kvmtool 08/13] virtio/net: Clean virtqueue state Julien Thierry
2018-12-04 11:08 ` [PATCH kvmtool 09/13] virtio/net: Implement device and virtqueue reset Julien Thierry
2018-12-04 11:08 ` [PATCH kvmtool 10/13] virtio/blk: Reset virtqueue Julien Thierry
2018-12-04 11:08 ` [PATCH kvmtool 11/13] threadpool: Add cancel() function Julien Thierry
2018-12-04 11:08 ` [PATCH kvmtool 12/13] virtio/p9: Implement reset Julien Thierry
2018-12-04 11:08 ` [PATCH kvmtool 13/13] virtio/console: " Julien Thierry
2018-12-05  8:21 ` [PATCH kvmtool 00/13] Implement reset of virtio devices Gerd Hoffmann
2018-12-05  9:10   ` Julien Thierry [this message]
2018-12-05 10:09     ` Gerd Hoffmann

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=8cc53cd8-1ab3-d7e1-6f21-e40a0447a0fd@arm.com \
    --to=julien.thierry@arm.com \
    --cc=kraxel@redhat.com \
    --cc=kvm@vger.kernel.org \
    --cc=kvmarm@lists.cs.columbia.edu \
    --cc=will.deacon@arm.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