]> git.baikalelectronics.ru Git - kernel.git/commit
r8152: Fix a deadlock by doubly PM resume
authorTakashi Iwai <tiwai@suse.de>
Wed, 14 Jul 2021 17:00:22 +0000 (19:00 +0200)
committerDavid S. Miller <davem@davemloft.net>
Wed, 14 Jul 2021 21:57:55 +0000 (14:57 -0700)
commit1b576d5c6f53ad717cbf5ccacbb3ee078a2a1bc5
treef72f2491cc4b8ed9c1153537e1b15d9a8a8ade10
parenta813f860dd51b161cc9f5d9eadef06c8922fbce3
r8152: Fix a deadlock by doubly PM resume

r8152 driver sets up the MAC address at reset-resume, while
rtl8152_set_mac_address() has the temporary autopm get/put.  This may
lead to a deadlock as the PM lock has been already taken for the
execution of the runtime PM callback.

This patch adds the workaround to avoid the superfluous autpm when
called from rtl8152_reset_resume().

Link: https://bugzilla.suse.com/show_bug.cgi?id=1186194
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/usb/r8152.c