1. Field of the Invention
The present invention relates generally to storage device controllers, and more particularly, to processing frames.
2. Background
Conventional computer systems typically include several functional components. These components may include a central processing unit (CPU), main memory, input/output (“I/O”) devices, and streaming storage devices (for example, tape drives).
In conventional systems, the main memory is coupled to the CPU via a system bus or a local memory bus. The main memory is used to provide the CPU access to data and/or program information that is stored in main memory at execution time. Typically, the main memory is composed of random access memory (RAM) circuits. A computer system with the CPU and main memory is often referred to as a host system.
The storage device is coupled to the host system via a controller that handles complex details of interfacing the storage devices to the host system. Communications between the host system and the controller is usually provided using one of a variety of standard I/O bus interfaces.
Typically, when data is read from a storage device, a host system sends a read command to the controller, which stores the read command into the buffer memory. Data is read from the device and stored in the buffer memory. Buffer memory may be a Synchronous Dynamic Random access Memory (“SDRAM”), or Double Data Rate-Synchronous Dynamic Random Access Memory (referred to as “DDR” or “SDRAM”)).
Storage controllers use various standards to move data frames in and out of storage devices. One such standard is the Fibre Channel standard. Fibre channel (incorporated herein by reference in its entirety) is an American National Standard Institute (ANSI) set of standards, which provides a serial transmission protocol for storage and network protocols such as HIPPI, SCSI, IP, ATM and others.
A storage controller may receive various types of frames, for example, data, link or command frames. Task management requests (“TMRs”) per the Fibre Channel protocol, provide an option to take action for a command thread that may be residing in buffer memory of the storage controller. A TMR is a command frame that includes task management flags. If a command buffer is full, then the TMR may also be encoded as a link frame.
Some conventional storage controllers store data, link, command and TMRs in sequential order and execute and process them as they are being received. This approach has disadvantages because it results in latency and delays.
Conventional storage systems may also use a timer to evaluate, execute and flush command frames from a queue. This requires additional logic and makes the process complex and expensive.
Therefore, there is a need for a system and method that can efficiently handle command frames and TMRs.
A storage controller is provided in one aspect of the present invention. The storage controller includes a frame snooper module that detects a task management request (“TMR”) and generates a pause signal to a channel that stops the channel from sending any non-data frames to a buffer memory, wherein the channel continues to receive and process data frames while the channel is stopped from sending the non-data frames to the buffer memory; a counter for counting TMRs; and logic for generating an interrupt if a number of TMRs received exceeds a certain threshold value.
In yet another aspect of the present invention, a method for processing frames is provided. The method includes detecting a TMR generating a command to stop a channel from receiving non-data frames while continuing to receive data frames from a Fibre Channel interface; and generating an interrupt to a processor after a certain number of TMRs are received.
In yet another aspect of the present invention, a system for transferring data between a computing system and a storage device is provided. The system includes a storage controller including a frame snooper module that detects a TMR and generates a pause signal to a channel that stops the channel from sending any non-data frames to a buffer memory, wherein the channel continues to receive and process data frames while the channel is stopped from sending the command frames to the buffer memory; a counter for counting TMRs; and logic for generating an interrupt if a number of TMRs received exceeds a certain threshold value.
This brief summary has been provided so that the nature of the invention may be understood quickly. A more complete understanding of the invention can be obtained by reference to the following detailed description of the preferred embodiments thereof concerning the attached drawings.
The foregoing features and other features of the present invention will now be described with reference to the drawings of a preferred embodiment. In the drawings, the same components have the same reference numerals. The illustrated embodiment is intended to illustrate, but not to limit the invention. The drawings include the following Figures:
To facilitate an understanding of the preferred embodiment, the general architecture and operation of a controller will initially be described. The specific architecture and operation of the preferred embodiment will then be described with reference to the general architecture.
The system of
As shown in
Controller 101 can be an integrated circuit (IC) that comprises of various functional modules, which provide for the writing and reading of data stored on storage device 110. Microprocessor 100 is coupled to controller 101 via interface 109 to facilitate transfer of data, address, timing and control information.
A read only memory (“ROM”) omitted from the drawing is used to store firmware code executed by microprocessor 100.
Fibre Channel interface 103 interfaces with host interface 104A and processes Fibre Channel frames. The frames received by Fibre Channel Interface 103 are sent to Channel 1 (CH1) 105 and then to buffer memory 111 via a buffer controller (also referred to as BC)108. CH1105 is a channel that is used for transferring frames/information from Fibre Channel interface 103 to BC 108.
BC 108 connects buffer memory 111 to CH1105, error correction code (“ECC”) module 106 and to bus 107. BC 108 regulates data movement into and out of buffer memory 111. ECC module 106 generates the ECC that is saved on disk 110 writes and provides correction mask to BC 108 for disk 110 read operation.
Buffer memory 111 is coupled to controller 101 via ports to facilitate transfer of data, timing and address information. Buffer memory 111 may be a DDR or SDRAM or any other type of memory.
While frames are in CH1 pipe 105C, frame snooper module 105E detects the different types of frames. The frames are shown as command frame 105K, link frame 105J, data frame 105H and a TMR frame 105G. TMR frame 105G is detected by decoding the following values in a Fibre Channel Frame:
Field R_CTL (defined by Fibre Channel standards)=6;
TYPE (Fibre Channel Standard defined field)=08; and
The payload byte 10 is equal to a non-zero value.
In one aspect of the present inventions, when frame snooper module 105E detects a command frame 105K, link frame 105J or a TMR frame 105G, then via signal 105F, the receive operation for other frames may be stopped. It is noteworthy that frame snooper module 105E may be configured to continue to receive data frames 105H after a stop “event” (i.e. receipt of command frame 105K, link frame 105J or a TMR frame 105G).
A TMR counter 201 is used to count all TMR frames 105G. In one aspect of the present invention, the TMR counter 201 may be 9-bits wide. It is noteworthy that other size counter(s) may also be used to count TMR frames and the present invention is not limited to any particular counter size.
TMR counter 201 is enabled by firmware using a TMR counter enable bit 212. The TMR count 201A is fed into a compare module 202. If count 201A is greater than a certain number then an interrupt is set (shown as 201B). Logic 203 is used to send an interrupt signal 204 to processor 100 via an interrupt pin/logic (not shown). TMR based interrupts may be masked by using a mask bit value 209 that is input to logic 203.
A register, shown as TMR/Frame snooper register 206 (may also be referred to as register 206) is used to store various bit values that are used to process frames, according to one aspect of the present invention. The following describes the various bit settings:
Allow Data Frames Through bit 207: When this bit is set, data frames are received and sent to buffer memory via CH 1105, even after the Frame Snooper module 105E generates a pause signal/command 105F.
Snoop Reset bit 208: When this bit is set (for example, to 1), it creates a pulse that resets all snoop related hardware.
TMR Interrupt Mask bit 209: As discussed above, when this bit is set, the TMR interrupt is masked.
“Stop on Link Frame” bit 210: Setting this bit instructs the Frame Snooper module 105E to stop CH1105 receive operations after a link frame has been sent to buffer memory 111.
“Stop on Command Frame” bit 211: Setting this bit instructs the Frame Snooper module 105E to stop CH1105 receive operations after a command frame has been sent to buffer memory 111.
“Stop on TMR” 212A: Setting this bit instructs the Frame Snooper module to stop CH1105 receive operations after a Command frame containing task management flag bits has been sent to buffer memory 111.
Task Management Counter Enable bit 212: When this bit is set, counter 201 will increment every time a TMR frame (105G) is received.
Task Management Request Interrupt 213: When this bit is set it denotes that a Task Management Request has been received.
Next Frame Link bit 214: If set, this bit indicates that the next Frame from CH1 FIFO 105B will be sent to a Link Buffer (shown in
Next Frame Command bit 215: If set, this bit indicates that the next frame from CH1 FIFO 105B will be sent to the Command Buffer.
Next Frame Data bit 216: If set, this bit indicates that the next frame from CH1 FIFO 105B will be sent to the Data Buffer.
Found Link Frame bit 217: If this bit is set, it indicates that the frame snooper module 105E stopped CH1105 receive operations after a link frame was sent to buffer memory 111.
Found Command Frame bit 218: If this bit is set, it indicates that the frame snooper module 105E stopped CH1105 receive operations after a command frame was sent to the buffer.
Found Task Management Request Frame bit 219: If this bit is set, it indicates that the frame snooper module 105E stopped CH1105 receive operations after a task management request frame was sent to buffer memory 111.
Turning in detail to
In step S302, a pause signal 105F is generated to stop CH1 pipe 105C to transmit frames to buffer memory 111 via BC 108. For example, if a “Stop on TMR frame” bit 212A is set then CH1 pipe 105C does not send any more frames to BC 108 after receiving a TMR.
In step S304, an interrupt is generated if a TMR frame 105G is received. It is noteworthy that firmware for controller 101 may generate an interrupt after a TMR counter 201 reaches a certain value.
In step S306, data frames are still received while CH1 pipe 105C stops sending command or link frames to BC 108, after the pause signal is generated in step S302.
Because receive operations stop when a TMR frame 105G is received, it allows processor 100 to complete the execution of previously received command frames. This is more efficient because a TMR 105G may request processor 100 to discard previously received command frame, or select certain command frames to execute in a certain order or priority. This improves performance and reduces latency. Also, no timers are needed to manage command frames.
Although the present invention has been described with reference to specific embodiments, these embodiments are illustrative only and not limiting. Many other applications and embodiments of the present invention will be apparent in light of this disclosure.
Number | Name | Date | Kind |
---|---|---|---|
3800281 | Devore et al. | Mar 1974 | A |
3988716 | Fletcher et al. | Oct 1976 | A |
4001883 | Strout et al. | Jan 1977 | A |
4016368 | Apple, Jr. | Apr 1977 | A |
4050097 | Miu et al. | Sep 1977 | A |
4080649 | Calle et al. | Mar 1978 | A |
4156867 | Bench et al. | May 1979 | A |
4225960 | Masters | Sep 1980 | A |
4275457 | Leighou et al. | Jun 1981 | A |
4390969 | Hayes | Jun 1983 | A |
4451898 | Palermo et al. | May 1984 | A |
4486750 | Aoki | Dec 1984 | A |
4500926 | Yoshimaru et al. | Feb 1985 | A |
4587609 | Boudreau et al. | May 1986 | A |
4603382 | Cole | Jul 1986 | A |
4625321 | Pechar et al. | Nov 1986 | A |
4667286 | Young et al. | May 1987 | A |
4777635 | Glover | Oct 1988 | A |
4805046 | Kuroki et al. | Feb 1989 | A |
4807116 | Katzman et al. | Feb 1989 | A |
4807253 | Hagenauer et al. | Feb 1989 | A |
4809091 | Miyazawa et al. | Feb 1989 | A |
4811282 | Masina | Mar 1989 | A |
4812769 | Agoston | Mar 1989 | A |
4860333 | Bitzinger et al. | Aug 1989 | A |
4866606 | Kopetz | Sep 1989 | A |
4881232 | Sako et al. | Nov 1989 | A |
4920535 | Watanabe et al. | Apr 1990 | A |
4949342 | Shimbo et al. | Aug 1990 | A |
4970418 | Masterson | Nov 1990 | A |
4972417 | Sako et al. | Nov 1990 | A |
4975915 | Sako et al. | Dec 1990 | A |
4989190 | Kuroe et al. | Jan 1991 | A |
5014186 | Chisholm | May 1991 | A |
5023612 | Liu | Jun 1991 | A |
5027357 | Yu et al. | Jun 1991 | A |
5050013 | Holsinger | Sep 1991 | A |
5051998 | Murai et al. | Sep 1991 | A |
5068755 | Hamilton et al. | Nov 1991 | A |
5068857 | Yoshida | Nov 1991 | A |
5072420 | Conley et al. | Dec 1991 | A |
5088093 | Storch et al. | Feb 1992 | A |
5109500 | Iseki et al. | Apr 1992 | A |
5117442 | Hall | May 1992 | A |
5127098 | Rosenthal et al. | Jun 1992 | A |
5133062 | Joshi et al. | Jul 1992 | A |
5136592 | Weng | Aug 1992 | A |
5146585 | Smith, III | Sep 1992 | A |
5157669 | Yu et al. | Oct 1992 | A |
5162954 | Miller et al. | Nov 1992 | A |
5193197 | Thacker | Mar 1993 | A |
5204859 | Paesler et al. | Apr 1993 | A |
5218564 | Haines et al. | Jun 1993 | A |
5220569 | Hartness | Jun 1993 | A |
5237593 | Fisher et al. | Aug 1993 | A |
5243471 | Shinn | Sep 1993 | A |
5249271 | Hopkinson et al. | Sep 1993 | A |
5257143 | Zangenehpour | Oct 1993 | A |
5261081 | White et al. | Nov 1993 | A |
5271018 | Chan | Dec 1993 | A |
5274509 | Buch | Dec 1993 | A |
5276564 | Hessing et al. | Jan 1994 | A |
5276662 | Shaver, Jr. et al. | Jan 1994 | A |
5276807 | Kodama et al. | Jan 1994 | A |
5280488 | Glover et al. | Jan 1994 | A |
5285327 | Hetzler | Feb 1994 | A |
5285451 | Henson et al. | Feb 1994 | A |
5301333 | Lee | Apr 1994 | A |
5307216 | Cook et al. | Apr 1994 | A |
5315708 | Eidler et al. | May 1994 | A |
5339443 | Lockwood | Aug 1994 | A |
5361266 | Kodama et al. | Nov 1994 | A |
5361267 | Godiwala et al. | Nov 1994 | A |
5408644 | Schneider et al. | Apr 1995 | A |
5420984 | Good et al. | May 1995 | A |
5428627 | Gupta | Jun 1995 | A |
5440751 | Santeler et al. | Aug 1995 | A |
5465343 | Henson et al. | Nov 1995 | A |
5487170 | Bass et al. | Jan 1996 | A |
5488688 | Gonzales et al. | Jan 1996 | A |
5491701 | Zook | Feb 1996 | A |
5500848 | Best et al. | Mar 1996 | A |
5506989 | Boldt et al. | Apr 1996 | A |
5507005 | Kojima et al. | Apr 1996 | A |
5519837 | Tran | May 1996 | A |
5523903 | Hetzler et al. | Jun 1996 | A |
5544180 | Gupta | Aug 1996 | A |
5544346 | Amini | Aug 1996 | A |
5546545 | Rich | Aug 1996 | A |
5546548 | Chen et al. | Aug 1996 | A |
5559963 | Gregg et al. | Sep 1996 | A |
5559988 | Durante et al. | Sep 1996 | A |
5563896 | Nakaguchi | Oct 1996 | A |
5572148 | Lytle et al. | Nov 1996 | A |
5574867 | Khaira | Nov 1996 | A |
5581715 | Verinsky et al. | Dec 1996 | A |
5583999 | Sato et al. | Dec 1996 | A |
5592404 | Zook | Jan 1997 | A |
5600662 | Zook et al. | Feb 1997 | A |
5602857 | Blauer et al. | Feb 1997 | A |
5613163 | Marron et al. | Mar 1997 | A |
5615190 | Best et al. | Mar 1997 | A |
5623672 | Popat | Apr 1997 | A |
5626949 | Zook | May 1997 | A |
5627695 | Prins et al. | May 1997 | A |
5640602 | Takase | Jun 1997 | A |
5649230 | Lentz | Jul 1997 | A |
5664121 | Cerauskis | Sep 1997 | A |
5689656 | Baden et al. | Nov 1997 | A |
5691994 | Acosta et al. | Nov 1997 | A |
5692135 | Alvarez, II et al. | Nov 1997 | A |
5692165 | Jeddeloh et al. | Nov 1997 | A |
5719516 | Sharpe-Geisler | Feb 1998 | A |
5729718 | Au | Mar 1998 | A |
5740466 | Geldman | Apr 1998 | A |
5745488 | Thompson et al. | Apr 1998 | A |
5745793 | Atsatt et al. | Apr 1998 | A |
5754759 | Clarke et al. | May 1998 | A |
5758188 | Appelbaum et al. | May 1998 | A |
5784569 | Miller et al. | Jul 1998 | A |
5794073 | Ramakrishnan et al. | Aug 1998 | A |
5801998 | Choi | Sep 1998 | A |
5818886 | Castle | Oct 1998 | A |
5822142 | Hicken | Oct 1998 | A |
5831922 | Choi | Nov 1998 | A |
5835930 | Dobbek | Nov 1998 | A |
5841722 | Willenz | Nov 1998 | A |
5844844 | Bauer et al. | Dec 1998 | A |
5850422 | Chen | Dec 1998 | A |
5854918 | Baxter | Dec 1998 | A |
5890207 | Sne et al. | Mar 1999 | A |
5890210 | Ishii et al. | Mar 1999 | A |
5907717 | Ellis | May 1999 | A |
5912906 | Wu et al. | Jun 1999 | A |
5925135 | Trieu et al. | Jul 1999 | A |
5937435 | Dobbek et al. | Aug 1999 | A |
5950223 | Chiang et al. | Sep 1999 | A |
5968180 | Baco | Oct 1999 | A |
5983275 | Ecclesine | Nov 1999 | A |
5983293 | Murakami | Nov 1999 | A |
5991911 | Zook | Nov 1999 | A |
6029226 | Ellis et al. | Feb 2000 | A |
6029250 | Keeth | Feb 2000 | A |
6041417 | Hammond et al. | Mar 2000 | A |
6065053 | Nouri et al. | May 2000 | A |
6067206 | Hull et al. | May 2000 | A |
6070200 | Gates et al. | May 2000 | A |
6078447 | Sim | Jun 2000 | A |
6081849 | Born et al. | Jun 2000 | A |
6092231 | Sze | Jul 2000 | A |
6094320 | Ahn | Jul 2000 | A |
6124994 | Malone, Sr. | Sep 2000 | A |
6134063 | Weston-Lewis et al. | Oct 2000 | A |
6157984 | Fisher | Dec 2000 | A |
6178486 | Gill et al. | Jan 2001 | B1 |
6192499 | Yang | Feb 2001 | B1 |
6201655 | Watanabe et al. | Mar 2001 | B1 |
6223303 | Billings et al. | Apr 2001 | B1 |
6279089 | Schibilla et al. | Aug 2001 | B1 |
6297926 | Ahn | Oct 2001 | B1 |
6330626 | Dennin et al. | Dec 2001 | B1 |
6381647 | Darnell et al. | Apr 2002 | B1 |
6381659 | Proch et al. | Apr 2002 | B2 |
6401149 | Dennin et al. | Jun 2002 | B1 |
6470461 | Pinvidic et al. | Oct 2002 | B1 |
6487631 | Dickinson et al. | Nov 2002 | B2 |
6490635 | Holmes | Dec 2002 | B1 |
6530000 | Krantz et al. | Mar 2003 | B1 |
6574676 | Megiddo | Jun 2003 | B1 |
6609180 | Sanada et al. | Aug 2003 | B2 |
6615305 | Olesen et al. | Sep 2003 | B1 |
6662334 | Stenfort | Dec 2003 | B1 |
6826650 | Krantz et al. | Nov 2004 | B1 |
7099962 | Nakayama et al. | Aug 2006 | B2 |
20010044873 | Wilson et al. | Nov 2001 | A1 |
20030037225 | Deng et al. | Feb 2003 | A1 |
20030172220 | Hao | Sep 2003 | A1 |
Number | Date | Country |
---|---|---|
0528273 | Feb 1993 | EP |
0622726 | Nov 1994 | EP |
0718827 | Jun 1996 | EP |
2285166 | Jun 1995 | GB |
63-292462 | Nov 1988 | JP |
01-315071 | Dec 1989 | JP |
03183067 | Aug 1991 | JP |
9814861 | Apr 1998 | WO |
Number | Date | Country | |
---|---|---|---|
20060104269 A1 | May 2006 | US |