linux-mips
[Top] [All Lists]

Re: Fix board type in db1x00

To: "Dan Malek" <dan@embeddedalley.com>
Subject: Re: Fix board type in db1x00
From: "Jordan Crouse" <jordan.crouse@amd.com>
Date: Tue, 22 Nov 2005 17:15:34 -0700
Cc: linux-mips@linux-mips.org, ralf@linux-mips.org
In-reply-to: <6dabaec28e238ccc915f20f51ee28327@embeddedalley.com>
Original-recipient: rfc822;linux-mips@linux-mips.org
References: <20051122221526.GZ18119@cosmic.amd.com> <6dabaec28e238ccc915f20f51ee28327@embeddedalley.com>
Sender: linux-mips-bounce@linux-mips.org
User-agent: Mutt/1.5.11
On 22/11/05 17:31 -0500, Dan Malek wrote:
> 
> On Nov 22, 2005, at 5:15 PM, Jordan Crouse wrote:
> 
> >+    /* Set the platform # */
> >+#if defined (CONFIG_MIPS_DB1550)
> >+    mips_machtype = MACH_DB1550;
> >+#elif       defined (CONFIG_MIPS_DB1500)
> >+    mips_machtype = MACH_DB1500;
> >+#elif       defined (CONFIG_MIPS_DB1100)
> >+    mips_machtype = MACH_DB1100;
> >+#else
> >+    mips_machtype = MACH_DB1000;
> >+#endif
> 
> Can't we just do something like
>       #define MACH_ALCHEMY_TYPE  xxxxx
> 
> in the include files and not have this mess in the
> actual code?  Then, all we have to do here is:
> 
>       mips_machtype = MACH_ALCHEMY_TYPE;

The problem with db1x00 in particular is that its sort of a 
catch all for all the Alchemy boards that don't have a proper home
of their own, so there really isn't a DB1000/DB1100/DB1500/DB1550 
header file.  That means either the mess goes in here or it goes
in asm-mips/mach-db1x00/db1x00.h, and I think I rather prefer it to
be in the .c file, just so one doesn't have to chase down the 
MACH_ALCHEMY_TYPE define. 

Jordan

-- 
Jordan Crouse
Senior Linux Engineer
AMD - Personal Connectivity Solutions Group
<www.amd.com/embeddedprocessors>


<Prev in Thread] Current Thread [Next in Thread>