source: grub-pc/trunk/fuentes/grub-core/lib/mips/setjmp.S @ 22

Last change on this file since 22 was 22, checked in by mabarracus, 4 years ago

updated version and apply net.ifnames=0 into debian/rules

File size: 1.5 KB
Line 
1/*
2 *  GRUB  --  GRand Unified Bootloader
3 *  Copyright (C) 2003,2007,2009  Free Software Foundation, Inc.
4 *
5 *  GRUB is free software: you can redistribute it and/or modify
6 *  it under the terms of the GNU General Public License as published by
7 *  the Free Software Foundation, either version 3 of the License, or
8 *  (at your option) any later version.
9 *
10 *  GRUB is distributed in the hope that it will be useful,
11 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
12 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13 *  GNU General Public License for more details.
14 *
15 *  You should have received a copy of the GNU General Public License
16 *  along with GRUB.  If not, see <http://www.gnu.org/licenses/>.
17 */
18
19#include <grub/symbol.h>
20#include <grub/dl.h>
21
22        .file   "setjmp.S"
23
24GRUB_MOD_LICENSE "GPLv3+"
25
26        .text
27
28/*
29 * int grub_setjmp (grub_jmp_buf env)
30 */
31FUNCTION(grub_setjmp)
32        sw $s0, 0($a0)
33        sw $s1, 4($a0)
34        sw $s2, 8($a0)
35        sw $s3, 12($a0)
36        sw $s4, 16($a0)
37        sw $s5, 20($a0)
38        sw $s6, 24($a0)
39        sw $s7, 28($a0)
40        sw $s8, 32($a0)
41        sw $gp, 36($a0)
42        sw $sp, 40($a0)
43        sw $ra, 44($a0)
44        move $v0, $zero
45        move $v1, $zero
46        jr $ra
47/*
48 * int grub_longjmp (grub_jmp_buf env, int val)
49 */
50FUNCTION(grub_longjmp)
51        lw $s0, 0($a0)
52        lw $s1, 4($a0)
53        lw $s2, 8($a0)
54        lw $s3, 12($a0)
55        lw $s4, 16($a0)
56        lw $s5, 20($a0)
57        lw $s6, 24($a0)
58        lw $s7, 28($a0)
59        lw $s8, 32($a0)
60        lw $gp, 36($a0)
61        lw $sp, 40($a0)
62        lw $ra, 44($a0)
63        move $v0, $a1
64        bne  $v0, $zero, 1f
65        addiu $v0, $v0, 1
661:     
67        move $v1, $zero
68        jr $ra
Note: See TracBrowser for help on using the repository browser.