From owner-freebsd-fs@FreeBSD.ORG Fri Feb 7 16:24:45 2014 Return-Path: Delivered-To: freebsd-fs@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 7CC7FABE; Fri, 7 Feb 2014 16:24:45 +0000 (UTC) Received: from wonkity.com (wonkity.com [67.158.26.137]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 30C851E4E; Fri, 7 Feb 2014 16:24:45 +0000 (UTC) Received: from wonkity.com (localhost [127.0.0.1]) by wonkity.com (8.14.7/8.14.7) with ESMTP id s17GOibW006600; Fri, 7 Feb 2014 09:24:44 -0700 (MST) (envelope-from wblock@wonkity.com) Received: from localhost (wblock@localhost) by wonkity.com (8.14.7/8.14.7/Submit) with ESMTP id s17GOh2l006597; Fri, 7 Feb 2014 09:24:44 -0700 (MST) (envelope-from wblock@wonkity.com) Date: Fri, 7 Feb 2014 09:24:43 -0700 (MST) From: Warren Block To: "Andrey V. Elsukov" Subject: Re: amd64/186515: Doesn't boot with GPT when # of entries over than 128. In-Reply-To: <52F4D4C9.3060902@yandex.ru> Message-ID: References: <201402061930.s16JU2Pi052495@freefall.freebsd.org> <52F4D4C9.3060902@yandex.ru> User-Agent: Alpine 2.00 (BSF 1167 2008-08-23) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3 (wonkity.com [127.0.0.1]); Fri, 07 Feb 2014 09:24:44 -0700 (MST) Cc: freebsd-fs@FreeBSD.org X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Feb 2014 16:24:45 -0000 On Fri, 7 Feb 2014, Andrey V. Elsukov wrote: > On 06.02.2014 23:30, John Baldwin wrote: >> Using more entries to pad out the table isn't the normal way to handle 4k >> alignment. You can just leave a gap before the start of freebsd-boot. Having >> the sectors "free" vs having them contain zero'd GPT entries doesn't really >> make a difference. One question is when does the boot break? Does it make it >> into the loader and break trying to boot the kernel? Does it make it into >> gptboot and break trying to load the loader? > > Hi John, > > this is gptboot's restriction. Look at the sys/boot/common/gpt.c. It is mentioned at the start of gptboot(8) under Implementation Notes, too. Alignment of freebsd-boot is usually not very important. It is only rarely written, and the bootcode is so small that it will probably not take appreciably longer to read or write even when misaligned. Filesystem partitions are where alignment really matters.