arm: omap: am33xx: set up SPI devices
Signed-off-by: Jan Luebbe <jlu@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
This commit is contained in:
parent
88796b1a99
commit
3b16061615
|
@ -37,4 +37,20 @@ static inline struct device_d *am33xx_add_cpsw(struct cpsw_platform_data *cpsw_d
|
|||
AM335X_CPSW_BASE, SZ_32K, IORESOURCE_MEM, cpsw_data);
|
||||
}
|
||||
|
||||
static inline struct device_d *am33xx_add_spi(int id, resource_size_t start)
|
||||
{
|
||||
return add_generic_device("omap3_spi", id, NULL, start + 0x100, SZ_4K - 0x100,
|
||||
IORESOURCE_MEM, NULL);
|
||||
}
|
||||
|
||||
static inline struct device_d *am33xx_add_spi0(void)
|
||||
{
|
||||
return am33xx_add_spi(0, AM33XX_MCSPI0_BASE);
|
||||
}
|
||||
|
||||
static inline struct device_d *am33xx_add_spi1(void)
|
||||
{
|
||||
return am33xx_add_spi(1, AM33XX_MCSPI1_BASE);
|
||||
}
|
||||
|
||||
#endif /* __MACH_OMAP3_DEVICES_H */
|
||||
|
|
|
@ -49,6 +49,10 @@
|
|||
#define AM33XX_MMC1_BASE (AM33XX_L4_PER_BASE + 0x1D8000)
|
||||
#define AM33XX_MMCHS2_BASE 0x47810000
|
||||
|
||||
/* SPI */
|
||||
#define AM33XX_MCSPI0_BASE (AM33XX_L4_PER_BASE + 0x30000)
|
||||
#define AM33XX_MCSPI1_BASE (AM33XX_L4_PER_BASE + 0x1A0000)
|
||||
|
||||
/* DTMTimer0 */
|
||||
#define AM33XX_DMTIMER0_BASE (AM33XX_L4_WKUP_BASE + 0x205000)
|
||||
|
||||
|
|
|
@ -40,7 +40,7 @@ config DRIVER_SPI_MXS
|
|||
|
||||
config DRIVER_SPI_OMAP3
|
||||
bool "OMAP3 McSPI Master driver"
|
||||
depends on ARCH_OMAP3
|
||||
depends on ARCH_OMAP3 || ARCH_AM33XX
|
||||
|
||||
endif
|
||||
|
||||
|
|
Loading…
Reference in New Issue