On Friday, July 26, 2013 2:55 AM, Laurent Pinchart wrote:
> On Thursday 25 July 2013 19:19:52 H Hartley Sweeten wrote:
>> On Thursday, July 25, 2013 4:27 PM, Laurent Pinchart wrote:
>>> Pass the CD and RO GPIO numbers to the MMC SPI driver and remove the
>>> custom .get_cd() and .get_ro() callback functions.
>>> 
>>> Signed-off-by: Laurent Pinchart
>>> <laurent.pinchart+rene...@ideasonboard.com>
>>> ---
>>> 
>>>  arch/arm/mach-ep93xx/vision_ep9307.c | 56  +++---------------------------
>>>  1 file changed, 4 insertions(+), 52 deletions(-)

<snip>

>> I tested this and it _kind_ of works.
>> 
>> The card detect is a bit flaky due to the gpio interrupt debounce not being
>> enabled.
>> 
>> The only way I can see to fix this is add the following to this patch:

<snip>

> What about extending the mmc_spi and MMC core with GPIO debounce support ? 
> The 
> mmc_spi driver would get a new cd_gpio_debounce field, which would be passed 
> to mmc_gpio_request_cd(). I can cook up a patch.

Works for me. That would also remove the need for the platform init to request 
then free
the GPIO just to set the debounce.

Make sure you do the gpiu_set_debounce() after the GPIO has been requested or 
you
trigger a WARN due to the auto-requested GPIO. Then, of course, the drivers 
gpio request
will fail...

I'll give it a test when you post it.

Thanks,
Hartley

--
To unsubscribe from this list: send the line "unsubscribe linux-mmc" 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