Please look at arch/i386/include/arch/io.h
Romcc need some built-in function, that can not be use gcc and
cache_as_ram.
So you can substitute, __ROMCC__ with __PRE_SDRAM__, it is just a
symbol....
YH
-----Original Message-----
From: Li-Ta Lo [mailto:ollie@lanl.gov]
Sent: Thursday, October 27, 2005 2:38 PM
To: Lu, Yinghai
Cc: LinuxBIOS
Subject: RE: [LinuxBIOS] Config file dependencies
On Thu, 2005-10-27 at 14:11 -0700, Lu, Yinghai wrote:
> You want CAR only or make them coexist?
>
Why does #define __PRE_SDRAM__ makes them non-coexist?
> YH
>
> -----Original Message-----
> From: Li-Ta Lo [mailto:ollie@lanl.gov]
> Sent: Thursday, October 27, 2005 2:01 PM
> To: Lu, Yinghai
> Cc: LinuxBIOS
> Subject: RE: [LinuxBIOS] Config file dependencies
>
> On Thu, 2005-10-27 at 13:49 -0700, Lu, Yinghai wrote:
> > __ASSEMBLY__ already be used.
> >
> > __PRE_SDRAM__ maybe good, but if we define USE_DCACHE = 1,
> > __ROMCC__is equal to __PRE_SDRAM___ it mean code will be compiled by
> gcc
> > instead of romcc.
> >
>
> If we #define __PRE_SDRAM__ then we can change
>
> #if !defined( __ROMCC__ ) && defined( __GNUC__)
> #include <device/device.h>
>
> to
> #if !defined(__PRE_SDRAM__)
> #include <device/device.h>
>
> Actually we should move most of the romcc_io.h into pre_dram.h
>
>
> > YH
> >
> > -----Original Message-----
> > From: linuxbios-bounces(a)openbios.org
> > [mailto:linuxbios-bounces@openbios.org] On Behalf Of Li-Ta Lo
> > Sent: Thursday, October 27, 2005 1:30 PM
> > To: Lu, Yinghai
> > Cc: LinuxBIOS
> > Subject: RE: [LinuxBIOS] Config file dependencies
> >
> > On Thu, 2005-10-27 at 14:21 -0600, Li-Ta Lo wrote:
> > > On Thu, 2005-10-27 at 11:11 -0700, Lu, Yinghai wrote:
> > > > If CONFIG_USE_INIT == 0, the cache_as_ram_auto.c will be
compiled
> to
> > > > auto.inc. ---> part of crt0.s---> part of linuxbios_rom
> > > >
> > > > If CONFIG_USE_INIF == 1, the cache_as_ram_auto.c will be
compiled
> to
> > > > auto.o and be linked with memcpy.o....and auto.o and memcpy.o
--->
> > > > init.o
> > > > And init.o ---> part of linuxbios_rom...
> > > >
> > >
> > > Is there any reason we need two different ways to do it? If both
of
> > them
> > > are as good, can we drop one and support just the other?
> > >
> > > BTW, after reading your patch, I found there is very little
> difference
> >
> > > between auto.c and cache_as_ram_auto.c. Most of the differences
are
> in
> > > the included files, can we merge auto.c and cache_as_ram_auto.c?
> > >
> >
> > Talking about merging auto.c and cache_as_ram_auto.c, you are using
> > #define __ROMCC__ to choose different definitions of device_t. I
don't
> > thing it is the right way to do it. Instead, we should use another
> > macro for this (__ASSEMBLY__ or __PRE_SDRAM__)?
> >
> > --
> > Li-Ta Lo <ollie(a)lanl.gov>
> > Los Alamos National Lab
> >
> >
--
Li-Ta Lo <ollie(a)lanl.gov>
Los Alamos National Lab