~serge-hallyn/ubuntu/oneiric/ipxe/link-kvm

« back to all changes in this revision

Viewing changes to .pc/remove-linuxprefix-resolve-ftbfs.patch/src/arch/x86_64/prefix/linuxprefix.S

  • Committer: Bazaar Package Importer
  • Author(s): Bastian Blank
  • Date: 2011-07-31 20:57:02 UTC
  • mfrom: (2.1.1 sid)
  • Revision ID: james.westby@ubuntu.com-20110731205702-kffmzz6tnmgfw50f
Tags: 1.0.0+git-2.149b50-1
New snapshot.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
#include <linux/unistd.h>
2
 
 
3
 
        .section ".text"
4
 
        .code64
5
 
        .globl _linux_start
6
 
        .type _linux_start, @function
7
 
 
8
 
_linux_start:
9
 
        xorq    %rbp, %rbp
10
 
 
11
 
        popq    %rdi       // argc -> C arg1
12
 
        movq    %rsp, %rsi // argv -> C arg2
13
 
 
14
 
        andq    $~15, %rsp // 16-byte align the stack
15
 
 
16
 
        call    save_args
17
 
 
18
 
        /* Our main doesn't use any arguments */
19
 
        call    main
20
 
 
21
 
        movq    %rax, %rdi // rc -> syscall arg1
22
 
        movq    $__NR_exit, %rax
23
 
        syscall
24
 
 
25
 
        .size _start, . - _start