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, 15 Apr 2014 18:24:11 +0530
From:	Vivek Gautam <gautam.vivek@...sung.com>
To:	Heikki Krogerus <heikki.krogerus@...ux.intel.com>
Cc:	Linux USB Mailing List <linux-usb@...r.kernel.org>,
	"linux-samsung-soc@...r.kernel.org" 
	<linux-samsung-soc@...r.kernel.org>, linux-omap@...r.kernel.org,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	Greg KH <gregkh@...uxfoundation.org>,
	Felipe Balbi <balbi@...com>,
	Sarah Sharp <sarah.a.sharp@...ux.intel.com>,
	Kukjin Kim <kgene.kim@...sung.com>, kishon <kishon@...com>,
	Jingoo Han <jg1.han@...sung.com>,
	Julius Werner <jwerner@...omium.org>
Subject: Re: [PATCH RFC 3/4] xhci: Tune PHY for the DWC3-Exynos host controller

Hi Heikki,


On Tue, Dec 10, 2013 at 7:25 PM, Heikki Krogerus
<heikki.krogerus@...ux.intel.com> wrote:

Giving life to this thread after long time.

> Hi,
>
> On Tue, Dec 10, 2013 at 04:25:25PM +0530, Vivek Gautam wrote:
>> @@ -170,6 +189,15 @@ static int xhci_plat_probe(struct platform_device *pdev)
>>       }
>>
>>       /*
>> +      * The parent of the xhci-plat device may pass in a PHY via
>> +      * platform data.  If it exists, store it in our struct usb_hcd
>> +      * so that we can use it later.
>> +      */
>> +     phy_generic = dev_get_platdata(&pdev->dev);
>> +     if (phy_generic)
>> +             xhci->shared_hcd->phy_generic = *phy_generic;
>
> Getting the handle to the phy from platform data like this is not
> going to work for long. It should be possible to get it normally with
> phy_get(). It's not going to be possible to get the handle from the
> platform data like this if the xhci-hcd platform device is created
> from ACPI or DT. You are also not considering case where you have two
> phys.
>
> Vivek, I have made a patch set for the phy framework allowing
> associations between the phys and their users to be made in same way
> gpios and clk make them. With those you should be able to create a
> lookup entry to the phy framework in drivers/usb/dwc3/host.c. Then we
> could use phy_get() here already. Please check them. Subject of the
> thread:
>
> "phy: remove the need for the phys to know about their users"

I had seen your patches in the mailing list, but i don't see any
updated version of these patches.
Are you planning to work on this above mentioned patch-series any time soon ?

Or, should i try to find a different approach for handling the phy
from the host controller (child of DWC3 in this case, which has the
phys).

>
> The lookup table can then be added in drivers/usb/dwc3/host.c with
> something like this:
>
> int dwc3_host_init(struct dwc3 *dwc)
> {
>         struct platform_device  *xhci;
>         struct phy_lookup_table *table;
>         ...
>         table->dev_id = dev_name(&xhci->dev);
>         if (dwc->usb2_generic_phy)
>                 table->table[0].phy_name = dev_name(&dwc->usb2_generic_phy->dev);
>         if (dwc->usb3_generic_phy)
>                 table->table[1].phy_name = dev_name(&dwc->usb3_generic_phy->dev);
>         phy_add_lookup_table(table);
>         ...
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ