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:	Fri, 20 May 2016 14:24:14 +0200
From:	Arnd Bergmann <arnd@...db.de>
To:	Andy Gross <andy.gross@...aro.org>
Cc:	Felipe Balbi <balbi@...nel.org>,
	David Brown <david.brown@...aro.org>,
	Peter Chen <Peter.Chen@....com>,
	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	Alan Stern <stern@...land.harvard.edu>,
	Mark Brown <broonie@...nel.org>,
	Bjorn Andersson <bjorn.andersson@...aro.org>,
	Linux Kernel list <linux-kernel@...r.kernel.org>,
	linux-arm-msm <linux-arm-msm@...r.kernel.org>,
	linux-soc@...r.kernel.org, linux-usb@...r.kernel.org
Subject: Re: [RFC 4/8] usb: phy: move TCSR driver into new file

On Thursday 19 May 2016 14:08:43 Andy Gross wrote:
> > + *             - Tim
> > + */
> > +int qcom_tcsr_phy_sel(u32 val)
> > +{
> > +       void __iomem *phy_select;
> > +       int ret;
> > +
> > +       phy_select = ioremap(USB2_PHY_SEL, 4);
> > +
> > +       if (!phy_select) {
> > +               ret = -ENOMEM;
> > +               goto out;
> > +       }
> > +       /* Enable second PHY with the OTG port */
> > +       writel(0x1, phy_select);
> > +       ret = 0;
> > +out:
> > +       iounmap(phy_select);
> > +       return ret;
> > +}
> > +EXPORT_SYMBOL_GPL(qcom_tcsr_phy_sel);
> 
> I'd rather do something like what we did for the GSBI.  It needed to
> change some phy related bits in the TCSR as well.  We defined the TCSR
> as a syscon, with binding documentation under mfd.  If we add a syscon
> entry and use it if it is present, we can deal with that pretty
> easily.  The offsets change for each soc, and this would also fix that
> issue because we can change offset based on tcsr compat.

Works for me, but be aware that this will break the server chips,
as ACPI has no support for regmap devices.

I think that's fine, they should really handle this register access
in the firmware anyway rather than relying on a hardcoded MMIO
location.

	Arnd

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ