| Summary: | ATA disk size detected incorrectly (lba sector count not used on 30GB disk) | ||
|---|---|---|---|
| Product: | Base System | Reporter: | Joost Bekkers <joost> |
| Component: | kern | Assignee: | Søren Schmidt <sos> |
| Status: | Closed FIXED | ||
| Severity: | Affects Only Me | CC: | paul |
| Priority: | Normal | ||
| Version: | 4.7-RELEASE | ||
| Hardware: | Any | ||
| OS: | Any | ||
Responsible Changed From-To: freebsd-bugs->sos ATA PR for Soren. State Changed From-To: open->closed The geometry from the disk is bogus, mayhaps a sizelimitting jumper is left on it ? |
ATA disk reports 4092 cylinders so lba sector count isn't used. This results in a 2GB disk being detected instead of the full 30GB from ata-disk.c: /* use the 28bit LBA size if valid */ if (atadev->param->cylinders == 16383 && adp->total_secs < atadev->param->lba_size) adp->total_secs = atadev->param->lba_size; So only if the reported numbers of cylinders os 16383 the lba size is taken into account, should we check for lba-support (bit 9, word 49 of 'identify device' information)? Fix: My guess at a fix would be to replace line 135 of ata-disk.c (1.60.2.23) if (atadev->param->cylinders == 16383 && with if (atadev->param->support_lba && but I haven't been able to test this.