usb: xhci: tegra: enable MC FLUSH of partition before ELPG
authorAjay Gupta <ajayg@nvidia.com>
Sat, 2 Mar 2013 01:02:58 +0000 (17:02 -0800)
committerMandar Padmawar <mpadmawar@nvidia.com>
Thu, 14 Mar 2013 14:08:06 +0000 (07:08 -0700)
commit8294bc952cb72254a0d867eeb148b0b2ad2002e6
tree53828dd3ce979061528d050395da83fab1a08c22
parent32251b6a54e47241ba3e8f5844947d9e4c07991d
usb: xhci: tegra: enable MC FLUSH of partition before ELPG

The partition client maintains credits for requests to MC. At the time of
ELPG entry, if there are any outstanding requests before the partition reset
is asserted, the credits are returned from MC at the time of ELPG exit after
the reset is released. This will result in overflow of credits and either cause
deadlock/lead to undesirable side effects in all future transactions.

In order to avoid this, SW needs to assert a hot reset to the PC which will
send out a FLUSH_DONE signal at a clean boundary after which all future
transactions are blocked. Only then partition reset can be asserted followed
by ELPG entry.

Bug 1237267

Change-Id: Ide45db658a327b1d663d0293817c7526b7068e74
Signed-off-by: Ajay Gupta <ajayg@nvidia.com>
Reviewed-on: http://git-master/r/205738
Reviewed-by: Henry Lin <henryl@nvidia.com>
Reviewed-by: Jui Chang Kuo <jckuo@nvidia.com>
Reviewed-by: Bo Yan <byan@nvidia.com>
(cherry picked from commit 782cecfe449e08fec201c0ebf011bc57b7545fbd)
Reviewed-on: http://git-master/r/208862
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Ashutosh Jha <ajha@nvidia.com>
GVS: Gerrit_Virtual_Submit
drivers/usb/host/xhci-tegra.c