lkml.org 
[lkml]   [2011]   [Aug]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Broken pci_block_user_cfg_access interface
On 2011-08-25 20:19, Michael S. Tsirkin wrote:
> On Thu, Aug 25, 2011 at 03:06:01PM +0200, Jan Kiszka wrote:
>>> I took a look at the sysfs triggered pci reset function and don't see any way
>>> that the controlling device driver ever gets to be involved in this reset.
>>> If code outside the ipr driver were to reset the adapter, the adapter firmware
>>> would be left in an uninitialized state and until scsi core starts timing
>>> out ops and driving EH, the card would be unusable. I can't imagine the
>>> ipr driver is unique in this.
>>
>> Right, that's why a PCI core service is needed for coordination.
>>
>> Jan
>
> But why do we want to trigger reset through sysfs while the
> driver runs?

A perfectly valid race conditions are created by KVM and VFIO: shared
IRQ handler is triggered while the user space part wants to reset the
assigned device. I'm quite sure that this how I first caused this bug to
show up (it triggered for an assigned device with a shared busy IRQ line
during QEMU startup, ie. the initial guest reset).

Jan

[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2011-08-25 20:55    [from the cache]
©2003-2014 Jasper Spaans. Advertise on this site