This is work in progress, I intend to merge the bbswitch_dev code into
the main module. Some comments in README and bbswitch.c might be stale.
Create a PCI driver such that runtime PM works. Without a bound driver,
the kernel assumes that the device is D0 state during suspend (which
therefore needs the notifier hack in bbswitch) but more importantly, it
will prevent the PCIe port from going to sleep in Linux v4.7.
Currently I use this to debug an infinite loop on my Clevo P651RA
laptop, it can be loaded as follows:
make modname=bbswitch_dev
insmod bbswitch_dev.ko
echo > /sys/bus/pci/drivers/bbswitch/new_id 10de 13d9
Needs Mika's pci/pm series ("PCI: Put PCIe ports into D3 during
suspend"), qeued for v4.7 via
https://git.kernel.org/cgit/linux/kernel/git/helgaas/pci.git/commit/?h=pci/pm
9 years ago
Proudly self-hosted by Cole Deck. Fast loading powered by Turbo.