PCI Rescan Question

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,



Can someone help me understand why I need to remove my stale PCI
device files from the tree if I want to properly get my device
re-initialized after unplugging and reinserting?



For example, I turn on my system with my PCI device plugged in. All is
fine. I unplug it, plug it back in, and rescan (echo 1 >
/sys/bus/pci/devices/rescan) and end up in this state where my BAR0 is
not set, and other things are not entirely correct.



But if I do a remove (echo 1 > /sys/bus/pci/devices/xxxx/xx.x/remove)
of the port, it then properly re-initializes my device when I do a
rescan.



Why does it not suffice to simply do a rescan? Does the rescan skip
some step if it finds that the device is already in the PCI tree? It's
not as if the rescan completely skips the device if I don't do a
remove, it just doesn't do all of the initialization.



Thanks,

Kyle Gale



[Index of Archives]     [DMA Engine]     [Linux Coverity]     [Linux USB]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Greybus]

  Powered by Linux