RE: [PATCH v2] usb: renesas_usbhs: Allow an OTG PHY driver to provide VBUS

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Sergei,

On 02 July 2015 12:17, Sergei wrote:
> To: Phil Edworthy; Yoshihiro Shimoda
> Hello.
> 
> On 7/2/2015 10:36 AM, Phil Edworthy wrote:
> 
> > These changes allow a PHY driver to trigger a VBUS interrupt and
> > to provide the value of VBUS.
> 
> > Signed-off-by: Phil Edworthy <phil.edworthy@xxxxxxxxxxx>
> 
> [...]
> 
> > diff --git a/drivers/usb/renesas_usbhs/mod_gadget.c
> b/drivers/usb/renesas_usbhs/mod_gadget.c
> > index dc2aa32..51b63f9 100644
> > --- a/drivers/usb/renesas_usbhs/mod_gadget.c
> > +++ b/drivers/usb/renesas_usbhs/mod_gadget.c
> [...]
> > @@ -947,12 +966,27 @@ static int usbhsg_set_selfpowered(struct usb_gadget
> *gadget, int is_self)
> >   	return 0;
> >   }
> >
> > +static int usbhsg_vbus_session(struct usb_gadget *gadget, int is_active)
> > +{
> > +	struct usbhsg_gpriv *gpriv = usbhsg_gadget_to_gpriv(gadget);
> > +	struct usbhs_priv *priv = usbhsg_gpriv_to_priv(gpriv);
> > +	struct platform_device *pdev = usbhs_priv_to_pdev(priv);
> > +
> > +	priv->vbus_is_indirect = 1;
> 
>     s/1/true/.
Ok.
 
> > +	priv->vbus_indirect_value = !!is_active;
> > +
> > +	renesas_usbhs_call_notify_hotplug(pdev);
> > +
> > +	return 0;
> > +}
> > +
> [...]
> > @@ -994,6 +1028,10 @@ int usbhs_mod_gadget_probe(struct usbhs_priv
> *priv)
> >   		goto usbhs_mod_gadget_probe_err_gpriv;
> >   	}
> >
> > +	gpriv->transceiver = usb_get_phy(USB_PHY_TYPE_UNDEFINED);
> > +	dev_info(dev, "%s transceiver found\n",
> > +		 gpriv->transceiver ? "" : "No");
> 
>     Hm, I told you to make this message cleaner, and you haven't. :-(
Ah, sorry, I missed that comment.

> [...]
> 
> WBR, Sergei

Thanks
Phil
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux