linux-mips
[Top] [All Lists]

Re: beginners question

To: Mad Props <madprops@gmx.net>
Subject: Re: beginners question
From: Ralf Baechle <ralf@linux-mips.org>
Date: Mon, 22 Nov 2004 16:01:08 +0100
Cc: linux-mips@linux-mips.org
In-reply-to: <8709.1101086706@www8.gmx.net>
Original-recipient: rfc822;linux-mips@linux-mips.org
References: <8709.1101086706@www8.gmx.net>
Sender: linux-mips-bounce@linux-mips.org
User-agent: Mutt/1.4.1i
On Mon, Nov 22, 2004 at 02:25:06AM +0100, Mad Props wrote:

> i wrote a little MIPS startup code that uses the serial port to print some
> output. Further I enabled timer interrupts. So far, I'm using kseg1 since
> nothing else is intialized.
> 
> I have a static variable in my C exception hander. The problem with it: it's
> apparently not within kseg1 but in the user segment and causes the exception
> handler to get invoked recursively. How can I change this so that all
> variables / code use kseg1 ?

Seems like you need a linker script.  The kernel has it's linker script
in arch/mips/kernel/vmlinux.lds.S but due to complexity that's probably
not a good example to look at.

  Ralf

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