linux-mips
[Top] [All Lists]

Re: port on exotic board.

To: Jun Sun <jsun@junsun.net>, moreau francis <francis_moreau2000@yahoo.fr>
Subject: Re: port on exotic board.
From: Manish Lachwani <m_lachwani@yahoo.com>
Date: Tue, 21 Dec 2004 21:36:51 -0800 (PST)
Cc: linux-mips@linux-mips.org
Comment: DomainKeys? See http://antispam.yahoo.com/domainkeys
Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; b=YB76wbq2/HW9oAQEUZVDGzMslgAU80fTJjl99rMMXTUxADhFSIGaIlps+DDL4YuGes6DulJ1xlRcp2vkscTq5nj3VogEcKVOiDjSwdmbS6n9SnYrr6bYhP58mUkay7VHAlWSWnfj3GA255UUkaeR64PS2RyYDLB2IrL7pQhHcQI= ;
In-reply-to: <20041222012715.GA13782@gw.junsun.net>
Original-recipient: rfc822;linux-mips@linux-mips.org
Sender: linux-mips-bounce@linux-mips.org
Hello !
> > In "tlb_init" function, cp0 WIRED register is set
> to
> > zero, therefore the call to "local_flush_tlb_all" 
> > flush all TLB entries which were mapping my kernel
> > in the 3 first entries. Why is this necessary ?  
> 
> Setting WIRED to zero is just part of kernel
> start-up initialization.
> 
> In 2.4 it is done before board setup routine, which
> allows board
> to setup certain wired mapping.
> 
> In 2.6 it is done after board setup routine.  You
> are screwed. :) I think
> this needs to be fixed.  A couple of boards should
> be broken because of this.
> 

Well, you can again setup the wired tlb entries later.
For example, in case of Ocelot3 board (setup.c code),
the wired tlb entries are again created in the
time_init function.


void momenco_time_init(void)
{
        setup_wired_tlb_entries();

....

And it is set for the first time in the board setup
function:

static int __init momenco_ocelot_3_setup(void)
{
        unsigned int tmpword;

        board_time_init = momenco_time_init;

        _machine_restart = momenco_ocelot_restart;
        _machine_halt = momenco_ocelot_halt;
        _machine_power_off = momenco_ocelot_power_off;

        /* Wired TLB entries */
        setup_wired_tlb_entries();

....

Maybe you can do the same for this board as well

Thanks
Manish Lachwani



=====
http://www.koffee-break.com

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