-static void au1xmmc_poll_event(unsigned long arg)
-{
- struct au1xmmc_host *host = (struct au1xmmc_host *)arg;
- int card = au1xmmc_card_inserted(host);
- int controller = (host->flags & HOST_F_ACTIVE) ? 1 : 0;
-
- if (card != controller) {
- host->flags &= ~HOST_F_ACTIVE;
- if (card)
- host->flags |= HOST_F_ACTIVE;
- mmc_detect_change(host->mmc, 0);
- }
-
-#ifdef DEBUG
- if (host->mrq != NULL) {
- u32 status = au_readl(HOST_STATUS(host));
- DBG("PENDING - %8.8x\n", host->pdev->id, status);
- }
-#endif
- mod_timer(&host->timer, jiffies + AU1XMMC_DETECT_TIMEOUT);
-}
-
-static void au1xmmc_init_cd_poll_timer(struct au1xmmc_host *host)
-{
- init_timer(&host->timer);
- host->timer.function = au1xmmc_poll_event;
- host->timer.data = (unsigned long)host;
- host->timer.expires = jiffies + AU1XMMC_DETECT_TIMEOUT;
-}
-