[U-Boot] [PATCH v2] mpc85xx: Add support for the Varisys Cyrus board
Andy Fleming
afleming at gmail.com
Wed Nov 4 20:05:50 CET 2015
On Wed, Nov 4, 2015 at 12:39 PM, York Sun <yorksun at freescale.com> wrote:
>
>
> On 11/03/2015 03:30 PM, Andy Fleming wrote:
>> This board runs a P5020 or P5040 chip, and utilizes
>> an EEPROM with similar formatting to the Freescale P5020DS.
>>
>> Large amounts of this code were developed by
>> Adrian Cox <adrian at humboldt dot co dot uk>
>>
>> Signed-off-by: Andy Fleming <afleming at gmail.com>
>> ---
>> v2:
>> * Cleaned up sys_eeprom.c
>> * Removed CONFIG_CMD_ELF, CONFIG_SYS_GENERIC_BOARD
>
> Why do you want to remove CONFIG_SYS_GENERIC_BOARD? We are dropping non-generic
> board.
Sorry, my comment was misleading. I didn't disable
CONFIG_SYS_GENERIC_BOARD. I removed it from the config file because
this patch made it the default:
commit 09f3ca3dd53b671b009ddc4e1dad669c280094f0
Author: Masahiro Yamada <yamada.masahiro at socionext.com>
Date: Tue Oct 20 21:09:06 2015 +0900
arm, powerpc: select SYS_GENERIC_BOARD
Otherwise, u-boot doesn't build. Same thing is true for
CONFIG_CMD_ELF. Didn't disable it, just deleted the redundant config.
>
>>
>> arch/powerpc/cpu/mpc85xx/Kconfig | 4 +
>> board/varisys/common/Makefile | 23 ++
>> board/varisys/common/eeprom.h | 6 +
>> board/varisys/common/sys_eeprom.c | 500 +++++++++++++++++++++++++++++
>> board/varisys/cyrus/Kconfig | 13 +
>> board/varisys/cyrus/Makefile | 8 +
>> board/varisys/cyrus/README | 21 ++
>> board/varisys/cyrus/cyrus.c | 116 +++++++
>> board/varisys/cyrus/cyrus.h | 11 +
>> board/varisys/cyrus/ddr.c | 188 +++++++++++
>> board/varisys/cyrus/eth.c | 100 ++++++
>> board/varisys/cyrus/law.c | 27 ++
>> board/varisys/cyrus/pbi.cfg | 35 +++
>> board/varisys/cyrus/pci.c | 23 ++
>> board/varisys/cyrus/rcw_p5020_v2.cfg | 11 +
>> board/varisys/cyrus/rcw_p5040.cfg | 11 +
>> board/varisys/cyrus/tlb.c | 106 +++++++
>> configs/Cyrus_P5020_defconfig | 9 +
>> configs/Cyrus_P5040_defconfig | 9 +
>> include/configs/cyrus.h | 588 +++++++++++++++++++++++++++++++++++
>> 20 files changed, 1809 insertions(+)
>> create mode 100644 board/varisys/common/Makefile
>> create mode 100644 board/varisys/common/eeprom.h
>> create mode 100644 board/varisys/common/sys_eeprom.c
>> create mode 100644 board/varisys/cyrus/Kconfig
>> create mode 100644 board/varisys/cyrus/Makefile
>> create mode 100644 board/varisys/cyrus/README
>> create mode 100644 board/varisys/cyrus/cyrus.c
>> create mode 100644 board/varisys/cyrus/cyrus.h
>> create mode 100644 board/varisys/cyrus/ddr.c
>> create mode 100644 board/varisys/cyrus/eth.c
>> create mode 100644 board/varisys/cyrus/law.c
>> create mode 100644 board/varisys/cyrus/pbi.cfg
>> create mode 100644 board/varisys/cyrus/pci.c
>> create mode 100644 board/varisys/cyrus/rcw_p5020_v2.cfg
>> create mode 100644 board/varisys/cyrus/rcw_p5040.cfg
>> create mode 100644 board/varisys/cyrus/tlb.c
>> create mode 100644 configs/Cyrus_P5020_defconfig
>> create mode 100644 configs/Cyrus_P5040_defconfig
>> create mode 100644 include/configs/cyrus.h
>
> Please add MAINTAINERS file.
Will do.
>
> <snip>
>
>> diff --git a/board/varisys/common/sys_eeprom.c b/board/varisys/common/sys_eeprom.c
>> new file mode 100644
>> index 0000000..086fad2
>> --- /dev/null
>> +++ b/board/varisys/common/sys_eeprom.c
>> @@ -0,0 +1,500 @@
>> +/*
>> + * Copyright 2006, 2008-2009, 2011 Freescale Semiconductor
>> + * York Sun (yorksun at freescale.com)
>> + * Haiying Wang (haiying.wang at freescale.com)
>> + * Timur Tabi (timur at freescale.com)
>> + *
>> + * This defines the API for storing board information in the
>> + * eeprom. It has been adapted from an earlier version of the
>> + * Freescale code for doing the same thing. Therefore it is
>> + * nearly identical to the Freescale code, but is intended for
>> + * use with Varisys-produced boards.
>> + *
>> + * SPDX-License-Identifier: GPL-2.0+
>> + */
>> +
>> +#include <common.h>
>> +#include <command.h>
>> +#include <i2c.h>
>> +#include <linux/ctype.h>
>> +
>> +#include "eeprom.h"
>> +
>> +#ifdef CONFIG_SYS_I2C_EEPROM_NXID_MAC
>> +#define MAX_NUM_PORTS CONFIG_SYS_I2C_EEPROM_NXID_MAC
>> +#else
>> +#define MAX_NUM_PORTS 8
>> +#endif
>> +#define NXID_VERSION 0
>> +
>> +/**
>> + * static eeprom: EEPROM layout for NXID formats
>> + *
>> + * See Freescale application note AN3638 for details.
>> + */
>
> This comment and file header still implies this file follows Freescale EEPROM
> spec. I think additional comment is needed to state the difference.
>
> There are several blank lines added to the end of files.
I'll fix these and send a new version today.
Andy
More information about the U-Boot
mailing list