mmc: s3c6410: add new quirk in sdhci driver and update ADMA descriptor build
[safe/jmp/linux-2.6] / drivers / mmc / host / sdhci.h
index 47c1360..c846813 100644 (file)
@@ -238,6 +238,8 @@ struct sdhci_host {
 #define SDHCI_QUIRK_DATA_TIMEOUT_USES_SDCLK            (1<<24)
 /* Controller reports wrong base clock capability */
 #define SDHCI_QUIRK_CAP_CLOCK_BASE_BROKEN              (1<<25)
+/* Controller cannot support End Attribute in NOP ADMA descriptor */
+#define SDHCI_QUIRK_NO_ENDATTR_IN_NOPDESC              (1<<26)
 
        int                     irq;            /* Device IRQ */
        void __iomem *          ioaddr;         /* Mapped address */
@@ -296,12 +298,12 @@ struct sdhci_host {
 
 struct sdhci_ops {
 #ifdef CONFIG_MMC_SDHCI_IO_ACCESSORS
-       u32             (*readl)(struct sdhci_host *host, int reg);
-       u16             (*readw)(struct sdhci_host *host, int reg);
-       u8              (*readb)(struct sdhci_host *host, int reg);
-       void            (*writel)(struct sdhci_host *host, u32 val, int reg);
-       void            (*writew)(struct sdhci_host *host, u16 val, int reg);
-       void            (*writeb)(struct sdhci_host *host, u8 val, int reg);
+       u32             (*read_l)(struct sdhci_host *host, int reg);
+       u16             (*read_w)(struct sdhci_host *host, int reg);
+       u8              (*read_b)(struct sdhci_host *host, int reg);
+       void            (*write_l)(struct sdhci_host *host, u32 val, int reg);
+       void            (*write_w)(struct sdhci_host *host, u16 val, int reg);
+       void            (*write_b)(struct sdhci_host *host, u8 val, int reg);
 #endif
 
        void    (*set_clock)(struct sdhci_host *host, unsigned int clock);
@@ -316,48 +318,48 @@ struct sdhci_ops {
 
 static inline void sdhci_writel(struct sdhci_host *host, u32 val, int reg)
 {
-       if (unlikely(host->ops->writel))
-               host->ops->writel(host, val, reg);
+       if (unlikely(host->ops->write_l))
+               host->ops->write_l(host, val, reg);
        else
                writel(val, host->ioaddr + reg);
 }
 
 static inline void sdhci_writew(struct sdhci_host *host, u16 val, int reg)
 {
-       if (unlikely(host->ops->writew))
-               host->ops->writew(host, val, reg);
+       if (unlikely(host->ops->write_w))
+               host->ops->write_w(host, val, reg);
        else
                writew(val, host->ioaddr + reg);
 }
 
 static inline void sdhci_writeb(struct sdhci_host *host, u8 val, int reg)
 {
-       if (unlikely(host->ops->writeb))
-               host->ops->writeb(host, val, reg);
+       if (unlikely(host->ops->write_b))
+               host->ops->write_b(host, val, reg);
        else
                writeb(val, host->ioaddr + reg);
 }
 
 static inline u32 sdhci_readl(struct sdhci_host *host, int reg)
 {
-       if (unlikely(host->ops->readl))
-               return host->ops->readl(host, reg);
+       if (unlikely(host->ops->read_l))
+               return host->ops->read_l(host, reg);
        else
                return readl(host->ioaddr + reg);
 }
 
 static inline u16 sdhci_readw(struct sdhci_host *host, int reg)
 {
-       if (unlikely(host->ops->readw))
-               return host->ops->readw(host, reg);
+       if (unlikely(host->ops->read_w))
+               return host->ops->read_w(host, reg);
        else
                return readw(host->ioaddr + reg);
 }
 
 static inline u8 sdhci_readb(struct sdhci_host *host, int reg)
 {
-       if (unlikely(host->ops->readb))
-               return host->ops->readb(host, reg);
+       if (unlikely(host->ops->read_b))
+               return host->ops->read_b(host, reg);
        else
                return readb(host->ioaddr + reg);
 }