> -----Original Message-----
> From: Simon Kagstrom [mailto:simon.kagst...@netinsight.net] 
> Sent: Thursday, June 10, 2010 3:56 PM
> To: Tanmay Upadhyay
> Cc: Prafulla Wadaskar; u-boot@lists.denx.de
> Subject: Re: [PATCH] ARM: Kirkwood: Add support for 
> OpenRD-Client & OpenRD-Ultimate
> 
> On Thu, 10 Jun 2010 15:08:00 +0530
> Tanmay Upadhyay <tanmay.upadh...@einfochips.com> wrote:
> 
> > >> +#define MACH_TYPE_OPENRD_ULTIMATE      2884
> > >>      
> > > I don't think this file is supposed to be edited in 
> patches, but rather
> > > synched from arm-linux by Wolfgang from time to time.
> >
> > Sorry, I didn't know about that. However, as the number is already 
> > registered, is that ok to have it here?
> 
> Probably Wolfgang or Tom Rix (the ARM maintainer) can synch it if you
> ask them to.

Tom Does this frequently, Hi Tom, can you pls do the needful?

> 
> > I agree with you. But auto-generated 'config.h' file includes 
> > <board_name.h>. So there has to be one for each board. 

Yes, This is correct approach, lets have three files for three boards (like 
other added)
Abstract common part in openrd.h and include it in respective board config 
header files.

> However, there 
> > could be one 'openrd.h'  in the configs and three board 
> specific files 
> > include it. This will increase the number of files, but 
> would decrease 
> > LOC. What do you think?

As suggested above, let's keep code clean and simple.
Adding new board support in future to the same family will keep on increasing 
code complexity.
I prefer adding few files instead of modifying existing.
Secondly kwimage.cfg in your port may have common settings for all three board 
which may not be the case always.
And file parsing does not support conditional code for this file.

So I suggest, you should keep common code under openrd.c/h, and board specific 
in <board_name>.c/h
Even I don't mind keeping existing openrd_base board support as it is and 
adding new board support for two other boards.

Regards..
Prafulla . .
_______________________________________________
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Reply via email to