X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=board%2Fbuffalo%2Flsxl%2Flsxl.c;h=8ae420740d1bab3055798e7459437cfe047b2bec;hb=ebca902aeb3af3eaedd2787928184ad84a86b98f;hp=83eea04cbcb90dcccc72ab587026b98cf727b7f3;hpb=612404c28a64a6df300642a1550a65dcc8e01f82;p=u-boot diff --git a/board/buffalo/lsxl/lsxl.c b/board/buffalo/lsxl/lsxl.c index 83eea04cbc..8ae420740d 100644 --- a/board/buffalo/lsxl/lsxl.c +++ b/board/buffalo/lsxl/lsxl.c @@ -5,35 +5,21 @@ * Based on sheevaplug/sheevaplug.c by * Marvell Semiconductor * - * 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., 51 Franklin Street, Fifth Floor, Boston, - * MA 02110-1301 USA + * SPDX-License-Identifier: GPL-2.0+ */ #include +#include #include #include #include #include -#include +#include +#include +#include #include #include #include -#include #include "lsxl.h" @@ -67,9 +53,9 @@ int board_early_init_f(void) * There are maximum 64 gpios controlled through 2 sets of registers * the below configuration configures mainly initial LED status */ - kw_config_gpio(LSXL_OE_VAL_LOW, - LSXL_OE_VAL_HIGH, - LSXL_OE_LOW, LSXL_OE_HIGH); + mvebu_config_gpio(LSXL_OE_VAL_LOW, + LSXL_OE_VAL_HIGH, + LSXL_OE_LOW, LSXL_OE_HIGH); /* * Multi-Purpose Pins Functionality configuration @@ -183,7 +169,7 @@ static void set_led(int state) int board_init(void) { /* address of boot parameters */ - gd->bd->bi_boot_params = kw_sdram_bar(0) + 0x100; + gd->bd->bi_boot_params = mvebu_sdram_bar(0) + 0x100; set_led(LED_POWER_BLINKING); @@ -218,7 +204,7 @@ void check_enetaddr(void) { uchar enetaddr[6]; - if (!eth_getenv_enetaddr("ethaddr", enetaddr)) { + if (!eth_env_get_enetaddr("ethaddr", enetaddr)) { /* signal unset/invalid ethaddr to user */ set_led(LED_INFO_BLINKING); } @@ -242,20 +228,8 @@ static void erase_environment(void) static void rescue_mode(void) { - uchar enetaddr[6]; - printf("Entering rescue mode..\n"); -#ifdef CONFIG_RANDOM_MACADDR - if (!eth_getenv_enetaddr("ethaddr", enetaddr)) { - eth_random_enetaddr(enetaddr); - if (eth_setenv_enetaddr("ethaddr", enetaddr)) { - printf("Failed to set ethernet address\n"); - set_led(LED_ALARM_BLINKING); - return; - } - } -#endif - setenv("bootsource", "rescue"); + env_set("bootsource", "rescue"); } static void check_push_button(void)