Date: Fri, 08 Apr 2011 15:01:01 -0700 From: Marcel Moolenaar <xcllnt@mac.com> To: Hans Petter Selasky <hselasky@c2i.net> Cc: "freebsd-current@FreeBSD.org" <freebsd-current@freebsd.org> Subject: Re: Fdisk formatting of disk having bs=1K fails Message-ID: <127C6AAD-9586-4B85-9297-F4BAF4BC61C3@mac.com> In-Reply-To: <201104082134.15674.hselasky@c2i.net> References: <201104082134.15674.hselasky@c2i.net>
next in thread | previous in thread | raw e-mail | index | archive | help
On Apr 8, 2011, at 12:34 PM, Hans Petter Selasky wrote: > Hi, > > It appears that src/sbin/fdisk.c can only read the MBR of disks having a > blocksize different than 512 bytes. When writing a new MBR, the below check > fails. Can someone having knowledge into fdisk, fix this issue and MFC to 8- > stable? Also I'm curious about the #ifdef __ia64__ . You can eliminate the __ia64__ conditional if you want. From the commit log: ======== r95860 | peter | 2002-05-01 06:48:29 +0000 (Wed, 01 May 2002) | 4 lines Add a hack so that fdisk(8) can initialize an ia64 disk. There is no /boot/mbr to read the boot code from (ia64 does not *have* bootblocks!). fdisk depended on magic in the /boot/mbr file to initialize some fields. ======== fdisk is not compiled for ia64 anymore since the introduction of gpart. The same holds for bsdlabel. So, that means that the hack is not needed anymore. FYI, -- Marcel Moolenaar xcllnt@mac.com
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?127C6AAD-9586-4B85-9297-F4BAF4BC61C3>