Do we still need ATA disk CHS addressing?

M. Warner Losh imp at
Mon Aug 10 22:27:20 UTC 2009

In message: <4A807BDD.6040709 at>
            Alexander Motin <mav at> writes:
: Warner Losh wrote:
: > My question, and maybe I missed this earlier in the thread, is what's
: > the benefit to removing this support?  How much code is saved?
: It is not about code size, but about code structurization. ATA(4) has 
: too much cross-level relations, making it cryptic. I am trying to unroll 
: some of them to simplify code.

Can you explain a bit more here...  How pervasive is it, etc...  I'm
not saying this is a bad change, but I think people wishing to remove
stuff should at least have a good result that's expected...

: > Having said all that, I think it is OK, but I'd definitely poll the
: > pc98 guys first...  Just to make sure they don't need it and re-fork
: > the ata driver to get it :)
: GEOM has no terms of cylinders/heads/sectors, in fact it works only with 
: LBA. CHS translation is only needed for drives, that have no native LBA 
: support. It is not about disk partitioning or label format. It is just a 
: method to linearize nonlinear address space of ancient drives. For last 
: 10 years, since drives lost their classic geometry, drives are doing 
: this translation on firmware level.

GEOM does have terms of CHS when it reports the classic geometry of
the device.  That can't be lost, or pc98 partitioning breaks.  And the
geometry reported must be massaged too, but that's a different issue.
The disk requests can be LBA, since the driver is responsible for
changing that anyway...  I don't think that there's any supported
pc98 hardware that would break, but I'm not 100% sure...

There's also some oddities at the lowest levels for pc98 controllers,
but I don't think this change would affect that.  However, like I
said, ask the pc98 guys for sure.

I've cc'd nyan@, since he can answer the question: "What breaks in
pc98 if we lose support for CHS-based disk I/O?"


More information about the freebsd-arch mailing list