summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJuergen Borleis <jbe@pengutronix.de>2015-07-31 11:03:51 +0200
committerSascha Hauer <s.hauer@pengutronix.de>2015-08-03 08:52:43 +0200
commit90c52fe07a1073826d009d2b5f1d4e5d8350580f (patch)
tree388a49398c913e3b98382617829d9e42b329e825
parentd2e8305b34af8ad9f4a9f698625d6cb3cf176501 (diff)
downloadbarebox-90c52fe07a1073826d009d2b5f1d4e5d8350580f.tar.gz
barebox-90c52fe07a1073826d009d2b5f1d4e5d8350580f.tar.xz
PPC/MPC5200: re-use the IMX I2C master driver for MPC5200
This IP core is shared between many FSL SoCs. The MPC5200 provides this core as well. Signed-off-by: Juergen Borleis <jbe@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
-rw-r--r--arch/ppc/mach-mpc5xxx/include/mach/clock.h4
-rw-r--r--drivers/i2c/busses/Kconfig9
2 files changed, 11 insertions, 2 deletions
diff --git a/arch/ppc/mach-mpc5xxx/include/mach/clock.h b/arch/ppc/mach-mpc5xxx/include/mach/clock.h
index 4e1a903e79..b19686f18c 100644
--- a/arch/ppc/mach-mpc5xxx/include/mach/clock.h
+++ b/arch/ppc/mach-mpc5xxx/include/mach/clock.h
@@ -6,5 +6,9 @@ unsigned long get_cpu_clock(void);
unsigned long get_ipb_clock(void);
unsigned long get_pci_clock(void);
unsigned long get_timebase_clock(void);
+static inline unsigned long fsl_get_i2c_freq(void)
+{
+ return get_ipb_clock();
+}
#endif /* __ASM_ARCH_CLOCKS_H */
diff --git a/drivers/i2c/busses/Kconfig b/drivers/i2c/busses/Kconfig
index 39622863fb..181321b159 100644
--- a/drivers/i2c/busses/Kconfig
+++ b/drivers/i2c/busses/Kconfig
@@ -17,8 +17,13 @@ config I2C_AT91
depends on ARCH_AT91
config I2C_IMX
- bool "MPC85xx/i.MX I2C Master driver"
- depends on (ARCH_IMX && !ARCH_IMX1) || ARCH_MPC85XX
+ bool "MPC85xx/MPC5200/i.MX I2C Master driver"
+ depends on (ARCH_IMX && !ARCH_IMX1) || ARCH_MPC85XX || ARCH_MPC5200
+ help
+ If you say yes to this option, support will be included for many
+ built-in I2C master controllers found in Freescale SoCs. This is true
+ for many i.MX ARM based SoCs, for MPC85xx and MPC5200 PowerPC based
+ SoCs.
config I2C_MV64XXX
bool "Marvell mv64xxx I2C Controller"