Merge commit 'origin/nolen' into gpxe-support
[syslinux.git] / cmdline.inc
blob5d5b3c22abc00da9eac00171f094c1ec05e1976a
1 ;; -----------------------------------------------------------------------
2 ;;
3 ;;   Copyright 2003-2008 H. Peter Anvin - All Rights Reserved
4 ;;
5 ;;   This program 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, Inc., 53 Temple Place Ste 330,
8 ;;   Boston MA 02111-1307, USA; either version 2 of the License, or
9 ;;   (at your option) any later version; incorporated herein by reference.
11 ;; -----------------------------------------------------------------------
14 ;; cmdline.inc
16 ;; Common routine to assemble [null-terminated] command line into
17 ;; real_mode_seg:cmd_line_here.
18 ;; Not used by plain kernel due to BOOT_IMAGE= etc.
22 ; Assumes DS == CS
23 make_plain_cmdline:
24                 push es
25                 ; ui.inc has already copied any APPEND options
26                 mov ax,real_mode_seg
27                 mov es,ax
29                 mov si,[CmdOptPtr]
30                 mov di,[CmdLinePtr]
32                 call strcpy
34                 dec di
35                 mov [CmdLinePtr],di
37                 pop es
38                 ret