Method and apparatus for updating task files
A method and system for updating files includes transmitting a frame having status information and non-status information between a device and a host controller, storing the status information in a buffer, updating the non-status information in a non-status register, after updating the non-status information in the non-status register, determining if the frame has an error. The status register is updated if the frame includes no error.
Latest Intel Patents:
- TECHNOLOGIES FOR COLLECTING DELAY RELATED MEASUREMENTS FROM USER PLANE FUNCTIONS USING TRACES
- GATE CONTACT PATTERNING FOR STATIC RANDOM-ACCESS MEMORY
- THROUGH-GATE STRUCTURE WITH AN AIRGAP SPACER IN A SEMICONDUCTOR DEVICE
- COMPOSITE BACKPLATE ARCHITECTURES FOR BACKSIDE POWER DELIVERY AND ASSOCIATED METHODS
- POWER SPECTRAL DENSITY LIMIT FOR 6 GHZ
This invention relates to file updates in electronic interfaces.
BACKGROUNDTypical computer systems include a common interface for connecting hard disks, CD-ROMs, DVD-ROMs and other storage-oriented devices to a computer (e.g., a desktop PC). Among these interfaces, Integrated Drive Electronics (IDE), also called by its official name, ATA (Advanced Technology Attachment), is a standard electronic interface used between the computer motherboard's data path or bus and the computer's disk storage devices. The IDE has been implemented in most computers used today in an enhanced version of IDE such as Enhanced Integrated Drive Electronics (EIDE) where the disk drive controller is built into the logic board in the disk drive of the computer. Since IDE was first implemented, newer and faster specifications have been developed to reduce cost and increase data transfer speed. To this end, the traditional Parallel ATA interface has been converted to a serial interface. The Serial ATA specification provides for systems having forward and backward compatibility with Parallel ATA as well as scalability and evolutionary enhancement to various types of computing platforms and chipsets in computer systems.
A method and system for updating files includes transmitting a frame having status information and non-status information between a device and a host controller, storing the status information in a buffer, updating the non-status information in a non-status register, after updating the non-status information in the non-status register, determining if the frame has an error. The status register is updated if the frame includes no error.
Referring to
The computer 10 also includes a driver 16 which provides software code or program that interfaces and interacts with a particular device (e.g., a hard disk). The driver 16 has special knowledge of the device or special software interface which application programs 18 lack. The driver 16 is a dynamic link library (DLL) file. In particular, the DLL file of the driver 16 is a small program that can be executed by the application programs 18 when needed. The DLL file supports one or more devices such as Serial Advanced Technology Attachment (ATA) hard disks 22 connected to the computer 10 which implement the interface specification used in the Serial Advanced Technology Attachment (Serial ATA) Specification 1.0. Serial ATA is a high-speed serial link replacement for the parallel ATA attachment of mass storage devices.
In operation, the computer 10 provides connectivity for a Serial ATA host controller 20 to the Serial ATA hard disks 22 through a serial cable 24 which carries high-speed data. The Serial ATA host controller 20 supplies a command interface to the driver 16 and the Serial ATA hard disks 22 for accessing the hardware status and control registers of the Serial ATA host controller 20, as further described below. Essentially, the Serial ATA host controller 20 provides a uniform method of accessing the OS stack 14 and the application programs 18 by enabling data transfer between the Serial ATA hard disks 22 and the driver 16 regardless of the bus architecture or computing platform. The application programs 18 include software, which initializes the Serial ATA host controller 20 and initiates a transfer of data between the Serial ATA hard disk 22 and the Serial ATA host controller 20.
Referring to
As is the case with standard Parallel ATA, the primary communication path in Serial ATA between the Serial ATA host controller 20 and the Serial ATA hard disk 22 is via a task file interface 32. The task file interface 32 provides the interface for transferring task files between the Serial ATA host controller 20 and the Serial ATA hard disk 22. The task file interface includes a set of shadowed non-status registers 30 and a shadowed status register 28. These two similar “shadow” registers such as shadowed non-status registers 30 and shadowed status register 28 (
In certain implementations, status information relates to which unit has control of the task file interface 32 and accordingly the shadowed non-status registers 30. In other words, status information indicates a condition to both the Serial ATA hard disk 22 and the Serial ATA host controller 20 that the task file interface 32 is to be used exclusively by either only the Serial ATA hard disk 22 or the Serial ATA host controller 20. Thus, status information pertains to control of reading and writing processes of the shadowed non-status registers 30. On the other hand, non-status information relates to actual data frame payload such as FIS that are used to update the information included in the shadowed non-status registers 30.
Therefore, the shadow non-status registers 30 and status register 28 allow for the task file interface 32 to simulate a traditional single ATA register, e.g., Parallel ATA. The shadow non-status registers 30 and status register 28 provide functionally identical portions to a traditional single (non-shadowed) ATA task file because legacy host software that is only Parallel ATA or ATA aware can still access the task file interface 32 in the exact same manner and will function correctly. In this case, however, the application programs 18 view the Serial ATA hard disk 22 as if it were a “master” with no master/slave communication configuration such as a “daisy chain.”
The Serial ATA host controller 20 further includes a buffer 26 for storing the Serial ATA task files being transmitted from the Serial ATA host controller 20 and the Serial ATA hard disk 22. In the Serial ATA connectivity shown in
Still referring to
An example process for optimizing and updating the shadowed non-status registers 30 and the shadowed status register 28 after receiving the Serial ATA task file is described in more detail with respect to
Referring to
If either register FIS or PIO SET UP has been received (110), the processor 12 of the computer 10 stores only the status information in the buffer 26. In this updating process 100, the fact that only the status information is stored in the buffer 26 provides an optimal usage of the buffer making available at least 80 bits of memory in the buffer. In short, the buffering of the non-status information of the data frame is eliminated, significantly optimizing the updating process 100.
If no register FIS is received, the host controller waits until the register FIS is received, which results in the Serial ATA host controller 20 following the processes as described in the transport layer of the Serial ATA specification. Thereafter, the shadowed non-status registers 30 are updated directly (112) regardless of whether a CRC of the data frame being transmitted from the Serial ATA hard disk 22 to the Serial ATA host controller 20 has been verified or not. After the shadowed non-status registers 30 have been updated (112), CRC verification is applied (114) and it is determined whether or not an error has been detected (116). If there is an error upon the CRC verification (118), the shadowed status register 28 is not updated. However, if no error has been detected (120), the shadowed status register 28 is finally updated with the status information stored in the buffer 26. Moreover, together with the shadowed status register 28, an alt-status (alternate status) register (not shown) is also updated with the status information stored in the buffer 26. The alt-status includes the same status information as the shadowed status register 28. The alt-status register is used because when the applications 18 read the shadowed status register 28, a side effect of clearing an interrupt pending flag occurs. The interrupt pending flag is a flag set by the Serial ATA hard disk 22 when it generates an interrupt. The read to the alt-status register does not have this side effect. The read returns the same value as a read to the shadowed status register 28.
To verify that the updating process 100 has been correctly implemented, the Serial ATA hard disk sends, for example, a register FIS with an incorrect CRC or a CRC having an error to the Serial ATA host controller 20. Software of the applications 18 reads the shadowed registers to check if the shadowed non-status registers have been updated. If the shadowed non-status registers have been updated, this is an indication that the updating process 100 has occurred.
In the example described above in conjunction with
Furthermore, the Serial ATA hard disk 22 can be any form of storage device that is connected to the Serial ATA host controller 20 provided the Serial ATA hard disk 22 adheres to a particular specification or standard. For example, the Serial ATA hard disk 22 can be a DVD drive or a CD-RW drive which are connected to a PC motherboard of the computer 10 via serial cable 24.
Other embodiments are within the scope of the following claims.
Claims
1. A method comprising:
- transmitting a frame having status information and non-status information between a device and a host controller;
- storing the status information of the frame in a buffer;
- updating the non-status information in a non-status register;
- after updating the non-status information in the non-status register, determining if the frame has an error; and
- updating a status register of the host controller if the frame includes no error.
2. The method of claim 1 wherein determining if the frame has an error includes transmitting a cyclic redundancy code (CRC) applied to the frame being transmitted.
3. The method of claim 1 further comprising transmitting a next set of data transfer commands after updating the status register of the host controller.
4. The method of claim 3 wherein the transmitting of the frame and the transmitting of the next set of data transfer commands is performed in a serial fashion.
5. The method of claim 3 wherein the data transfer commands are selected from a group of interface specifications consisting of Advanced Technology Attachment (ATA) specification, Serial ATA specification, and Advanced Technology Attachment Packet Interface (ATAPI) specification.
6. The method of claim 1 further comprising establishing shadow task file registers within the host controller.
7. The method of claim 6 wherein the shadow task file registers include the status registers and non-status registers.
8. The method of claim 6 wherein the shadow task file registers emulate legacy parallel task file configurations.
9. The method of claim 1 wherein the transmitting of the frame from the device to the host controller includes transmitting a register frame information structure (FIS).
10. The method of claim 1 wherein the transmitting of the frame from the device to the host includes transmitting a programmed input/output setup frame information structure (PIO SETUP FIS).
11. The method of claim 1 wherein the updating of the non-status information in the plurality of non-status registers occurs irrespective of whether or not a cyclic redundancy code (CRC) of the frame has been verified.
12. A system comprising:
- a host controller;
- a device connected to the host controller via a data transmission channel, the data transmission channel configured to transmit a frame having status information and non-status information between the device and the host controller;
- a status register in the host controller, the status register being configured to be updated if the frame has no errors;
- a buffer for storing the status information of the frame; and
- a non-status register in the host controller, the non-status register configured to be updated with the non-status information of the frame before the status register is updated with the status information stored in the buffer.
13. The system of claim 12 wherein the frame includes a cyclic redundancy code (CRC) configured to check for errors in the frame.
14. The system of claim 12 further comprising connections configured to transmit a next set of data transfer commands after the status registers have been updated.
15. The system of claim 14 wherein the connection is serial.
16. The system of claim 14 wherein the next set of data transfer commands are selected from a group of interface specifications consisting of Advanced Technology Attachment (ATA) specification, Serial ATA specification, and Advanced Technology Attachment Packet Interface (ATAPI) specification.
17. The system of claim 12 wherein the frame is a register frame information structure (FIS).
18. The system of claim 12 wherein the frame is a programmed input/output setup frame information structure (PIO SETUP FIS).
19. The system of claim 12 wherein the non-status register in the host controller is updated irrespective of whether or not a cyclic redundancy code (CRC) of the frame has been verified.
20. A computer program product residing on a computer readable media comprises instructions for causing a processor to:
- transmit a frame having status information and non-status information between the device and the host controller;
- store the status information of the frame in a buffer;
- update the non-status information in a non-status register;
- after the update of the non-status information in the non-status register, determine if the frame has an error; and
- update a status register of the host controller if the frame includes no error.
21. The computer program product of claim 20 further comprising instructions for causing the processor to transmit a cyclic redundancy code (CRC) applied to the frame being transmitted.
22. The computer program product of claim 20 further comprising instructions for causing the processor to transmit a next set of data transfer commands after the processor has updated the status register of the host controller.
23. The computer program product of claim 20 wherein the instructions causing the processor to transmit the frame and transmit the next set of data transfer commands is performed in a serial fashion.
24. The computer program product of claim 22 wherein the data transfer commands are selected from a group of interface specifications consisting of Advanced Technology Attachment (ATA) specification, Serial ATA specification, and Advanced Technology Attachment Packet Interface (ATAPI) specification.
25. The computer program product of claim 20 further comprising instructions for causing the processor to establish a plurality of shadow task file registers within the host controller, the plurality of shadow task file registers including the status registers and non-status registers.
26. The computer program product of claim 25 wherein the plurality of shadow task file registers emulate legacy parallel task file configurations.
27. The computer program product of claim 20 wherein the frame is a register frame information structure (FIS).
28. The computer program product of claim 20 wherein the frame is a programmed input/output setup frame information structure (PIO SETUP FIS).
29. The computer program product of claim 20 wherein the instructions causing the processor to update the non-status information in the non-status register occurs irrespective of whether or not a cyclic redundancy code (CRC) of the frame has been verified.
Type: Grant
Filed: Jan 7, 2002
Date of Patent: Nov 1, 2005
Patent Publication Number: 20030131125
Assignee: Intel Corporation (Santa Clara, CA)
Inventor: Thien Ern Ooi (Penang)
Primary Examiner: Jeffrey Gaffin
Assistant Examiner: Harold Kim
Attorney: Fish & Richardson P.C.
Application Number: 10/041,547