]> err.no Git - linux-2.6/blobdiff - drivers/mmc/host/pxamci.c
Merge branch 'for_rmk_13' of git://git.mnementh.co.uk/linux-2.6-im
[linux-2.6] / drivers / mmc / host / pxamci.c
index d89475d36988228c09e60b54034c288bd81368e6..a8e18fe53077fee9023442745332706a9929888f 100644 (file)
@@ -177,7 +177,7 @@ static void pxamci_setup_data(struct pxamci_host *host, struct mmc_data *data)
        if (dalgn)
                DALGN |= (1 << host->dma);
        else
-               DALGN &= (1 << host->dma);
+               DALGN &= ~(1 << host->dma);
        DDADR(host->dma) = host->sg_dma;
        DCSR(host->dma) = DCSR_RUN;
 }
@@ -374,9 +374,12 @@ static int pxamci_get_ro(struct mmc_host *mmc)
        struct pxamci_host *host = mmc_priv(mmc);
 
        if (host->pdata && host->pdata->get_ro)
-               return host->pdata->get_ro(mmc_dev(mmc));
-       /* Host doesn't support read only detection so assume writeable */
-       return 0;
+               return !!host->pdata->get_ro(mmc_dev(mmc));
+       /*
+        * Board doesn't support read only detection; let the mmc core
+        * decide what to do.
+        */
+       return -ENOSYS;
 }
 
 static void pxamci_set_ios(struct mmc_host *mmc, struct mmc_ios *ios)