mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Rabin Vincent <rabin@rab.in>
To: Felipe Balbi <balbi@ti.com>
Cc: Rabin Vincent <rabin@rab.in>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [PATCH] usb: musb: turn phy on
Date: Wed,  2 Apr 2014 21:26:27 +0200	[thread overview]
Message-ID: <1396466787-19093-1-git-send-email-rabin@rab.in> (raw)

30a70b026b4cde4 ("usb: musb: fix obex in g_nokia.ko causing kernel
panic") broke USB gadget support on Pandaboard because it simply deletes
the call to phy_power_on() and the PHY is therefore never turned on.

Fix it by actually turning the phy on.

Cc: stable@vger.kernel.org
Signed-off-by: Rabin Vincent <rabin@rab.in>
---
 drivers/usb/musb/musb_gadget.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/usb/musb/musb_gadget.c b/drivers/usb/musb/musb_gadget.c
index d4aa779..09d5883 100644
--- a/drivers/usb/musb/musb_gadget.c
+++ b/drivers/usb/musb/musb_gadget.c
@@ -1850,6 +1850,7 @@ static int musb_gadget_start(struct usb_gadget *g,
 	}
 
 	pm_runtime_get_sync(musb->controller);
+	phy_power_on(musb->phy);
 
 	dev_dbg(musb->controller, "registering driver %s\n", driver->function);
 
@@ -1963,6 +1964,7 @@ static int musb_gadget_stop(struct usb_gadget *g,
 	 * that currently misbehaves.
 	 */
 
+	phy_power_off(musb->phy);
 	pm_runtime_put(musb->controller);
 
 	return 0;
-- 
1.9.1


             reply	other threads:[~2014-04-02 19:26 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-02 19:26 Rabin Vincent [this message]
2014-04-02 19:31 ` Felipe Balbi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1396466787-19093-1-git-send-email-rabin@rab.in \
    --to=rabin@rab.in \
    --cc=balbi@ti.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®