linux-mips
[Top] [All Lists]

Instruction error with cache opcode

To: linux-mips@linux-mips.org
Subject: Instruction error with cache opcode
From: John Miller <jamiller1110@cox.net>
Date: Sun, 14 May 2006 09:51:02 -0400
Original-recipient: rfc822;linux-mips@linux-mips.org
Sender: linux-mips-bounce@linux-mips.org
User-agent: Thunderbird 1.5 (X11/20060402)
I am attempting to write a routine to initialize the cache for a MIPS
4kc core to get Linux 2.6.16.14 to compile.  I am sure someone has
probably already done this, but I am doing it for educational reasons. 
I am receiving the following error:

arch/mips/kernel/head.S: Assembler messages:
arch/mips/kernel/head.S:131: Error: Instruction cache requires absolute
expression

From the following code section:

        li      t0, 0x80000000                  # start address (KSEG0)
        addu    t1,t0,0x2000                    # 8KB I-cache
1:      addu    t0,0x10                         # 16B line size
        cache   Index_Store_Tag_I,-4(t0)        # clear tag
        nop
        cache   Fill_I,-4(t0)                   # fill line
        nop
        bne     t0,t1,1b
        cache   Index_Store_Tag_I,-4(t0)

 I copied the code section from See MIPS Run, so I know the code must be
correct.  What am I doing wrong?

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