• David S. Miller's avatar
    [SPARC64]: Fix boot failures on SunBlade-150 · c9c10830
    David S. Miller authored
    The sequence to move over to the Linux trap tables from
    the firmware ones needs to be more air tight.  It turns
    out that to be %100 safe we do need to be able to translate
    OBP mappings in our TLB miss handlers early.
    
    In order not to eat up a lot of kernel image memory with
    static page tables, just use the translations array in
    the OBP TLB miss handlers.  That solves the bulk of the
    problem.
    
    Furthermore, to make sure the OBP TLB miss path will work
    even before the fixed MMU globals are loaded, explicitly
    load %g1 to TLB_SFSR at the beginning of the i-TLB and
    d-TLB miss handlers.
    
    To ease the OBP TLB miss walking of the prom_trans[] array,
    we sort it then delete all of the non-OBP entries in there
    (for example, there are entries for the kernel image itself
    which we're not interested in at all).
    
    We also save about 32K of kernel image size with this change.
    Not a bad side effect :-)
    
    There are still some reasons why trampoline.S can't use the
    setup_trap_table() ...
    c9c10830
dtlb_prot.S 1.29 KB