summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2013-03-07 05:34:25 (GMT)
committerH. Peter Anvin <hpa@zytor.com>2013-03-09 13:18:53 (GMT)
commit15ab0fe771cc4a65eef4a36c81aa76d4955094b6 (patch)
treebbaa9076aeae7ef1322e4b9be37541808eb47ec5
parent49282c863daae2ace9781ab6d1e89bd571e28f69 (diff)
downloadvirtio9p-15ab0fe771cc4a65eef4a36c81aa76d4955094b6.zip
virtio9p-15ab0fe771cc4a65eef4a36c81aa76d4955094b6.tar.gz
virtio9p-15ab0fe771cc4a65eef4a36c81aa76d4955094b6.tar.bz2
virtio9p-15ab0fe771cc4a65eef4a36c81aa76d4955094b6.tar.xz
start: Just put the volume label in a space-initialized buffer
The volume label buffer is so small we can just put it in .rdata
-rw-r--r--start.asm15
1 files changed, 8 insertions, 7 deletions
diff --git a/start.asm b/start.asm
index 4317e11..c3cf4c7 100644
--- a/start.asm
+++ b/start.asm
@@ -123,7 +123,13 @@ ok_version:
gibuf mount_tag, MOUNT_TAG_MAX+4+2
/* Mount tag in codepage, up to 11 bytes - volume label */
- grbuf volume_label, 11
+ .pushsection ".rdata","aw"
+ .globl volume_label
+volume_label:
+ .ascii " " /* 11 space characters */
+ .type volume_label,@object
+ .size volume_label,.-volume_label
+ .popsection
parse_cmdline:
call utf_init_plain
@@ -188,12 +194,7 @@ parse_cmdline:
subw $mount_tag+2,%di
movw %di,mount_tag /* 2 first bytes for length */
-6:
- cmpw $volume_label+11,%bx
- jae get_dos_bits
- movb $0x20,(%bx) /* Space pad */
- incw %bx
- jmp 6b
+ jmp get_dos_bits
usage_error:
printmsg "Usage: v9fs drive: mount_tag\r\n"