]> www.infradead.org Git - users/jedix/linux-maple.git/commit
usb: cdns3-ti: run HW init at resume() if HW was reset
authorThéo Lebrun <theo.lebrun@bootlin.com>
Wed, 5 Feb 2025 17:36:51 +0000 (18:36 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 14 Mar 2025 08:18:02 +0000 (09:18 +0100)
commit9925aa4b025e46cffc9fc98c5fb28a4a303a739b
tree59023b7be62cbeb7d119e472823b61396e0c8fca
parent24346dc29174632237ad3f6f920fbe0765061cf9
usb: cdns3-ti: run HW init at resume() if HW was reset

At runtime_resume(), read the W1 (Wrapper Register 1) register to detect
if an hardware reset occurred. If it did, run the hardware init sequence.

This callback will be called at system-wide resume. Previously, if a
reset occurred during suspend, we would crash. The wrapper config had
not been written, leading to invalid register accesses inside cdns3.

Signed-off-by: Théo Lebrun <theo.lebrun@bootlin.com>
Link: https://lore.kernel.org/r/20250205-s2r-cdns-v7-6-13658a271c3c@bootlin.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/cdns3/cdns3-ti.c