Re: [PATCH V2 1/3] mmc: esdhc: enable polling to detect card by itself

2012-11-07 Thread yongd
On 2012年11月06日 20:52, Shawn Guo wrote: On Tue, Nov 06, 2012 at 04:49:42PM +0800, yongd wrote: From your info, we can see that on your platform, those pins (including power, clk, DATA) necessary for MMC_SEND_STATUS transaction still keep connected for some time just after the GPIO's level

Re: [PATCH V2 1/3] mmc: esdhc: enable polling to detect card by itself

2012-11-07 Thread yongd
On 2012年11月06日 20:52, Shawn Guo wrote: On Tue, Nov 06, 2012 at 04:49:42PM +0800, yongd wrote: From your info, we can see that on your platform, those pins (including power, clk, DATA) necessary for MMC_SEND_STATUS transaction still keep connected for some time just after the GPIO's level

Re: [PATCH V2 1/3] mmc: esdhc: enable polling to detect card by itself

2012-11-06 Thread Shawn Guo
On Tue, Nov 06, 2012 at 04:49:42PM +0800, yongd wrote: > From your info, we can see that on your platform, those pins (including > power, clk, DATA) necessary for MMC_SEND_STATUS transaction still keep > connected for some time just after the GPIO's level changes due to card > removable. And if we

Re: [PATCH V2 1/3] mmc: esdhc: enable polling to detect card by itself

2012-11-06 Thread yongd
On 2012年11月05日 20:48, Shawn Guo wrote: On Mon, Nov 05, 2012 at 11:34:49AM +0800, yongd wrote: From the code logic, without SDHCI_QUIRK_BROKEN_CARD_DETECTION for ESDHC_CD_GPIO, when your card (using GPIO detection) is removed, we can know the card's absence through the fake CARD_PRESENT flag

Re: [PATCH V2 1/3] mmc: esdhc: enable polling to detect card by itself

2012-11-06 Thread yongd
On 2012年11月05日 20:48, Shawn Guo wrote: On Mon, Nov 05, 2012 at 11:34:49AM +0800, yongd wrote: From the code logic, without SDHCI_QUIRK_BROKEN_CARD_DETECTION for ESDHC_CD_GPIO, when your card (using GPIO detection) is removed, we can know the card's absence through the fake CARD_PRESENT flag

Re: [PATCH V2 1/3] mmc: esdhc: enable polling to detect card by itself

2012-11-06 Thread Shawn Guo
On Tue, Nov 06, 2012 at 04:49:42PM +0800, yongd wrote: From your info, we can see that on your platform, those pins (including power, clk, DATA) necessary for MMC_SEND_STATUS transaction still keep connected for some time just after the GPIO's level changes due to card removable. And if we

Re: [PATCH V2 1/3] mmc: esdhc: enable polling to detect card by itself

2012-11-05 Thread Shawn Guo
On Mon, Nov 05, 2012 at 11:34:49AM +0800, yongd wrote: > From the code logic, without SDHCI_QUIRK_BROKEN_CARD_DETECTION for > ESDHC_CD_GPIO, when your card (using > GPIO detection) is removed, we can know the card's absence through the fake > CARD_PRESENT flag in esdhc_readl_le(). > As a result,

Re: [PATCH V2 1/3] mmc: esdhc: enable polling to detect card by itself

2012-11-05 Thread Shawn Guo
On Mon, Nov 05, 2012 at 11:34:49AM +0800, yongd wrote: From the code logic, without SDHCI_QUIRK_BROKEN_CARD_DETECTION for ESDHC_CD_GPIO, when your card (using GPIO detection) is removed, we can know the card's absence through the fake CARD_PRESENT flag in esdhc_readl_le(). As a result, we

Re: [PATCH V2 1/3] mmc: esdhc: enable polling to detect card by itself

2012-11-04 Thread yongd
On 2012年11月05日 09:54, Shawn Guo wrote: On Fri, Nov 02, 2012 at 08:37:41PM +0800, yongd wrote: I got it. So how do you think of such below partition/reorganization? It looks fine to me for imx. Ok. I will update like this way if we have no other issues. Thanks. Patch-1: For

Re: [PATCH V2 1/3] mmc: esdhc: enable polling to detect card by itself

2012-11-04 Thread Shawn Guo
On Fri, Nov 02, 2012 at 08:37:41PM +0800, yongd wrote: > I got it. So how do you think of such below partition/reorganization? > It looks fine to me for imx. > Patch-1: > For sdhci-esdhc-imx.c, only add MMC_CAP_NEEDS_POLL for ESDHC_CD_NONE. With > that > improper logic of sdhci_add_host(), this

Re: [PATCH V2 1/3] mmc: esdhc: enable polling to detect card by itself

2012-11-04 Thread Shawn Guo
On Fri, Nov 02, 2012 at 08:37:41PM +0800, yongd wrote: I got it. So how do you think of such below partition/reorganization? It looks fine to me for imx. Patch-1: For sdhci-esdhc-imx.c, only add MMC_CAP_NEEDS_POLL for ESDHC_CD_NONE. With that improper logic of sdhci_add_host(), this is

Re: [PATCH V2 1/3] mmc: esdhc: enable polling to detect card by itself

2012-11-04 Thread yongd
On 2012年11月05日 09:54, Shawn Guo wrote: On Fri, Nov 02, 2012 at 08:37:41PM +0800, yongd wrote: I got it. So how do you think of such below partition/reorganization? It looks fine to me for imx. Ok. I will update like this way if we have no other issues. Thanks. Patch-1: For

Re: [PATCH V2 1/3] mmc: esdhc: enable polling to detect card by itself

2012-11-02 Thread yongd
On 2012年10月31日 23:20, Shawn Guo wrote: On Tue, Oct 30, 2012 at 05:30:01PM +0800, yongd wrote: In the current code logic, sdhci_add_host() will enable the polling method (set MMC_CAP_NEEDS_POLL) for a removable card (MMC_CAP_ NONREMOVABLE is not set) whose host's internal card detection method

Re: [PATCH V2 1/3] mmc: esdhc: enable polling to detect card by itself

2012-11-02 Thread yongd
On 2012年10月31日 23:20, Shawn Guo wrote: On Tue, Oct 30, 2012 at 05:30:01PM +0800, yongd wrote: In the current code logic, sdhci_add_host() will enable the polling method (set MMC_CAP_NEEDS_POLL) for a removable card (MMC_CAP_ NONREMOVABLE is not set) whose host's internal card detection method

Re: [PATCH V2 1/3] mmc: esdhc: enable polling to detect card by itself

2012-10-31 Thread Shawn Guo
On Tue, Oct 30, 2012 at 05:30:01PM +0800, yongd wrote: > In the current code logic, sdhci_add_host() will enable the polling > method (set MMC_CAP_NEEDS_POLL) for a removable card (MMC_CAP_ > NONREMOVABLE is not set) whose host's internal card detection method > is disabled for some reason

Re: [PATCH V2 1/3] mmc: esdhc: enable polling to detect card by itself

2012-10-31 Thread Shawn Guo
On Tue, Oct 30, 2012 at 05:30:01PM +0800, yongd wrote: In the current code logic, sdhci_add_host() will enable the polling method (set MMC_CAP_NEEDS_POLL) for a removable card (MMC_CAP_ NONREMOVABLE is not set) whose host's internal card detection method is disabled for some reason