From: Fabio Estevam Date: Mon, 21 Sep 2009 13:58:29 -0700 (PDT) Subject: [U-Boot] [PATCH] imx51:Add support basic boot code of freescale imx51 bbg board In-Reply-To: <4AB7BE0F.4020602@gmail.com> Message-ID: <458722.17344.qm@web51007.mail.re2.yahoo.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hi Fred, --- On Mon, 9/21/09, Magnus Lilja wrote: > From: Magnus Lilja > Subject: Re: [U-Boot] [PATCH] imx51:Add support basic boot code of freescale imx51 bbg board > To: gareatech at gmail.com > Cc: u-boot at lists.denx.de > Date: Monday, September 21, 2009, 2:55 PM > Hi > > > I've scanned the patch briefly and have some comments > below. > > gareatech at gmail.com > wrote: > > From: Fred Fan > > > > This patch just supports boot into u-boot from mmc or > spi-nor flash. > > It just implements console, iomux and clock. There are > no ethernet, > > nor-flash, mmc or other peripheral drivers. > > > > Sign-of-by: Fred.Fan > > Sign-of-by: Fred.Fan > > Should be 'Signed-off-by: FredFan '. > > > > > diff --git a/MAINTAINERS b/MAINTAINERS > > index 620604c..5fb1221 100644 > > --- a/MAINTAINERS > > +++ b/MAINTAINERS > > @@ -549,6 +549,10 @@ Fabio Estevam > >? > >? ??? mx31pdk??? > ??? i.MX31 > >? > > +Fred Fan > > + > > +??? imx51??? > ??? i.MX51 > > + > > Is imx51 really the name of this board? Later on it looks > like the name is MX51_BABBAGE. I agree with Magnus. You should use the board name here, not the processor name. > > >? Peter Figuli > >? > >? ??? wepep250??? > xscale > > diff --git a/MAKEALL b/MAKEALL > > index edebaea..ed8c437 100755 > > --- a/MAKEALL > > +++ b/MAKEALL > > > > diff --git a/board/freescale/imx51/Makefile > b/board/freescale/imx51/Makefile > > new file mode 100644 > > index 0000000..fbd40f2 > > --- /dev/null > > +++ b/board/freescale/imx51/Makefile As Magnus pointed out you should use /board/freescale/mx51babbage/... > > > diff --git a/board/freescale/imx51/board-imx51.h Ditto > b/board/freescale/imx51/board-imx51.h > > new file mode 100644 > > index 0000000..7a2cae0 > > --- /dev/null > > +++ b/board/freescale/imx51/board-imx51.h > > @@ -0,0 +1,64 @@ > > +/* > > + * Copyright 2009 Freescale Semiconductor, Inc. All > Rights Reserved. > > + */ > > + > > +/* > > + * The code contained herein is licensed under the > GNU General Public > > + * License. You may obtain a copy of the GNU General > Public License > > + * Version 2 or later at the following locations: > > + * > > + * http://www.opensource.org/licenses/gpl-license.html > > + * http://www.gnu.org/copyleft/gpl.html > > + */ > > + > > +#ifndef __BOARD_FREESCALE_BOARD_IMX51_H__ > > +#define __BOARD_FREESCALE_BOARD_IMX51_H__ > > + > > +/*! > > + * @defgroup BRDCFG_MX51 Board Configuration Options > > + * @ingroup MSL_MX51 > > + */ > > + > > +/*! > > + * @file mx51_3stack/board-imx51.h > > + * > > + * @brief This file contains all the board level > configuration options. > > + * > > + * It currently hold the options defined for MX51 > 3Stack Platform. I think you should remove MX51 3stack references as it can cause confusion. > > + * > > + * @ingroup BRDCFG_IMX51 > > + */ > > + > > +/* CPLD offsets */ > > +#define PBC_LED_CTRL??? > ??? (0x20000) > > +#define PBC_SB_STAT??? > ??? (0x20008) > > +#define PBC_ID_AAAA??? > ??? (0x20040) > > +#define PBC_ID_5555??? > ??? (0x20048) > > +#define PBC_VERSION??? > ??? (0x20050) > > +#define PBC_ID_CAFE??? > ??? (0x20058) > > +#define PBC_INT_STAT??? > ??? (0x20010) > > +#define PBC_INT_MASK??? > ??? (0x20038) > > +#define PBC_INT_REST??? > ??? (0x20020) > > +#define PBC_SW_RESET??? > ??? (0x20060) > > + > > +/* LED switchs */ > > +#define LED_SWITCH_REG??? > ??? 0x00 > > +/* buttons */ > > +#define SWITCH_BUTTONS_REG??? 0x08 > > +/* status, interrupt */ > > +#define INTR_STATUS_REG??? 0x10 > > +#define INTR_MASK_REG??? > ??? 0x38 > > +#define INTR_RESET_REG??? > ??? 0x20 > > +/* magic word for debug CPLD */ > > +#define MAGIC_NUMBER1_REG??? 0x40 > > +#define MAGIC_NUMBER2_REG??? 0x48 > > +/* CPLD code version */ > > +#define CPLD_CODE_VER_REG??? 0x50 > > +/* magic word for debug CPLD */ > > +#define MAGIC_NUMBER3_REG??? 0x58 > > +/* module reset register*/ > > +#define MODULE_RESET_REG??? 0x60 > > +/* CPU ID and Personality ID */ > > +#define MCU_BOARD_ID_REG??? 0x68 > > + > > +#endif??? ??? > ??? ??? /* > __BOARD_FREESCALE_BOARD_IMX51_H__ */ > > diff --git a/board/freescale/imx51/config.mk > b/board/freescale/imx51/config.mk > > new file mode 100644 > > index 0000000..d8b0f10 > > --- /dev/null > > +++ b/board/freescale/imx51/config.mk > > @@ -0,0 +1,2 @@ > > +LDSCRIPT = board/$(VENDOR)/$(BOARD)/u-boot.lds > > +TEXT_BASE = 0x97800000 > > diff --git a/board/freescale/imx51/flash_header.S > b/board/freescale/imx51/flash_header.S > > new file mode 100644 > > index 0000000..6790679 > > --- /dev/null > > +++ b/board/freescale/imx51/flash_header.S > > @@ -0,0 +1,113 @@ > > +/* > > + * Copyright 2009 Freescale Semiconductor, Inc. > > + * > > + * 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 > > + */ > > + > > I wouldn't mind a short description of what this file does > and why it's needed. Yes, please mention that this is needed for the internal boot mode. Regards, Fabio Estevam