On Wed, Dec 12, 2012 at 05:38:21PM +0100, Paolo Bonzini wrote:
> Il 12/12/2012 16:38, Michael S. Tsirkin ha scritto:
> >> > These patches fix this problem by calling qdev_reset_all when zero
> >> > is written to the status field.
> > Looks like this is a virtio-scsi thing - others don't have a hierarchy.
> 
> virtio-serial does, and is doing the same walk manually.

So just do the same.

> > Let's just stick this code in virtio_scsi_reset then?
> 
> No.
> 
> > It likely can access the scsi bus without going through virtio-pci
> > and s390 right?
> 
> Yes, it can, but it's not a good reason to do it there.
> 
> Paolo

Maybe it's obvious to you that qdev_reset_all(x)
does a soft reset and what soft reset means
for each bus type, but it is not for me,
it is in particular not well defined for classical PCI,
and you said youself the hierarchy is wrong,
disks should be under virtio-scsi.
So until we have better qdev interfaces and modeling
in virtio I think it's better to avoid relying on it
in common virtio code. You maintain and understand
virtio scsi better maybe it makes sense there.

-- 
MST

Reply via email to