Re: [U-Boot] [PATCH 2/9] mx1: add i2c registers
Dear Eric Jarrige, In message 20110810203310.21204.54944.st...@shuttle2.etheralp.ch you wrote: Add i2c registers for Freescale imx1/L/S Signed-off-by: Eric Jarrige eric.jarr...@armadeus.org Cc: Stefano Babic sba...@denx.de --- arch/arm/include/asm/arch-imx/imx-regs.h | 23 +++ 1 files changed, 23 insertions(+), 0 deletions(-) Checkpatch says: total: 0 errors, 13 warnings, 27 lines checked Please clean up and resubmit. Thanks. Best regards, Wolfgang Denk -- DENX Software Engineering GmbH, MD: Wolfgang Denk Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: w...@denx.de The perversity of nature is nowhere better demonstrated by the fact that, when exposed to the same atmosphere, bread becomes hard while crackers become soft. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 2/9] mx1: add i2c registers
On 08/10/2011 10:33 PM, Eric Jarrige wrote: Add i2c registers for Freescale imx1/L/S Signed-off-by: Eric Jarrige eric.jarr...@armadeus.org Cc: Stefano Babic sba...@denx.de --- arch/arm/include/asm/arch-imx/imx-regs.h | 23 +++ 1 files changed, 23 insertions(+), 0 deletions(-) Hi Eric, +/* + * I2C module + */ +#define IADR __REG(IMX_I2C_BASE + 0x000) /* I2C Address Register */ +#define IFDR __REG(IMX_I2C_BASE + 0x004) /* I2C Frequency Divider Register*/ +#define I2CR __REG(IMX_I2C_BASE + 0x008) /* I2C Control Register */ +#define I2SR __REG(IMX_I2C_BASE + 0x00C) /* I2C Status Register */ +#define I2DR __REG(IMX_I2C_BASE + 0x010) /* I2C Data I/O Register */ See my comments on your [PATCH 3/9] apf9328: Add Armadeus Project board APF9328. Access to registers must be done via accessors and __REG macro should be removed. Best regards, Stefano Babic -- = DENX Software Engineering GmbH, MD: Wolfgang Denk Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: off...@denx.de = ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 2/9] mx1: add i2c registers
Hi Stefano, On 11 août 2011, at 10:52, Stefano Babic wrote: On 08/10/2011 10:33 PM, Eric Jarrige wrote: Add i2c registers for Freescale imx1/L/S Signed-off-by: Eric Jarrige eric.jarr...@armadeus.org Cc: Stefano Babic sba...@denx.de --- arch/arm/include/asm/arch-imx/imx-regs.h | 23 +++ 1 files changed, 23 insertions(+), 0 deletions(-) Hi Eric, +/* + * I2C module + */ +#define IADR __REG(IMX_I2C_BASE + 0x000) /* I2C Address Register */ +#define IFDR __REG(IMX_I2C_BASE + 0x004) /* I2C Frequency Divider Register*/ +#define I2CR __REG(IMX_I2C_BASE + 0x008) /* I2C Control Register */ +#define I2SR __REG(IMX_I2C_BASE + 0x00C) /* I2C Status Register */ +#define I2DR __REG(IMX_I2C_BASE + 0x010) /* I2C Data I/O Register */ See my comments on your [PATCH 3/9] apf9328: Add Armadeus Project board APF9328. Access to registers must be done via accessors and __REG macro should be removed. Ok, I remove the i2c driver from the apf9328 set of patches change the __REG macro to C struct and submit the i2c driver in a separate set of patches according to your comment in the [PATCH 3/9] Cheers, Eric ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH 2/9] mx1: add i2c registers
Add i2c registers for Freescale imx1/L/S Signed-off-by: Eric Jarrige eric.jarr...@armadeus.org Cc: Stefano Babic sba...@denx.de --- arch/arm/include/asm/arch-imx/imx-regs.h | 23 +++ 1 files changed, 23 insertions(+), 0 deletions(-) diff --git a/arch/arm/include/asm/arch-imx/imx-regs.h b/arch/arm/include/asm/arch-imx/imx-regs.h index 0c26a36..a7b3404 100644 --- a/arch/arm/include/asm/arch-imx/imx-regs.h +++ b/arch/arm/include/asm/arch-imx/imx-regs.h @@ -638,4 +638,27 @@ extern void imx_gpio_mode(int gpio_mode); #define TSTAT_CAPT (11) /* Capture event */ #define TSTAT_COMP (1) /* Compare event */ +/* + * I2C module + */ +#define IADR __REG(IMX_I2C_BASE + 0x000) /* I2C Address Register */ +#define IFDR __REG(IMX_I2C_BASE + 0x004) /* I2C Frequency Divider Register*/ +#define I2CR __REG(IMX_I2C_BASE + 0x008) /* I2C Control Register */ +#define I2SR __REG(IMX_I2C_BASE + 0x00C) /* I2C Status Register */ +#define I2DR __REG(IMX_I2C_BASE + 0x010) /* I2C Data I/O Register */ +/* I2C Control Register Bit Fields */ +#define I2CR_IEN (17) /* I2C Enable */ +#define I2CR_IIEN (16) /* I2C Interrupt Enable */ +#define I2CR_MSTA (15) /* I2C Master/Slave Mode Select */ +#define I2CR_MTX (14) /* I2C Transmit/Receive Mode Select */ +#define I2CR_TXAK (13) /* I2C Transmit Acknowledge Enable */ +#define I2CR_RSTA (12) /* I2C Repeated START */ +#define I2SR_ICF (17) /* I2C Data Transfer */ +#define I2SR_IAAS (16) /* I2C Addressed As a Slave */ +#define I2SR_IBB (15) /* I2C Bus Busy */ +#define I2SR_IAL (14) /* I2C Arbitration Lost */ +#define I2SR_SRW (12) /* I2C Slave Read/Write */ +#define I2SR_IIF (11) /* I2C interrupt */ +#define I2SR_RXAK (10) /* I2C Received Acknowledge */ + #endif /* _IMX_REGS_H */ ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot