ATA Features


The ATA standards have gone a long way toward eliminating incompatibilities and problems with drive interfacing. The ATA specifications define the signals on the 40- or 44-pin connector, the functions and timings of these signals, cable specifications, and so on. This section lists some of the elements and functions defined by the ATA specification.

ATA I/O Connector

The ATA interface connector is normally a 40-pin (for 3.5-inch drives) or 44-pin (for 2.5-inch or smaller drives) header-type connector with pins spaced 0.1 inches (2.54mm) apart and generally is keyed to prevent installing it upside down (see Figures 9.12 and 9.13). To create a keyed connector, the manufacturer generally removes pin 20 from the male connector and blocks pin 20 on the female cable connector, which prevents the user from installing the cable backward. Some cables also incorporate a protrusion on the top of the female cable connector that fits into a notch in the shroud surrounding the mating male connector on the device. The use of keyed connectors and cables is highly recommended; plugging in an ATA cable backward normally won't cause any permanent damage. However, it can lock up the system and prevent it from running at all.

Figure 9.12. Typical ATA hard drive connectors.


Figure 9.13. ATA 40-pin interface connector detail.


Table 9.8 shows the standard 40-pin ATA interface connector pinout.

Table 9.8. 40-Pin ATA Connector

Signal Name

Pin

Pin

Signal Name

-RESET

1

2

GROUND

Data Bit 7

3

4

Data Bit 8

Data Bit 6

5

6

Data Bit 9

Data Bit 5

7

8

Data Bit 10

Data Bit 4

9

10

Data Bit 11

Data Bit 3

11

12

Data Bit 12

Data Bit 2

13

14

Data Bit 13

Data Bit 1

15

16

Data Bit 14

Data Bit 0

17

18

Data Bit 15

GROUND

19

20

KEY (pin missing)

DRQ 3

21

22

GROUND

-IOW

23

24

GROUND

-IOR

25

26

GROUND

I/O CH RDY

27

28

CSEL:SPSYNC[1]

-DACK 3

29

30

GROUND

IRQ 14

31

32

Reserved[2]

Address Bit 1

33

34

-PDIAG

Address Bit 0

35

36

Address Bit 2

-CS1FX

37

38

-CS3FX

-DA/SP

39

40

GROUND

+5V (Logic)

41

42

+5V (Motor)

GROUND

43

44

Reserved

Note that "-" preceding a signal name (such as with -RESET) indicates the signal is "active low."


[1] Pin 28 is normally cable select, but some older drives could use it for spindle synchronization between multiple drives.

[2] Pin 32 was defined as -IOCS16 in ATA-2 but is no longer used.

The 2.5-inch drives found in notebook/laptop-size computers normally use a smaller unitized 50-pin header connector with pins spaced only 2.0mm (0.079 inches) apart.

The main 40-pin part of the connector is the same as the standard ATA connector (except for the physical pin spacing), but there are added pins for power and jumpers. Normally, the cable that plugs into this connector has 44 pins, carrying power as well as the standard ATA signals. The jumper pins normally have a jumper on them (the jumper position controls cable select, master, or slave settings). Figure 9.14 shows the unitized 50-pin connector used on 2.5-inch ATA drives normally found in laptop or notebook computers.

Figure 9.14. 50-pin unitized ATA connector detail (used on 2.5-inch notebook/laptop ATA drives with a 44-pin cable).


Note the jumper pins at positions AD and that the pins at positions E and F are removed. A jumper usually is placed between positions B and D to set the drive for cable select operation. On this connector, pin 41 provides +5V power to the drive logic (circuit board), pin 42 provides +5V power to the motor (2.5-inch drives use 5V motors, unlike larger drives, which normally use 12V motors), and pin 43 provides a power ground. The last pin (44) is reserved and not used.

Table 9.9 shows the 50-pin unitized ATA interface connector pinout as used on most 2.5-inch (laptop or notebook computer) drives.

Table 9.9. 50-Pin Unitized ATA 2.5-Inch (Notebook/Laptop Drive) Connector Pinout

Signal Name

Pin

Pin

Signal Name

Jumper pin

A

B

Jumper pin

Jumper pin

C

D

Jumper pin

KEY (pin missing)

E

F

KEY (pin missing)

-RESET

1

2

GROUND

Data Bit 7

3

4

Data Bit 8

Data Bit 6

5

6

Data Bit 9

Data Bit 5

7

8

Data Bit 10

Data Bit 4

9

10

Data Bit 11

Data Bit 3

11

12

Data Bit 12

Data Bit 2

13

14

Data Bit 13

Data Bit 1

15

16

Data Bit 14

Data Bit 0

17

18

Data Bit 15

GROUND

19

20

KEY (pin missing)

DRQ 3

21

22

GROUND

-IOW

23

24

GROUND

-IOR

25

26

GROUND

I/O CH RDY

27

28

CSEL

-DACK 3

29

30

GROUND

IRQ 14

31

32

Reserved

Address Bit 1

33

34

-PDIAG

Address Bit 0

35

36

Address Bit 2

-CS1FX

37

38

-CS3FX

-DA/SP

39

40

GROUND

+5V (Logic)

41

42

+5V (Motor)

GROUND

43

44

Reserved


Not All Cables and Connectors Are Keyed

Note that many lower-cost board and cable manufacturers leave out the keying. Cheaper motherboards often won't have pin 20 removed on their ATA connectors, and consequently they won't supply a cable with pin 20 blocked. If they don't use a shrouded connector with a notch and a corresponding protrusion on the cable connector, no keying exists and the cables can be inserted backward. Fortunately, the only consequence of this in most cases is that the device won't work until the cable is attached with the correct orientation.

In rare situations in which you are mixing and matching items, you might encounter a cable with pin 20 blocked (as it should be) and a board with pin 20 still present. In that case, you can break off pin 20 from the board, or for the more squeamish, remove the block from the cable. Some cables have the block permanently installed as a part of the connector housing, in which case you must break off pin 20 on the board or device end or use a different cable.

The simple rule of thumb is that pin 1 should be oriented toward the power connector on the device, which normally corresponds to the stripe on the cable.


ATA I/O Cable

A 40-conductor ribbon cable is specified to carry signals between the bus adapter circuits and the drive (controller). To maximize signal integrity and eliminate potential timing and noise problems, the cable should not be longer than 18 inches (0.46 meters).

Note that ATA drives supporting the higher-speed transfer modes, such as PIO Mode 4 or any of the Ultra-DMA (UDMA) modes, are especially susceptible to cable integrity problems and cables that are too long. If the cable is too long, you can experience data corruption and other errors that can be maddening. This will be manifested in any type of problem reading from or writing to the drive. In addition, any drive using UDMA Mode 4 (66MBps transfer rate), Mode 5 (100MBps transfer rate), or Mode 6 (133MBps transfer rate) must use a special higher-quality 80-conductor cable (the extra conductors are grounds to reduce noise). I also recommend this type of cable if your drive is running at UDMA Mode 2 (33MBps) or slower because it can't hurt and can only help. Although cable length is not a problem inside portable systems, finding replacement cables that fit can be difficult. Many portables use special cables, called flex-cables, that are constructed like a filmstrip with the "wires" printed on much like on a circuit board. Because of their custom construction, you normally can't replace the cables inside a laptop with different ones than supplied by the manufacturer. Figure 9.15 shows the typical desktop ATA cable layout and dimensions. Unlike standard ATA ribbon cables, which allow for two drives to be connected, the flex-cables in a laptop will normally support only a single drive at a time.

Figure 9.15. An ATA cable with 40-pin connectors and either 40- or 80-conductor cables (additional wires are grounded in 80-conductor versions).


Note

Most 40-conductor cables do not color-code the connectors, whereas all 80-conductor cables do color-code the connectors.


Two primary variations of ATA cables are used today: one with 40 conductors and the other with 80 conductors. Both use 40-pin connectors, and the additional wires in the 80-conductor version are simply wired to ground. The additional conductors are designed to reduce noise and interference and are required when setting the interface to run at 66MBps (ATA/66) or faster. The drive and host adapter are designed to disable the higher-speed ATA/66, ATA/100, and ATA/133 modes if an 80-conductor cable is not detected. The 80-conductor cable can also be used at lower speeds; although this is unnecessary, it improves the signal integrity. Therefore, it is the recommended version no matter which drive you use. Note the keying on the cable, which is designed to prevent backward installation.

Dual-Drive Configurations

Dual-drive ATA installations can be problematic because each drive has its own controller, and both controllers must function while being connected to the same bus. There has to be a way to ensure that only one of the two controllers will respond to a command at a time.

The ATA standard provides the option of operating on the AT bus with two drives in a daisy-chained configuration. The primary drive (drive 0) is called the master, and the secondary drive (drive 1) is called the slave. You designate a drive as being master or slave by setting a jumper or switch on the drive or by using a special line in the interface called the cable select pin and setting the CS jumper on the drive.

When only one drive is installed, the controller responds to all commands from the system. When two drives (and, therefore, two controllers) are installed, both controllers receive all commands from the system. Each controller then must be set up to respond only to commands for itself. In this situation, one controller must be designated as the master and the other as the slave. When the system sends a command for a specific drive, the controller on the other drive must remain silent while the selected controller and drive are functioning. Setting the jumper to master or slave enables discrimination between the two controllers by setting a special bit (the DRV bit) in the Drive/Head Register of a command block.

Configuring ATA drives can be simple, as is the case with most single-drive installations, or troublesome, especially when it comes to mixing two older drives from different manufacturers on a single cable.

Most ATA drives can be configured with four possible settings:

  • Master (single drive)

  • Master (dual drive)

  • Slave (dual drive)

  • Cable select

Many drives simplify this to three settings: master, slave, and cable select. Because each ATA drive has its own controller, you must specifically tell one drive to be the master and the other to be the slave. No functional difference exists between the two, except that the drive that's specified as the slave will assert a signal called DASP (drive active/slave present) after a system reset informs the master that a slave drive is present in the system. The master drive then pays attention to the drive select line, which it otherwise ignores. Telling a drive that it's the slave also causes it to delay its spin-up for several seconds to allow the master to get going and thus lessens the load on the system's power supply.

Until the official ATA specifications were developed, no common implementation for IDE drive configuration was in use. Some drive companies even used different master/slave methods for different models of drives. Because of these incompatibilities, some drives work together only in a specific master/slave or slave/master order. This situation mostly affects older drives introduced before the ATA specification was officially adopted.

Most drives that fully follow the ATA specification now need only one jumper (master/slave) for configuration. A few also need a slave present jumper. Table 9.10 shows the jumper settings required by most 3.5-inch ATA drives.

Table 9.10. Jumper Settings for Most 3.5-inch ATA Drives on Standard (NonCable Select) Cables

Jumper Name

Single-Drive

Dual-Drive Master

Dual-Drive Slave

Master (M/S)

On

On

Off

Slave present (SP)

Off

On

Off

Cable select (CS)

Off

Off

Off


Note

If a cable select cable is used, the CS jumper should be set to On and all others should be Off. The cable connector then determines which drive will be master or slave.


Figure 9.16 shows the jumpers on a typical 3.5-inch ATA drive.

Figure 9.16. ATA drive jumpers for most 3.5-inch drives.


The master jumper indicates that the drive is a master or a slave. Some drives also require a slave present jumper, which is used only in a dual-drive setup and then installed only on the master drivewhich is somewhat confusing. This jumper tells the master that a slave drive is attached. With many ATA drives, the master jumper is optional and can be left off. Installing this jumper doesn't hurt in these cases and can eliminate confusion; I recommend that you install the jumpers listed here.

Note

Some drives have these jumpers on the drive circuit board, and as such they might not be visible on the rear.


The 2.5-inch drives used internally in most portables have a different jumper arrangement. The four jumper pins, labeled A, B, C, and D, are shown in Figure 9.17.

Figure 9.17. ATA drive jumpers for most 2.5-inch drives.


Because most 2.5-inch drives are installed as the only drive on the cable, you normally don't install any jumper, which results in a default master setting. Installing a jumper connecting the A-B pins results in a slave setting, and jumpering B-D is for cable select. Other jumper settings are not used.

To eliminate confusion over master/slave settings, most newer systems with cables supporting dual drives now use the cable select option. This involves two things. The first is having a special ATA cable that has all the wires except pin 28 running from the motherboard connector to both drive connectors. Pin 28 is used for cable select and is connected to one of the drive connectors (labeled master) and not to the other (labeled slave). Both drives are then configured in cable select mode via the CS jumper on each drive.

With cable select, the drive that receives signals on pin 28 automatically becomes the master, and the other becomes the slave. Most cables implement this by removing the metal insulation displacement bit from the pin-28 hole, which can be difficult to see at a glance. Other cables have a section of pin 28 visibly cut from the cable somewhere along the ribbon. Because this is such a minor modification to the cable and can be difficult to see, cable select cables normally have the connectors labeled master, slave, and system, indicating that the cable controls these options rather than the drive. All 80-conductor Ultra-ATA cables are designed to use cable select.

With cable select, you simply set the CS jumper on all drives and then plug the drive you want to be the master into the connector labeled master on the cable and the drive you want to be the slave into the connector labeled slave.

The only downside I see to using cable select is that it may restrict how the cable is routed or where you mount the drive that is to be the master versus the slave, because they must be plugged into specific cable connector positions.

ATA Commands

One of the best features of the ATA interface is the enhanced command set. The ATA interface was modeled after the WD1003 controller IBM used in the original AT system. All ATA drives must support the original WD command set (eight commands) with no exceptions, which is why ATA drives are so easy to install in systems today. All IBM-compatible systems have built-in ROM BIOS support for the WD1003, so they essentially support ATA as well.

In addition to supporting all the WD1003 commands, the ATA specification added numerous other commands to enhance performance and capabilities. These commands are an optional part of the ATA interface, but several of them are used in most drives available today and are very important to the performance and use of ATA drives in general.

Perhaps the most important is the Identify Drive command. This command causes the drive to transmit a 512-byte block of data that provides all details about the drive. Through this command, any program (including the system BIOS) can find out exactly which type of drive is connected, including the drive manufacturer, model number, operating parameters, and even the serial number of the drive. Many modern BIOSes use this information to automatically receive and enter the drive's parameters into CMOS memory, eliminating the need for the user to enter these parameters manually during system configuration. This arrangement helps prevent mistakes that can later lead to data loss when the user no longer remembers what parameters he used during setup.

The Identify Drive data can tell you many things about your drive, including the following:

  • Number of logical block addresses available using LBA mode

  • Number of physical cylinders, heads, and sectors available in P-CHS mode

  • Number of logical cylinders, heads, and sectors in the current translation L-CHS mode

  • Transfer modes (and speeds) supported

  • Manufacturer and model number

  • Internal firmware revision

  • Serial number

  • Buffer type/size, indicating sector buffering or caching capabilities

Several public-domain programs can execute this command to the drive and report the information onscreen. For more up-to-date information, use IDEDIAG, which is available from www.penguin.cz/~mhi/idediag, or HWINFO, which is available from www.hwinfo.com. I find these programs especially useful when I am trying to install ATA drives on a system that has a user-defined drive type but doesn't support auto-detection, and I need to know the correct parameters for a user-definable BIOS type. These programs get the information directly from the drive.

Two other important commands are the Read Multiple and Write Multiple commands. These commands permit multiple-sector data transfers and, when combined with block-mode PIO capabilities in the system, can result in incredible data transfer rates, many times faster than single-sector PIO transfers.

Many other enhanced commands are available, including room for a given drive manufacturer to implement what are called vendor-unique commands. Certain vendors often use these commands for features unique to each vendor. Often, vendor-unique commands control features such as low-level formatting and defect management. This is why low-level format (LLF) programs can be so specific to a particular manufacturer's ATA drives and why many manufacturers make their own LLF programs available.

Drive Capacity Limitations

ATA interface versions up through ATA-5 suffered from a drive capacity limitation of about 137GB (billion bytes). Depending on the BIOS used, this limitation can be further reduced to 8.4GB, or even as low as 528MB (million bytes). This is due to limitations in both the BIOS and the ATA interface, which when combined create even further limitations. To understand these limits, you have to look at the BIOS (software) and ATA (hardware) interfaces together.

The limitations when dealing with ATA drives are those of the ATA interface itself as well as the BIOS interface used to talk to the drive. A summary of the limitations is provided in Table 9.11.

Table 9.11. ATA Capacity Limitations for Various Sector-Addressing Methods

Sector- Addressing Method

Total Sectors Calculation

Max. Total Sectors

Max. Capacity (Bytes)

Capacity (Decimal)

Capacity (Binary)

CHS: BIOS w/o TL

1024x16x63

1,032,192

528,482,304

528.48MB

504.00MiB

CHS: BIOS w/ bit-shift TL

1024x240x63

15,482,880

7,927,234,560

7.93GB

7.38GiB

CHS: BIOS w/ LBA-assist TL

1024x255x63

16,450,560

8,422,686,720

8.42GB

7.84GiB

CHS: BIOS INT13h

1024x256x63

16,515,072

8,455,716,864

8.46GB

7.88GiB

CHS: ATA-1/ATA-5

65536x16x255

267,386,880

136,902,082,560

136.90GB

127.50GiB

LBA: ATA-1/ATA-5

228

268,435,456

137,438,953,472

137.44GB

128.00GiB

LBA: ATA-6+

248

281,474,976,710,655

144,115,188,075,855,360

144.12PB

128.00PiB

LBA: EDD BIOS

264

18,446,744,073,709,551,600

9,444,732,965,739,290,430,000

9.44ZB

8.00ZiB

BIOS = Basic Input Output System

ATA = AT Attachment (IDE)

CHS = cylinder, head, sector

LBA = logical block (sector) address

w/ = with

w/o = without

TL = translation

INT13h = interrupt 13 hex

EDD = Enhanced Disk Drive specification (Phoenix/ATA)

MB = megabyte (million bytes)

MiB = mebibyte

GB = gigabyte (billion bytes)

GiB = gibibyte

PB = petabyte (quadrillion bytes)

PiB = pebibyte

ZB = zettabyte (sextillion bytes)

ZiB = zebibyte


Prefixes for Decimal and Binary Multiples

Many readers will be unfamiliar with the MiB (mebibyte), GiB (gibibyte), PiB (pebibyte), and ZiB (zebibyte) designations I am using in this section and throughout the book. These are part of a standard designed to eliminate confusion between decimal- and binary-based multiples, especially in computer systems. Standard SI (system international or metric system) units are based on multiples of 10. This works well for most things, but not for computers, which operate in a binary world where most numbers are based on powers of 2. This resulted in different meanings being assigned to the same prefixfor example, 1MB (megabyte) could mean either 1 million bytes (106) or 1,048,576 bytes (220).

To eliminate confusion, in December 1998 the International Electrotechnical Commission (IEC) approved as an international standard the prefix names and symbols for binary multiples used in data processing and transmission. Some of these prefixes are shown in Table 9.12.

Table 9.12. Standard Prefix Names and Symbols for Binary Multiples

Decimal Prefixes:

Binary Prefixes:

Factor

Symbol

Name

Value

Factor

Symbol

Name

Derivation

Value

103

k

Kilo

1,000

210

Ki

Kibi

Kilobinary

1,024

106

M

Mega

1,000,000

220

Mi

Mebi

Megabinary

1,048,576

109

G

Giga

1,000,000,000

230

Gi

Gibi

Gigabinary

1,073,741,824

1012

T

Tera

1,000,000,000,000

240

Ti

Tebi

Terabinary

1,099,511,627,776

1015

P

Peta

1,000,000,000,000,000

250

Pi

Pebi

Petabinary

1,125,899,906,842,624

1018

E

Exa

1,000,000,000,000,000,000

260

Ei

Exbi

Exabinary

1,152,921,504,606,846,980

1021

Z

Zetta

1,000,000,000,000,000,000,000

270

Zi

Zebi

Zettabinary

1,180,591,620,717,411,300,000

Note that the symbol for kilo (k) is in lowercase (which is technically correct according to the SI standard), whereas all other decimal prefixes are uppercase.


Under this standard terminology, an MB (megabyte) would be 1,000,000 bytes, whereas an MiB (mebibyte) would be 1,048,576 bytes.

Note

For more information on these industry-standard decimal and binary prefixes, check out the National Institute for Standards and Technology (NIST) website at physics.nist.gov/cuu/Units/prefixes.html.


Note that even though these designations are official, they have yet to be widely adopted and in many cases confusion still reigns. MB is still often used to indicate both decimal millions of bytes and binary megabytes. Similarly, GB is often used to refer to decimal billions of bytes and binary gigabytes. In general, memory values are expressed by using the binary values, although disk capacities can go either way. This often leads to confusion in reporting disk capacities because many manufacturers tend to use whichever value makes their products look better. For example, drive capacities are often rated in decimal billions (G or giga), whereas most BIOS chips and operating system utilities, such as Windows FDISK, rate the same drive in binary gigabytes (Gi or gibi). Note also that when bits and bytes are used as part of some other measurement, the difference between bits and bytes is often distinguished by the use of a lower- or uppercase B. For example, the "bits" part of megabits is typically abbreviated with a lowercase b, resulting in the abbreviation Mbps for megabits per second, whereas MBps indicates megabytes per second.

CHS Versus LBA

There are two primary methods to address (or number) sectors on an ATA drive. The first method is called CHS (cylinder, head, sector) after the three respective coordinate numbers used to address each sector of the drive. The second method is called LBA (logical block address), which uses a single number to address each sector on a drive. CHS was derived from the physical way drives were constructed (and is how they work internally), whereas LBA evolved as a simpler and more logical way to number the sectors regardless of the internal physical construction.

When reading a drive sequentially in CHS mode, we start with cylinder 0, head 0, and sector 1, which is the first sector on the disk. Then all the remaining sectors on that first track are read, then the next head is selected, and all the sectors on that track are read, and so on until all the heads on the first cylinder are read. Then the next cylinder is selected, and the sequence starts over. Think of CHS as an odometer of sorts: The sector numbers must roll over before the head number can change, and the head numbers must roll over before the cylinder number can change.

When reading a drive sequentially in LBA mode, we start with sector 0, then read 1, then 2, and so on. The first sector on the drive in CHS mode would be 0,0,1; the same sector in LBA mode would be 0.

As an example, imagine a drive with one platter, two heads (both sides of the platter are used), two tracks on each platter (cylinders), and two sectors on each track. We would say the drive has two cylinders (tracks per side), two heads (sides), and two sectors per track. This would result in a total capacity of eight (2x2x2) sectors. Noting that cylinders and heads begin numbering from 0, while physical sectors on a track number from 1, using CHS addressing we would say the first sector on the drive is cylinder 0, head 0, sector 1 (0,0,1), the second sector is 0,0,2, the third sector is 0,1,1, the fourth sector is 0,1,2, and so on until we get to the last sector, which would be 1,1,2.

Now imagine that we could take the eight sectors and rather than refer directly to the physical cylinder, head, and sector, we number the sectors in order from 0 through 7. Therefore, if we wanted to address the fourth sector on the drive, we could reference it as sector 0,1,2 in CHS mode, or as sector 3 in LBA mode. Table 9.13 shows the correspondence between CHS and LBA sector numbers for this eight-sector imaginary drive.

Table 9.13. CHS and LBA Sector Numbers for an Imaginary Drive with Two Cylinders, Two Heads, and Two Sectors per Track (Eight Sectors Total)

Mode

Equivalent Sector Numbers

CHS:

0,0,1

0,0,2

0,1,1

0,1,2

1,0,1

1,0,2

1,1,1

1,1,2

LBA:

0

1

2

3

4

5

6

7


As you can see from the example, using LBA numbers is simpler and generally easier to handle. However, when the PC was first developed, all BIOS and ATA drive-level addressing was done using CHS addressing.

CHS/LBA and LBA/CHS conversions

It is possible to address the same sectors in either CHS or LBA mode. The conversion from CHS to LBA is always consistent in that for a given drive, a particular CHS address will always convert to a given LBA address, and vice versa. The ATA-1 document specifies a simple formula that can be used to convert CHS parameters to LBA:

LBA = (((C * HPC) + H) * SPT) + S - 1

By reversing this formula, you can convert the other way (that is, from LBA back to CHS):

C = int (LBA / SPT / HPC)

H = int ((LBA / SPT) mod HPC)

S = (LBA mod SPT) + 1

For these formulae

  • LBA = logical block address

  • C = cylinder

  • H = head

  • S = sector

  • HPC = heads per cylinder (total number of heads)

  • SPT = sectors per track

  • int X = integer portion of X

  • X mod Y = modulus (remainder) of X/Y

Using these formulae, you can calculate the LBA for any given CHS address, and vice versa. Given a drive of 16,383 cylinders, 16 heads, and 63 sectors per track, Table 9.14 shows the equivalent CHS and LBA addresses.

Table 9.14. Equivalent CHS and LBA Sector Numbers for a Drive with 16,383 Cylinders, 16 Heads, and 63 Sectors per Track (16,514,064 Sectors Total)

Cylinders

Heads

Sectors

LBA

0

0

1

0

0

0

63

62

1

1

1

63

999

15

63

1,007,999

1,000

0

1

1,008,000

9,999

15

63

10,079,999

10,000

0

1

10,080,000

16,382

15

63

16,514,063


BIOS Commands Versus ATA Commands

In addition to the two methods of sector addressing (CHS and LBA), there are two levels of interfaces where sector addressing occurs. One interface is where the operating system talks to the BIOS (using BIOS commands); the other is where the BIOS talks to the drive (using ATA commands). The specific commands at these levels are different, but both support CHS and LBA modes. Figure 9.18 illustrates the two interface levels.

Figure 9.18. Typical ATA hard drive connectors. (In this figure, L-CHS stands for Logical CHS, and P-CHS stands for Physical CHS.)


When the operating system talks to the BIOS to read or write sectors, it issues commands via software INT13h, which is how the BIOS subroutines for disk access are called. Various INT13h subfunctions allow sectors to be read or written using either CHS or LBA addressing. The BIOS routines then convert the BIOS commands into ATA hardware-level commands, which are sent over the bus I/O ports to the drive controller. Commands at the ATA hardware level can also use either CHS or LBA addressing, although the limitations are different. Whether your BIOS and drive use CHS or LBA addressing depends on the drive capacity, the age of the BIOS and drive, as well as the BIOS Setup settings and operating system used.

CHS Limitations (The 528MB Barrier)

The original BIOS-based driver for hard disks is accessed via software interrupt 13h (13 hex) and offers functions for reading and writing drives at the sector level. Standard INT13h functions require that a particular sector be addressed by its cylinder, head, and sector location, otherwise known as CHS addressing. This interface is used by the operating system and low-level disk utilities to access the drive. IBM originally wrote the INT13h interface for the BIOS on the PC XT hard disk controller in 1983. In 1984, IBM incorporated it into the AT motherboard BIOS. This interface used numbers to define the particular cylinder, head, and sector being addressed. Table 9.15, which shows the standard INT13h BIOS CHS parameter limits, includes the maximum values for these numbers.

Table 9.15. INT13h BIOS CHS Parameter Limits

Field

Field Size

Maximum Value

Range

Total Usable

Cylinder

10 bits

1024

01023

1024

Head

8 bits

256

0255

256

Sector

6 bits

64

163

63


The concept of a maximum value given a number of digits is simple: If you had, for example, a hotel with two-digit decimal room numbers, you could have only 100 (102) rooms, numbered 099. The CHS numbers used by the standard BIOS INT13h interface are binary, and with a 10-bit number being used to count cylinders, you can have only 1,024 (210) maximum, numbered 01,023. Because the head is identified by an 8-bit number, the maximum number of heads is 256 (28), numbered 0255. Finally, with sectors per track, there is a minor difference. Sectors on a track are identified by a 6-bit number, which would normally allow a maximum of 64 (26) sectors; however, because sectors are numbered starting with 1 (instead of 0), the range is limited to 163, which means a total of 63 sectors per track is the maximum the BIOS can handle.

These BIOS limitations are true for all BIOS versions or programs that rely on CHS addressing. Using the maximum numbers possible for CHS at the BIOS level, addressing a drive with 1,024 cylinders, 256 heads, and 63 sectors per track is possible. Because each sector is 512 bytes, the math works out as follows:

                 Max. Values ----------------------------     Cylinders         1,024         Heads           256 Sectors/Track            63 ============================ Total Sectors    16,515,072 ---------------------------- Total Bytes   8,455,716,864 Megabytes (MB)        8,456 Mebibytes (MiB)       8,064 Gigabytes (GB)          8.4 Gibibytes (GiB)         7.8 


From these calculations, you can see that the maximum capacity drive addressable via the standard BIOS INT13h interface is about 8.4GB (where GB equals roughly one billion bytes), or 7.8GiB (where GiB means gigabinary bytes).

Unfortunately, the BIOS INT13h limits are not the only limitations that apply. Limits also exist in the ATA interface itself. The ATA CHS limits are shown in Table 9.16.

Table 9.16. Standard ATA CHS Parameter Limitations

Field

Field Size

Maximum Value

Range

Total Usable

Cylinder

16 bits

65536

065535

65536

Head

4 bits

16

015

16

Sector

8 bits

256

1255

255


As you can see, the ATA interface uses different sized fields to store CHS values. Note that the ATA limits are higher than the BIOS limits for cylinders and sectors but lower than the BIOS limit for heads. The CHS limits for capacity according to the ATA-1 through ATA-5 specifications are as follows:

                    Max. Values ------------------------------     Cylinders           65,536         Heads               16 Sectors/Track              255 =============================== Total Sectors      267,386,880 ---------------------------- 


 Total Bytes    136,902,082,560 Megabytes (MB)         136,902 Mebibytes (MiB)        130,560 Gigabytes (GB)           136.9 Gibibytes (GiB)          127.5 


When you combine the limitations of the BIOS and ATA CHS parameters, you end up with the situation shown in Table 9.17.

Table 9.17. Combined BIOS and ATA CHS Parameter Limits

Field

BIOS CHS Parameter Limits

ATA CHS Parameter Limits

Combined CHS Parameter Limits

Cylinder

1,024

65,536

1,024

Head

256

16

16

Sector

63

255

63

Total sectors

16,515,072

267,386,880

1,032,192

Maximum capacity

8.4GB

136.9GB

528MB


As you can see, the lowest common denominator of the combined CHS limits results in maximum usable parameters of 1,024 cylinders, 16 heads, and 63 sectors, which results in a maximum drive capacity of 528MB. This became known as the 528MB barrier, and it affects virtually all PCs built in 1993 or earlier.

CHS Translation: Breaking the 528MB Barrier

Having a barrier that limits drive capacity to 528MB wasn't a problem when the largest drives available were smaller than that. But by 1994, drive technology had developed such that it was possible to make drives larger than what the combined BIOS and ATA limitations could address. Clearly, a fix for the problem was needed.

Starting in 1993, the BIOS developer Phoenix Technologies had begun working on BIOS extensions to work around the combined CHS limits. In January of 1994 it released the "BIOS Enhanced Disk Drive (EDD) Specification," which was later republished by the T13 committee (also responsible for ATA) as "BIOS Enhanced Disk Drive Services." The EDD documents detail several methods for circumventing the limitations of previous BIOSes without causing compatibility problems with existing software. These include

  • BIOS INT13h extensions supporting 64-bit LBA

  • Bit-shift geometric CHS translation

  • LBA-assist geometric CHS translation

The method for dealing with the CHS problem was called translation, because it allowed for additional subroutines in the BIOS to translate CHS parameters from ATA maximums to BIOS maximums (and vice versa). In an effort to make its methods standard among the entire PC industry, Phoenix released the EDD document publicly and allowed the technology to be used free of charge, even among its competitors, such as AMI and Award. The T13 committee in charge of ATA subsequently adopted the EDD standard and incorporated it into official ATA documents.

Starting in 1994, most BIOSes began implementing the Phoenix-designed CHS translation methods, which enabled drives up to the BIOS limit of 8.4GB to be supported. The fix involved what is termed parameter translation at the BIOS level, which adapted or translated the cylinder, head, and sector numbers to fit within the allowable BIOS parameters. There are two types of translation: One works via a technique called CHS bit-shift (usually called Large or Extended CHS in the BIOS Setup), whereas the other uses a technique called LBA-assist (usually called just LBA in the BIOS Setup). They refer to the different mathematical methods of doing essentially the same thingthat is, converting one set of CHS numbers to another.

Virtually all PC BIOSes since 1994 have translation capability in the BIOS Setup, and virtually all offer both translation modes as well as an option to disable translation entirely. If both CHS bit-shift ("Large" or "ECHS") and LBA-assist ("LBA") translation modes are offered, you should probably choose the LBA method of translation because it is the more efficient and flexible of the two. LBA-assist translation also gets around the 4.2GB operating system bug because it is designed to allow a maximum of 255 logical heads no matter what.

You usually can tell whether your BIOS supports translation by the capability to specify more than 1,024 cylinders in the BIOS Setup, although this can be misleading. The best clue is to look for the translation setting parameters in the drive setup page in the BIOS Setup. See Chapter 5, "Motherboards," for more information on how to enter the BIOS Setup on your system. If you see drive-related settings, such as LBA or ECHS (sometimes called Large or Extended), these are telltale signs of a BIOS with translation support. Most BIOSes with a date of 1994 or later include this capability. If your system currently does not support parameter translation, you might be able to get an upgrade from your motherboard manufacturer.

Table 9.18 summarizes the four ways today's BIOSes can handle addressing sectors on the drive: Standard CHS (no translation), Extended CHS translation, LBA translation, and pure LBA addressing.

Table 9.18. Drive Sector Addressing Methods

BIOS Mode

OS to BIOS

BIOS to Drive

Standard (Normal; no translation)

P-CHS

P-CHS

CHS bit-shift (ECHS) translation

L-CHS

P-CHS

LBA-assist (LBA) translation

L-CHS

LBA

Pure LBA (EDD BIOS)

LBA

LBA


In Standard CHS, there is only one possible translation step internal to the drive. The drive's actual physical geometry is completely invisible from the outside with all zone-recorded ATA drives today. The cylinders, heads, and sectors printed on the label for use in the BIOS Setup are purely logical geometry and do not represent the actual physical parameters. Standard CHS addressing is limited to 16 heads and 1,024 cylinders, which provides a limit of 504MB.

This is often called "Normal" in the BIOS Setup and causes the BIOS to behave like an old-fashioned one without translation. Use this setting if your drive has fewer than 1,024 cylinders or if you want to use the drive with a non-DOS operating system that doesn't understand translation.

"ECHS" or "Large" in the BIOS Setup is CHS bit-shift, and most from 1997 and later use the revised method (240 logical heads maximum). "LBA" as selected in the BIOS Setup indicates LBA-assist translation, not pure LBA mode. This allows software to operate using L-CHS parameters while the BIOS talks to the drive in LBA mode.

The only way to select a pure LBA mode, from the OS to the BIOS as well as from the BIOS to the drive, is with a drive that is over 8.4GB. All drives over 137GB must be addressed via LBA at both the BIOS and drive level, and most PC BIOSes will automatically address any drive over 8.4GB in that manner as well. In this case, no special BIOS Setup settings are needed other than setting the type to auto or auto-detect.

Caution

A word of warning with these BIOS translation settings: If you have a drive 8.4GB or less in capacity and switch between Standard CHS, ECHS, or LBA, the BIOS can change the (translated) geometry. The same thing can happen if you transfer a disk that has been formatted on an old, non-LBA computer to a new one that uses LBA. This causes the logical CHS geometry seen by the operating system to change and the data to appear in the wrong locations from where it actually is! This can cause you to lose access to your data if you are not careful. I always recommend recording the CMOS Setup screens associated with the hard disk configuration so you can properly match the setup of a drive and the settings to which it was originally set. This does not affect drives over 8.4GB because in that case pure LBA is automatically selected.


The 8.4GB Barrier

Although CHS translation breaks the 528MB barrier, it runs into another barrier at 8.4GB. Supporting drives larger than 8.4GB requires that we leave CHS behind and change from CHS to LBA addressing at the BIOS level. The ATA interface had always supported LBA addressing, even in the original ATA-1 specification. One problem was that originally LBA support at the ATA level was optional, but the main problem was that there was no LBA support at the BIOS interface level. You could set LBA-assist translation in the BIOS Setup, but all that did was convert the drive LBA numbers to CHS numbers at the BIOS interface level.

Phoenix Technologies recognized that the BIOS interface needed to move from CHS to LBA early on and, beginning in 1994, published the "BIOS Enhanced Disk Drive (EDD) Specification," which addressed this problem with new extended INT13h BIOS services that worked with LBA rather than CHS addresses.

To ensure industry-wide support and compatibility for these new BIOS functions, in 1996 Phoenix turned this document over to the National Committee on Information Technology Standards (NCITS) T13 technical committee for further enhancement and certification as a standard called the "BIOS Enhanced Disk Drive (EDD) Specification." Starting in 1998, most of the other BIOS manufacturers began installing EDD support in their BIOSes, enabling BIOS-level LBA mode support for ATA drives larger than 8.4GB. Coincidentally (or not), this support arrived just in time because ATA drives of that size and larger became available that same year.

The EDD document describes new extended INT13h BIOS commands that allow LBA addressing up to 264 sectors, which results in a theoretical maximum capacity of more than 9.44ZB (zettabytes, or quadrillion bytes). That is the same as saying 9.44 trillion gigabytes (9.44x1021 bytes or, to be more precise, 9,444,732,965,739,290,430,000 bytes)! I say "theoretical capacity" because even though by 1998 the BIOS could handle up to 264 sectors, ATA drives were still using only 28-bit addressing (228 sectors) at the ATA interface level. This limited an ATA drive to 268,435,456 sectors, which was a capacity of 137,438,953,472 bytes or 137.44GB. Thus, the 8.4GB barrier had been broken, but another barrier remained at 137GB due to the 28-bit LBA addressing used in the ATA interface. The numbers work out as follows:

                      Max. Values --------------------------------- Total Sectors        268,435,456 --------------------------------- Total Bytes      137,438,953,472 Megabytes (MB)           137,439 Mebibytes (MiB)          131,072 Gigabytes (GB)            137.44 Gibibytes (GiB)           128.00 


Through use of the new extended INT13h 64-bit LBA mode commands at the BIOS level, as well as the existing 28-bit LBA mode commands at the ATA level, no translation would be required, and the LBA numbers would be passed unchanged. The combination of LBA at the BIOS level and the ATA interface level meant that the clumsy CHS addressing could finally die. This also means that when you install an ATA drive larger than 8.4GB in a PC that has an EDD-capable BIOS (1998 or newer), both the BIOS and the drive are automatically set to use LBA mode.

An interesting quirk is that to allow backward compatibility in case you boot an older operating system that doesn't support LBA mode addressing (DOS or the original release of Windows 95 for example), most drives larger than 8.4GB will report 16,383 cylinders, 16 heads, and 63 sectors per track, which is 8.4GB. This allows a 160GB drive, for example, to be seen by older BIOSes or older operating systems as an 8.4GB drive. That sounds strange, but I guess having a 160GB drive being recognized as an 8.4GB drive is better than not having it work at all. If you do want to install a drive larger than 8.4GB into a system dated before 1998, then either a motherboard BIOS upgrade or an add-on BIOS card with EDD support (available from MicroFirmware, for example) is recommended.

The 137GB Barrier and Beyond

By 2001 the 137GB barrier had become a problem because 3.5-inch hard drives were poised to breach that capacity level. The solution came in the form of ATA-6, which was being developed during that year. To allow for addressing drives of greater capacity, ATA-6 upgraded the LBA functions from using 28-bit numbers to using larger, 48-bit numbers instead.

The ATA-6 specification extends the LBA interface such that it can use 48-bit sector addressing. This means that maximum capacity is increased to 248 (281,474,976,710,656) total sectors. Because each sector stores 512 bytes, this results in the following maximum drive capacity:

                             Max. Values --------------------------------------- Total Sectors       281,474,976,710,656 --------------------------------------- Total Bytes     144,115,188,075,855,888 Megabytes (MB)          144,115,188,076 Mebibytes (MiB)         137,438,953,472 Gigabytes (GB)              144,115,188 Gibibytes (GiB)             134,217,728 Terabytes (TB)                  144,115 Tebibytes (TiB)                 131,072 Petabytes (PB)                   144.12 Pebibytes (PiB)                  128.00 


As you can see, the 48-bit LBA in ATA-6 allows a capacity of just over 144PB (petabytes = quadrillion bytes)!

Because the EDD BIOS functions use a 64-bit LBA number, they have a much larger limit:

                                      Max. Values ------------------------------------------------ Total Sectors         18,446,744,073,709,551,600 ------------------------------------------------ Total Bytes        9,444,732,965,739,290,430,000 Megabytes (MB)             9,444,732,965,739,291 Mebibytes (MiB)            9,007,199,254,740,993 Gigabytes (GB)                 9,444,732,965,739 Gibibytes (GiB)                8,796,093,022,208 Terabytes (TB)                     9,444,732,966 Tebibytes (TiB)                    8,589,934,592 Petabytes (PB)                         9,444,733 Pebibytes (PiB)                        8,388,608 Exabytes (EB)                              9,445 Exbibytes (EiB)                            8,192 Zettabytes (ZB)                             9.44 Zebibytes (ZiB)                             8.00 


Although the BIOS services use 64-bit LBA (allowing up to 264 sectors) for even greater capacity, the 144PB ATA-6 limitation will be the lower of the two that will apply. Still, that should hold us for some time to come.

Given that hard disk drives have been doubling in capacity every 1.52 years (Moore's Law), and considering that 160GB ATA drives were available in late 2001, I estimate that it will take us until between the years 2031 to 2041 before we reach the 144PB barrier (assuming hard disk technology hasn't been completely replaced by this point). Similarly, I estimate the 9.44ZB EDD BIOS barrier won't be reached until between the years 2055 to 2073! Phoenix originally claimed that the EDD specification would hold us until 2020; it seems Phoenix was being quite conservative.

The 137GB barrier has proven a bit more complicated than previous barriersnot only are there BIOS issues but also operating system and chipset-based ATA host adapter driver issues as well. Drives larger than 137GB are accessed using 48-bit LBA (logical block address) numbers, which require BIOS support, chipset driver support, and operating systems support. Generally, you will need the following:

  • A BIOS with 48-bit LBA support (normally dated September 2002 or newer)

  • The latest chipset driver, such as the Intel Application Accelerator (for motherboards using Intel chipsets; go to www.intel.com/support/chipsets/iaa)

  • Windows XP with Service Pack 1 (or later) installed

If you have a system without the BIOS support, check with your motherboard manufacturer for an update, or optionally you can use a card with onboard BIOS, such as the Ultra ATA 133 PCI card from Maxtor. If your motherboard uses an Intel chipset, you can download the latest chipset driver (Intel calls it the Intel Application Accelerator) from www.intel.com/support/chipsets/iaa. If your motherboard uses a non-Intel chipset, check with the motherboard or chipset manufacturer for driver updates to enable 48-bit LBA support.

Finally, note that the original version of XP, as well as Windows 2000/NT and Windows 95/98/Me, does not currently provide native support for ATA hard drives larger than 137GB. You will need to use Windows XP and ensure you have Service Pack 1 or later installed.

Operating System and Other Software Limitations

Note that if you use older software, including utilities, applications, or even operating systems that rely exclusively on CHS parameters, they will see all drives over 8.4GB as 8.4GB only. You will need not only a newer BIOS but also newer software designed to handle the direct LBA addressing to work with drives over 8.4GB.

Operating systems limitations with respect to drives over 8.4GB are shown in Table 9.19.

Table 9.19. Operating Systems Limitations

Operating System

Limitations for Hard Drive Size

DOS/Windows 3x

DOS 6.22 or lower cannot support drives greater than 8.4GB. DOS 7.0 or higher (included with Windows 95 or later) is required to recognize a drive over 8.4GB.

Windows 9X/Me

Windows 95a (original version) does support the INT13h extensions, which means it does support drives over 8.4GB; however, due to limitations of the FAT16 file system, the maximum individual partition size is limited to 2GB. Windows 95B/OSR2 or later (including Windows 98/Me) supports the INT13h extensions, which allows drives over 8.4GB, and also supports FAT32, which allows partition sizes up to the maximum capacity of the drive. However, Windows 95 doesn't support hard drives larger than 32GB because of limitations in its design. Windows 98 requires an update to FDISK to partition drives larger than 64GB.

Windows NT

Windows NT 3.5x does not support drives greater than 8.4GB. Windows NT 4.0 does support drivers greater than 8.4GB, however. When a drive larger than 8.4GB is being used as the primary bootable device, Windows NT will not recognize more than 8.4GB. Microsoft has released Service Pack 4, which corrects this problem.

Windows 2000/XP

Windows 2000/XP supports drives greater than 8.4GB.

OS/2 Warp

Some versions of OS/2 are limited to a boot partition size of 3.1GB or 4.3GB. IBM has a Device Driver Pack upgrade that enables the boot partition to be as large as 8.4GB. The HPFS file system in OS/2 will support drives up to 64GB.

Novell

NetWare 5.0 or later supports drives greater than 8.4GB.


In the case of operating systems that support drives over 8.4GB, the maximum drive size limitations are dependent on the BIOS and the hard drive interface standard, not the OS. Instead, other limitations come into play for the volumes (partitions) and files that can be created and managed by the various operating systems. These limitations are dependent not only on the operating system involved but also the file system that is used for the volume. Table 9.20 shows the minimum and maximum volume (partition) size and file size limitations of the various Windows operating systems. You must use Windows 98/Me or a Windows NTtype operating system (NT, 2000, or XP) if you want to use a drive larger than 137GB. Note that the original version of XP, as well as Windows 2000/NT and Windows 95/98/Me, does not currently provide native support for ATA hard drives larger than 137GB. You will need to use Windows XP and ensure you have Service Pack 1 or later installed to use an ATA drive over 137GB. This does not affect drives interfaced via USB, FireWire, SCSI, or other interfaces.

Table 9.20. Operating Systems Volume/File Size Limitations by File System

OS Limitations by File System

FAT16

FAT32

NTFS

Min. Volume Size (9x/Me)

2.092MB

33.554MB

Min. Volume Size (NT/2000/XP)

2.092MB

33.554MB

1.000MB

Max. Volume Size (9x)

2.147GB

136.902GB

Max. Volume Size (Me)

2.147GB

8.796TB

Max. Volume Size (NT/2000/XP)

4.294GB

8.796GB

281.475TB

Max. File Size (all)

4.294GB

4.294GB

16.384TB

= not applicable

MB = megabyte = 1,000,000 bytes

GB = gigabyte = 1,000,000,000 bytes

TB = terabyte = 1,000,000,000,000 bytes


ATA Transfer Modes

ATA-2 and ATA-3 defined the first of several higher-performance modes for transferring data to and from the drive. These faster modes were the main part of the newer specifications and were the main reason they were initially developed. The following subsections discuss these modes.

PIO Mode

The PIO (Programmed I/O) mode determines how fast data is transferred to and from the drive using PIO transfers. In the slowest possible modePIO mode 0the data cycle time cannot exceed 600 nanoseconds (ns). In a single cycle, 16 bits are transferred into or out of the drive, making the theoretical transfer rate of PIO Mode 0 (600ns cycle time) 3.3MBps, whereas PIO Mode 4 (120ns cycle time) achieves a 16.6MBps transfer rate.

Table 9.21 shows the PIO modes, with their respective transfer rates.

Table 9.21. PIO (Programmed I/O) Modes and Transfer Rates

PIO Mode

Bus Width (bits)

Cycle Speed (ns)

Bus Speed (MHz)

Cycles per Clock

Transfer Rate (MBps)

ATA Specification

0

16

600

1.67

1

3.33

ATA-1

1

16

383

2.61

1

5.22

ATA-1

2

16

240

4.17

1

8.33

ATA-1

3

16

180

5.56

1

11.11

ATA-2

4

16

120

8.33

1

16.67

ATA-2

ATA-2 was also referred to as EIDE (Enhanced IDE) or Fast-ATA

ns = nanoseconds (billionths of a second)

MB = million bytes


Most motherboards with ATA-2 or greater support have dual ATA connectors on the motherboard. Most of the motherboard chipsets include the ATA interface in their South Bridge components, which in most systems is tied into the PCI bus.

Older 486 and some early Pentium boards have only the primary connector running through the system's PCI local bus. The secondary connector on those boards usually runs through the ISA bus and therefore supports up to Mode 2 operation only.

When interrogated with an Identify Drive command, a hard disk returns, among other things, information about the PIO and DMA modes it is capable of using. Most enhanced BIOSes automatically set the correct mode to match the capabilities of the drive. If you set a mode faster than the drive can handle, data corruption results.

ATA-2 and newer drives also perform Block Mode PIO, which means they use the Read/Write Multiple commands that greatly reduce the number of interrupts sent to the host processor. This lowers the overhead, and the resulting transfers are even faster.

DMA Transfer Modes

ATA drives also support direct memory access (DMA) transfers. DMA means that the data is transferred directly between drive and memory without using the CPU as an intermediary, as opposed to PIO. This has the effect of offloading much of the work of transferring data from the processor, in effect allowing the processor to do other things while the transfer is taking place.

There are two distinct types of direct memory access: singleword (8-bit) and multiword (16-bit) DMA. Singleword DMA modes were removed from the ATA-3 and later specifications and are obsolete. DMA modes are also sometimes called busmaster ATA modes because they use a host adapter that supports busmastering. Ordinary DMA relies on the legacy DMA controller on the motherboard to perform the complex task of arbitration, grabbing the system bus and transferring the data. In the case of busmastering DMA, all this is done by a higher-speed logic chip in the host adapter interface (which is also on the motherboard).

Systems using the Intel PIIX (PCI IDE ISA eXcelerator) or mobile PIIX and later South Bridge chips (or equivalent) have the capability of supporting busmaster ATA. The singleword and doubleword busmaster ATA modes and transfer rates are shown in Tables 9.22 and 9.23.

Table 9.22. Singleword (8-bit) DMA Modes and Transfer Rates

8-bit DMA Mode

Bus Width (bits)

Cycle Speed (ns)

Bus Speed (MHz)

Cycles per Clock

Transfer Rate (MBps)

ATA Specification

0

16

960

1.04

1

2.08

ATA-1[1]

1

16

480

2.08

1

4.17

ATA-1[1]

2

16

240

4.17

1

8.33

ATA-1[1]


[1] Singleword (8-bit) DMA modes were removed from the ATA-3 and later specifications.

Table 9.23. Multiword (16-bit) DMA Modes and Transfer Rates

16-bit DMA Mode

Bus Width (bits)

Cycle Speed (ns)

Bus Speed (MHz)

Cycles per Clock

Transfer Rate (MBps)

ATA Specification

0

16

480

2.08

1

4.17

ATA-1

1

16

150

6.67

1

13.33

ATA-2

2

16

120

8.33

1

16.67

ATA-2

ATA-2 was also referred to as EIDE (Enhanced IDE) or Fast-ATA.


Note that doubleword DMA modes are also called busmaster DMA modes by some manufacturers. Unfortunately, even the fastest mode (doubleword DMA Mode 2) results in the same 16.67MBps transfer speed as PIO Mode 4. However, even though the transfer speed is the same as PIO, because DMA offloads much of the work from the processor, overall system performance would be higher. Even so, multiword DMA modes were never very popular and have been superseded by the newer Ultra-DMA modes supported in ATA-4 through ATA-7 compatible devices.

Table 9.24 shows the Ultra-DMA modes now supported in the ATA-4 through ATA-7 specifications.

Table 9.24. Ultra-DMA Support in ATA-4 Through ATA-7

Ultra-DMA Mode

Bus Width (bits)

Cycle Speed (ns)

Bus Speed (MHz)

Cycles per Clock

Transfer Rate (MBps)

ATA Specification

0

16

240

4.17

2

16.67

ATA-4

1

16

160

6.25

2

25.00

ATA-4

2

16

120

8.33

2

33.33

ATA-4

3

16

90

11.11

2

44.44

ATA-5

4

16

60

16.67

2

66.67

ATA-5

5

16

40

25.00

2

100.00

ATA-6

6

16

30

33.00

2

133.00

ATA-7

ATA-4 UDMA Mode 2 is sometimes called Ultra-ATA/33 or ATA-33.

ATA-5 UDMA Mode 4 is sometimes called Ultra-ATA/66 or ATA-66.

ATA-6 UDMA Mode 5 is sometimes called Ultra-ATA/100 or ATA-100.

ATA-7 UDMA Mode 6 is sometimes called Ultra-ATA/133 or ATA-133.


ATAPI (ATA Packet Interface)

ATAPI (or the ATA Packet Interface) is a standard designed to provide the commands needed for devices such as CD-ROMs, DVD-ROMs and tape drives that plug into an ordinary ATA connector. The principal advantage of ATAPI hardware is that it's cheap and works on your current adapter. For CD-ROMs and DVD-ROMs, it has a somewhat lower CPU usage compared to proprietary adapters, but there's no performance gain otherwise. For tape drives, ATAPI has potential for superior performance and reliability compared to the popular floppy controllerattached tape devices. ATAPI is also used to run other removable storage devices, such as the LS-120 SuperDisk drives and internal Iomega Zip and Jaz drives as well as CDRW and DVD+-RW drives.

Although ATAPI CD-ROMs use the hard disk interface, this does not mean they look like ordinary hard disks; to the contrary, from a software point of view, they are a completely different kind of animal. They closely resemble a SCSI device. All modern ATA CD-ROMs support the ATAPI protocols, and generally the terms are synonymous. In other words, an ATAPI CD-ROM is an ATA CD-ROM, and vice versa.

Caution

ATAPI support other than for booting is not found directly in the BIOS of many systems. Systems without ATAPI support in the BIOS cannot boot from an ATAPI CD-ROM, so you still must load a driver to use ATAPI under DOS or Windows. Windows 95 and later (including 98 and Me) and Windows NT (including Windows 2000 and XP) have native ATAPI support. Newer systems with ATAPI-aware BIOSes are now available, which allow booting from an ATAPI CD-ROM. However, ATAPI drivers still need to be loaded by the OS for access after booting. Some versions of the Windows 98, NT, 2000, and XP CD-ROMs are directly bootable on those systems, greatly easing installation.


I normally recommend keeping different types of ATA devices on separate channels because ATA does not normally support overlapping access. When one drive is being accessed, the other cannot. By keeping the CD-ROM and hard disk on separate channels, you can more effectively overlap accessing between them.




Upgrading and Repairing Laptops
Scott Muellers Upgrading and Repairing Laptops, Second Edition
ISBN: 0789733765
EAN: 2147483647
Year: 2005
Pages: 180
Authors: Scott Mueller

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net