OSDN Git Service

usb: gadget: udc: renesas_usb3: lock for PN_ registers access
authorYoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
Wed, 26 Apr 2017 11:50:09 +0000 (20:50 +0900)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 24 Jun 2017 05:11:15 +0000 (07:11 +0200)
commitcb53a4e03b2f2341f1b24d8c6785d4ff57928f41
treeab304035c1fda4bcabfb1fdbe9315acd2742ce7c
parentdd65c0958b77d97a9419f1ccfab3fa8c30f61338
usb: gadget: udc: renesas_usb3: lock for PN_ registers access

commit 940f538a100c84c6e72813e4ac88bd1753a86945 upstream.

This controller disallows to change the PIPE until reading/writing
a packet finishes. However. the previous code is not enough to hold
the lock in some functions. So, this patch fixes it.

Fixes: 746bfe63bba3 ("usb: gadget: renesas_usb3: add support for Renesas USB3.0 peripheral controller")
Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/gadget/udc/renesas_usb3.c