Ignore:
Timestamp:
2006-08-31T18:53:14Z (18 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
6767c1d
Parents:
e0b241f
Message:

A lot of untested sparc64 stuff:

  • Write ASID to hardware when a thread is about to run in userspace.
  • Add userspace() and switch_to_userspace() functions.
  • Handle special cases when the userspace spill/fill handler causes MMU trap.
  • Resolve some TODOs in the existing sparc64 code.
  • sparc64 has now C99 compliant header guards.
  • Formatting and indentation fixes.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/arch/sparc64/src/trap/trap_table.S

    re0b241f red166f7  
    4141#include <arch/trap/exception.h>
    4242#include <arch/trap/mmu.h>
     43#include <arch/mm/mmu.h>
    4344#include <arch/mm/page.h>
    4445#include <arch/stack.h>
     
    349350        wrpr %l0, %otherwin
    350351        wrpr %g0, %cansave
    351         wrpr %g0, NWINDOW-1, %cleanwin
     352        wrpr %g0, NWINDOW - 1, %cleanwin
    352353
    353354        /*
     
    355356         */
    356357        mov VA_PRIMARY_CONTEXT_REG, %l0
    357         stxa %g0, [%l0] ASI_DMMU
    358         set kernel_image_start, %l0
    359         flush %l0
     358        stxa %g0, [%l0] ASI_DMMU
     359        rd %pc, %l0
     360        flush %l0
    360361
    361362        ba 1f
     
    498499         */
    499500        wrpr %g0, WSTATE_OTHER(0) | WSTATE_NORMAL(1), %wstate
     501
     502        /*
     503         * Set primary context according to secondary context.
     504         */
     505        wr %g0, ASI_DMMU, %asi
     506        ldxa [VA_SECONDARY_CONTEXT_REG] %asi, %g1
     507        stxa %g1, [VA_PRIMARY_CONTEXT_REG] %asi
     508        flush %o7
    500509       
    501510        rdpr %cwp, %g1
Note: See TracChangeset for help on using the changeset viewer.