diff options
author | Heiko Schocher <hs@denx.de> | 2011-03-15 16:52:29 +0100 |
---|---|---|
committer | Wolfgang Denk <wd@denx.de> | 2011-04-30 00:44:22 +0200 |
commit | b11f53f31b97536c74d75e7678ad7a363a9537da (patch) | |
tree | 48fd9244ad791ab6fe0365ddf186d634719a730d /board/keymile/common/common.h | |
parent | 802d996324777173f123116c00a6c654f4a4177a (diff) | |
download | u-boot-imx-b11f53f31b97536c74d75e7678ad7a363a9537da.zip u-boot-imx-b11f53f31b97536c74d75e7678ad7a363a9537da.tar.gz u-boot-imx-b11f53f31b97536c74d75e7678ad7a363a9537da.tar.bz2 |
keymile: Fix Coding style issues for keymile boards.
- use I/O accessors
-> For accessing the FPGA therefore a struct km_bec_fpga
is introduced.
- no longer externs needed
- to defines, that only select functions, don;t assign a
numeric value
- Codingstyle changes to prevent checkpatch errors/warnings
Signed-off-by: Heiko Schocher <hs@denx.de>
Acked-by: Kim Phillips <kim.phillips@freescale.com>
cc: Kim Phillips <kim.phillips@freescale.com>
cc: Holger Brunck <holger.brunck@keymile.com>
cc: Wolfgang Denk <wd@denx.de>
cc: Detlev Zundel <dzu@denx.de>
cc: Valentin Longchamp <valentin.longchamp@keymile.com>
cc: Prafulla Wadaskar <prafulla@marvell.com>
Diffstat (limited to 'board/keymile/common/common.h')
-rw-r--r-- | board/keymile/common/common.h | 40 |
1 files changed, 35 insertions, 5 deletions
diff --git a/board/keymile/common/common.h b/board/keymile/common/common.h index a38c727..8497ab6 100644 --- a/board/keymile/common/common.h +++ b/board/keymile/common/common.h @@ -11,20 +11,50 @@ #ifndef __KEYMILE_COMMON_H #define __KEYMILE_COMMON_H -int ethernet_present (void); -int ivm_read_eeprom (void); +#define WRG_RESET 0x80 +#define H_OPORTS_14 0x40 +#define WRG_LED 0x02 +#define WRL_BOOT 0x01 + +#define H_OPORTS_SCC4_ENA 0x10 +#define H_OPORTS_SCC4_FD_ENA 0x04 +#define H_OPORTS_FCC1_PW_DWN 0x01 + +#define PIGGY_PRESENT 0x80 + +struct km_bec_fpga { + unsigned char id; + unsigned char rev; + unsigned char oprth; + unsigned char oprtl; + unsigned char res1[3]; + unsigned char bprth; + unsigned char bprtl; + unsigned char res2[6]; + unsigned char prst; + unsigned char res3[0xfff0]; + unsigned char pgy_id; + unsigned char pgy_rev; + unsigned char pgy_outputs; + unsigned char pgy_eth; +}; + +int ethernet_present(void); +int ivm_read_eeprom(void); #ifdef CONFIG_KEYMILE_HDLC_ENET -int keymile_hdlc_enet_initialize (bd_t *bis); +int keymile_hdlc_enet_initialize(bd_t *bis); #endif -int fdt_set_node_and_value (void *blob, +int fdt_set_node_and_value(void *blob, char *nodename, char *regname, void *var, int size); -int fdt_get_node_and_value (void *blob, +int fdt_get_node_and_value(void *blob, char *nodename, char *propname, void **var); + +int i2c_soft_read_pin(void); #endif /* __KEYMILE_COMMON_H */ |