[U-Boot] [PATCH V3 2/2] Kirkwood: Add support for Ka-Ro TK71

Prafulla Wadaskar prafulla at marvell.com
Tue Jul 3 15:00:09 CEST 2012



> -----Original Message-----
> From: Marek Vasut [mailto:marex at denx.de]
> Sent: 03 July 2012 18:21
> To: Prafulla Wadaskar
> Cc: u-boot at lists.denx.de; Wolfgang Denk
> Subject: Re: [PATCH V3 2/2] Kirkwood: Add support for Ka-Ro TK71
> 
> Dear Prafulla Wadaskar,
> 
> > > -----Original Message-----
> > > From: Marek Vasut [mailto:marex at denx.de]
> > > Sent: 03 July 2012 17:58
> > > To: u-boot at lists.denx.de
> > > Cc: Marek Vasut; Prafulla Wadaskar; Wolfgang Denk
> > > Subject: [PATCH V3 2/2] Kirkwood: Add support for Ka-Ro TK71
> > >
> > > Signed-off-by: Marek Vasut <marex at denx.de>
> > > Cc: Prafulla Wadaskar <prafulla at marvell.com>
> > > Cc: Wolfgang Denk <wd at denx.de>
> >
> > ...snip...
> >
> > > diff --git a/board/karo/tk71/tk71.c b/board/karo/tk71/tk71.c
> > > new file mode 100644
> > > index 0000000..50b563e
> > > --- /dev/null
> > > +++ b/board/karo/tk71/tk71.c
> > > @@ -0,0 +1,174 @@
> > > +/*
> > > + * Copyright (C) 2012 Marek Vasut <marex at denx.de>
> > > + * on behalf of DENX Software Engineering GmbH
> > > + *
> > > + * 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
> > > + */
> > > +
> > > +#include <common.h>
> > > +#include <miiphy.h>
> > > +#include <asm/arch/cpu.h>
> > > +#include <asm/arch/kirkwood.h>
> > > +#include <asm/arch/mpp.h>
> > > +#include <asm/io.h>
> > > +
> > > +DECLARE_GLOBAL_DATA_PTR;
> > > +
> > > +#define TK71_OE_LOW			(~0)
> > > +#define TK71_OE_HIGH			(~0)
> > > +#define TK71_OE_VAL_LOW			(0)
> > > +#define TK71_OE_VAL_HIGH		(0)
> > > +
> > > +int board_early_init_f(void)
> > > +{
> > > +	unsigned long size = get_ram_size(PHYS_SDRAM_1,
> > > PHYS_SDRAM_1_SIZE);
> > > +
> > > +	/* 256MB module, adjust BAR register */
> > > +	if (size == 256 * 1024 * 1024) {
> > > +		writel(KW_REG_CPUCS_WIN_ENABLE |
> KW_REG_CPUCS_WIN_SIZE(0xf),
> > > +			KW_REG_CPUCS_WIN_SZ(0));
> > > +	}
> >
> > Hi Marek
> > This is first patch to support this board series, so ideally you
> don't need
> > further tuning of DRAM configuration, if you address it in
> kwbimage.cfg
> 
> What do you mean adress is in kwbimage.cfg ?
> 
> > You may think of this approach if you have similar board support in
> future.
> >
> > Please post the patch w/o updating DRAM registers or
> 
> How exactly would you support the 256MB variant?
> 
> > Let's do it in cleaner way.
> 
> I already asked -- did you get anywhere with the cleaner approach?
> It's not even
> discussed properly yet, let alone implemented.

Let's discuss and address this first

> 
> > macros are NOT encouraged to use for register definition.
> 
> What do you mean?

KW_REGISTER(0x1504) + (x * 0x08) is not recommended, let's use c-struct for this.

Regards..
Prafulla . . .


More information about the U-Boot mailing list