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, 09 Dec 2014 12:20:04 +0100
From:	Arnd Bergmann <arnd@...db.de>
To:	Matthias Brugger <matthias.bgg@...il.com>
Cc:	Sascha Hauer <s.hauer@...gutronix.de>,
	Flora Fu <flora.fu@...iatek.com>,
	"linux-arm-kernel@...ts.infradead.org" 
	<linux-arm-kernel@...ts.infradead.org>,
	Rob Herring <robh+dt@...nel.org>,
	Samuel Ortiz <sameo@...ux.intel.com>,
	Lee Jones <lee.jones@...aro.org>,
	Liam Girdwood <lgirdwood@...il.com>,
	Mark Brown <broonie@...nel.org>, arm@...nel.org,
	Mark Rutland <mark.rutland@....com>,
	"devicetree@...r.kernel.org" <devicetree@...r.kernel.org>,
	Russell King <linux@....linux.org.uk>,
	srv_heupstream <srv_heupstream@...iatek.com>,
	Pawel Moll <pawel.moll@....com>,
	Ian Campbell <ijc+devicetree@...lion.org.uk>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	HenryC Chen <henryc.chen@...iatek.com>,
	Menghui Lin <menghui.lin@...iatek.com>,
	Olof Johansson <olof@...om.net>,
	Sascha Hauer <kernel@...gutronix.de>,
	Kumar Gala <galak@...eaurora.org>,
	Grant Likely <grant.likely@...aro.org>,
	Yingjoe Chen <yingjoe.chen@...iatek.com>,
	Eddie Huang <eddie.huang@...iatek.com>,
	Dongdong Cheng <dongdong.cheng@...iatek.com>
Subject: Re: [PATCH v3 1/8] soc: mediatek: Add PMIC wrapper for MT8135 and MT6397 SoC

On Tuesday 09 December 2014 11:30:15 Matthias Brugger wrote:
> 2014-12-09 11:13 GMT+01:00 Sascha Hauer <s.hauer@...gutronix.de>:
> > On Tue, Dec 09, 2014 at 09:23:18AM +0100, Arnd Bergmann wrote:
> >>
> >> I think we have had a similar case recently where a controller wasn't
> >> actually using I2C, but the sofware protocol was close enough so we decided
> >> to make it appear as i2c in Linux.
> >>
> >> Would that work for you, i.e. register the pmic wrapper as a fake spi
> >> master driver in drivers/spi/ and register the rtc/regulator/codec
> >> as SPI clients from DT?
> >
> > I don't think that's appropriate. I mean technically that could even
> > work, but in software you really don't see anything from the underlying
> > SPI bus. The SoC and the PMIC are really tightly coupled via the PMIC
> > wrapper. This goes to the point where pins of the SoCs internal I2C and
> > keypad controllers are routed over the SPI bus out of the PMIC. In
> > software you do this by setting a bit in the I2C controller. If it's
> > set, the signals are routed out of the PMIC instead of the main die.
> > As said, technically we probably could create a fake SPI master, but
> > that wouldn't really fit to this situation.

Ok, I see.

> I agree with Sascha. Although from the hardware point of view, the
> communication between the PMIC and the SOC is done through SPI from
> the point of view of the software everything looks like I2C commands
> which will be "transalted" into SPI messages by the PMIC wrapper.

If it looks like i2c messages, would it be more appropriate to make
it appear as an i2c controller then?

	Arnd
--
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