]> git.baikalelectronics.ru Git - kernel.git/commit
realtek/8139too: use generic power management
authorVaibhav Gupta <vaibhavgupta40@gmail.com>
Mon, 18 May 2020 15:02:13 +0000 (20:32 +0530)
committerDavid S. Miller <davem@davemloft.net>
Tue, 19 May 2020 22:32:24 +0000 (15:32 -0700)
commit64ac278893352498d09e14258d2f8e08685570da
tree7b4aebc92378fb8309f3caa5d7d6957e0a3f8e9a
parent1987d9a43e408fa340093f0ae47ae81cf7d579e6
realtek/8139too: use generic power management

compile-tested only

With legacy PM hooks, it was the responsibility
of a driver to manage PCI states and also
device's power state. The generic approach is
to let PCI core handle the work.

PCI core passes "struct device*" as an argument
to the .suspend() and .resume() callbacks. As
these callabcks work with "struct net_device*",
extract it from "struct device*" using
dev_get_drv_data().

Signed-off-by: Vaibhav Gupta <vaibhavgupta40@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/realtek/8139too.c