[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: powerpc-rtems-4.7-gcc-4.0 patch commited

Ralf Corsepius wrote:
On Fri, 2005-02-18 at 06:29 -0600, Joel Sherrill  wrote:

Sergei Organov wrote:

Ralf Corsepius <ralf.corsepius@rtems.org> writes:


E.g. the m8260 would be superflous, if it could be removed from cpukit.
The code it uses is _identical_ to the 603e, except of 1 define in

Well, which one of the following 8 do you mean? Or am I missing

cpukit/score/cpu/powerpc/rtems/new-exceptions/cpu.h:180:  || defined(mpc860) || defined(mpc821) || defined(mpc8260))
cpukit/score/cpu/powerpc/rtems/new-exceptions/cpu.h:192:  || defined(mpc860) || defined(mpc821) || defined(mpc8260))
cpukit/score/cpu/powerpc/rtems/old-exceptions/cpu.h:204:  || defined(mpc860) || defined(mpc821) || defined(mpc8260))
cpukit/score/cpu/powerpc/rtems/old-exceptions/cpu.h:216:  || defined(mpc860) || defined(mpc821) || defined(mpc8260))
cpukit/score/cpu/powerpc/rtems/score/powerpc.h:211:#elif defined(mpc8260)
cpukit/score/cpu/powerpc/rtems/score/powerpc.h:461:#elif defined(mpc8260)
cpukit/score/cpu/powerpc/rtems/score/cpu.h:407:  || defined(mpc860) || defined(mpc821) || defined(mpc8260))
cpukit/score/cpu/powerpc/rtems/score/cpu.h:436:  || defined(mpc860) || defined(mpc821) || defined(mpc8260))

Most of those are related to having configuration info for drivers in libcpu and could easily be defined in libcpu.

There is a PPC_INTERRUPTS_MAX which still remains to be addressed.

That's the one I was referring to.

I know how to eliminate the others (Introducing an abstract base class
for rtems_cpu_table and to move all CPU-variant specific fields out of
CPUkit - This would be a major redesign of RTEMS), but I have no idea
how to clean up the PPC_INTERRUPTS mess in powerpc.h

It should be as simple as a single file in libcpu/powerpc/shared which defines an initialized variable with the maximum number of vectors. See below for how the mips does this.

Ralf.. I think the the MIPS defines that in libcpu as a variable used by the cpukit.

Hmm? I don't understand.

Do you mean an extern variable in cpukit to be filled in libcpu?
We already have this at several places. The problem with with powerpc is
the borked design of the way the interrupt defines are being setup in

find c/src/lib/libcpu/mips -name "maxvectors.c"

A single variable is defined which has the maximum number of vectors.

unsigned int mips_interrupt_number_of_vectors = TX3904_MAXIMUM_VECTORS;


Joel Sherrill, Ph.D.             Director of Research & Development
joel@OARcorp.com                 On-Line Applications Research
Ask me about RTEMS: a free RTOS  Huntsville AL 35805
   Support Available             (256) 722-9985