Re: [PATCH 1/2] mfd: max8925: request resource region

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

On Mon, May 07, 2012 at 10:01:28AM +0100, Mark Brown wrote:
> On Mon, May 07, 2012 at 08:58:00AM +0100, Russell King - ARM Linux wrote:
> > On Mon, May 07, 2012 at 11:10:48AM +0800, Haojian Zhuang wrote:
> > > If resource region isn't requested, component devices will fail to request
> > > their resources.
> > > Signed-off-by: Haojian Zhuang <haojian.zhuang@xxxxxxxxx>
> > This looks wrong.
> > This driver looks broken.  IO regions are for PC IO stuff, not for I2C
> > buses.  There is no resource reservation system in the kernel for
> > registers on I2C devices.
> They've commonly been used for this, it's a fairly sane way for an MFD
> to communicate with its subdevices.  The fix in this series isn't good,
> though - providing a parent resource with a suitable range for all the
> device resources should do the job much more sensibly.  This isn't great
> but the infrastructure seems to do the right thing with it for now and
> it only requires a bit of reinterpretation of what IORESOURCE_IO means.

It's an abuse.  And it won't work unless PCMCIA, PCI or ISA is enabled.
This abuse must stop, and it must stop right now.  And I really don't
care about "it's commonly been used for XYZ" because it's a totally fucked

What if you have two devices both claiming IO regions at 0?  Hint: it

It's buggered beyond belief and it needs to die right now, no questions
about it.  And anyone who supports this idea needs to be...

linux-arm-kernel mailing list

[Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [PDAs]     [Linux]     [Linux MIPS]     [Yosemite Campsites]     [Photos]

Add to Google Follow linuxarm on Twitter