diff options
author | Artur Petrosyan <[email protected]> | 2021-04-16 16:48:26 +0400 |
---|---|---|
committer | Greg Kroah-Hartman <[email protected]> | 2021-04-22 11:55:34 +0200 |
commit | a94f01814be4fb46fb89c08209f808b665182763 (patch) | |
tree | e0cc5dd70203d5114584524908fd8666347a782c /lib/mpi/mpi-inline.h | |
parent | ae0da4fd225804a2c5c60a03b16fcf7d930d8581 (diff) |
usb: dwc2: Add exit hibernation mode before removing drive
When dwc2 core is in hibernation mode loading
driver again causes driver fail. Because in
that mode registers are not accessible.
In order to exit from hibernation checking
dwc2 core power saving state in "dwc2_driver_remove()"
function. If core is in hibernation, then checking the
operational mode of the driver. To check whether dwc2 core
is operating in host mode or device mode there is one way
which is retrieving the backup value of "gotgctl" and compare
the "CurMod" value. If previously core entered hibernation
in host mode then the exit is performed for host if not then
exit is performed for device mode. The introduced checking
is because in hibernation state all registers are not
accessible.
Reported-by: kernel test robot <[email protected]>
Reported-by: Dan Carpenter <[email protected]>
Acked-by: Minas Harutyunyan <[email protected]>
Signed-off-by: Artur Petrosyan <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Diffstat (limited to 'lib/mpi/mpi-inline.h')
0 files changed, 0 insertions, 0 deletions