Linus,

+dw_mmc folks and Stephen Warren : for context here, we are discussing
device tree bindings for pinmux for dw_mmc.  The issue at hand is
whether they belong under the slot node or under the top-level device
node.


On Wed, Mar 6, 2013 at 11:57 PM, Linus Walleij <linus.wall...@linaro.org> wrote:
> I don't quite understand the above. Is it such that there is one device,
> with two slots, and in the device model you have represented this
> two-slot device with a single struct device?

Yes, that's the issue.  That's dw_mmc that has been in the kernel for
a bit of time now (looks like Jan 2011) and has had a single struct
device for as long as I've been looking at it.

Relevant links for convenience:
* 
https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/tree/drivers/mmc/host/dw_mmc.c
* 
https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/tree/Documentation/devicetree/bindings/mmc/synopsis-dw-mshc.txt
* 
https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/tree/arch/arm/boot/dts/exynos5250.dtsi#n243
* 
https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/tree/arch/arm/boot/dts/cros5250-common.dtsi#n92


> Have you considered just registering one device for each slot?
>
> That would make things quite a lot simpler, just a single pinctrl
> handle per device, right?

I don't know why the original decision was made to just have one
struct device.  ...that would be a pretty big code change at this
point, I think.

...I think the most important issue at hand is the device tree
bindings for pinmux on this device.  It sounds like you are in
agreement that the best thing is to have a pinmux specified per-slot.
If the code is a bit awkward now (due to not having a struct device
per slot) then that's just something we have to live with.


-Doug
--
To unsubscribe from this list: send the line "unsubscribe linux-samsung-soc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to