[PATCH] ARM i.MX31: Add i2c register convenience functions
Sascha Hauer
s.hauer at pengutronix.de
Tue Aug 2 22:28:37 PDT 2016
On Wed, Jul 27, 2016 at 04:52:52PM +0200, Alexander Kurz wrote:
> Signed-off-by: Alexander Kurz <akurz at blala.de>
> ---
> arch/arm/mach-imx/include/mach/devices-imx31.h | 15 +++++++++++++++
> 1 file changed, 15 insertions(+)
Applied, thanks
Sascha
>
> diff --git a/arch/arm/mach-imx/include/mach/devices-imx31.h b/arch/arm/mach-imx/include/mach/devices-imx31.h
> index 63319fe..8169b98 100644
> --- a/arch/arm/mach-imx/include/mach/devices-imx31.h
> +++ b/arch/arm/mach-imx/include/mach/devices-imx31.h
> @@ -2,6 +2,21 @@
> #include <mach/imx31-regs.h>
> #include <mach/devices.h>
>
> +static inline struct device_d *imx31_add_i2c0(void *pdata)
> +{
> + return imx_add_i2c((void *)MX31_I2C1_BASE_ADDR, 0, pdata);
> +}
> +
> +static inline struct device_d *imx31_add_i2c1(void *pdata)
> +{
> + return imx_add_i2c((void *)MX31_I2C2_BASE_ADDR, 1, pdata);
> +}
> +
> +static inline struct device_d *imx31_add_i2c2(void *pdata)
> +{
> + return imx_add_i2c((void *)MX31_I2C3_BASE_ADDR, 2, pdata);
> +}
> +
> static inline struct device_d *imx31_add_spi0(struct spi_imx_master *pdata)
> {
> return imx_add_spi_imx27((void *)MX31_CSPI1_BASE_ADDR, 0, pdata);
> --
> 2.1.4
>
>
> _______________________________________________
> barebox mailing list
> barebox at lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/barebox
>
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
More information about the barebox
mailing list