Document PXELINUX timeout fix
[syslinux.git] / init.inc
blob9eb4c7b404c0c83fadd38dea0c5953f8a88ee7b4
1 ; -*- fundamental -*-
2 ; -----------------------------------------------------------------------
4 ;   Copyright 2004 H. Peter Anvin - All Rights Reserved
6 ;   This program is free software; you can redistribute it and/or modify
7 ;   it under the terms of the GNU General Public License as published by
8 ;   the Free Software Foundation, Inc., 53 Temple Place Ste 330,
9 ;   Boston MA 02111-1307, USA; either version 2 of the License, or
10 ;   (at your option) any later version; incorporated herein by reference.
12 ; -----------------------------------------------------------------------
13 ; $Id$
16 ; init.inc
18 ; Common initialization code (inline)
21                 section .text
22 common_init:
23                 ; Now set up screen parameters
24                 call adjust_screen
26                 ; Wipe the F-key area
27                 mov al,NULLFILE
28                 mov di,FKeyName
29                 mov cx,10*(1 << FILENAME_MAX_LG2)
30                 rep stosb
32                 mov si,linuxauto_cmd            ; Default command: "linux auto"
33                 mov di,default_cmd
34                 mov cx,linuxauto_len
35                 rep movsb
37                 mov di,KbdMap                   ; Default keymap 1:1
38                 xor al,al
39                 inc ch                          ; CX <- 256
40 mkkeymap:       stosb
41                 inc al
42                 loop mkkeymap
45 ; Clear Files structures
47                 mov di,Files
48                 mov cx,(MAX_OPEN*open_file_t_size)/4
49                 xor eax,eax
50                 rep stosd
52 %if IS_PXELINUX
53                 mov di,Files+tftp_pktbuf
54                 mov cx,MAX_OPEN
55 .setbufptr:
56                 mov [di],ax
57                 add di,open_file_t_size
58                 add ax,PKTBUF_SIZE
59                 loop .setbufptr
60 %endif
62                 section .data
63 linuxauto_cmd   db 'linux auto',0
64 linuxauto_len   equ $-linuxauto_cmd
66                 section .text                   ; This is an inline file...