Hi Jean-Christophe On 04/07/2009 11:27, Jean-Christophe PLAGNIOL-VILLARD wrote: > On 20:02 Fri 05 Jun , kevin.morf...@fearnside-systems.co.uk wrote: >> This re-formats the S3C24x0 drivers code to meet the coding style >> requirements >> and to make it always use the proper I/O accessor functions when accessing >> registers. It was done using 'Lindent -kr -i8 -l80' followed by manual >> inspection of the output. checkpatch.pl reports no problems with the patch >> and I've run MAKEALL for all ARM9 boards with no problems. >> >> This has been done to create a good starting point for me to add support for >> a new board, the Embest SBC2440-II. Another patch does the same for the >> ARM920 S3C24x0 CPU and headers code. >> >> Signed-off-by: Kevin Morfitt <kevin.morf...@fearnside-systems.co.uk> >> --- >> drivers/i2c/s3c24x0_i2c.c | 269 >> ++++++++++++++++++++------------------- >> drivers/mtd/nand/s3c2410_nand.c | 97 +++++++-------- >> drivers/rtc/s3c24x0_rtc.c | 126 +++++++++--------- >> drivers/serial/serial_s3c24x0.c | 143 ++++++++++++--------- >> 4 files changed, 324 insertions(+), 311 deletions(-) >> >> diff --git a/drivers/i2c/s3c24x0_i2c.c b/drivers/i2c/s3c24x0_i2c.c >> index f0c1aa3..33cd3d4 100644 >> --- a/drivers/i2c/s3c24x0_i2c.c >> +++ b/drivers/i2c/s3c24x0_i2c.c >> @@ -32,6 +32,8 @@ >> #elif defined(CONFIG_S3C2410) >> #include <s3c2410.h> >> #endif >> + >> +#include <asm/io.h> >> #include <i2c.h> >> >> #ifdef CONFIG_HARD_I2C >> @@ -42,36 +44,35 @@ >> #define I2C_OK 0 >> #define I2C_NOK 1 >> #define I2C_NACK 2 >> -#define I2C_NOK_LA 3 /* Lost arbitration */ >> -#define I2C_NOK_TOUT 4 /* time out */ >> - >> -#define I2CSTAT_BSY 0x20 /* Busy bit */ >> -#define I2CSTAT_NACK 0x01 /* Nack bit */ >> -#define I2CCON_IRPND 0x10 /* Interrupt pending bit */ >> -#define I2C_MODE_MT 0xC0 /* Master Transmit Mode */ >> -#define I2C_MODE_MR 0x80 /* Master Receive Mode */ >> -#define I2C_START_STOP 0x20 /* START / STOP */ >> -#define I2C_TXRX_ENA 0x10 /* I2C Tx/Rx enable */ >> +#define I2C_NOK_LA 3 /* Lost arbitration */ >> +#define I2C_NOK_TOUT 4 /* time out */ >> >> -#define I2C_TIMEOUT 1 /* 1 second */ >> +#define I2CSTAT_BSY 0x20 /* Busy bit */ >> +#define I2CSTAT_NACK 0x01 /* Nack bit */ >> +#define I2CCON_IRPND 0x10 /* Interrupt pending bit */ >> +#define I2C_MODE_MT 0xC0 /* Master Transmit Mode */ >> +#define I2C_MODE_MR 0x80 /* Master Receive Mode */ >> +#define I2C_START_STOP 0x20 /* START / STOP */ >> +#define I2C_TXRX_ENA 0x10 /* I2C Tx/Rx enable */ >> >> +#define I2C_TIMEOUT 1 /* 1 second */ >> >> static int GetI2CSDA(void) >> { >> S3C24X0_GPIO * const gpio = S3C24X0_GetBase_GPIO(); > const make not so much sense here > please replace by > type *name > > when you are at cleaning it please use lowercase for type and function and > var name > and replace typedef struct by struct > as > struct s3c24x0_gpio *gpio = s3c24x0_get_base_gpio(); This patch, and the others associated with adding the SBC2440-II Board, have been replaced by the series of patches "Add support for Embest SBC2440-II Board" 1 to 7. Patches 1 to 3 use lower case for var and type name, and replace typedef struct by struct, but they still have the function name as S3C24X0_GetBase_GPIO() instead of s3c24x0_getbase_gpio().
I'm happy to make the function name lower case and re-issue the "Add support for Embest SBC2440-II Board" patches 1 to 7 but it might be better if I waited for you to review them first in case you have any other comments. Also, these patches rely on one other patch that hasn't been reviewed yet - "[U-Boot] [PATCH-ARM] CONFIG_SYS_HZ fix for ARM920T S3C24X0 Boards". Best Regards Kevin > > Best Regards, > J. > __________ Information from ESET NOD32 Antivirus, version of virus signature database 4216 (20090704) __________ The message was checked by ESET NOD32 Antivirus. http://www.eset.com _______________________________________________ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot