kern/61960: [Patch] BigDrive support for PC-98 architecture (ata(4) driver)

Hirokazu WATANABE wnabe at par.odn.ne.jp
Mon Jan 26 08:20:13 PST 2004


>Number:         61960
>Category:       kern
>Synopsis:       [Patch] BigDrive support for PC-98 architecture (ata(4) driver)
>Confidential:   no
>Severity:       serious
>Priority:       high
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Mon Jan 26 08:20:06 PST 2004
>Closed-Date:
>Last-Modified:
>Originator:     Hirokazu WATANABE
>Release:        FreeBSD/pc98 5.2-RELEASE
>Organization:
>Environment:
FreeBSD hebe.fb98.dyndns.org 5.2-CURRENT FreeBSD 5.2-CURRENT #0: Sun Jan 25 14:06:12 JST 2004 watanabe at proteus.fb98.dyndns.org:/usr/src/sys/pc98/compile/GENERIC  i386

>Description:
PC-98's slice table managed by CHS geometry. And the ata(4) driver is 
using the head/sector value acquired from HDD. However, in 32GB or more 
of HDD, since a cylinder value overflows, it cannot be used normally.
(Some interfaces for PC-98x1 works over 8GB HDDs. But there are still 
manages in CHS geometry.)

PC-98's slice table max values are followd(maybe)...
Cylinder: 65534(=65535)
Heads:    255(=256)
Sectors:  255

Typical PC-98's geometry:
under 4.3GB:                    heads=8,   sectors=17
4.3GB to 32GB:                  heads=16,  sectors=63(=HDD's geometry)
32GB to 128GB:                  heads=16,  sectors=255(*1)
128GB to 2TB:                   heads=255, sectors=255(*2,*3,*4)
over 2TB:      cylinders=65534, heads=255, sectors=255(*2,*3)

(*1) PK98-Mistress9[atacbus's add-on BIOS] and UIDE-133/98(PCI-ATA) only
(*2) UIDE-133/98 only
(*3) PK98-Mistress9 is cylinders=65534, heads=16, sectors=255
(*4) over 128GB or supports 48bit LBA

>How-To-Repeat:
FreeBSD/pc98 5.2-RELEASE installed, and use fdisk_pc98(8) for 
over-32GB-HDD. Then, fdisk_pc98 cannot handle its geometry.
This is because cylinder of HDD is over 16bit.

>Fix:
ata(4) use BIOS geometry, or it changes not with the value acquired from HDDs but with the fixed value(heads/sectors). 

A patch which solves this problem is appended to below.
(http://fb98.dyndns.org/FreeBSD/bignadrive-20040126.diff.gz)

begin 644 bignadrive.diff.gz
M'XL(")W.%$```V)I9VYA9')I=F4N9&EF9@"]6/USVD83_AG^BHT[3<$@T!>?
MKDF(33.\$\<98[_O3-,,(Z23N3%(C#ZHT\;_^[M[^D`2"#OMM(PMT-WMWN[>
ML\_=WM2QV.,0?,]LK_B"_BWN/[3-I>'<LY99/?_[G^K-Q0QLOF)#:"_=-6L[
MYM9OE\W8W%8]%GB<;;ES#QY^^=QU0&FI>M7BM at U2"))'KY`:*4E2J0<5I0,?
MW2VHLJR"H at U5?:@.0)+Q4Q%*&XU&N;#:A?\8#@GK(.M#11G*G4BX^O8M2+K<
M[$$#GXH";]]6H<)MJ)$&:;3 at KC\WOZY@!(JLZO4J_,`<=``'57S#87`.\EFU
M\0.W+6;#IXM!O]HHBB\M&)V#VNG6<2!;^6Q_!AH"2C1 at 7SUDU>_)^LP,T at G(
MG5ZOV85&7VFJFG`G55EPZ1RB!G,9.@^^-/+Y'PS:-/6>^E/(&5M_SF52_S-T
M.QV-?*I4$`NAYZ`4OK1/8>S[X9K!W?1R(BF:UA[TI3%<+(W5BN&">?!N>CT#
MN37HJ\H%;`S/6+,`FT_;*%XTC1SOG.4[,)SG&,Y"ZQ&?&R_S^3O=?#=]+SF&
M=.GQ+7NS9[TP<M_VOV]ELMY/5:C"UN56=;JC!_^KW[;8MFT$!OU+)/U/$\3A
M.4LI0NEV<QR![Y`Q-:&)PUHKF,-IKJOJ4.X/-3TE"E*=,$6)?($K5&W8T;-<
MT:7DPF<ORBWNF*O08O#S=MW>KEO+4:%MLS8VA=:U82ZYP]IK:[XU/.IL['<N
M7#?@CNV6R"Y"O]!#[GAKPRDTWS-WW:;'7/B'G8(B.N1%K]L<""_HXP=>B'@R
MK+GOVH$)IX:U.8NZPCEW`DV=![!:&(3%;'M7W[7K?80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