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] [day] [month] [year] [list]
Date:	Mon, 28 Apr 2014 09:38:47 +0530
From:	Vivek Gautam <gautam.vivek@...sung.com>
To:	Alan Stern <stern@...land.harvard.edu>
Cc:	Linux USB Mailing List <linux-usb@...r.kernel.org>,
	"linux-samsung-soc@...r.kernel.org" 
	<linux-samsung-soc@...r.kernel.org>,
	"devicetree@...r.kernel.org" <devicetree@...r.kernel.org>,
	linux-doc@...r.kernel.org,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	"linux-arm-kernel@...ts.infradead.org" 
	<linux-arm-kernel@...ts.infradead.org>,
	Greg KH <gregkh@...uxfoundation.org>,
	Felipe Balbi <balbi@...com>,
	Kukjin Kim <kgene.kim@...sung.com>,
	Kamil Debski <k.debski@...sung.com>,
	Jingoo Han <jg1.han@...sung.com>
Subject: Re: [PATCH v8 2/2] usb: ehci-exynos: Change to use phy provided by
 the generic phy framework

Hi,


On Fri, Apr 25, 2014 at 8:11 PM, Alan Stern <stern@...land.harvard.edu> wrote:
> On Fri, 25 Apr 2014, Vivek Gautam wrote:
>
>> From: Kamil Debski <k.debski@...sung.com>
>>
>> Add the phy provider, supplied by new Exynos-usb2phy using
>> Generic phy framework.
>> Keeping the support for older USB phy intact right now, in order
>> to prevent any functionality break in absence of relevant
>> device tree side change for ehci-exynos.
>> Once we move to new phy in the device nodes for ehci, we can
>> remove the support for older phys.
>>
>> Signed-off-by: Kamil Debski <k.debski@...sung.com>
>> [gautam.vivek@...sung.com: Addressed review comments from mailing list]
>> [gautam.vivek@...sung.com: Kept the code for old usb-phy, and just
>> added support for new exynos5-usb2phy in generic phy framework]
>> [gautam.vivek@...sung.com: Edited the commit message]
>> Signed-off-by: Vivek Gautam <gautam.vivek@...sung.com>
>
>> +static int exynos_ehci_phyg_off(struct phy *phy[])
>> +{
>> +     int i;
>> +     int ret = 0;
>> +
>> +     for (i = 0; ret == 0 && i < PHY_NUMBER; i++)
>> +             if (phy[i])
>> +                     ret = phy_power_off(phy[i]);
>> +
>> +     return ret;
>> +}
>
> Same comment as in the OHCI driver about ret.

Ok, will change this.

>
>> @@ -175,6 +269,7 @@ skip_phy:
>>  fail_add_hcd:
>>       if (exynos_ehci->phy)
>>               usb_phy_shutdown(exynos_ehci->phy);
>> +     exynos_ehci_phyg_off(exynos_ehci->phy_g);
>>  fail_io:
>>       clk_disable_unprepare(exynos_ehci->clk);
>>  fail_clk:
>> @@ -195,6 +290,8 @@ static int exynos_ehci_remove(struct platform_device *pdev)
>>       if (exynos_ehci->phy)
>>               usb_phy_shutdown(exynos_ehci->phy);
>>
>> +     exynos_ehci_phyg_off(exynos_ehci->phy_g);
>> +
>
> In both these places, you need to test exynos_ehci->phyg before calling
> exynos_ehci_phyg_off().
>
> Maybe it would help to add exynos_ehci_phy_enable/disable routines,
> like in the OHCI driver.

Will move these statements as a part of enable()/disable() routines,
put necessary check there.



-- 
Best Regards
Vivek Gautam
Samsung R&D Institute, Bangalore
India
--
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