Re: svn commit: r216269 - head/sys/geom/part

2010-12-10 Thread Warner Losh
From: Matthew Jacob > Geometry is still important. Trying booting a USB flash drive on all > BIOS' with a 63/255 geometry instead of a 64/32 geometry. At least most modern BIOSes I've had to deal with can be configured to use packet mode which makes the problem go away... Don't know if I'm luc

Re: svn commit: r216269 - head/sys/geom/part

2010-12-10 Thread Bruce Evans
On Fri, 10 Dec 2010, Bruce Cran wrote: On Fri, 10 Dec 2010 10:12:34 +1100 (EST) Bruce Evans wrote: The BIOS has little control over the mode. It can't enforce LBA if the drive supports CHS. It can't force any particular CHS mode since the driver may set any CHS mode. ata used to reset the

Re: svn commit: r216269 - head/sys/geom/part

2010-12-10 Thread Bruce Evans
On Fri, 10 Dec 2010, Erik Trulsson wrote: On Thu, Dec 09, 2010 at 10:14:58PM +, Bruce Cran wrote: On Thu, 9 Dec 2010 19:58:56 +1100 (EST) Bruce Evans wrote: I had understood the ATA_FLAG_54_58 backwards. It tells us if the drive is not so old that it doesn't support IDENTIFY records for

Re: svn commit: r216269 - head/sys/geom/part

2010-12-10 Thread Bruce Cran
On Fri, 10 Dec 2010 10:12:34 +1100 (EST) Bruce Evans wrote: > The BIOS has little control over the mode. It can't enforce LBA if > the drive supports CHS. It can't force any particular CHS mode since > the driver may set any CHS mode. ata used to reset the drive in the > probe and in reinit.

Re: svn commit: r216269 - head/sys/geom/part

2010-12-10 Thread Bruce Cran
On Fri, 10 Dec 2010 02:00:23 +0100 Erik Trulsson wrote: > Modern drives do not really report 'the current CHS geometry'. They > report a fake geometry that normally do not have anything do with the > actual geometry. (As an example just about all modern ATA/SATA drives > report having 16 heads,

Re: svn commit: r216269 - head/sys/geom/part

2010-12-10 Thread Andriy Gapon
on 10/12/2010 03:10 Erik Trulsson said the following: > On Fri, Dec 10, 2010 at 12:36:57AM +0200, Andriy Gapon wrote: >> on 10/12/2010 00:14 Bruce Cran said the following: >>> Since it appears that disks are still using the CHS fields despite >>> having been obsolete since ATA-7 I guess it makes se

Re: svn commit: r216269 - head/sys/geom/part

2010-12-09 Thread Erik Trulsson
On Fri, Dec 10, 2010 at 12:36:57AM +0200, Andriy Gapon wrote: > on 10/12/2010 00:14 Bruce Cran said the following: > > Since it appears that disks are still using the CHS fields despite > > having been obsolete since ATA-7 I guess it makes sense to continue > > printing them. > > I apologize for r

Re: svn commit: r216269 - head/sys/geom/part

2010-12-09 Thread Erik Trulsson
On Thu, Dec 09, 2010 at 10:14:58PM +, Bruce Cran wrote: > On Thu, 9 Dec 2010 19:58:56 +1100 (EST) > Bruce Evans wrote: > > > I had understood the ATA_FLAG_54_58 backwards. It tells us if the > > drive is not so old that it doesn't support IDENTIFY records for > > words 54-58. I think we rar

Re: svn commit: r216269 - head/sys/geom/part

2010-12-09 Thread Bruce Evans
On Thu, 9 Dec 2010, Bruce Cran wrote: On Thu, 9 Dec 2010 19:58:56 +1100 (EST) Bruce Evans wrote: I had understood the ATA_FLAG_54_58 backwards. It tells us if the drive is not so old that it doesn't support IDENTIFY records for words 54-58. I think we rarely get here. Drives old enough to

Re: svn commit: r216269 - head/sys/geom/part

2010-12-09 Thread Andriy Gapon
on 10/12/2010 00:55 Kostik Belousov said the following: > On Fri, Dec 10, 2010 at 12:36:57AM +0200, Andriy Gapon wrote: >> on 10/12/2010 00:14 Bruce Cran said the following: >>> Since it appears that disks are still using the CHS fields despite >>> having been obsolete since ATA-7 I guess it makes

Re: svn commit: r216269 - head/sys/geom/part

2010-12-09 Thread Kostik Belousov
On Fri, Dec 10, 2010 at 12:36:57AM +0200, Andriy Gapon wrote: > on 10/12/2010 00:14 Bruce Cran said the following: > > Since it appears that disks are still using the CHS fields despite > > having been obsolete since ATA-7 I guess it makes sense to continue > > printing them. > > I apologize for r

Re: svn commit: r216269 - head/sys/geom/part

2010-12-09 Thread Andriy Gapon
on 10/12/2010 00:14 Bruce Cran said the following: > Since it appears that disks are still using the CHS fields despite > having been obsolete since ATA-7 I guess it makes sense to continue > printing them. I apologize for repeating myself, that probably starts to be annoying... We read some reser

Re: svn commit: r216269 - head/sys/geom/part

2010-12-09 Thread Bruce Cran
On Thu, 9 Dec 2010 19:58:56 +1100 (EST) Bruce Evans wrote: > I had understood the ATA_FLAG_54_58 backwards. It tells us if the > drive is not so old that it doesn't support IDENTIFY records for > words 54-58. I think we rarely get here. Drives old enough to use > CHS may be so old that they do

Re: svn commit: r216269 - head/sys/geom/part

2010-12-09 Thread Bruce Evans
On Wed, 8 Dec 2010, Bruce Cran wrote: On Wed, 8 Dec 2010 16:46:17 +1100 (EST) Bruce Evans wrote: - for ATA drives, it uses the "firmware" geometry supplied by the drive firmware. The ATA standard specifies this to be H=16/S=63 for all drives larger than a certain size (IIRC, about 8GB, which

Re: svn commit: r216269 - head/sys/geom/part

2010-12-08 Thread Bruce Cran
On Wed, 8 Dec 2010 16:46:17 +1100 (EST) Bruce Evans wrote: > - for ATA drives, it uses the "firmware" geometry supplied by the > drive firmware. The ATA standard specifies this to be H=16/S=63 for > all drives larger than a certain size (IIRC, about 8GB, which is the > size at which the better d

Re: svn commit: r216269 - head/sys/geom/part

2010-12-07 Thread Bruce Evans
On Wed, 8 Dec 2010, Andriy Gapon wrote: on 08/12/2010 01:11 Matthew Jacob said the following: Geometry is still important. Trying booting a USB flash drive on all BIOS' with a 63/255 geometry instead of a 64/32 geometry. Well, I don't know anything about USB... My point about modern HDDs sti

Re: svn commit: r216269 - head/sys/geom/part

2010-12-07 Thread Bruce Evans
On Tue, 7 Dec 2010, Bruce Cran wrote: On Tue, 07 Dec 2010 23:54:17 +0200 Andriy Gapon wrote: You repeated that statement, so I am picking on you :-) Can someone show me how/where exactly modern drives fakes CHS geometry? Let me specifically ask that question about modern (S)ATA drives directl

Re: svn commit: r216269 - head/sys/geom/part

2010-12-07 Thread Bruce Evans
On Wed, 8 Dec 2010, Andriy Gapon wrote: on 08/12/2010 00:05 Matthew Jacob said the following: On 12/7/2010 1:54 PM, Andriy Gapon wrote: on 07/12/2010 22:46 Bruce Cran said the following: Don't warn if a partition appears not to be aligned on a track boundary. Modern disks use LBA and

Re: svn commit: r216269 - head/sys/geom/part

2010-12-07 Thread Andriy Gapon
on 08/12/2010 01:11 Bruce Cran said the following: > On Tue, 7 Dec 2010 23:06:24 + > Bruce Cran wrote: >> I guess the fields are still defined to keep old tools happy. > > I mean that values are still returned by the drive firmware, > while they could be left zero according to the spec. For e

Re: svn commit: r216269 - head/sys/geom/part

2010-12-07 Thread Andriy Gapon
on 08/12/2010 01:11 Matthew Jacob said the following: > Geometry is still important. Trying booting a USB flash drive on all BIOS' > with > a 63/255 geometry instead of a 64/32 geometry. Well, I don't know anything about USB... My point about modern HDDs still stands. > On 12/7/2010 2:14 PM, An

Re: svn commit: r216269 - head/sys/geom/part

2010-12-07 Thread Matthew Jacob
Geometry is still important. Trying booting a USB flash drive on all BIOS' with a 63/255 geometry instead of a 64/32 geometry. On 12/7/2010 2:14 PM, Andriy Gapon wrote: on 08/12/2010 00:05 Matthew Jacob said the following: On 12/7/2010 1:54 PM, Andriy Gapon wrote: on 07/12/2010 22:46 Bruce

Re: svn commit: r216269 - head/sys/geom/part

2010-12-07 Thread Bruce Cran
On Tue, 7 Dec 2010 23:06:24 + Bruce Cran wrote: > I guess the fields are still defined to keep old tools happy. I mean that values are still returned by the drive firmware, while they could be left zero according to the spec. For example a new 1TB ATA-8 drive returns a geometry of 16H/63S/163

Re: svn commit: r216269 - head/sys/geom/part

2010-12-07 Thread Bruce Cran
On Tue, 07 Dec 2010 23:54:17 +0200 Andriy Gapon wrote: > You repeated that statement, so I am picking on you :-) > Can someone show me how/where exactly modern drives fakes CHS > geometry? Let me specifically ask that question about modern (S)ATA > drives directly connected to a system (controlle

Re: svn commit: r216269 - head/sys/geom/part

2010-12-07 Thread Matthew Jacob
On 12/7/2010 1:54 PM, Andriy Gapon wrote: on 07/12/2010 22:46 Bruce Cran said the following: Don't warn if a partition appears not to be aligned on a track boundary. Modern disks use LBA and create a fake CHS geometry that doesn't have any relation to the on-disk layout of data. You

Re: svn commit: r216269 - head/sys/geom/part

2010-12-07 Thread Andriy Gapon
on 08/12/2010 00:05 Matthew Jacob said the following: > > > On 12/7/2010 1:54 PM, Andriy Gapon wrote: >> on 07/12/2010 22:46 Bruce Cran said the following: >>>Don't warn if a partition appears not to be aligned on a track boundary. >>>Modern disks use LBA and create a fake CHS geometry th

Re: svn commit: r216269 - head/sys/geom/part

2010-12-07 Thread Andriy Gapon
on 07/12/2010 22:46 Bruce Cran said the following: > Don't warn if a partition appears not to be aligned on a track boundary. > Modern disks use LBA and create a fake CHS geometry that doesn't have any > relation to the on-disk layout of data. You repeated that statement, so I am picking on

svn commit: r216269 - head/sys/geom/part

2010-12-07 Thread Bruce Cran
Author: brucec Date: Tue Dec 7 20:46:11 2010 New Revision: 216269 URL: http://svn.freebsd.org/changeset/base/216269 Log: Don't warn if a partition appears not to be aligned on a track boundary. Modern disks use LBA and create a fake CHS geometry that doesn't have any relation to the on-disk