Apple assembly doesn't handle symbol arithmetic well. So define an

offset symbol in boot.S and use it.
This commit is contained in:
Vladimir Serbinenko 2013-11-24 06:20:10 +01:00
parent 78f961efe9
commit 5c066a81c2
2 changed files with 12 additions and 3 deletions

View file

@ -1,3 +1,8 @@
2013-11-24 Vladimir Serbinenko <phcoder@gmail.com>
Apple assembly doesn't handle symbol arithmetic well. So define an
offset symbol in boot.S and use it.
2013-11-24 Vladimir Serbinenko <phcoder@gmail.com>
Apple assembly doesn't handle symbol arithmetic well. So instead

View file

@ -31,7 +31,7 @@
.macro floppy
part_start:
probe_values:
LOCAL(probe_values):
.byte 36, 18, 15, 9, 0
LOCAL(floppy_probe):
@ -39,8 +39,12 @@ LOCAL(floppy_probe):
/*
* Perform floppy probe.
*/
movw MACRO_DOLLAR(probe_values) - 1, %si
#ifdef __APPLE__
LOCAL(probe_values_minus_one) = LOCAL(probe_values) - 1
movw MACRO_DOLLAR(LOCAL(probe_values_minus_one)), %si
#else
movw MACRO_DOLLAR(LOCAL(probe_values)) - 1, %si
#endif
LOCAL(probe_loop):
/* reset floppy controller INT 13h AH=0 */