diff options
author | Alessandro Rubini <rubini@unipv.it> | 2009-07-24 11:27:14 +0200 |
---|---|---|
committer | Heiko Schocher <hs@denx.de> | 2009-07-29 09:57:47 +0200 |
commit | bb4291e62579dbc611e84eaaf973631e0bf129c7 (patch) | |
tree | 2a2bc8563067e0554fd154184cb6b0866d2a5096 /include/configs/nhk8815.h | |
parent | 60cbfbfd0fbebb4682f10ba96f622bfe17317598 (diff) | |
download | u-boot-imx-bb4291e62579dbc611e84eaaf973631e0bf129c7.zip u-boot-imx-bb4291e62579dbc611e84eaaf973631e0bf129c7.tar.gz u-boot-imx-bb4291e62579dbc611e84eaaf973631e0bf129c7.tar.bz2 |
arm nomadik: add i2c
Signed-off-by: Alessandro Rubini <rubini@unipv.it>
Acked-by: Andrea Gallo <andrea.gallo@stericsson.com>
Acked-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Diffstat (limited to 'include/configs/nhk8815.h')
-rw-r--r-- | include/configs/nhk8815.h | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/include/configs/nhk8815.h b/include/configs/nhk8815.h index 3e2e09f..8a83d92 100644 --- a/include/configs/nhk8815.h +++ b/include/configs/nhk8815.h @@ -93,7 +93,7 @@ #define CONFIG_SYS_GBL_DATA_SIZE 128 /* for initial data */ #define CONFIG_SYS_64BIT_VSPRINTF /* mtd desires this */ -#define CONFIG_MISC_INIT_R /* call misc_init_r during start up */ +#define BOARD_LATE_INIT /* call board_late_init during start up */ /* timing informazion */ #define CONFIG_SYS_HZ 1000 /* Mandatory... */ @@ -110,6 +110,22 @@ #define CONFIG_PL01x_PORTS { (void *)CFG_SERIAL0, (void *)CFG_SERIAL1 } #define CONFIG_PL011_CLOCK 48000000 +/* i2c, for the port extenders (uses gpio.c in board directory) */ +#ifndef __ASSEMBLY__ +#include <asm/arch/gpio.h> +#define CONFIG_CMD_I2C +#define CONFIG_SOFT_I2C +#define CONFIG_SYS_I2C_SPEED 400000 +#define __SDA 63 +#define __SCL 62 +#define I2C_SDA(x) nmk_gpio_set(__SDA, x) +#define I2C_SCL(x) nmk_gpio_set(__SCL, x) +#define I2C_READ (nmk_gpio_get(__SDA)!=0) +#define I2C_ACTIVE nmk_gpio_dir(__SDA, 1) +#define I2C_TRISTATE nmk_gpio_dir(__SDA, 0) +#define I2C_DELAY (udelay(2)) +#endif /* __ASSEMBLY__ */ + /* Ethernet */ #define PCI_MEMORY_VADDR 0xe8000000 #define PCI_IO_VADDR 0xee000000 |