usb: musb: restore INDEX register in resume path
authorAjay Kumar Gupta <ajay.gupta@ti.com>
Fri, 8 Jul 2011 09:36:13 +0000 (15:06 +0530)
committerGreg Kroah-Hartman <gregkh@suse.de>
Fri, 5 Aug 2011 04:58:32 +0000 (21:58 -0700)
commit 3c5fec75e121b21a2eb35e5a6b44291509abba6f upstream.

Restoring the missing INDEX register value in musb_restore_context().
Without this suspend resume functionality is broken with offmode
enabled.

Acked-by: Anand Gadiyar <gadiyar@ti.com>
Signed-off-by: Ajay Kumar Gupta <ajay.gupta@ti.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/usb/musb/musb_core.c

index c71b0372786e00482bf2f9fadf4bf6293721d27f..dce7182e1dfeabe59df62b9e7ae3d38e2cb806a3 100644 (file)
@@ -2329,6 +2329,7 @@ static void musb_restore_context(struct musb *musb)
                                musb->context.index_regs[i].rxhubport);
                }
        }
+       musb_writeb(musb_base, MUSB_INDEX, musb->context.index);
 }
 
 static int musb_suspend(struct device *dev)