Skip to content

Commit

Permalink
Merge tag 'usb-ci-v4.1-rc1' of git://git.kernel.org/pub/scm/linux/ker…
Browse files Browse the repository at this point in the history
…nel/git/peter.chen/usb into usb-next

Peter writes:

Two Chipidea updates

- Forbid dumpping registers when the controller in low power mode
- dp pullup needs to be controlled by fsm when working at otg
fsm mode
  • Loading branch information
Greg Kroah-Hartman committed Apr 10, 2015
2 parents 2aebe3f + 0c4d6af commit b9cd825
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/usb/chipidea/debug.c
Original file line number Diff line number Diff line change
Expand Up @@ -336,8 +336,8 @@ static int ci_registers_show(struct seq_file *s, void *unused)
struct ci_hdrc *ci = s->private;
u32 tmp_reg;

if (!ci)
return 0;
if (!ci || ci->in_lpm)
return -EPERM;

/* ------ Registers ----- */
tmp_reg = hw_read_intr_enable(ci);
Expand Down
4 changes: 4 additions & 0 deletions drivers/usb/chipidea/udc.c
Original file line number Diff line number Diff line change
Expand Up @@ -1574,6 +1574,10 @@ static int ci_udc_pullup(struct usb_gadget *_gadget, int is_on)
{
struct ci_hdrc *ci = container_of(_gadget, struct ci_hdrc, gadget);

/* Data+ pullup controlled by OTG state machine in OTG fsm mode */
if (ci_otg_is_fsm_mode(ci))
return 0;

pm_runtime_get_sync(&ci->gadget.dev);
if (is_on)
hw_write(ci, OP_USBCMD, USBCMD_RS, USBCMD_RS);
Expand Down

0 comments on commit b9cd825

Please sign in to comment.