Messages in this thread | | | Date | Tue, 7 Aug 2012 17:48:56 +0100 | From | Mark Brown <> | Subject | Re: [PATCH 0/5] mfd: replace IORESOURCE_IO by IORESOURCE_MEM |
| |
On Tue, Aug 07, 2012 at 04:44:58PM +0100, Russell King wrote:
> However, one issue that I hope has already been addressed is what space > the ranges are in, and how does a sub-driver get to know that. To put > it another way, how does a sub-driver get to know about the 'base' for > these register ranges. I hope that problem has been thought about in > MFD land _before_ the approach of passing around register ranges > through resources was allowed to happen.
That's been thought through - the subdevice drivers already have to rely heavily on the fact that they know about their parent and part of that contract is that the base address for these resources is always address zero in the register space of the MFD and there's never more than one resource in the tree. Nothing will ever do anything like reserve the resources, they just get looked up to retrieve the base address for the relevant range.
Someone could do a device which does something different but nobody wanted to yet and it's very unclear that anyone would, if they did then they'd have to deal with the issues that will result.
| |