|Publication number||US7139848 B1|
|Application number||US 09/733,401|
|Publication date||Nov 21, 2006|
|Filing date||Dec 8, 2000|
|Priority date||Dec 8, 2000|
|Publication number||09733401, 733401, US 7139848 B1, US 7139848B1, US-B1-7139848, US7139848 B1, US7139848B1|
|Inventors||James Murray, Jean-Didier Allegrucci|
|Original Assignee||Xilinx, Inc.|
|Export Citation||BiBTeX, EndNote, RefMan|
|Patent Citations (28), Referenced by (12), Classifications (10), Legal Events (4)|
|External Links: USPTO, USPTO Assignment, Espacenet|
The present invention relates to integrated circuits, and more specifically, to executing direct memory access (DMA) transfers.
DMA controllers are used in computer systems for moving blocks of data from one location to another location. Consequently, the system processor is relieved of the need to generate a long sequence of addresses to accomplish the transfer of data. Typically, the data transferred is a large block of data that begins at a source address and is moved to a destination beginning at a destination address. The DMA controller is started by an event responsive to which the DMA controller generates addresses of a source location and of a destination location wherein data is transferred.
However, before the acknowledge is transmitted and data is transferred to (or from) the I/O device, the system processor, or other bus master, must typically set up the DMA transfer parameters and mode of operations by writing directly to the control registers of the controller. Therefore, the processor is required to update the registers prior to each subsequent transfer. Using the system processor to continuously set up the DMA controller is not efficient. As a result, a more efficient system and method for executing DMA transfers is desired.
According to one embodiment a system is described. The system includes a direct memory access (DMA) controller and an input/output (I/O) device coupled to the DMA controller. The DMA controller is adaptable to terminate a DMA transfer before a terminal count is reached. Further the DMA controller is adaptable to re-transmit data.
A better understanding of the present invention can be obtained from the following detailed description in conjunction with the following drawings, in which:
In the following description, numerous details are set forth. It will be apparent, however, to one skilled in the art, that the present invention may be practiced without these specific details. In other instances, well-known structures and devices are shown in block diagram form, rather than in detail, in order to avoid obscuring the present invention.
CSI 102 is a dedicated system bus for connecting CPU 105 to the other components within system 100. In addition, CSI 102 provides a synchronous interface for system 100 components. Further, CSI 102 includes address and data paths, a clock and control signals. According to one embodiment, CSI 102 is a 32-bit bus that supports multiple access modes. In such an embodiment, devices in system 100 may be configured to transmit 32-bit, 16-bit or 8-bit packets of data via CSI 102.
CPU 105 is coupled to CSI 102 and executes sequences of instructions received from other components within system 100. According to one embodiment, CPU 105 is an ARM7TDMI processor developed by ARM of Cambridge, Mass. Alternatively, other processors may be used.
DMA controller 110 is coupled to CSI 102 and controls direct memory accesses between memory devices within system 100 (e.g., RAM 150 and ROM 140), and input/output (I/O) devices, without using CPU 105. DMA transfers typically include a number of transactions from an I/O device to a memory location, or vice versa. JTAG interface 120 is adaptable to test the boundaries of system 100. According to one embodiment, JTAG interface 120 operates as a master device of CSI 102 and has access to all system resources in order to debug system 100. In a further embodiment, JTAG interface 120 converts serial bit streams into parallel registers whose contents are placed on the address, data and command busses in order to emulate CSI 102 transactions.
Memory interface 130 provides a connection between CSI 102 and one or more external memory devices (not shown). ROM 140 is also coupled to CSI 102. ROM 140 is used to initialize system 100 upon startup. Further, ROM 140 may be configured to instruct CPU 102 to fetch and execute code segments from external memory devices and other interfaces. One of ordinary skill in the art will appreciate that other non-volatile memory devices (e.g., flash memory) may be used instead of a ROM.
RAM 140 stores sequences of instructions that are executed by CPU 105. According to one embodiment, RAM 140, CPU 105 and CSL 160 are connected through CSI 102 such that devices residing in the matrices of CSL 160 may effectively access RAM 140 using DMA controller 110, in addition to access by CPU 105. CSL 160 comprises programmable logic that is coupled to CPU 105, RAM 150 and other system 100 components via CSI 102. According to one embodiment, CSL 160 includes an array of programmable logic tiles that correspond to design units of the physical layout of CSL 160. CSL 160 may be used to implement various device components such as Universal Asynchronous Receiver Transmitters (UARTs), registers, memories, etc. In a further embodiment, CSL 160 may include one or more I/O devices.
According to one embodiment, DMA controller 110 is configured to terminate a DMA transfer before a terminal count has been reached. In addition, DMA controller 110 is configured to re-transmit data upon request by a connected I/O device.
According to one embodiment, four DMA channels 220 (e.g., channels 0–3) are included within DMA controller 110. However, one of ordinary skill in the art will appreciate that other quantities of channels 220 may be included within DMA controller 110. DMA channels 220 are system pathways used by devices within system 100 to transfer data directly to and from RAM 150, ROM 140 or external memory devices coupled to memory interface 130. In one embodiment, each channel 220 is coupled to an I/O device via CSI 102. As described above, the I/O devices may be programmable logic implementations within CSL 160. In yet a further embodiment, REQUEST, ACKNOWLEDGE, STATUS and CONTROL wires are use to control data transfers between channel 220 and I/O devices.
Configuration register matrix 240 stores DMA configuration data received from CPU 105 or any other bus master (e.g., JTAG interface 120). The data stored in register 240 includes information used for executing a DMA transfer. For example, register 240 may store the start and stop memory addresses of data to be transferred to or from an I/O device, as well as the size of the transfer.
CRC 250 uses an error checking technique used to ensure the accuracy of transmitted data. According to one embodiment, transmitted messages are divided into predetermined lengths which, used as dividends, are divided by a fixed divisor. The remainder of the calculation is appended onto and sent with the message. The remainder is recalculated at the receiving end. If it does not match the transmitted remainder, an error is detected.
In addition to a regular request for a transfer of data, I/O device 410 may request for a retransmission of data as well as request an early termination of data. Similarly, the CONTROL and ACKNOWLEDGE components are paired. Tables 1 and 2 below illustrate one embodiment of signal values needed for the different request types and their respective acknowledge signals.
Early Termination Request
Early Termination Acknowledge
According to one embodiment, DMA controller may operate in either a normal mode or a descriptor mode.
At process block 520, a regular request (e.g., REQUEST=1 and STATUS=0) is received at a DMA channel 220 from an I/O device requesting service. At process block 530, DMA controller 110 requests access of CSI 102. At process block 540, DMA controller 110 transmits a regular acknowledge signal (e.g., ACKNOWLEDGE=1 and CONTROL=0) to I/O device 410. At process block 550, data is transmitted over CSI 102 to (or from) I/O device 410 according to the first command. At process block 560, it is determined whether register 240 contains more commands. If there are more commands stored in register 240, control is returned to process block 560. Otherwise, the process is completed.
If DMA controller 110 is operating in the normal mode and receives a retransmit request signal (e.g., REQUEST=0 and STATUS=1) during a transfer, DMA channel 220 re-executes the current transfer. A retransmit request signal allows I/O device 410 to signal DMA controller 110 to retransmit the current active transfer without any action by CPU 105 being needed. In one embodiment, a retransmit request signal may be received if I/O device 410 determines that an error in transmission has occurred.
If DMA controller 110 is operating in the normal mode and receives an early termination request signal (e.g., REQUEST=1 and STATUS=1) during a transfer, DMA channel 220 terminates the current transfer. An early termination request signal may be received in cases where the exact amount of incoming data is not known in advance and I/O device 410 determines that all of the required data has been received.
The descriptor mode features a series of single transfers wherein DMA controller 110 automatically deduces the next transfer that is to be performed. The descriptor mode releases CPU 105 from the task of having to continuously monitor and manage DMA transfers.
At process block 810, CPU 105, or other bus master, constructs a descriptor table 380 in memory (e.g., RAM 150). At process block 820, DMA controller 220 retrieves a command at the beginning of the descriptor table. At process block 830, the retrieved command is programmed into configuration register matrix 240 in conjunction with descriptor logic 380. At process block 840, a regular request signal is received at a DMA channel 220. At process block 850, DMA controller 110 requests access of CSI 102. At process block 860, DMA controller 110 transmits a regular acknowledge signal to I/O device 410.
At process block 870, data is transmitted to (or received from) I/O device 410 over CSI 102. At process block 880, it is determined whether register 240 contains more transfer commands. If there are more commands stored in register 240, control is returned to process block 870 where more data is transmitted. If there are no more commands stored in register 240, it is determined whether descriptor table 380 contains more commands. If there are more commands stored in descriptor table 380, control is returned to process block 820 where the next command is retrieved, process block 890. Otherwise, the process is completed.
While operating in the descriptor mode, DMA controller 110 may receive a retransmit request signal.
At process block 930, DMA controller 110 transmits a retransmit acknowledge signal (e.g., ACKNOWLEDGE=0 and CONTROL=1) to I/O device 410. At process block 940, DMA controller 110 will restart the existing descriptor entry since a copy of the current descriptor command is stored in configuration register matrix 240. At process block 950, the transfer of data is again commenced from the beginning.
While operating in the descriptor mode, DMA controller 110 may receive an early termination signal.
At process block 1030, DMA controller 110 transmits an early termination acknowledge signal to I/O device 410. At process block 1040, DMA channel 220 terminates the transfer associated with the current descriptor entry. At process block 1050, DMA channel 220 updates the reduced transfer count into the descriptor table in memory. In one embodiment, the descriptor table includes a field entry that indicates the amount of data that is to be transferred. This field is updated after the transfer with the amount of data that has actually been transferred.
At process block 1060, DMA controller retrieves the next entry in descriptor table 380. At process block 1070, it is determined whether the next descriptor table entry is valid. If the next descriptor table entry is valid, the transfer of data is terminated, process block 1080. However, if the next descriptor table entry is invalid, it is determined whether I/O device 410 is signaling another request, process block 1090. If I/O device 410 is signaling another request, control is returned to process block 1010 where data is transferred. If I/O device 410 is not signaling another request, control is returned to process block 1090 where it is determined whether I/O device 410 is signaling another request.
Whereas many alterations and modifications of the present invention will no doubt become apparent to a person of ordinary skill in the art after having read the foregoing description, it is to be understood that any particular embodiment shown and described by way of illustration is in no way intended to be considered limiting. Therefore, references to details of various embodiments are not intended to limit the scope of the claims which in themselves recite only those features regarded as the invention.
|Cited Patent||Filing date||Publication date||Applicant||Title|
|US4947366 *||Oct 2, 1987||Aug 7, 1990||Advanced Micro Devices, Inc.||Input/output controller incorporating address mapped input/output windows and read ahead/write behind capabilities|
|US5291494 *||Nov 18, 1992||Mar 1, 1994||Digital Equipment Corporation||Method of handling errors in software|
|US5333274 *||Oct 15, 1991||Jul 26, 1994||International Business Machines Corp.||Error detection and recovery in a DMA controller|
|US5369314||Feb 22, 1994||Nov 29, 1994||Altera Corporation||Programmable logic device with redundant circuitry|
|US5381538 *||Oct 15, 1991||Jan 10, 1995||International Business Machines Corp.||DMA controller including a FIFO register and a residual register for data buffering and having different operating modes|
|US5402014||Jul 14, 1993||Mar 28, 1995||Waferscale Integration, Inc.||Peripheral port with volatile and non-volatile configuration|
|US5448493||Dec 20, 1989||Sep 5, 1995||Xilinx, Inc.||Structure and method for manually controlling automatic configuration in an integrated circuit logic block array|
|US5481756 *||Oct 15, 1992||Jan 2, 1996||Nec Corporation||DMA controller mailing auto-initialize halting unit|
|US5504875||Mar 17, 1993||Apr 2, 1996||Intel Corporation||Nonvolatile memory with a programmable output of selectable width and a method for controlling the nonvolatile memory to switch between different output widths|
|US5651138||Dec 21, 1994||Jul 22, 1997||Motorola, Inc.||Data processor with controlled burst memory accesses and method therefor|
|US5655151 *||Jan 28, 1994||Aug 5, 1997||Apple Computer, Inc.||DMA controller having a plurality of DMA channels each having multiple register sets storing different information controlling respective data transfer|
|US5713044 *||Dec 19, 1995||Jan 27, 1998||Intel Corporation||System for creating new group of chain descriptors by updating link value of last descriptor of group and rereading link value of the updating descriptor|
|US5752078 *||Jul 10, 1995||May 12, 1998||International Business Machines Corporation||System for minimizing latency data reception and handling data packet error if detected while transferring data packet from adapter memory to host memory|
|US5774684||Oct 8, 1996||Jun 30, 1998||National Semiconductor Corporation||Integrated circuit with multiple functions sharing multiple internal signal buses according to distributed bus access and control arbitration|
|US5809335 *||Oct 12, 1995||Sep 15, 1998||Yamaha Corporation||Data transfer apparatus capable of handling DMA block transfer interruptions|
|US5844854||Dec 2, 1996||Dec 1, 1998||Altera Corporation||Programmable logic device with two dimensional memory addressing|
|US5883525||Oct 3, 1997||Mar 16, 1999||Xilinx, Inc.||FPGA architecture with repeatable titles including routing matrices and logic matrices|
|US5884100 *||Jun 6, 1996||Mar 16, 1999||Sun Microsystems, Inc.||Low-latency, high-throughput, integrated cache coherent I/O system for a single-chip processor|
|US5903775 *||Jun 6, 1996||May 11, 1999||International Business Machines Corporation||Method for the sequential transmission of compressed video information at varying data rates|
|US5963050||Mar 24, 1997||Oct 5, 1999||Xilinx, Inc.||Configurable logic element with fast feedback paths|
|US6026230 *||Feb 5, 1998||Feb 15, 2000||Axis Systems, Inc.||Memory simulation system and method|
|US6085317||Aug 15, 1997||Jul 4, 2000||Altera Corporation||Reconfigurable computer architecture using programmable logic devices|
|US6192492 *||Mar 10, 1998||Feb 20, 2001||Seagate Technology Llc||Fast ATA-compatible drive interface with error detection and/or error correction|
|US6199121 *||Aug 7, 1998||Mar 6, 2001||Oak Technology, Inc.||High speed dynamic chaining of DMA operations without suspending a DMA controller or incurring race conditions|
|US6298396 *||Jun 1, 1998||Oct 2, 2001||Advanced Micro Devices, Inc.||System for loading a current buffer desciptor register with a value different from current value to cause a previously read buffer descriptor to be read again|
|US6467009||Oct 14, 1998||Oct 15, 2002||Triscend Corporation||Configurable processor system unit|
|US20030028408 *||Feb 23, 2001||Feb 6, 2003||Rudusky Daryl||System, method and article of manufacture for a contractor-based hardware development service|
|USRE34363||Jun 24, 1991||Aug 31, 1993||Xilinx, Inc.||Configurable electrical circuit having configurable logic elements and configurable interconnects|
|Citing Patent||Filing date||Publication date||Applicant||Title|
|US7680963 *||Mar 5, 2007||Mar 16, 2010||Apple Inc.||DMA controller configured to process control descriptors and transfer descriptors|
|US7917132 *||Feb 15, 2007||Mar 29, 2011||Broadcom Corporation||Direct memory download in a voice data and RF integrated circuit and method for use therewith|
|US8028103||Sep 22, 2009||Sep 27, 2011||Apple Inc.||Method and apparatus for generating secure DAM transfers|
|US8032670||Jan 29, 2010||Oct 4, 2011||Apple Inc.||Method and apparatus for generating DMA transfers to memory|
|US8069279||Mar 5, 2007||Nov 29, 2011||Apple Inc.||Data flow control within and between DMA channels|
|US8209446||Aug 30, 2011||Jun 26, 2012||Apple Inc.||DMA controller that passes destination pointers from transmit logic through a loopback buffer to receive logic to write data to memory|
|US8249575 *||Jan 28, 2011||Aug 21, 2012||Broadcom Corporation||Direct memory download in a voice data and RF integrated circuit and method for use therewith|
|US8266338||Oct 19, 2011||Sep 11, 2012||Apple Inc.||Data flow control within and between DMA channels|
|US8417844||May 17, 2012||Apr 9, 2013||Apple Inc.||DMA controller which performs DMA assist for one peripheral interface controller and DMA operation for another peripheral interface controller|
|US8443118||Jul 31, 2012||May 14, 2013||Apple Inc.||Data flow control within and between DMA channels|
|US8566485||Aug 3, 2012||Oct 22, 2013||Apple Inc.||Data transformation during direct memory access|
|US20050120147 *||Apr 12, 2004||Jun 2, 2005||Renesas Technology Corp.||Direct memory access controller enabling cycle stealing among channels|
|U.S. Classification||710/22, 710/5, 710/24, 710/25, 710/6|
|International Classification||G06F13/00, G06F13/28, G06F3/00|
|Mar 5, 2001||AS||Assignment|
Owner name: TRISCEND CORPORATION, CALIFORNIA
Free format text: ASSIGNMENT OF ASSIGNORS INTEREST;ASSIGNORS:MURRAY, JAMES;ALLEGRUCCI, JEAN-DIDIER;REEL/FRAME:011619/0519
Effective date: 20010223
|May 14, 2004||AS||Assignment|
Owner name: XILINX, INC., CALIFORNIA
Free format text: ASSIGNMENT OF ASSIGNORS INTEREST;ASSIGNOR:TRISCEND CORPORATION;REEL/FRAME:014634/0065
Effective date: 20040305
|May 21, 2010||FPAY||Fee payment|
Year of fee payment: 4
|May 21, 2014||FPAY||Fee payment|
Year of fee payment: 8