From owner-freebsd-hackers Mon Apr 10 14:36:45 2000 Delivered-To: freebsd-hackers@freebsd.org Received: from server.baldwin.cx (jobaldwi.campus.vt.edu [198.82.67.146]) by hub.freebsd.org (Postfix) with ESMTP id CC6A537BA05 for ; Mon, 10 Apr 2000 14:36:36 -0700 (PDT) (envelope-from jhb@FreeBSD.org) Received: from john.baldwin.cx (john [10.0.0.2]) by server.baldwin.cx (8.9.3/8.9.3) with ESMTP id RAA12324; Mon, 10 Apr 2000 17:36:06 -0400 (EDT) (envelope-from jhb@FreeBSD.org) Message-Id: <200004102136.RAA12324@server.baldwin.cx> X-Mailer: XFMail 1.4.0 on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 In-Reply-To: <200004100128.TAA15168@harmony.village.org> Date: Mon, 10 Apr 2000 17:36:05 -0400 (EDT) From: John Baldwin To: Warner Losh Subject: RE: How hard would it be... Cc: hackers@FreeBSD.org Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On 10-Apr-00 Warner Losh wrote: > ... to get FreeBSD to boot off a BSD partition that wasn't labeled as > 0xa5? I'm looking for a way to create a disk that a certain picky > BIOS will like and boot off of, and I think I have to create it with a > certain ID and then it will be happy. I suspect that it involves > hacking the boot blocks, the boot loader and the kernel's idea of the > BSD partition number in disk*subr.c. Are there other things that are > needed? I may be barking up the wrong tree in trying to get around > this BIOS's pickiness, but I thought I'd at least ask. > > Yes, this is for a well-known, cheap internet device, which shall > remain nameless. I've already OPENed mine up. a real lookER. Heh. Well, I can't speak for the kernel side of things, but for the rest of the boot strap you would need to change these lines in these files: /sys/boot/i386/boot2/boot1.s: .set PRT_BSD,0xa5 # Partition type /usr/include/sys/disklabel.h: #define DOSPTYP_386BSD 0xa5 /* 386BSD partition type */ Once you've done that, go into /sys/boot/i386 and just do a make. If you update /sys/sys/disklabel.h you might be able to compile a new kernel and be able to mount, etc., but I'm not sure about that part. > Warner -- John Baldwin -- http://www.FreeBSD.org/~jhb/ PGP Key: http://www.cslab.vt.edu/~jobaldwi/pgpkey.asc "Power Users Use the Power to Serve!" - http://www.FreeBSD.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message