More fixes to the extlinux installer; change back to writable types
[profile/ivi/syslinux.git] / writestr.inc
1 ;; $Id$
2 ;; -----------------------------------------------------------------------
3 ;;   
4 ;;   Copyright 1994-2002 H. Peter Anvin - All Rights Reserved
5 ;;
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.
11 ;;
12 ;; -----------------------------------------------------------------------
13
14 ;;
15 ;; writestr.inc
16 ;;
17 ;; Code to write a simple string.
18 ;;
19
20                 section .text
21 ;
22 ; crlf: Print a newline
23 ;
24 crlf:           mov si,crlf_msg
25                 ; Fall through
26
27 ;
28 ; cwritestr: write a null-terminated string to the console, saving
29 ;            registers on entry.
30 ;
31 ; Note: writestr and cwritestr are distinct in SYSLINUX (only)
32 ;
33 cwritestr:
34                 pushfd
35                 pushad
36 .top:           lodsb
37                 and al,al
38                 jz .end
39                 call writechr
40                 jmp short .top
41 .end:           popad
42                 popfd
43                 ret