lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 21 Apr 2015 10:08:27 +0200
From:	Maxime Ripard <maxime.ripard@...e-electrons.com>
To:	Roger Quadros <rogerq@...com>
Cc:	Mathias Nyman <mathias.nyman@...ux.intel.com>,
	mathias.nyman@...el.com, gregkh@...uxfoundation.org,
	linux-usb@...r.kernel.org, linux-kernel@...r.kernel.org,
	"Balbi, Felipe" <balbi@...com>, kishon@...comg
Subject: Re: [PATCH 2/5] usb: xhci: plat: Create both HCDs before adding them

On Tue, Apr 21, 2015 at 12:49:54PM +0300, Roger Quadros wrote:
> On 20/04/15 15:35, Mathias Nyman wrote:
> > Hi
> > 
> > On 02.04.2015 15:23, Roger Quadros wrote:
> >> As xhci_hcd is now allocated by usb_create_hcd(), we don't
> >> need to add the primary HCD before creating the shared HCD.
> >>
> >> Creating the shared HCD before adding the primary HCD is particularly
> >> useful for the OTG use case so that we know at the OTG core if
> >> the HCD is in single configuration or dual (primary + shared)
> >> configuration.
> >>
> > 
> > This doesn't apply as 
> > 
> > commit 7b8ef22ea547b80475ac7feab06fb15e0fc143d8
> >     usb: xhci: plat: Add USB phy support
> > 
> > changed xhci-plat.c since.
> > 
> > I rebased it, and the changed version is sitting in the for-usb-next branch in:
> > git://git.kernel.org/pub/scm/linux/kernel/git/mnyman/xhci.git
> > 
> > But it appeared to me that usb_add_hcd() and usb_remove_hcd() will also
> > call phy init and remove functions. As the order how hcds are created and added
> > would change I'd need some more eyes on this to see if it will cause regression.
> > 
> > Or maybe in the best case we could get rid of the "Add USB phy support" patch as
> > we will call xhci_add_hcd() for the first hcd much later, and it could maybe init
> > the phy for us?
> 
> I thought usb_phy_*() stuff would be deprecated and we should use
> phy framework instead i.e. phy_init() and friends.

Except that all drivers have not been converted yet... So it's not
really an option until then.

> In fact usb_add_hcd() is already handling the phy for us.

If it handles USB phy, then I don't really have an issue with it.

Maxime

-- 
Maxime Ripard, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

Download attachment "signature.asc" of type "application/pgp-signature" (820 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ