From: Sudhakar Rajashekhar Date: Fri, 18 Dec 2009 10:23:52 +0000 (UTC) Subject: [U-Boot] [PATCH 2/3] Add board specific code for da850 EVM References: <1260959064-29783-1-git-send-email-sudhakar.raj@ti.com> <4B28CAFA.5010902@ge.com> Message-ID: List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Nick Thompson ge.com> writes: > > On 16/12/09 10:24, Sudhakar Rajashekhara wrote: > > Provides initial support for TI OMAP-L138/DA850 SoC devices on > > a Logic PD EVM board. > > > > Provides: > > Initial boot and configuration. > > Support for i2c. > > UART support (console). > > > > Signed-off-by: Sudhakar Rajashekhara ti.com> > > --- > > board/davinci/da8xxevm/Makefile | 1 + > > board/davinci/da8xxevm/da850evm.c | 124 +++++++++++++++++++++++++++++++ > > include/asm-arm/arch-davinci/hardware.h | 1 + > > 3 files changed, 126 insertions(+), 0 deletions(-) > > create mode 100644 board/davinci/da8xxevm/da850evm.c > > > > [...] > > > diff --git a/board/davinci/da8xxevm/da850evm.c b/board/davinci/da8xxevm/da850evm.c > > new file mode 100644 > > index 0000000..92548e2 > > --- /dev/null > > +++ b/board/davinci/da8xxevm/da850evm.c > > @@ -0,0 +1,124 @@ > > +/* > > + * (C) Copyright 2009, Texas Instruments, Inc. http://www.ti.com/ > > + * > > + * Based on da830evm.c > > At this point, this seem to be a copy of da830evm.c (well except the first few lines above). > I don't think you have observed that the PINMUX registers are different on da850. So we are at risk of adding many ifdefs now itself if we combine da830 and da850. Also, there are few things which differ between da830 and da850, for example, MAC address is stored in I2C eeprom on da830 and in SPI eeprom on da850. You can have a look at http://www.arago-project.org/git/people/? p=sekhar/u-boot-omapl1.git;a=summary to understand how the da830 and da850 files look later when support for most peripherals are added. To avoid code cluttering, I prefer using two separate files for da830 and da850. Regards, Sudhakar