Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/x68k/stand Use .org directive to fix disklabel loca...



details:   https://anonhg.NetBSD.org/src/rev/a2df95341783
branches:  trunk
changeset: 467174:a2df95341783
user:      isaki <isaki%NetBSD.org@localhost>
date:      Thu Jan 16 13:37:26 2020 +0000

description:
Use .org directive to fix disklabel location instead of hand calculation.
If the code size before disklabel is less, zero is filled automatically.
If the code size before disklabel is exceeded, assembler stops with error.
Note that this changes a padding word in the current output binary from
a NOP instruction to zero but there are no functional changes.

diffstat:

 sys/arch/x68k/stand/boot_ufs/boot.S         |  4 ++--
 sys/arch/x68k/stand/boot_ustar/boot_ustar.S |  6 +++---
 sys/arch/x68k/stand/xxboot/boot.S           |  4 ++--
 3 files changed, 7 insertions(+), 7 deletions(-)

diffs (65 lines):

diff -r 34fd9abc5044 -r a2df95341783 sys/arch/x68k/stand/boot_ufs/boot.S
--- a/sys/arch/x68k/stand/boot_ufs/boot.S       Thu Jan 16 13:16:59 2020 +0000
+++ b/sys/arch/x68k/stand/boot_ufs/boot.S       Thu Jan 16 13:37:26 2020 +0000
@@ -2,7 +2,7 @@
 | author: chapuni(webmaster%chapuni.com@localhost)
 |         ITOH Yasufumi
 |
-| $NetBSD: boot.S,v 1.12 2020/01/14 04:00:41 isaki Exp $
+| $NetBSD: boot.S,v 1.13 2020/01/16 13:37:26 isaki Exp $
 
 #include <machine/asm.h>
 #include "iocscall.h"
@@ -44,7 +44,7 @@
 |      Disklabel= 404bytes
 |      Since LABELOFFSET in <machine/disklabel.h> is 0x40,
 |      entry must be after 0x000001d4 (0x000f01d4)
-               nop
+               .org    0x40
 disklabel:
                .space  404
 
diff -r 34fd9abc5044 -r a2df95341783 sys/arch/x68k/stand/boot_ustar/boot_ustar.S
--- a/sys/arch/x68k/stand/boot_ustar/boot_ustar.S       Thu Jan 16 13:16:59 2020 +0000
+++ b/sys/arch/x68k/stand/boot_ustar/boot_ustar.S       Thu Jan 16 13:37:26 2020 +0000
@@ -3,7 +3,7 @@
 |         ITOH Yasufumi
 |        minoura%NetBSD.org@localhost
 |
-| $NetBSD: boot_ustar.S,v 1.9 2020/01/13 03:34:05 isaki Exp $
+| $NetBSD: boot_ustar.S,v 1.10 2020/01/16 13:37:26 isaki Exp $
 
 | supports floppy only
 
@@ -46,8 +46,8 @@
 |      Disklabel= 404bytes
 |      Since LABELOFFSET in <machine/disklabel.h> is 0x40,
 |      entry must be after 0x000001d4 (0x000021d4)
-               nop
-GLOBAL(disklabel)
+               .org    0x40
+disklabel:
                .space  404
 
 ASENTRY_NOPROFILE(entry)
diff -r 34fd9abc5044 -r a2df95341783 sys/arch/x68k/stand/xxboot/boot.S
--- a/sys/arch/x68k/stand/xxboot/boot.S Thu Jan 16 13:16:59 2020 +0000
+++ b/sys/arch/x68k/stand/xxboot/boot.S Thu Jan 16 13:37:26 2020 +0000
@@ -2,7 +2,7 @@
 | author: chapuni(webmaster%chapuni.com@localhost)
 |         ITOH Yasufumi
 |
-| $NetBSD: boot.S,v 1.4 2020/01/13 03:34:05 isaki Exp $
+| $NetBSD: boot.S,v 1.5 2020/01/16 13:37:27 isaki Exp $
 
 #include <machine/asm.h>
 #include "iocscall.h"
@@ -46,7 +46,7 @@
 |      Disklabel= 404bytes
 |      Since LABELOFFSET in <machine/disklabel.h> is 0x40,
 |      entry must be after 0x000001d4 (0x000f01d4)
-               nop
+               .org    0x40
 disklabel:
                .space  404
 



Home | Main Index | Thread Index | Old Index