Commit 6ef297f8 authored by Linus Walleij's avatar Linus Walleij Committed by Russell King

ARM: 5720/1: Move MMCI header to amba include dir

This moves the mmci platform data definition struct away from
arch/arm/include/asm/mach/mmc.h into the more proper place among
the other primecells in include/linux/amba/mmci.h and at the same
time renames it to "mmci.h", and also the struct in this file
confusingly named mmc_platform_data has been renamed
mmci_platform_data for clarity.

Cc: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: default avatarLinus Walleij <linus.walleij@stericsson.com>
Signed-off-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
parent 4321532c
...@@ -19,6 +19,7 @@ ...@@ -19,6 +19,7 @@
#include <linux/amba/bus.h> #include <linux/amba/bus.h>
#include <linux/amba/kmi.h> #include <linux/amba/kmi.h>
#include <linux/amba/clcd.h> #include <linux/amba/clcd.h>
#include <linux/amba/mmci.h>
#include <linux/io.h> #include <linux/io.h>
#include <asm/clkdev.h> #include <asm/clkdev.h>
...@@ -35,7 +36,6 @@ ...@@ -35,7 +36,6 @@
#include <asm/mach/arch.h> #include <asm/mach/arch.h>
#include <asm/mach/flash.h> #include <asm/mach/flash.h>
#include <asm/mach/irq.h> #include <asm/mach/irq.h>
#include <asm/mach/mmc.h>
#include <asm/mach/map.h> #include <asm/mach/map.h>
#include <asm/mach/time.h> #include <asm/mach/time.h>
...@@ -400,7 +400,7 @@ static unsigned int mmc_status(struct device *dev) ...@@ -400,7 +400,7 @@ static unsigned int mmc_status(struct device *dev)
return status & 8; return status & 8;
} }
static struct mmc_platform_data mmc_data = { static struct mmci_platform_data mmc_data = {
.ocr_mask = MMC_VDD_32_33|MMC_VDD_33_34, .ocr_mask = MMC_VDD_32_33|MMC_VDD_33_34,
.status = mmc_status, .status = mmc_status,
.gpio_wp = -1, .gpio_wp = -1,
......
...@@ -30,6 +30,7 @@ ...@@ -30,6 +30,7 @@
#include <linux/io.h> #include <linux/io.h>
#include <linux/smsc911x.h> #include <linux/smsc911x.h>
#include <linux/ata_platform.h> #include <linux/ata_platform.h>
#include <linux/amba/mmci.h>
#include <asm/clkdev.h> #include <asm/clkdev.h>
#include <asm/system.h> #include <asm/system.h>
...@@ -44,7 +45,6 @@ ...@@ -44,7 +45,6 @@
#include <asm/mach/flash.h> #include <asm/mach/flash.h>
#include <asm/mach/irq.h> #include <asm/mach/irq.h>
#include <asm/mach/map.h> #include <asm/mach/map.h>
#include <asm/mach/mmc.h>
#include <asm/hardware/gic.h> #include <asm/hardware/gic.h>
...@@ -237,14 +237,14 @@ static unsigned int realview_mmc_status(struct device *dev) ...@@ -237,14 +237,14 @@ static unsigned int realview_mmc_status(struct device *dev)
return readl(REALVIEW_SYSMCI) & mask; return readl(REALVIEW_SYSMCI) & mask;
} }
struct mmc_platform_data realview_mmc0_plat_data = { struct mmci_platform_data realview_mmc0_plat_data = {
.ocr_mask = MMC_VDD_32_33|MMC_VDD_33_34, .ocr_mask = MMC_VDD_32_33|MMC_VDD_33_34,
.status = realview_mmc_status, .status = realview_mmc_status,
.gpio_wp = 17, .gpio_wp = 17,
.gpio_cd = 16, .gpio_cd = 16,
}; };
struct mmc_platform_data realview_mmc1_plat_data = { struct mmci_platform_data realview_mmc1_plat_data = {
.ocr_mask = MMC_VDD_32_33|MMC_VDD_33_34, .ocr_mask = MMC_VDD_32_33|MMC_VDD_33_34,
.status = realview_mmc_status, .status = realview_mmc_status,
.gpio_wp = 19, .gpio_wp = 19,
......
...@@ -47,8 +47,8 @@ static struct amba_device name##_device = { \ ...@@ -47,8 +47,8 @@ static struct amba_device name##_device = { \
extern struct platform_device realview_flash_device; extern struct platform_device realview_flash_device;
extern struct platform_device realview_cf_device; extern struct platform_device realview_cf_device;
extern struct platform_device realview_i2c_device; extern struct platform_device realview_i2c_device;
extern struct mmc_platform_data realview_mmc0_plat_data; extern struct mmci_platform_data realview_mmc0_plat_data;
extern struct mmc_platform_data realview_mmc1_plat_data; extern struct mmci_platform_data realview_mmc1_plat_data;
extern struct clcd_board clcd_plat_data; extern struct clcd_board clcd_plat_data;
extern void __iomem *gic_cpu_base_addr; extern void __iomem *gic_cpu_base_addr;
extern void __iomem *timer0_va_base; extern void __iomem *timer0_va_base;
......
...@@ -24,6 +24,7 @@ ...@@ -24,6 +24,7 @@
#include <linux/sysdev.h> #include <linux/sysdev.h>
#include <linux/amba/bus.h> #include <linux/amba/bus.h>
#include <linux/amba/pl061.h> #include <linux/amba/pl061.h>
#include <linux/amba/mmci.h>
#include <linux/io.h> #include <linux/io.h>
#include <mach/hardware.h> #include <mach/hardware.h>
...@@ -37,7 +38,6 @@ ...@@ -37,7 +38,6 @@
#include <asm/mach/arch.h> #include <asm/mach/arch.h>
#include <asm/mach/map.h> #include <asm/mach/map.h>
#include <asm/mach/mmc.h>
#include <asm/mach/time.h> #include <asm/mach/time.h>
#include <mach/board-eb.h> #include <mach/board-eb.h>
......
...@@ -24,6 +24,7 @@ ...@@ -24,6 +24,7 @@
#include <linux/sysdev.h> #include <linux/sysdev.h>
#include <linux/amba/bus.h> #include <linux/amba/bus.h>
#include <linux/amba/pl061.h> #include <linux/amba/pl061.h>
#include <linux/amba/mmci.h>
#include <linux/io.h> #include <linux/io.h>
#include <mach/hardware.h> #include <mach/hardware.h>
...@@ -37,7 +38,6 @@ ...@@ -37,7 +38,6 @@
#include <asm/mach/arch.h> #include <asm/mach/arch.h>
#include <asm/mach/flash.h> #include <asm/mach/flash.h>
#include <asm/mach/map.h> #include <asm/mach/map.h>
#include <asm/mach/mmc.h>
#include <asm/mach/time.h> #include <asm/mach/time.h>
#include <mach/board-pb1176.h> #include <mach/board-pb1176.h>
......
...@@ -24,6 +24,7 @@ ...@@ -24,6 +24,7 @@
#include <linux/sysdev.h> #include <linux/sysdev.h>
#include <linux/amba/bus.h> #include <linux/amba/bus.h>
#include <linux/amba/pl061.h> #include <linux/amba/pl061.h>
#include <linux/amba/mmci.h>
#include <linux/io.h> #include <linux/io.h>
#include <mach/hardware.h> #include <mach/hardware.h>
...@@ -38,7 +39,6 @@ ...@@ -38,7 +39,6 @@
#include <asm/mach/arch.h> #include <asm/mach/arch.h>
#include <asm/mach/flash.h> #include <asm/mach/flash.h>
#include <asm/mach/map.h> #include <asm/mach/map.h>
#include <asm/mach/mmc.h>
#include <asm/mach/time.h> #include <asm/mach/time.h>
#include <mach/board-pb11mp.h> #include <mach/board-pb11mp.h>
......
...@@ -24,6 +24,7 @@ ...@@ -24,6 +24,7 @@
#include <linux/sysdev.h> #include <linux/sysdev.h>
#include <linux/amba/bus.h> #include <linux/amba/bus.h>
#include <linux/amba/pl061.h> #include <linux/amba/pl061.h>
#include <linux/amba/mmci.h>
#include <linux/io.h> #include <linux/io.h>
#include <asm/irq.h> #include <asm/irq.h>
...@@ -34,7 +35,6 @@ ...@@ -34,7 +35,6 @@
#include <asm/mach/arch.h> #include <asm/mach/arch.h>
#include <asm/mach/map.h> #include <asm/mach/map.h>
#include <asm/mach/mmc.h>
#include <asm/mach/time.h> #include <asm/mach/time.h>
#include <mach/hardware.h> #include <mach/hardware.h>
......
...@@ -23,6 +23,7 @@ ...@@ -23,6 +23,7 @@
#include <linux/sysdev.h> #include <linux/sysdev.h>
#include <linux/amba/bus.h> #include <linux/amba/bus.h>
#include <linux/amba/pl061.h> #include <linux/amba/pl061.h>
#include <linux/amba/mmci.h>
#include <linux/io.h> #include <linux/io.h>
#include <asm/irq.h> #include <asm/irq.h>
...@@ -34,7 +35,6 @@ ...@@ -34,7 +35,6 @@
#include <asm/mach/arch.h> #include <asm/mach/arch.h>
#include <asm/mach/map.h> #include <asm/mach/map.h>
#include <asm/mach/mmc.h>
#include <asm/mach/time.h> #include <asm/mach/time.h>
#include <mach/hardware.h> #include <mach/hardware.h>
......
...@@ -19,8 +19,8 @@ ...@@ -19,8 +19,8 @@
#include <linux/regulator/consumer.h> #include <linux/regulator/consumer.h>
#include <linux/regulator/machine.h> #include <linux/regulator/machine.h>
#include <linux/gpio.h> #include <linux/gpio.h>
#include <linux/amba/mmci.h>
#include <asm/mach/mmc.h>
#include "mmc.h" #include "mmc.h"
#include "padmux.h" #include "padmux.h"
...@@ -28,7 +28,7 @@ struct mmci_card_event { ...@@ -28,7 +28,7 @@ struct mmci_card_event {
struct input_dev *mmc_input; struct input_dev *mmc_input;
int mmc_inserted; int mmc_inserted;
struct work_struct workq; struct work_struct workq;
struct mmc_platform_data mmc0_plat_data; struct mmci_platform_data mmc0_plat_data;
}; };
static unsigned int mmc_status(struct device *dev) static unsigned int mmc_status(struct device *dev)
......
...@@ -27,6 +27,7 @@ ...@@ -27,6 +27,7 @@
#include <linux/amba/bus.h> #include <linux/amba/bus.h>
#include <linux/amba/clcd.h> #include <linux/amba/clcd.h>
#include <linux/amba/pl061.h> #include <linux/amba/pl061.h>
#include <linux/amba/mmci.h>
#include <linux/clocksource.h> #include <linux/clocksource.h>
#include <linux/clockchips.h> #include <linux/clockchips.h>
#include <linux/cnt32_to_63.h> #include <linux/cnt32_to_63.h>
...@@ -47,7 +48,6 @@ ...@@ -47,7 +48,6 @@
#include <asm/mach/irq.h> #include <asm/mach/irq.h>
#include <asm/mach/time.h> #include <asm/mach/time.h>
#include <asm/mach/map.h> #include <asm/mach/map.h>
#include <asm/mach/mmc.h>
#include "core.h" #include "core.h"
#include "clock.h" #include "clock.h"
...@@ -369,7 +369,7 @@ unsigned int mmc_status(struct device *dev) ...@@ -369,7 +369,7 @@ unsigned int mmc_status(struct device *dev)
return readl(VERSATILE_SYSMCI) & mask; return readl(VERSATILE_SYSMCI) & mask;
} }
static struct mmc_platform_data mmc0_plat_data = { static struct mmci_platform_data mmc0_plat_data = {
.ocr_mask = MMC_VDD_32_33|MMC_VDD_33_34, .ocr_mask = MMC_VDD_32_33|MMC_VDD_33_34,
.status = mmc_status, .status = mmc_status,
.gpio_wp = -1, .gpio_wp = -1,
......
...@@ -24,6 +24,7 @@ ...@@ -24,6 +24,7 @@
#include <linux/sysdev.h> #include <linux/sysdev.h>
#include <linux/amba/bus.h> #include <linux/amba/bus.h>
#include <linux/amba/pl061.h> #include <linux/amba/pl061.h>
#include <linux/amba/mmci.h>
#include <linux/io.h> #include <linux/io.h>
#include <mach/hardware.h> #include <mach/hardware.h>
...@@ -31,7 +32,6 @@ ...@@ -31,7 +32,6 @@
#include <asm/mach-types.h> #include <asm/mach-types.h>
#include <asm/mach/arch.h> #include <asm/mach/arch.h>
#include <asm/mach/mmc.h>
#include "core.h" #include "core.h"
...@@ -41,7 +41,7 @@ ...@@ -41,7 +41,7 @@
#define IRQ_MMCI1A IRQ_SIC_MMCI1A #define IRQ_MMCI1A IRQ_SIC_MMCI1A
#endif #endif
static struct mmc_platform_data mmc1_plat_data = { static struct mmci_platform_data mmc1_plat_data = {
.ocr_mask = MMC_VDD_32_33|MMC_VDD_33_34, .ocr_mask = MMC_VDD_32_33|MMC_VDD_33_34,
.status = mmc_status, .status = mmc_status,
.gpio_wp = -1, .gpio_wp = -1,
......
...@@ -22,12 +22,12 @@ ...@@ -22,12 +22,12 @@
#include <linux/clk.h> #include <linux/clk.h>
#include <linux/scatterlist.h> #include <linux/scatterlist.h>
#include <linux/gpio.h> #include <linux/gpio.h>
#include <linux/amba/mmci.h>
#include <asm/cacheflush.h> #include <asm/cacheflush.h>
#include <asm/div64.h> #include <asm/div64.h>
#include <asm/io.h> #include <asm/io.h>
#include <asm/sizes.h> #include <asm/sizes.h>
#include <asm/mach/mmc.h>
#include "mmci.h" #include "mmci.h"
...@@ -537,7 +537,7 @@ static void mmci_check_status(unsigned long data) ...@@ -537,7 +537,7 @@ static void mmci_check_status(unsigned long data)
static int __devinit mmci_probe(struct amba_device *dev, struct amba_id *id) static int __devinit mmci_probe(struct amba_device *dev, struct amba_id *id)
{ {
struct mmc_platform_data *plat = dev->dev.platform_data; struct mmci_platform_data *plat = dev->dev.platform_data;
struct mmci_host *host; struct mmci_host *host;
struct mmc_host *mmc; struct mmc_host *mmc;
int ret; int ret;
......
...@@ -161,7 +161,7 @@ struct mmci_host { ...@@ -161,7 +161,7 @@ struct mmci_host {
unsigned int mclk; unsigned int mclk;
unsigned int cclk; unsigned int cclk;
u32 pwr; u32 pwr;
struct mmc_platform_data *plat; struct mmci_platform_data *plat;
u8 hw_designer; u8 hw_designer;
u8 hw_revision:4; u8 hw_revision:4;
......
/* /*
* arch/arm/include/asm/mach/mmc.h * include/linux/amba/mmci.h
*/ */
#ifndef ASMARM_MACH_MMC_H #ifndef AMBA_MMCI_H
#define ASMARM_MACH_MMC_H #define AMBA_MMCI_H
#include <linux/mmc/host.h> #include <linux/mmc/host.h>
struct mmc_platform_data { struct mmci_platform_data {
unsigned int ocr_mask; /* available voltages */ unsigned int ocr_mask; /* available voltages */
u32 (*translate_vdd)(struct device *, unsigned int); u32 (*translate_vdd)(struct device *, unsigned int);
unsigned int (*status)(struct device *); unsigned int (*status)(struct device *);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment