Rev 2055 | Rev 2071 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 2055 | Rev 2058 | ||
---|---|---|---|
Line 627... | Line 627... | ||
627 | * |
627 | * |
628 | * This trap handler makes arrangements to make calling of scheduler() from |
628 | * This trap handler makes arrangements to make calling of scheduler() from |
629 | * within a trap context possible. It is called from several other trap |
629 | * within a trap context possible. It is called from several other trap |
630 | * handlers. |
630 | * handlers. |
631 | * |
631 | * |
632 | * This function can be entered either with interrupt globals or alternate globals. |
632 | * This function can be entered either with interrupt globals or alternate |
633 | * Memory management trap handlers are obliged to switch to one of those global sets |
633 | * globals. Memory management trap handlers are obliged to switch to one of |
634 | * prior to calling this function. Register window management functions are not |
634 | * those global sets prior to calling this function. Register window management |
635 | * allowed to modify the alternate global registers. |
635 | * functions are not allowed to modify the alternate global registers. |
- | 636 | * |
|
- | 637 | * The kernel is designed to work on trap levels 0 - 4. For instance, the |
|
- | 638 | * following can happen: |
|
- | 639 | * TL0: kernel thread runs (CANSAVE=0, kernel stack not in DTLB) |
|
- | 640 | * TL1: preemptible trap handler started after a tick interrupt |
|
- | 641 | * TL2: preemptible trap handler did SAVE |
|
- | 642 | * TL3: spill handler touched the kernel stack |
|
- | 643 | * TL4: hardware or software failure |
|
636 | * |
644 | * |
637 | * Input registers: |
645 | * Input registers: |
638 | * %g1 Address of function to call. |
646 | * %g1 Address of function to call. |
639 | * %g2 First argument for the function. |
647 | * %g2 First argument for the function. |
640 | * %g6 Pre-set as kernel stack base if trap from userspace. |
648 | * %g6 Pre-set as kernel stack base if trap from userspace. |