From mboxrd@z Thu Jan 1 00:00:00 1970 From: "H. Peter Anvin" Subject: Re: ATA 4 KiB sector issues. Date: Sun, 14 Mar 2010 18:21:54 -0700 Message-ID: <4B9D8BB2.1010507@zytor.com> References: <4B947393.2050002@kernel.org> <201003100046.24695.arnd@arndb.de> <1158166a1003100114j6ea329fbh84bfad65dcac90bf@mail.gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Return-path: Received: from terminus.zytor.com ([198.137.202.10]:35328 "EHLO mail.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S935078Ab0COBWu (ORCPT ); Sun, 14 Mar 2010 21:22:50 -0400 In-Reply-To: <1158166a1003100114j6ea329fbh84bfad65dcac90bf@mail.gmail.com> Sender: linux-ide-owner@vger.kernel.org List-Id: linux-ide@vger.kernel.org To: Denys Vlasenko Cc: Arnd Bergmann , Tejun Heo , "linux-ide@vger.kernel.org" , lkml , Daniel Taylor , Jeff Garzik , Mark Lord , tytso@mit.edu, hirofumi@mail.parknet.co.jp, Andrew Morton , Alan Cox , irtiger@gmail.com, Matthew Wilcox , aschnell@suse.de, knikanth@suse.de, jdelvare@suse.de On 03/10/2010 01:14 AM, Denys Vlasenko wrote: > > 63s/255h is more or less "standard" now. > > Alignment issues can be solved by picking a good multiple of > _heads_ or _cylinders_: > > For first partition, pick the start at 8th head: > > cyl 0 head 1 sector 1: LBA sector 63) - bad > cyl 0 head 8 sector 1: LBA sector 8*63) - good (4k aligned) > > For any other partition, pick start cylinder which is a multiple of 8: > > cyl 8*x head 0 sector 1: LBA sector 8*x*255*63 - good (4k aligned) > > This will actually work well for *any* geometry, not only for 63s/255h. Yes, but it does squat for a flash disk that wants, say, 256K alignment. -hpa