On Mon, Jun 25, 2018 at 04:27:37PM +0530, Hari Vyas wrote: > This issue is happening with multiple times device removal and > rescan from sysfs. Card is not removed physically. > Is_added bit is set after device attach which probe nvme driver. > NVMe driver starts one workqueue and that one is calling pci_set_master() > to set is_busmaster bit. > With multiple times device removal and rescan from sysfs, race > condition is observed and is_added bit is over-written to 0 from workqueue > started by NVMe driver. Could you add a dump_stack() to pci_bus_add_device() and pci_stop_dev() where the is_added bit is modified, reproduce the issue and attach the resulting dmesg output to a newly opened bug on bugzilla.kernel.org? Thanks, Lukas