Re: fdisk -BI ob clean disk broken - but 1.64 works

2002-11-05 Thread Marcin Cieslak
On my system, FreeBSD 5.0-CURRENT #1: Mon Nov 4 21:00:50 CET 2002 fdisk ceased to work after a recent upgrade. It used to work fine under GEOMized kernel with both internal ATA disks and external IDE drive attached via fireware or USB (tested both). I had to switch to non-GEOM kernel (my

Re: umass CF geometry problems, was Re: fdisk -BI ob clean disk broken

2002-11-04 Thread John Hay
USB is only the transport. It doesn't add or remove functionality (the only exception being probing for LUNs on CBI devices). If you want to determine the geometry you will have to do this through SCSI commands. I was hoping that the CAM code would be smart enough to request the details

Re: umass CF geometry problems, was Re: fdisk -BI ob clean disk broken

2002-11-04 Thread John Hay
Well the short version of the problem is that fdisk -BI disk works on -stable to get a FreeBSD partition on the Compact Flash. This does not work on -current anymore. I have traced that back to the commit in umass.c rev 1.61 that removed the fake geometry setting and just leave the

Re: umass CF geometry problems, was Re: fdisk -BI ob clean disk broken

2002-11-04 Thread John Hay
Let's work on the 'proper' solution first. What SCSI commands are suitable for getting the geometry, generically on a device? Hmmm, I made an interesting discovery. I searched through some of the scsi drivers, sys/dev/{aha|ahb|aic*|sym}, looking for XPT_CALC_GEOMETRY and they all fake the

Re: umass CF geometry problems, was Re: fdisk -BI ob clean disk broken

2002-11-04 Thread Poul-Henning Kamp
In message [EMAIL PROTECTED], John Hay wri tes: Let's work on the 'proper' solution first. What SCSI commands are suitable for getting the geometry, generically on a device? Hmmm, I made an interesting discovery. I searched through some of the scsi drivers, sys/dev/{aha|ahb|aic*|sym},

Re: fdisk -BI ob clean disk broken

2002-11-04 Thread Nate Lawson
On Sat, 2 Nov 2002, Poul-Henning Kamp wrote: In message [EMAIL PROTECTED], John Hay wri tes: Hmmm. I just noticed that the disks probe with zero values for the heads, sectors/track and cylinders. I have tried two different USB CF readers and both do it. On 4.x it probes with the correct

Re: umass CF geometry problems, was Re: fdisk -BI ob clean disk broken

2002-11-04 Thread Poul-Henning Kamp
In message [EMAIL PROTECTED], Nate Lawson writ es: It might be more useful for GEOM to query the BIOS for the physical values and provide a way for upper levels (like CAM) to retrieve this. This is a driver task. besides GEOM is above CAM, not below it. -- Poul-Henning Kamp | UNIX since

Re: umass CF geometry problems, was Re: fdisk -BI ob clean disk broken

2002-11-04 Thread Poul-Henning Kamp
In message [EMAIL PROTECTED], Nate Lawson writ es: On Mon, 4 Nov 2002, Poul-Henning Kamp wrote: In message [EMAIL PROTECTED], Nate Lawson writ es: It might be more useful for GEOM to query the BIOS for the physical values and provide a way for upper levels (like CAM) to retrieve this. This

umass CF geometry problems, was Re: fdisk -BI ob clean disk broken

2002-11-03 Thread John Hay
: Hmmm. I just noticed that the disks probe with zero values for the : heads, sectors/track and cylinders. I have tried two different USB : CF readers and both do it. On 4.x it probes with the correct values : on the same machine and the same devices. So why do they probe : wrong? Don't

Re: fdisk -BI ob clean disk broken

2002-11-02 Thread M. Warner Losh
In message: [EMAIL PROTECTED] John Hay [EMAIL PROTECTED] writes: : On 4.x I have been using a slightly modified version of Warner's diskprep : to write new compact flashes. On -current fdisk die with signal 8 (Floating : point exception) when this part of the script runs: : :

Re: fdisk -BI ob clean disk broken

2002-11-02 Thread John Hay
: On 4.x I have been using a slightly modified version of Warner's diskprep : to write new compact flashes. On -current fdisk die with signal 8 (Floating : point exception) when this part of the script runs: : : $dev = /dev/r${drive}; : system /bin/dd if=/dev/zero of=$dev count=128

Re: fdisk -BI ob clean disk broken

2002-11-02 Thread M. Warner Losh
In message: [EMAIL PROTECTED] John Hay [EMAIL PROTECTED] writes: : Hmmm. I just noticed that the disks probe with zero values for the : heads, sectors/track and cylinders. I have tried two different USB : CF readers and both do it. On 4.x it probes with the correct values : on the same

Re: fdisk -BI ob clean disk broken

2002-11-02 Thread Poul-Henning Kamp
In message [EMAIL PROTECTED], John Hay wri tes: : On 4.x I have been using a slightly modified version of Warner's diskprep : to write new compact flashes. On -current fdisk die with signal 8 (Floating : point exception) when this part of the script runs: : :$dev = /dev/r${drive}; :