diff options
Diffstat (limited to 'board/keymile/common')
-rw-r--r-- | board/keymile/common/common.c | 18 | ||||
-rw-r--r-- | board/keymile/common/common.h | 5 | ||||
-rw-r--r-- | board/keymile/common/ivm.c | 37 |
3 files changed, 5 insertions, 55 deletions
diff --git a/board/keymile/common/common.c b/board/keymile/common/common.c index 544784a..136b2de 100644 --- a/board/keymile/common/common.c +++ b/board/keymile/common/common.c @@ -5,23 +5,7 @@ * (C) Copyright 2011 * Holger Brunck, Keymile GmbH Hannover, holger.brunck@keymile.com * - * See file CREDITS for list of people who contributed to this - * project. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License as - * published by the Free Software Foundation; either version 2 of - * the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, - * MA 02111-1307 USA + * SPDX-License-Identifier: GPL-2.0+ */ #include <common.h> diff --git a/board/keymile/common/common.h b/board/keymile/common/common.h index aab706e..e075f46 100644 --- a/board/keymile/common/common.h +++ b/board/keymile/common/common.h @@ -2,10 +2,7 @@ * (C) Copyright 2008 * Heiko Schocher, DENX Software Engineering, hs@denx.de. * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License as - * published by the Free Software Foundation; either version 2 of - * the License, or (at your option) any later version. + * SPDX-License-Identifier: GPL-2.0+ */ #ifndef __KEYMILE_COMMON_H diff --git a/board/keymile/common/ivm.c b/board/keymile/common/ivm.c index 0deed1d..f0e91bb 100644 --- a/board/keymile/common/ivm.c +++ b/board/keymile/common/ivm.c @@ -2,23 +2,7 @@ * (C) Copyright 2011 * Holger Brunck, Keymile GmbH Hannover, holger.brunck@keymile.com * - * See file CREDITS for list of people who contributed to this - * project. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License as - * published by the Free Software Foundation; either version 2 of - * the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, - * MA 02111-1307 USA + * SPDX-License-Identifier: GPL-2.0+ */ #include <common.h> @@ -314,29 +298,14 @@ static int ivm_analyze_eeprom(unsigned char *buf, int len) int ivm_read_eeprom(void) { -#if defined(CONFIG_I2C_MUX) - I2C_MUX_DEVICE *dev = NULL; -#endif uchar i2c_buffer[CONFIG_SYS_IVM_EEPROM_MAX_LEN]; - uchar *buf; - unsigned long dev_addr = CONFIG_SYS_IVM_EEPROM_ADR; int ret; -#if defined(CONFIG_I2C_MUX) - /* First init the Bus, select the Bus */ - buf = (unsigned char *) getenv("EEprom_ivm"); - if (buf != NULL) - dev = i2c_mux_ident_muxstring(buf); - if (dev == NULL) { - printf("Error couldnt add Bus for IVM\n"); - return -1; - } - i2c_set_bus_num(dev->busid); -#endif + i2c_set_bus_num(CONFIG_KM_IVM_BUS); /* add deblocking here */ i2c_make_abort(); - ret = i2c_read(dev_addr, 0, 1, i2c_buffer, + ret = i2c_read(CONFIG_SYS_IVM_EEPROM_ADR, 0, 1, i2c_buffer, CONFIG_SYS_IVM_EEPROM_MAX_LEN); if (ret != 0) { printf("Error reading EEprom\n"); |