paul@68 | 1 | /* |
paul@114 | 2 | * Interrupt and TLB miss handling support. |
paul@68 | 3 | * |
paul@114 | 4 | * Copyright (C) 2015, 2016 Paul Boddie <paul@boddie.org.uk> |
paul@68 | 5 | * |
paul@68 | 6 | * This program is free software: you can redistribute it and/or modify |
paul@68 | 7 | * it under the terms of the GNU General Public License as published by |
paul@68 | 8 | * the Free Software Foundation, either version 3 of the License, or |
paul@68 | 9 | * (at your option) any later version. |
paul@68 | 10 | * |
paul@68 | 11 | * This program is distributed in the hope that it will be useful, |
paul@68 | 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
paul@68 | 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
paul@68 | 14 | * GNU General Public License for more details. |
paul@68 | 15 | * |
paul@68 | 16 | * You should have received a copy of the GNU General Public License |
paul@68 | 17 | * along with this program. If not, see <http://www.gnu.org/licenses/>. |
paul@68 | 18 | */ |
paul@68 | 19 | |
paul@68 | 20 | .text |
paul@114 | 21 | .extern tlb_handler |
paul@86 | 22 | .extern interrupt_handler |
paul@114 | 23 | .globl _tlb_entry |
paul@68 | 24 | .globl _irq_entry |
paul@68 | 25 | .globl _end_entries |
paul@68 | 26 | .set noreorder |
paul@68 | 27 | |
paul@114 | 28 | _tlb_entry: |
paul@114 | 29 | lui $k0, %hi(tlb_handler) |
paul@114 | 30 | ori $k0, $k0, %lo(tlb_handler) |
paul@114 | 31 | jr $k0 |
paul@114 | 32 | nop |
paul@114 | 33 | |
paul@68 | 34 | _irq_entry: |
paul@86 | 35 | lui $k0, %hi(interrupt_handler) |
paul@86 | 36 | ori $k0, $k0, %lo(interrupt_handler) |
paul@68 | 37 | jr $k0 |
paul@68 | 38 | nop |
paul@68 | 39 | |
paul@68 | 40 | _end_entries: |
paul@68 | 41 | |
paul@68 | 42 | .set reorder |