Re: [PATCH] mmc: dt: Add 'broken-cd' DT binding
From: Thomas Abraham <hidden>
Date: 2012-08-21 12:30:52
Also in:
linux-mmc, linux-samsung-soc
On 21 August 2012 17:26, Chris Ball [off-list ref] wrote:
Hi, On Tue, Aug 21 2012, Thomas Abraham wrote:quoted
I am trying to have a way to represent a gpio line as card detect line that is not connected to the card-detect pad of the mmc controller but instead used as a gpio interrupt line or polled gpio line. 'broken-cd' would imply that the card-detect pad of the mmc controller is not connected to the card-detect pin at the slot. The 'cd-gpios' property in that case would let the driver code to use the 'cd-gpios' line as the external gpio interrupt or poll it.How about this? broken-cd: No CD available, use polling. cd-gpios: The CD pin on the host is working and brought out to a GPIO. external-cd-gpios: The CD pin on the host is broken, but there's an independent external GPIO available. (Each host should only have one of these properties.)
How about a property using 'cd-external' property in place of 'external-cd-gpios'. 'cd-external' would mean that the gpio listed by 'cd-gpios' is a gpio line which is not connected the card-detect pad of the mmc controller. This can simplfy the dt parsing code since it is required to look for only one gpio property, which is 'cd-gpios' which implies lesser error handling code. 'cd-external' can qualify it further as an external cd pin. Either way, I am fine with the binding you have proposed. If you post a patch for these new bindings, I will base the sdhci-s3c dt patch on top of that patch. Thanks, Thomas.