On Wed, Aug 27, 2025 at 06:21:28AM -0400, Michael S. Tsirkin wrote:
> On Tue, Aug 26, 2025 at 06:52:11PM +0000, Parav Pandit wrote:
> > > > > If it does not, and a user pull out the working device, how does
> > > > > your patch help?
> > > > >
> > > > A driver must tell that it will not follow broken ancient behaviour and 
> > > > at that
> > > point device would stop its ancient backward compatibility mode.
> > > 
> > > 
> > > 
> > > I don't know what is "ancient backward compatibility mode".
> > > 
> > Let me explain.
> > Sadly, CSPs virtio pci device implementation is done such a way that, it 
> > works with ancient Linux kernel which does not have commit 43bb40c5b9265.
> 
> 
> OK we are getting new information here.
> 
> So let me summarize. There's a virtual system that pretends, to the
> guest, that device was removed by surprise removal, but actually
> device is there and is still doing DMA.
> Is that a fair summary?

If that is the case, the thing to do would be to try and detect the fake
removal and then work with device as usual - device not doing DMA
after removal is pretty fundamental, after all.

For example, how about reading device control+status?

If we get all ones device has been removed
If we get 0 in bus master: device has been removed but re-inserted
Anything else is a fake removal

Hmm?



> -- 
> MST


Reply via email to