]> git.baikalelectronics.ru Git - kernel.git/commit
r8152: adjust the settings of ups flags
authorHayes Wang <hayeswang@realtek.com>
Thu, 5 Sep 2019 02:46:20 +0000 (10:46 +0800)
committerDavid S. Miller <davem@davemloft.net>
Thu, 5 Sep 2019 10:41:11 +0000 (12:41 +0200)
commitee8cd3aa7f5faaab38e886eb8fa5d79fde0a816d
tree1702ed64d1d5a2703d1ee63b1b0b3645ad4e8e9e
parent03ed63232d4f0196478c1bfe4db9a7fc6320dd1c
r8152: adjust the settings of ups flags

The UPS feature only works for runtime suspend, so UPS flags only
need to be set before enabling runtime suspend. Therefore, I create
a struct to record relative information, and use it before runtime
suspend.

All chips could record such information, even though not all of
them support the feature of UPS. Then, some functions could be
combined.

Signed-off-by: Hayes Wang <hayeswang@realtek.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/usb/r8152.c