Please consider a donation to the Higher Intellect project. See https://preterhuman.net/donate.php or the Donate to Higher Intellect page for more info. |
Seagate's Advanced SCSI Architecture II
By: Tai Patwardhan
Date: October, 1994
ASA-II Extending the Power of Seagate's Advanced SCSI Architecture
Introduction
Within the past four years, the computer industry has experienced a consolidation of disc drive interfaces. The ST412 interface once dominated the desktop, with MFM and RLL format drives accounting for the vast majority of disc drives sold. Other interfaces, such as ESDI, were predicted to have bright futures, but the market dictated otherwise. The handful of disc drive interfaces has since shrink down to two: ATA/IDE and the Small Computer Systems Interface (SCSI). As the performance needs of the desktop continue to grow, however, both of these interfaces have spawned a host of successors based on specific needs of the host platform. While ATA and its kin have had tremendous success in the PC market, the limitations of the ATA specification led users who were seeking higher performance and multiple device support to discover the benefits of SCSI.
A SCSI Family Portrait
The SCSI has become the high performance standard for the computer industry. Featuring fast data transfer rates, a highly functional command set and the ability to support many devices on a single bus, SCSI offers an unparalleled combination of performance, flexibility and expandability. It is for these reasons that SCSI is used as the standard interface in computers ranging from the single user PCs through LAN servers and high performance RISC workstations, to super computers.
SCSI-2 was introduced three years ago and added a host of new commands and functionality. These enhancements, which include caching, command queuing and power management, increased its performance and flexibility. The Fast-SCSI protocol then doubled the physical speed of the SCSI bus signals to allow faster data transfers and the Wide-SCSI specification doubled the width of the data path from eight bits to sixteen bits to allow even greater amounts of data to be transferred between SCSI devices and the host computer. The vast majority of SCSI drives currently sold for desktop machines implement Fast SCSI-2, while most modern workstations regularly support and use Fast Wide SCSI-2 devices.
All of the enhancements were largely the result of system designers seeking to improve total system performance while retaining the advantages inherent to the basic SCSI paradigm. It is important to recognize, however, that all of the enhancements are directly dependent on the ability of an individual device to accept, interpret and execute commands efficiently. Optimizing the internal architecture is critical to take advantage of the increases in bus bandwidth afforded by the higher-performance SCSI protocols.
Improving from within
Since SCSI is mainly used with multi-tasking operating systems, special demands were placed on the drive which often challenged the capabilities of standard drive architectures. Seagate Technology recognized that in order to create a true high performance drive, it was not enough to simply implement the particular requirements of a Fast or Wide SCSI version. The internal architecture of the drive itself must be designed to provide optimum performance in such demanding operating environments as UNIX, Windows 95, Windows NT, Novell NetWare, or OS/2. The result was ASA, Seagate's Advanced SCSI Architecture. ASA has proved itself in the field in such highly successful products as Seagate's Barracuda 2 disc drive, (of which more then 300,000 units have been sold since its inception,) and has set the performance benchmark for the industry.
Boosted by strong customer demand, the hardware and firmware engineers at Seagate worked together to enhance the existing ASA architecture. The design goals were to optimize ASA to meet the special needs of the digital audio/video (A/V) industry, while maintaining the leadership position of ASA in the disc array, network server and workstation markets; the result was ASA-II. Boasting next-generation features such as a multi-tasking kernel, command pipelining, write merging, and background processing, ASA-II delivers industry leading disc drives with a high performance interface.
ASA-II, Improving on the Advanced SCSI Architecture
Seagate's decision to develop a SCSI architecture was based on the advantages afforded by an internal program. First, there is a much higher degree of control available to optimize performance. Since leading competitors use third-party chipsets, the performance of their drives is subject to the design integrity of the chipset. The drive company itself has reduced control over the optimization. Seagate's decision afforded the advantage that the designers were not subject to the constraints of these third-party chipsets, and thereby had complete control over the design process from inception to completion. That has made it possible for Seagate to implement advanced features previously unavailable in SCSI drive designs. It also provided for close interaction between firmware and hardware engineers during the design phase, which in turn resulted in a design with tightly integrated hardware and firmware functionality.
Another advantage of the internal development is based on the commonality of using a single architecture. Seagate implements ASA-II across multiple product lines, so that drive families share a common code-base. This has a significant advantage over companies that use different implementations between their product families, since each design has inherent idiosyncrasies that can complicate integration for system designers. With ASA-II, Seagate can insure compatibility across product families while allowing all products to realize the performance benefits built into ASA-II.
Such cross-platform utilization of ASA-II yields a migration path of drive capacities beginning at 500 megabytes, and extending up through at least 9 gigabytes of storage capacity. Since all of the drives have a common SCSI architecture, OEMs can qualify a single model with ASA-II, and rely on successive ASA drive models to be fully compatible with existing system designs and requirements. This can also be viewed as an "ease of integration" factor, mitigating the burdensome qualification testing and re-testing of successive drive generations as higher capacities are needed.
The power of this approach is demonstrated by the fact that there are already scores of thousands of Seagate drives with the Advanced SCSI Architecture in the field. An additional reason for this success is Seagate's ability to offer other popular versions of SCSI, including SCSI-2, Fast SCSI-2, and Fast/Wide SCSI-2 disc drives.
Multi-tasking comes to the disc drive
The heart of the ASA-II system is the Interrupt Handler. Lower performance drives process a single command at a time, and execute the commands in the order they are received. In true multi-tasking operations, drives with ASA-II need not sit idle while waiting for a particular operation to complete. As the term implies, the drive is capable of carrying out several actions concurrently. Because SCSI is a high-level interface with the controller embedded in the drive, a certain amount of time is necessary for the drive to decode a command from the host computer. Once the drive determines what command has been issued, more time is needed to setup the various elements within the drive to service the command before the command is executed. ASA-II uses many sophisticated techniques to minimize or eliminate much of this waiting time associated with receiving and processing a new command.
Figure 1: ASA-II System Architecture (image missing)
The two most common instances causing the drive electronics to remain idle during an I/O operation are when a drive is moving the recording heads to the target track (seeking), or the time it takes for the target sector on the target track to rotate under the heads (latency). This is because the physical mechanics of a seek require several milliseconds to complete; the electronics, by comparison, require only nanoseconds to take each of their required steps. This million-fold difference in response times offers the opportunity for the electronics to perform other operations while waiting for the mechanical portions of the drive.
The greatest advantage of an interrupt-driven architecture is the ability to do background processing. This allows command pipelining, where the drive decodes a subsequent command and begins the necessary setup to execute that command at the same time that it is fetching data for a prior command. This ability to preprocess a command while executing another command greatly reduces the amount of time necessary to service multiple commands. At times when the electronics on a conventional drive must wait for time-consuming operations to complete, like seeking or latency, a drive with ASA-II is able to perform other functions.
During this time, the drive has a host of operations that it can perform in the background. One example is rotational/seek sorting. Suppose, for example, a host computer sends a set of read requests to the drive. Often these requests require reading data from disparate areas on the recording media. Suppose, in this example that the read requests are for positions A, B, C and D as shown in Figure 2. Without seek sorting, the drive must first seek to location A, wait for a half-revolution of the disc and then read location B. The heads must then seek to the track of location C and wait for a 3/4 revolution of the disc. Finally, the same occurs for reading location D. This forces the recording heads to cover a lot of territory. Given average seek times this set of operation would take about 22 seconds to complete. A drive with ASA-II is able to reorder these requests so that they may be serviced more efficiently, minimizing the time spent seeking back and forth. An ASA-II drive would handle the same set of requests as shown in the latter portion of the illustration. During this time the kernel would be free to examine other pending commands and perform other background tasks.
Figure 2: Rotational Seek Sorting in ASA-II (image missing)
Managing the Cache
Other examples of tasks handled concurrently with disc operations are the management of the data cache on the drive, and event logging. Cache management is an important function for efficient drive operation, and an ideal candidate for a multi-tasking operation. ASA-II supports fully adaptive caching, including dynamic adjustment of segment size, and modification of the caching algorithm itself. If the drive can service incoming data requests more efficiently by sub-dividing the available cache memory into smaller partitions, it will do so. Assuming a total cache size of 512 Kilobytes, a drive with ASA-II is able to detect that it could best service the current stream of data requests by having, for example, two cache segments of 256 Kilobytes each. Later, if more segments are required, the drive is able to further divide the cache segments into four segments of 128 Kilobytes each, and so on. Also, if the drive currently has four segments, and determines that it would be better to have two segments, it will restructure from four segments to two. This is accomplished by having the drive examine the history of requests from the host. If the profile of requests seems to indicate that a particular cache configuration would achieve better performance, and if the host has allowed it, the drive adjusts the cache settings to optimize for that profile.
In addition to segment adaptation, ASA-II is also able to adapt for random seeks by disabling the read look-ahead function. Often, drives with large look-ahead caches waste time filling the cache with data that may never be used. Read look-ahead is based on the observation that data is usually accessed sequentially from the drive. If the current request for data is from location 100, than there is a strong (e.g. 85%) likelihood that the next request will be for location 101 and so forth. In such cases, the extra effort a drive expends reading data into a cache is offset by the ability to provide subsequent data requests directly from the cache memory. However, with random read requests, the drive could waste time reading the extra data when it is unlikely to be requested by the host. In this case the best course of action is to disable read look-ahead, and ASA-II is able to detect if the mode of caching is appropriate for the current situation, and adjust it accordingly.
Self-Diagnosis
A very exciting aspect of the ASA-II is event logging. Currently, all error conditions, and anomalous operations are automatically logged by the drive. This feature allows the host to query the drive and review errors statistics. A diagnostic host program can retrieve this log from the drive and signal the operating system, or possibly even the user, that something is amiss. This offers great potential to diagnose and prevent conditions which may cause subsequent drive failure or data loss. Since the drives perform event logging in the background, performance is not adversely impacted.
The Chute
Of course, the power of multi-tasking carries a price. ASA-II is optimized to handle and execute multiple commands simultaneously, and thus some overhead is incurred in the preprocessing stages. Although this is a great advantage for multiple commands, it could be a detriment for single commands. All of the logic concerned with pre-processing a command is unnecessary for executing a single command. The best way to process a single command is to just do it.
To accommodate such situations, ASA-II has an added feature Seagate refers to as the "Chute." When the first command is received by the drive, it takes the Chute, and bypasses all of the ancillary processing so that it can be executed immediately. This is of great benefit to systems in which the operating system can only process a single command at a time. Thus ASA-II has the flexibility to perform well in either multi-user, multiprocessor environments or single-tasking environments.
Zero latency reads
As mentioned, to find a particular sector of data on the disc, the drive must first move the recording heads to the correct track. Then, the drive must wait for the target sector to rotate under the heads. Latency, as the latter event is called, is one of the biggest contributors to idle-time for the drive electronics during execution of a command. In addition to other background tasks ASA-II performs during latency, the drive begins reading data into the cache memory as soon as the heads reach the target track. In this way, if the system requires subsequent sectors of data on the same track, some of the information is already in the cache. Since most data is accessed sequentially, the ability to perform zero-latency reads enhances performance by using idle time more effectively.
Fast Bus Connects
Much of the improvement in raw performance with ASA-II was the result of placing common interface responsibilities in hardware. This resulted in incredibly fast bus connect and disconnect speeds for all drives using ASA-II. For a typical drive to connect to the SCSI bus, and perform the selection, message, command transfer and disconnect phases, it takes about 350 microseconds. Since ASA-II performs these tasks in hardware, only 25 microseconds are needed to complete the entire bus connect/disconnect operation exclusive of the data transfer. In fact, Advanced SCSI Architecture drives boast the lowest bus overhead times in the industry.
The ability to quickly connect to and disconnect from the SCSI bus not only enhances the performance of the drive, but the SCSI bus as a whole. Since a single unit is not "hogging" the bus enables for long, a chain of Advanced SCSI Architecture drives on a single bus increased throughput for the entire SCSI subsystem.
Hardware Integration
The key to the improvements in hardware performance is the high level of integration of ASA-II chipset. The four major components driving the operation of the drive are integrated onto a single chip. This includes the SCSI interface protocol, the sequencer functions, the cache controller, and the drive's formatter/controller. A high level of integration allows for tighter operation and better cooperation between each element, which further enhances performance.
One of the most important aspects of the hardware design is the implementation of dual sequencers. Most other SCSI drive architectures only implement a single sequencer to handle transfers from the disc to the controller, and to accept commands from the host. With ASA-II, each function has a separate sequencer, namely the command sequencer and the disc sequencer. Without this design, multi-tasking would not be nearly as effective. While the disc sequencer is handling data transfers between the controller and media, the command sequencer is free to accept (and begin preprocessing) commands form the host. Conversely, if the command sequencer is busy receiving a new command from the host, the disc sequencer can still perform data transfers for another command.
The dual sequencer design of ASA-II is both a facilitator and enhancement for multi-tasking system performance. While the sequencers are busy with their respective tasks, the drives' main processor is able to handle still more tasks. This multi-processor architecture creates the true multi-tasking ability of ASA-II. The key to high performance for disc intensive computing needs.
Thermal Calibration and A/V
The demands multimedia applications place on storage go beyond speed and efficiency. Audio and video applications require sustained, high-bandwidth data throughput. Typically, high performance disc drives need better tracking accuracy for the recording heads, and thereby use a dedicated servo system for head positioning. To insure optimal tracking, time must be taken to intermittently calibrate the head positing system, due to thermal changes in an operating drive. This process is called Thermal Calibration, or T-Cal. Although T-Cal is an essential function, it can spell disaster for multimedia applications, which do not have the tolerance to wait for the drive to perform a T-Cal. Such tasks as mastering a CD-ROM or editing a video are dependent on sustained data streams. Standard T-Cal operations can ruin the process.
Recognizing the need for an A/V solution, Seagate designed ASA-II to perform non-sequential or interruptable thermal calibration. With interruptable T-Cal, the drive can suspend the calibration process to services data requests. Later, when there are no requests pending, the drive returns to the calibration task. With this design, ASA-II mitigates the problems associated with thermal calibration for A/V applications. Therefore, all ASA-II based disc drives are specially designed and ideally suited for performing in demanding A/V environments.
The Future - Now
Seagate has taken the advantages of a multi-tasking operating system for a computer and implemented them in the disc drive. The result is a drive architecture especially suited for operating with high-end, multi-threaded operating systems. System designers have recognized the value and potential of ASA-II, and responded with enthusiastic acceptance of these drives.
ASA-II represents the high-performance facet of Seagate's SCSI. Complementing this is the cost-effective SCSI implementation, which available on those drive where price is a greater issue than performance. This provides Seagate the ability to offer total storage solutions for all types of SCSI needs. SCSI for entry-level and desktop systems, and ASA-II for high-performance applications.
The Advanced SCSI Architecture has proven its performance in such drives as the Barracuda 2 and the ST11200N, both of which have received multiple awards from trade magazines. Since the ideal architecture was not externally available to implement the fastest drives, Seagate took the initiative to develop an in-house firmware/hardware combination which takes the power, flexibility and extendibility inherent with SCSI to a higher echelon of performance, reliability, and efficiency, and did so because the makers of leading-edge computer systems today required it. ASA-II is continuing the tradition in such industry leading products as the 9 gigabyte Elite 9, and the next generation Barracuda 4.