From e06b5b43133a3b38620376378f860d8eb3941d11 Mon Sep 17 00:00:00 2001 From: krw Date: Tue, 24 May 2022 17:29:02 +0000 Subject: [PATCH] fdisk(8) no longer uses the partition table it finds in /usr/mdec/mbr. Make the partition table all zeros and see if any hidden uses fall out. ok deraadt@ --- sys/arch/amd64/stand/mbr/mbr.S | 6 +++--- sys/arch/i386/stand/mbr/mbr.S | 6 +++--- sys/arch/landisk/stand/mbr/mbr.S | 6 +++--- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/sys/arch/amd64/stand/mbr/mbr.S b/sys/arch/amd64/stand/mbr/mbr.S index 8a9a4d26b5e..2b00826dd0c 100644 --- a/sys/arch/amd64/stand/mbr/mbr.S +++ b/sys/arch/amd64/stand/mbr/mbr.S @@ -1,4 +1,4 @@ -/* $OpenBSD: mbr.S,v 1.5 2012/06/04 16:17:04 mglocker Exp $ */ +/* $OpenBSD: mbr.S,v 1.6 2022/05/24 17:29:02 krw Exp $ */ /* * Copyright (c) 1997 Michael Shalayeff and Tobias Weingartner @@ -562,8 +562,8 @@ pt: .long 0,0 .byte 0x0,0,0,0,0,0,0,0 .long 0,0 - .byte DOSACTIVE,0,1,0,DOSPTYP_OPENBSD,255,255,255 - .long 0,0x7FFFFFFF + .byte 0x0,0,0,0,0,0,0,0 + .long 0,0 /* the last 2 bytes in the sector 0 contain the signature */ . = 0x1fe signature: diff --git a/sys/arch/i386/stand/mbr/mbr.S b/sys/arch/i386/stand/mbr/mbr.S index 66149ca6cd7..99ad02d1048 100644 --- a/sys/arch/i386/stand/mbr/mbr.S +++ b/sys/arch/i386/stand/mbr/mbr.S @@ -1,4 +1,4 @@ -/* $OpenBSD: mbr.S,v 1.23 2012/06/04 16:17:04 mglocker Exp $ */ +/* $OpenBSD: mbr.S,v 1.24 2022/05/24 17:29:02 krw Exp $ */ /* * Copyright (c) 1997 Michael Shalayeff and Tobias Weingartner @@ -562,8 +562,8 @@ pt: .long 0,0 .byte 0x0,0,0,0,0,0,0,0 .long 0,0 - .byte DOSACTIVE,0,1,0,DOSPTYP_OPENBSD,255,255,255 - .long 0,0x7FFFFFFF + .byte 0x0,0,0,0,0,0,0,0 + .long 0,0 /* the last 2 bytes in the sector 0 contain the signature */ . = 0x1fe signature: diff --git a/sys/arch/landisk/stand/mbr/mbr.S b/sys/arch/landisk/stand/mbr/mbr.S index 130da948972..4e5d1b6b8c4 100644 --- a/sys/arch/landisk/stand/mbr/mbr.S +++ b/sys/arch/landisk/stand/mbr/mbr.S @@ -1,4 +1,4 @@ -/* $OpenBSD: mbr.S,v 1.1 2006/10/06 21:48:50 mickey Exp $ */ +/* $OpenBSD: mbr.S,v 1.2 2022/05/24 17:29:02 krw Exp $ */ /* $NetBSD: mbr.S,v 1.1 2006/09/01 21:26:19 uwe Exp $ */ /*- @@ -203,8 +203,8 @@ _pbr_part2: .byte 0, 0, 0, 0, 0, 0, 0, 0 .byte 0, 0, 0, 0, 0, 0, 0, 0 _pbr_part3: - .byte 0x80, 0, 1, 0, 0xa6, 255, 255, 255 - .word 0, 0, 0xffff, 0x7fff + .byte 0, 0, 0, 0, 0, 0, 0, 0 + .byte 0, 0, 0, 0, 0, 0, 0, 0 . = _C_LABEL(start) + 0x1fe magic: -- 2.20.1