2
* GRUB -- GRand Unified Bootloader
3
* Copyright (C) 2003,2007 Free Software Foundation, Inc.
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.
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.
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/>.
19
#include <grub/symbol.h>
27
* rbx rsp rbp r12 r13 r14 r15 rip
28
* 0 8 16 24 32 40 48 56
32
* int grub_setjmp (grub_jmp_buf env)
35
pop %rsi /* Return address, and adjust the stack */
37
movq %rbx, 0(%rdi) /* RBX */
38
movq %rsp, 8(%rdi) /* RSP */
40
movq %rbp, 16(%rdi) /* RBP */
41
movq %r12, 24(%rdi) /* R12 */
42
movq %r13, 32(%rdi) /* R13 */
43
movq %r14, 40(%rdi) /* R14 */
44
movq %r15, 48(%rdi) /* R15 */
45
movq %rsi, 56(%rdi) /* RSI */
49
* int grub_longjmp (grub_jmp_buf env, int val)
51
FUNCTION(grub_longjmp)