提交 2bcb7514 编写于 作者: N Neil Zhang 提交者: Felipe Balbi

usb: gadget: mv_udc: replace some debug info

replace some debug info, make it easy to use.
Signed-off-by: NNeil Zhang <zhangwm@marvell.com>
Signed-off-by: NFelipe Balbi <balbi@ti.com>
上级 5076ae55
...@@ -1230,10 +1230,11 @@ static int mv_udc_vbus_session(struct usb_gadget *gadget, int is_active) ...@@ -1230,10 +1230,11 @@ static int mv_udc_vbus_session(struct usb_gadget *gadget, int is_active)
udc = container_of(gadget, struct mv_udc, gadget); udc = container_of(gadget, struct mv_udc, gadget);
spin_lock_irqsave(&udc->lock, flags); spin_lock_irqsave(&udc->lock, flags);
udc->vbus_active = (is_active != 0);
dev_dbg(&udc->dev->dev, "%s: softconnect %d, vbus_active %d\n", dev_dbg(&udc->dev->dev, "%s: softconnect %d, vbus_active %d\n",
__func__, udc->softconnect, udc->vbus_active); __func__, udc->softconnect, udc->vbus_active);
udc->vbus_active = (is_active != 0);
if (udc->driver && udc->softconnect && udc->vbus_active) { if (udc->driver && udc->softconnect && udc->vbus_active) {
retval = mv_udc_enable(udc); retval = mv_udc_enable(udc);
if (retval == 0) { if (retval == 0) {
...@@ -1262,10 +1263,11 @@ static int mv_udc_pullup(struct usb_gadget *gadget, int is_on) ...@@ -1262,10 +1263,11 @@ static int mv_udc_pullup(struct usb_gadget *gadget, int is_on)
udc = container_of(gadget, struct mv_udc, gadget); udc = container_of(gadget, struct mv_udc, gadget);
spin_lock_irqsave(&udc->lock, flags); spin_lock_irqsave(&udc->lock, flags);
udc->softconnect = (is_on != 0);
dev_dbg(&udc->dev->dev, "%s: softconnect %d, vbus_active %d\n", dev_dbg(&udc->dev->dev, "%s: softconnect %d, vbus_active %d\n",
__func__, udc->softconnect, udc->vbus_active); __func__, udc->softconnect, udc->vbus_active);
udc->softconnect = (is_on != 0);
if (udc->driver && udc->softconnect && udc->vbus_active) { if (udc->driver && udc->softconnect && udc->vbus_active) {
retval = mv_udc_enable(udc); retval = mv_udc_enable(udc);
if (retval == 0) { if (retval == 0) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册