From owner-freebsd-current@freebsd.org Wed Oct 4 05:16:18 2017 Return-Path: Delivered-To: freebsd-current@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E853AE2E4C2 for ; Wed, 4 Oct 2017 05:16:18 +0000 (UTC) (envelope-from tsoome@me.com) Received: from st13p35im-asmtp002.me.com (st13p35im-asmtp002.me.com [17.164.199.65]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id BFCEA71BFD for ; Wed, 4 Oct 2017 05:16:18 +0000 (UTC) (envelope-from tsoome@me.com) Received: from process-dkim-sign-daemon.st13p35im-asmtp002.me.com by st13p35im-asmtp002.me.com (Oracle Communications Messaging Server 8.0.1.2.20170607 64bit (built Jun 7 2017)) id <0OXA0040097M8U00@st13p35im-asmtp002.me.com> for freebsd-current@freebsd.org; Wed, 04 Oct 2017 05:16:12 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=me.com; s=04042017; t=1507094172; bh=v8RIgXgp9M1tvEJs1eZjc9W/+rdrKVSX8Coz6qhSNcQ=; h=From:Content-type:MIME-version:Subject:Date:To:Message-id; b=7lpDVLI3f0ZAqJtr4UDayhfq+YarmJGMyT5ceDoHEXVf1upGM1XzJ8Q1jPCGmFBdH YM1zphppSdnyW6jflH2mC01iIlmq+IZz9M5uj+dZeGgmDclUghhETdXJgSuP8h14z7 DvgOosbOmMm1nsqG58Muwp5agqRmZdT/4bI1H90+4tV1RWnOkfF/Xzu80qL7k0wIGu wpQ8CXCEFPuBjbzwPlivuVyBbGMFIg7XxiLl5fvf4Mwdvb/UTj4l4j4oYoxtEOIVUb UCjTdDmp33u8dwluoE6WHeyZSBnfL7rCibg3IO8X1F0XNA87xZRwq0IATq3HK+v4Om zuRB32JBtErEg== Received: from icloud.com ([127.0.0.1]) by st13p35im-asmtp002.me.com (Oracle Communications Messaging Server 8.0.1.2.20170607 64bit (built Jun 7 2017)) with ESMTPSA id <0OXA000C49ARXP00@st13p35im-asmtp002.me.com> for freebsd-current@freebsd.org; Wed, 04 Oct 2017 05:16:11 +0000 (GMT) X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2017-10-04_02:,, signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 clxscore=1015 suspectscore=2 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1707230000 definitions=main-1710040076 From: Toomas Soome Content-type: text/plain; charset=utf-8 Content-transfer-encoding: quoted-printable MIME-version: 1.0 (Mac OS X Mail 11.0 \(3445.1.6\)) Subject: Re: Booting native 4K SSD disk from FreeBSD ? Date: Wed, 04 Oct 2017 08:16:03 +0300 References: <10608d2a-4209-25c1-4117-8568993bfe6a@selasky.org> To: FreeBSD Current In-reply-to: <10608d2a-4209-25c1-4117-8568993bfe6a@selasky.org> Message-id: X-Mailer: Apple Mail (2.3445.1.6) X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 Oct 2017 05:16:19 -0000 > On 4 Oct 2017, at 00:18, Hans Petter Selasky wrote: >=20 > Hi, >=20 > I accidentially ordered a Sata SSD disk which diskinfo reports a = sector-size 4K instead of 512 bytes. Trying to get it to boot under = FreeBSD appeared impossible. Then I started looking into the boot0,1,2 = and loader and the assumptions they make about 512 byte sector size LBA = :-( >=20 > Anyone has any recommendations or experience about how to use native = 4K disks with FreeBSD? >=20 The fastest way right now is via UEFI boot, it should be able to cope = with 4k, but as Allan noted, there may be some corners. The BIOS version is totally out right now, it only is supporting 512B = sectors. I have been working to fix it starting with loader libi386 = biosdisk interface (for loader itself), but due to lack of time it has = been delayed somewhat. The plain loader bits are done, but the +GELI = needs more work (the code has to cope with 512/4k sector and GELI is = only doing 4k logical IO). The hard part is about the boot1 code = (boot1,gptboot etc) and thats due to boot block area size limits (in = existing setups). We are struggling to fit into UFS boot block area, and = freebsd-boot and ESP sizes are also very small, making all this pain in = the =E2=80=A6=20 rgds, toomas