X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=board%2Fsocrates%2Fsocrates.c;h=2caefbbe5844a217b4380160b00044c60b609826;hb=1655f9f6c73c2b4b5d3f3b3c8aab999c194d8486;hp=72e7401f14c355050c454ad7460fdf79c05ee6fc;hpb=b6c208ab1ebc2ac01e0029b8456210617ff67156;p=u-boot diff --git a/board/socrates/socrates.c b/board/socrates/socrates.c index 72e7401f14..2caefbbe58 100644 --- a/board/socrates/socrates.c +++ b/board/socrates/socrates.c @@ -8,23 +8,7 @@ * * (C) Copyright 2002 Scott McNutt * - * 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 @@ -52,15 +36,17 @@ ulong flash_get_size (ulong base, int banknum); int checkboard (void) { volatile ccsr_gur_t *gur = (void *)(CONFIG_SYS_MPC85xx_GUTS_ADDR); - - char *src; + char buf[64]; int f; - char *s = getenv("serial#"); + int i = getenv_f("serial#", buf, sizeof(buf)); +#ifdef CONFIG_PCI + char *src; +#endif puts("Board: Socrates"); - if (s != NULL) { + if (i > 0) { puts(", serial# "); - puts(s); + puts(buf); } putc('\n'); @@ -157,7 +143,7 @@ void local_bus_init (void) get_sys_info (&sysinfo); clkdiv = lbc->lcrr & LCRR_CLKDIV; - lbc_mhz = sysinfo.freqSystemBus / 1000000 / clkdiv; + lbc_mhz = sysinfo.freq_systembus / 1000000 / clkdiv; /* Disable PLL bypass for Local Bus Clock >= 66 MHz */ if (lbc_mhz >= 66)