summaryrefslogtreecommitdiffstats
path: root/target/linux/s3c24xx/files-2.6.30/drivers/mfd/glamo/glamo-mci.h
diff options
context:
space:
mode:
authorlars <lars@3c298f89-4303-0410-b956-a3cf2f4a3e73>2009-05-18 17:55:41 +0000
committerlars <lars@3c298f89-4303-0410-b956-a3cf2f4a3e73>2009-05-18 17:55:41 +0000
commitfb189822fcab111e55d1c7e83c482dc2c144500a (patch)
treedd10e61f382ace3afbe40af3af8238757cf5e3d0 /target/linux/s3c24xx/files-2.6.30/drivers/mfd/glamo/glamo-mci.h
parentc5f7c391b56bb88e21895f0fc9310cd0919e8d0c (diff)
[s3c24xx] bump to 2.6.30-rc6
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@15918 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/s3c24xx/files-2.6.30/drivers/mfd/glamo/glamo-mci.h')
-rw-r--r--target/linux/s3c24xx/files-2.6.30/drivers/mfd/glamo/glamo-mci.h84
1 files changed, 84 insertions, 0 deletions
diff --git a/target/linux/s3c24xx/files-2.6.30/drivers/mfd/glamo/glamo-mci.h b/target/linux/s3c24xx/files-2.6.30/drivers/mfd/glamo/glamo-mci.h
new file mode 100644
index 000000000..daae7a3bc
--- /dev/null
+++ b/target/linux/s3c24xx/files-2.6.30/drivers/mfd/glamo/glamo-mci.h
@@ -0,0 +1,84 @@
+/*
+ * linux/drivers/mmc/host/glamo-mmc.h - GLAMO MCI driver
+ *
+ * Copyright (C) 2007-2008 Openmoko, Inc, Andy Green <andy@openmoko.com>
+ * based on S3C MMC driver -->
+ * Copyright (C) 2004-2006 Thomas Kleffel, All Rights Reserved.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ */
+
+#include <linux/regulator/consumer.h>
+
+enum glamo_mci_waitfor {
+ COMPLETION_NONE,
+ COMPLETION_FINALIZE,
+ COMPLETION_CMDSENT,
+ COMPLETION_RSPFIN,
+ COMPLETION_XFERFINISH,
+ COMPLETION_XFERFINISH_RSPFIN,
+};
+
+struct glamo_mci_host {
+ struct platform_device *pdev;
+ struct glamo_mci_pdata *pdata;
+ struct mmc_host *mmc;
+ struct resource *mem;
+ struct resource *mem_data;
+ struct clk *clk;
+ void __iomem *base;
+ u16 __iomem *base_data;
+ int irq;
+ int irq_cd;
+ int dma;
+ int data_max_size;
+
+ int suspending;
+
+ int power_mode_current;
+ unsigned int vdd_current;
+
+ unsigned long clk_rate;
+ unsigned long clk_div;
+ unsigned long real_rate;
+ u8 prescaler;
+
+ int force_slow_during_powerup;
+
+ unsigned sdiimsk;
+ int dodma;
+
+ volatile int dmatogo;
+
+ struct mmc_request *mrq;
+ int cmd_is_stop;
+ struct work_struct irq_work;
+
+ spinlock_t complete_lock;
+ volatile enum glamo_mci_waitfor
+ complete_what;
+
+ volatile int dma_complete;
+
+ volatile u32 pio_sgptr;
+ volatile u32 pio_words;
+ volatile u32 pio_count;
+ volatile u16 *pio_ptr;
+#define XFER_NONE 0
+#define XFER_READ 1
+#define XFER_WRITE 2
+ volatile u32 pio_active;
+
+ int bus_width;
+
+ char dbgmsg_cmd[301];
+ char dbgmsg_dat[301];
+ volatile char *status;
+
+ unsigned int ccnt, dcnt;
+ struct tasklet_struct pio_tasklet;
+
+ struct regulator *regulator;
+};