Date: Thu, 8 Sep 2005 14:18:44 -0400 From: Jung-uk Kim <jkim@FreeBSD.org> To: freebsd-arch@FreeBSD.org Subject: Bigger boot block size? Message-ID: <200509081418.47794.jkim@FreeBSD.org>
next in thread | raw e-mail | index | archive | help
--Boundary-00=_HCIID6syY0rPUQu Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Content-Disposition: inline I have been working on boot2 recently. I faced constant problem with boot2 size limitation. Can we have bigger boot block size (aka BBSIZE)? In the future, we may have to support different file system to boot from and we won't have any space to add the support without dropping UFS1 support. In fact, I am using 32-sector boot block and I don't see any problem so far. The patch that I've been using is attached. Cheers, Jung-uk Kim --Boundary-00=_HCIID6syY0rPUQu Content-Type: text/x-diff; charset="us-ascii"; name="32sect.diff" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="32sect.diff" Index: src/sys/boot/i386/boot2/Makefile =================================================================== RCS file: /home/ncvs/src/sys/boot/i386/boot2/Makefile,v retrieving revision 1.59 diff -u -r1.59 Makefile --- src/sys/boot/i386/boot2/Makefile 15 Jul 2005 12:22:14 -0000 1.59 +++ src/sys/boot/i386/boot2/Makefile 8 Sep 2005 18:13:32 -0000 @@ -60,9 +60,9 @@ boot2.s boot2.s.tmp boot2.h sio.o boot2: boot2.ld - @set -- `ls -l boot2.ld`; x=$$((7680-$$5)); \ + @set -- `ls -l boot2.ld`; x=$$((15872-$$5)); \ echo "$$x bytes available"; test $$x -ge 0 - dd if=boot2.ld of=${.TARGET} obs=7680 conv=osync + dd if=boot2.ld of=${.TARGET} obs=15872 conv=osync boot2.ld: boot2.ldr boot2.bin ${BTXKERN} btxld -v -E ${ORG2} -f bin -b ${BTXKERN} -l boot2.ldr \ Index: src/sys/boot/i386/boot2/boot1.S =================================================================== RCS file: /home/ncvs/src/sys/boot/i386/boot2/boot1.S,v retrieving revision 1.30 diff -u -r1.30 boot1.S --- src/sys/boot/i386/boot2/boot1.S 28 Aug 2004 08:32:23 -0000 1.30 +++ src/sys/boot/i386/boot2/boot1.S 8 Sep 2005 18:13:32 -0000 @@ -37,7 +37,7 @@ .set SIZ_PAG,0x1000 # Page size .set SIZ_SEC,0x200 # Sector size - .set NSECT,0x10 + .set NSECT,0x20 .globl start .globl xread .code16 Index: src/sys/sys/disklabel.h =================================================================== RCS file: /home/ncvs/src/sys/sys/disklabel.h,v retrieving revision 1.107 diff -u -r1.107 disklabel.h --- src/sys/sys/disklabel.h 7 Apr 2005 22:09:02 -0000 1.107 +++ src/sys/sys/disklabel.h 8 Sep 2005 18:13:32 -0000 @@ -68,7 +68,7 @@ #endif /* Size of bootblock area in sector-size neutral bytes */ -#define BBSIZE 8192 +#define BBSIZE 16384 #define LABEL_PART 2 /* partition containing label */ #define RAW_PART 2 /* partition containing whole disk */ --Boundary-00=_HCIID6syY0rPUQu--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200509081418.47794.jkim>