diff options
author | Holger Brunck <holger.brunck@keymile.com> | 2015-11-17 10:53:26 +0100 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2015-11-18 15:28:53 -0500 |
commit | d3f1d6f43472f74abf34cadf0bf6236dd70177bc (patch) | |
tree | 8c189ec43243be4a6e36627e6d7ac5394e836547 /board/keymile/km82xx/km82xx.c | |
parent | 74edc607d6cd6102ac181232c5bb6562a733ea7b (diff) | |
download | u-boot-imx-d3f1d6f43472f74abf34cadf0bf6236dd70177bc.zip u-boot-imx-d3f1d6f43472f74abf34cadf0bf6236dd70177bc.tar.gz u-boot-imx-d3f1d6f43472f74abf34cadf0bf6236dd70177bc.tar.bz2 |
powerpc/82xx/km: add testpin detection for mgcoge3ne
On mgcoge3ne we also want to start the test application if the testpin
is asserted. But we don't have a full POST test support yet. So simply
add a function to read the testpin value.
Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
Signed-off-by: Valentin Longchamp <valentin.longchamp@keymile.com>
Diffstat (limited to 'board/keymile/km82xx/km82xx.c')
-rw-r--r-- | board/keymile/km82xx/km82xx.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/board/keymile/km82xx/km82xx.c b/board/keymile/km82xx/km82xx.c index 03cd10c..cc9a7c9 100644 --- a/board/keymile/km82xx/km82xx.c +++ b/board/keymile/km82xx/km82xx.c @@ -473,3 +473,12 @@ int ft_board_setup(void *blob, bd_t *bd) return 0; } #endif /* defined(CONFIG_OF_BOARD_SETUP) && defined(CONFIG_OF_LIBFDT) */ + +#if defined(CONFIG_MGCOGE3NE) +int get_testpin(void) +{ + /* Testpin is Port C pin 29 - enable = low */ + int testpin = !get_pin(0x00000004, 2); + return testpin; +} +#endif |