JP2000215154A - Dma controller - Google Patents

Dma controller

Info

Publication number
JP2000215154A
JP2000215154A JP1564799A JP1564799A JP2000215154A JP 2000215154 A JP2000215154 A JP 2000215154A JP 1564799 A JP1564799 A JP 1564799A JP 1564799 A JP1564799 A JP 1564799A JP 2000215154 A JP2000215154 A JP 2000215154A
Authority
JP
Japan
Prior art keywords
dma
buffer
transfer
channel
data
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP1564799A
Other languages
Japanese (ja)
Inventor
Takanori Furuzono
貴則 古園
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Panasonic Holdings Corp
Original Assignee
Matsushita Electric Industrial Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Matsushita Electric Industrial Co Ltd filed Critical Matsushita Electric Industrial Co Ltd
Priority to JP1564799A priority Critical patent/JP2000215154A/en
Publication of JP2000215154A publication Critical patent/JP2000215154A/en
Pending legal-status Critical Current

Links

Landscapes

  • Bus Control (AREA)

Abstract

PROBLEM TO BE SOLVED: To provide a DMA controller which can decrease the penalties due to the waiting for transfer of channels caused in a DMA transfer mode without preparing a buffer for every channel. SOLUTION: A DMA transfer request generation part 2 generates a DMA transfer request for every channel by a DMA transfer request signal 30, and a DMA transfer request control part 3 decides a channel that uses a DMA buffer 5 to save the data and performs the DMA transfer of data. Then the buffer 5 is used by a certain channel, a request is given from another channel having higher priority and also the buffer 5 has the sufficient capacity to store the data. Under such conditions, the buffer 5 is used for the channel having higher priority and the DMA transfer of data is carried out by means of the remainder of the buffer 5. Thus, it's possible to prevent a case where the necessary processing time cannot be fully secured due to the waiting for transfer of channels and then to improve the data transfer efficiency.

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【発明の属する技術分野】本発明は、デバイス(メモ
リ、I/O)の間のDMA (ダイレクト・メモリ・アクセス)
転送制御を行なうDMA コントローラに関するものであ
る。DMA 転送データを一時的に退避させるDMA バッファ
をチャネル毎に複数備えることなく、DMA バッファを利
用しているチャネルから、異なるチャネルへの遷移を行
なうことによって、チャネル遷移待ちによるペナルティ
を軽減し、転送効率を高めることを図ったDMA コントロ
ーラである。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to DMA (Direct Memory Access) between devices (memory, I / O).
It relates to a DMA controller that performs transfer control. The transition from a channel using a DMA buffer to a different channel is performed without providing multiple DMA buffers for each channel to temporarily save DMA transfer data, thereby reducing the penalty caused by waiting for channel transition and transferring data. A DMA controller designed to increase efficiency.

【0002】[0002]

【従来の技術】従来の技術を図8に示す情報システムを
用いて説明する。
2. Description of the Related Art A conventional technique will be described with reference to an information system shown in FIG.

【0003】このシステムは、DMA コントローラ100
1、CPU 1002、バスコントローラ1003、メモリ
1004、I/Oデバイス1005、システムバス100
6で構成される。
This system uses a DMA controller 100
1, CPU 1002, bus controller 1003, memory 1004, I / O device 1005, system bus 100
6.

【0004】DMA コントローラ1001は、CPU100
2からの要求、具体的にはCPU 1002からバスコント
ローラ1003の制御を介してDMA コントローラ100
1の制御レジスタ1010にセットされたチャネル、ソ
ースアドレス、デスティネーションアドレス、転送バイ
トサイズの情報に基づいて、バスコントローラ1003
に対してDMA 転送要求を行なう。
[0004] The DMA controller 1001
2, specifically, from the CPU 1002 to the DMA controller 100 via the control of the bus controller 1003.
1 based on the information on the channel, source address, destination address and transfer byte size set in the control register 1010.
Request a DMA transfer.

【0005】DMA コントローラ1001は、バスコント
ローラ1003に対してDMA 転送要求信号1020をア
サートして転送要求を行ない、ソースへのアクセスでは
DMA転送要求信号1020をアサートするサイクルでソ
ースアクセス要求信号1021をアサートし、デスティ
ネーションへのアクセスではソースアクセス要求信号を
ネゲートする。その他、要求時にはアドレス1022、
転送データサイズ1023を出力する。
The DMA controller 1001 issues a transfer request by asserting a DMA transfer request signal 1020 to the bus controller 1003.
The source access request signal 1021 is asserted in the cycle in which the DMA transfer request signal 1020 is asserted, and the source access request signal is negated in accessing the destination. In addition, when requested, the address 1022,
The transfer data size 1023 is output.

【0006】DMA 転送動作のデータの流れとしてはソー
スへのアクセス時には、例えばメモリ1004からシス
テムバス1006を経由してDMA コントローラ1001
のDMA バッファ1011に退避され、デスティネーショ
ンへのアクセス時にはDMA バッファ1011からシステ
ムバス1006を経由して、例えばI/Oデバイス100
5に書き込まれる。これらの転送制御についてはDMA コ
ントローラ1001の要求に基づいてバスコントローラ
1003が行なう。
The data flow of the DMA transfer operation is, for example, when the source is accessed, from the memory 1004 via the system bus 1006 to the DMA controller 1001.
Of the I / O device 100 via the system bus 1006 from the DMA buffer 1011 when accessing the destination.
5 is written. These transfer controls are performed by the bus controller 1003 based on a request from the DMA controller 1001.

【0007】DMA コントローラ1001で、DMA のチャ
ネルをそれまでDMA バッファ1011を利用してDMA 転
送していたチャネルから、他のチャネルに遷移する場合
には、異なるチャネルのデータを転送してしまうことを
避けるため、DMA バッファ1011にデータがなくなっ
てから行なわれる。
When the DMA controller 1001 transitions from a channel that has been DMA-transferred using the DMA buffer 1011 to another channel, the data of a different channel is transferred. In order to avoid this, the operation is performed after the DMA buffer 1011 has no more data.

【0008】[0008]

【発明が解決しようとする課題】しかしながら、上記従
来技術においては以下に述べるような問題がある。メモ
リ1004が例えばSDRAM など複数ワードのデータを連
続して読み出し、もしくは書き込みできるバースト転送
機能を持ったメモリであるとすると、メモリ1004に
対するアクセスはバースト転送可能なメモリアドレスの
境界まで一度に行なってしまうのが効率的である。この
境界が例えば16バイト毎に存在する場合に、図9に示
すようにソースアドレス(0x0002)とデスティネーション
アドレス(0x0000)で16バイト境界でのアラインが異な
る場合に、転送すべきデータが16バイト境界をまたが
る長い転送を考えると、1回目の転送はソースからのア
ドレス1022が0x0002、転送データサイズ1023が
0x8(8バイト)の転送となる。1回目のデータをDMA バ
ッファ1011に退避した段階では、デスティネーショ
ンのイニシャルアドレス0x0000から次の16バイト境界
0x0004まで転送すべき16バイトのデータはDMA バッファ
1011にはないので、2回目もソースからのアドレス
1022が0x0004、転送データサイズ1023が0x10(
16バイト) の転送となる。3回目にはDMA バッファ1
011にデスティネーションへ転送するのに充分なデー
タがたまったことから、デスティネーションへのアドレ
ス1022が0x0000、転送データサイズ1023が0x10
の転送となる。以下4回目はソースからのアドレス10
22が0x0008、転送データサイズ1023が0x10の転
送、5回目はデスティネーションへのアドレス1022
が0x0004、転送データサイズ1023が0x10の転送、最
後の6回目は転送すべき残りデータは8バイトになるの
で、デスティネーションへのアドレス1022が0x000
8、転送データサイズ1023が0x08の転送になる。1
024はDMA 転送許可信号、1025はリードデータア
クノリッジ、1026はライトデータアクノリッジであ
る。
However, the above-mentioned prior art has the following problems. Assuming that the memory 1004 is a memory having a burst transfer function capable of continuously reading or writing a plurality of words of data, such as an SDRAM, for example, access to the memory 1004 is performed at one time up to the boundary of a memory address at which burst transfer is possible. Is more efficient. For example, when this boundary exists every 16 bytes, if the alignment at the 16-byte boundary between the source address (0x0002) and the destination address (0x0000) is different as shown in FIG. Considering a long transfer that crosses the boundary, the first transfer has an address 1022 from the source of 0x0002 and a transfer data size 1023 of
This is a transfer of 0x8 (8 bytes). At the stage where the first data is saved in the DMA buffer 1011, the next 16 byte boundary from the initial address 0x0000 of the destination
Since there is no 16-byte data to be transferred to 0x0004 in the DMA buffer 1011, the address 1022 from the source is 0x0004 and the transfer data size 1023 is 0x10 (
(16 bytes). Third time, DMA buffer 1
Since there was enough data to transfer to the destination at 011, the address 1022 to the destination was 0x0000, and the transfer data size 1023 was 0x10.
Will be transferred. The fourth time is the address 10 from the source
22 is 0x0008 and the transfer data size 1023 is 0x10, the fifth time is the address 1022 to the destination
Is 0x0004 and the transfer data size 1023 is 0x10. In the last sixth transfer, the remaining data to be transferred is 8 bytes, so the address 1022 to the destination is 0x000.
8. The transfer data size 1023 is 0x08. 1
024 is a DMA transfer permission signal, 1025 is a read data acknowledge, and 1026 is a write data acknowledge.

【0009】図9を例に説明したようにソースアドレス
とデスティネーションアドレスで16バイト境界でのア
ラインが異なる転送では、デスティネーションに転送す
るのに充分なデータを格納すると、このデータは16バ
イトを上回った状態になっているため、デスティネーシ
ョンへの転送後にも、完全に一連の転送が完了するまで
は、DMA バッファ1011にデータが存在し続けること
になる(例えば3回目の転送後には8バイトのデータが
残る)。
As described with reference to FIG. 9 as an example, in a transfer in which the alignment at the 16-byte boundary is different between the source address and the destination address, if sufficient data to be transferred to the destination is stored, this data is 16 bytes. Therefore, even after the transfer to the destination, data continues to exist in the DMA buffer 1011 until a complete series of transfers is completed (for example, 8 bytes after the third transfer). Data remains).

【0010】そのため、あるチャネルでソースとデステ
ィネーションでアラインのずれたアドレス間でのDMA 転
送を、大量のデータについて行っていたり、極端にアク
セス速度の遅いデバイスに対して行なっていたりする
と、他のチャネルはDMA バッファが空になって利用可能
になるまでの待ち時間によって、要求される処理時間内
での転送を完了できなくなるという問題がある。
For this reason, if a DMA transfer is performed for a large amount of data or a device having an extremely low access speed when a DMA transfer is performed between a source and a destination at a misaligned address in a certain channel, the other DMA transfer is performed. The problem is that the channel cannot complete the transfer within the required processing time due to the waiting time until the DMA buffer becomes empty and available.

【0011】本発明は、上記の問題点に鑑み、あるチャ
ネルで利用しているDMA バッファについても、格納可能
な容量が残されている場合には、緊急度の高い他のチャ
ネルを優先してDMA バッファを割り当て、その際には、
DMA バッファの残量に応じたDMA 転送制御を行なうこと
で、各チャネル毎にDMA バッファを備えることによる回
路規模の増加を避けつつ、チャネル遷移待ち時間のペナ
ルティを軽減し、転送効率を向上させることができるDM
A コントローラを提供することを目的とする。
In view of the above problems, the present invention gives priority to another channel having a high degree of urgency even if a DMA buffer used in a certain channel has sufficient storage capacity. Allocate a DMA buffer,
By performing DMA transfer control according to the remaining amount of the DMA buffer, the penalty of channel transition waiting time is reduced and transfer efficiency is improved while avoiding an increase in circuit size due to the provision of a DMA buffer for each channel. DM that can
A The purpose is to provide a controller.

【0012】[0012]

【課題を解決するための手段】請求項1記載のDMA コン
トローラは、デバイス間でDMA 転送されるデータを、複
数バイトのデータサイズのDMA バッファに一時的に退避
させることによってDMA 転送を行なうDMA コントローラ
であって、DMA バッファと、複数のチャネルからのDMA
転送要求信号に基づいて、DMA バッファを利用するチャ
ネルを複数のチャネルから決定するDMA 転送要求制御部
と、DMA バッファへのデータアクセス制御を行なうDMA
バッファ制御部とを備え、DMA バッファを利用している
チャネルより、優先度の高いチャネルからの転送要求が
あった場合には、DMA 転送要求制御部が、DMA バッファ
にデータ格納可能な容量があれば、優先度の高いチャネ
ルに対しDMA バッファを利用してDMA 転送することを許
可することを特徴とするものである。
According to a first aspect of the present invention, there is provided a DMA controller for performing a DMA transfer by temporarily saving data to be DMA transferred between devices to a DMA buffer having a data size of a plurality of bytes. DMA buffer and DMA from multiple channels
A DMA transfer request control unit that determines a channel to use the DMA buffer from a plurality of channels based on a transfer request signal, and a DMA that controls data access to the DMA buffer.
When a transfer request is issued from a channel with a higher priority than the channel using the DMA buffer, the DMA transfer request control unit has a capacity to store data in the DMA buffer. For example, it is characterized in that a high-priority channel is allowed to perform a DMA transfer using a DMA buffer.

【0013】請求項1記載のDMA コントローラによれ
ば、DMA 転送要求制御部が、DMA バッファを利用するチ
ャネルの決定を行ない、あるチャネルがDMA バッファを
利用している場合にも、より優先度の高いチャネルの転
送要求があった場合には、DMAバッファにデータ格納可
能な容量があれば、優先度の高いチャネルに遷移して、
その転送制御を優先的に行なう。
[0013] According to the DMA controller of the first aspect, the DMA transfer request control unit determines a channel to use the DMA buffer. Even when a certain channel uses the DMA buffer, the DMA transfer request control unit has a higher priority. When there is a transfer request for a high channel, if there is enough capacity to store data in the DMA buffer, transition to a higher priority channel is performed.
The transfer control is preferentially performed.

【0014】このように、あるチャネルが利用している
DMA バッファの残量を、より優先度の高いチャネルのDM
A 転送用に用いることによって、チャネル毎にバッファ
を設けることなくしかも回路規模の増加をさけるととも
に、従来のようにあるチャネルが極端に長い時間DMA バ
ッファを利用し続けることによって、別のチャネルがチ
ャネルの遷移待ち時間のペナルティで要求される処理時
間をみたせなくなることを防ぎ、転送効率を向上させる
効果がある。
Thus, a certain channel is using
The remaining amount of the DMA buffer is changed to the higher priority channel DM.
A By using it for transfer, there is no need to provide a buffer for each channel and to avoid an increase in circuit size.Also, as one channel continues to use a DMA buffer for an extremely long time, another channel is Has the effect of preventing the processing time required by the transition waiting time penalty from being exceeded and improving the transfer efficiency.

【0015】請求項2記載のDMA コントローラは、請求
項1において、優先度の高いチャネルの要求する転送デ
ータサイズが、DMA バッファにデータ格納可能な容量を
上回る場合に、優先度の高いチャネルの要求に対応した
要求を、DMA バッファにデータ格納可能な転送データサ
イズのDMA 転送制御を複数回に分けてDMA 転送要求制御
部に対し行なうDMA 転送要求生成部を有するものであ
る。
According to a second aspect of the present invention, there is provided a DMA controller according to the first aspect, wherein a transfer data size requested by a high priority channel exceeds a capacity that can store data in a DMA buffer. And a DMA transfer request generation unit for performing a DMA transfer control of a transfer data size capable of storing data in the DMA buffer in a plurality of times to the DMA transfer request control unit.

【0016】請求項2記載のDMA コントローラによれ
ば、請求項1と同様な効果のほか、DMA 転送要求を行な
うDMA 転送要求生成部が、DMA バッファにデータ格納可
能な容量を、もともと要求すべき転送データサイズが上
回った場合は、DMA バッファに格納可能な転送データサ
イズに分けて、複数回DMA 転送要求を行なう。
According to the DMA controller of the second aspect, in addition to the same effect as the first aspect, the DMA transfer request generation unit for performing the DMA transfer request should originally request the capacity capable of storing data in the DMA buffer. When the transfer data size exceeds, the transfer data size is divided into transfer data sizes that can be stored in the DMA buffer, and DMA transfer requests are made a plurality of times.

【0017】このように、チャネルが利用してるDMA バ
ッファの残量があるチャネル行なおうとする転送データ
サイズより少ない場合に、DMA バッファの残量でDMA 転
送可能な複数回の転送に分割して行なうことで、DMA バ
ッファの残量が少ないために、DMA 転送が行なえず、チ
ャネルの遷移待ち時間のペナルティが発生することを防
ぐ効果がある。
As described above, when the remaining amount of the DMA buffer used by the channel is smaller than the transfer data size to be performed for a certain channel, the channel is divided into a plurality of transfers capable of performing the DMA transfer with the remaining amount of the DMA buffer. By doing so, there is an effect that it is possible to prevent a DMA transfer from being performed because the remaining amount of the DMA buffer is small, and to prevent a penalty of a channel transition waiting time from being generated.

【0018】[0018]

【発明の実施の形態】本発明の一実施の形態について図
1から図7を用いて説明する。
DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS One embodiment of the present invention will be described with reference to FIGS.

【0019】図2は本発明の一実施の形態によるDMA コ
ントローラを用いた情報システムの構成例であり、図8
のDMA コントローラ1001がDMA コントローラ1にな
る他は図8に示した従来のシステムと同等のものであ
る。
FIG. 2 shows an example of the configuration of an information system using a DMA controller according to an embodiment of the present invention.
The DMA controller 1001 is the same as the conventional system shown in FIG.

【0020】図1は本発明のDMA コントローラ1の構成
を示したものである。DMA コントローラ1はDMA 転送要
求生成部2とDMA 転送要求制御部3、DMA バッファ制御
部4、DMA バッファ5、制御レジスタ6および、DMA デ
ータバス10、制御データバス11から構成される。
FIG. 1 shows the configuration of a DMA controller 1 according to the present invention. The DMA controller 1 includes a DMA transfer request generator 2, a DMA transfer request controller 3, a DMA buffer controller 4, a DMA buffer 5, a control register 6, a DMA data bus 10, and a control data bus 11.

【0021】また、DMA コントローラ1は制御のために
DMA バッファライトポインタ15、DMA バッファリード
ポインタ16、DMA バッファフルフラグ17、DMA バッ
ファフラグ18、DMA バッファロックフラグ19を有し
ている。
The DMA controller 1 is used for control.
It has a DMA buffer write pointer 15, a DMA buffer read pointer 16, a DMA buffer full flag 17, a DMA buffer flag 18, and a DMA buffer lock flag 19.

【0022】DMA 転送要求生成部2の主な制御内容は、
CPU 1002からセットされた制御レジスタ6の情報に
対応するDMA 転送要求を生成することである。
The main control contents of the DMA transfer request generation unit 2 are as follows.
This is to generate a DMA transfer request corresponding to the information of the control register 6 set from the CPU 1002.

【0023】DMA 転送要求制御部3の主な制御内容は、
DMA 転送要求生成部2からの要求のチャネル間での調停
を行ないバスコントローラ1003に対してDMA 転送要
求を行なうことである。
The main control contents of the DMA transfer request control unit 3 are as follows.
This is to arbitrate the request from the DMA transfer request generator 2 between channels and make a DMA transfer request to the bus controller 1003.

【0024】DMA バッファ制御部4の主な制御内容は、
バスコントローラ1003からのアクノリッジ信号のタ
イミングに基づいて、DMA バッファ5へのデータの読み
書きの制御を行なうことである。
The main control contents of the DMA buffer control unit 4 are as follows.
This is to control the reading and writing of data from and to the DMA buffer 5 based on the timing of the acknowledge signal from the bus controller 1003.

【0025】DMA バッファ5はソースデバイスから読み
出したDMA 転送データをデスティネーションに転送する
までの間、格納するバッファである。
The DMA buffer 5 is a buffer for storing DMA transfer data read from the source device until the data is transferred to the destination.

【0026】制御レジスタ6はDMA コントローラ1の制
御のための設定値を格納するレジスタであり、DMA コン
トローラ1の起動はCPU1002によってこの制御レジ
スタ6がセットされることで行なわれる。
The control register 6 is a register for storing a set value for controlling the DMA controller 1. The DMA controller 1 is activated by setting the control register 6 by the CPU 1002.

【0027】DMA バッファライトポインタ15は、DMA
バッファ5の次にデータを書き込むべき番地を指すポイ
ンタである。
The DMA buffer write pointer 15
This is a pointer indicating an address to which data is to be written next to the buffer 5.

【0028】DMA バッファリードポインタ16は、DMA
バッファ5の次にデータを読み出すべき番地を指すポイ
ンタである。DMA バッファライトポインタ15とDMA バ
ッファリードポインタ16はDMA バッファ制御部4によ
ってインクリメントされ、そのポインタは上限値を超え
てインクリメントする場合は、0に戻って続きをインク
リメントすることになる。
The DMA buffer read pointer 16
This is a pointer indicating the address from which data is to be read next to the buffer 5. The DMA buffer write pointer 15 and the DMA buffer read pointer 16 are incremented by the DMA buffer control unit 4. When the pointers exceed the upper limit value and return to 0, the pointers return to 0 and continue.

【0029】DMA バッファフルフラグ17は、DMA バッ
ファ5にデータを書き込む容量のないことを示すフラグ
であり、DMA バッファ制御部4によってセット/クリア
される。
The DMA buffer full flag 17 is a flag indicating that there is no capacity for writing data to the DMA buffer 5 and is set / cleared by the DMA buffer control unit 4.

【0030】DMA バッファフラグ18は、DMA バッファ
5を使用しているチャネルを示すフラグであり、DMA 転
送要求生成部2によってセット/クリアされる。
The DMA buffer flag 18 is a flag indicating a channel using the DMA buffer 5, and is set / cleared by the DMA transfer request generator 2.

【0031】DMA バッファロックフラグ19は、DMA バ
ッファ5をロックして排他的に使用しているチャネルを
示すフラグであり、DMA 転送要求制御部3によってセッ
トされ、DMA 転送要求生成部2によってクリアされる。
The DMA buffer lock flag 19 is a flag indicating a channel used exclusively by locking the DMA buffer 5 and is set by the DMA transfer request control unit 3 and cleared by the DMA transfer request generation unit 2. You.

【0032】図3にDMA 転送要求生成部2の各チャネル
毎の制御フローチャートを示す。
FIG. 3 shows a control flowchart for each channel of the DMA transfer request generator 2.

【0033】ステップ101ではDMA チャネルを起動す
るかを判断する。制御レジスタ6は各チャネル毎に独立
して、ソースアドレス、デスティネーションアドレス、
転送データサイズおよびDMA 転送要求フラグのフィール
ドを有しており、DMA 転送要求生成部2は制御レジスタ
6が新たにセットされ、DMA 転送要求フラグのフィール
ドのセットされたチャネルを起動する。DMA 転送要求フ
ラグのフィールドのセットされていないチャネルではス
テップ101で待機し、セットされたチャネルではステ
ップ102に遷移する。
In step 101, it is determined whether to activate the DMA channel. The control register 6 has a source address, a destination address,
The DMA transfer request generator 2 has a transfer data size and a DMA transfer request flag field. The DMA transfer request generator 2 activates the channel in which the control register 6 is newly set and the DMA transfer request flag field is set. For a channel in which the field of the DMA transfer request flag is not set, the process waits in step 101, and for a channel in which the DMA transfer request flag is set, the process proceeds to step 102.

【0034】ステップ102ではDMA 転送でソースから
の転送要求を行なうか、デスティネーションへの転送要
求を行なうかを判断する。DMA 転送要求生成部2は、既
に転送されたデータのサイズをカウントするソースデー
タカウンタ20、デスティネーションデータカウンタ2
1を有し、それぞれはDMA チャネルが起動された直後に
は0の値を示している。ステップ102では、ソースデ
ータカウンタ20とデスティネーションデータカウンタ
21の値の差が、DMA 転送するデバイスへ1度に転送で
きるデータサイズもしくはDMA バッファ5の残量のいず
れか値の小さい方を上回る場合、もしくはソースデータ
カウンタ20が全てのデータを転送済みであることを示
す場合に、デスティネーションに転送するのに充分なデ
ータがDMA バッファ5に格納されていると判断し、デス
ティネーションへの転送要求を、そうでない場合にはソ
ースからの転送要求を行なう。DMA バッファ5の残量は
(DMAバッファリードポインタ16の値) >(DMAバッファ
ライトポインタ15の値)の場合は、(DMAバッファリー
ドポインタ16の値) - (DMAバッファライトポインタ1
5の値)であり、(DMAバッファリードポインタ16の値)
<(DMAバッファライトポインタ15の値) の場合は、
(DMAバッファ5の総容量) + (DMAバッファリードポイン
タ16の値) - (DMAバッファライトポインタ15の値)
で与えられる。
In step 102, it is determined whether a transfer request from the source or a transfer request to the destination is made in the DMA transfer. The DMA transfer request generation unit 2 includes a source data counter 20 for counting the size of already transferred data, a destination data counter 2
Each has a value of 0, each immediately after the DMA channel is activated. In step 102, if the difference between the values of the source data counter 20 and the destination data counter 21 exceeds the smaller of the data size that can be transferred to the device that performs DMA transfer at a time or the remaining amount of the DMA buffer 5, Alternatively, if the source data counter 20 indicates that all data has been transferred, it is determined that sufficient data to be transferred to the destination is stored in the DMA buffer 5, and a transfer request to the destination is issued. Otherwise, a transfer request is made from the source. The remaining amount of DMA buffer 5
If (value of DMA buffer read pointer 16)> (value of DMA buffer write pointer 15), (value of DMA buffer read pointer 16)-(DMA buffer write pointer 1)
(Value of DMA buffer read pointer 16)
<(Value of DMA buffer write pointer 15)
(Total capacity of DMA buffer 5) + (Value of DMA buffer read pointer 16)-(Value of DMA buffer write pointer 15)
Given by

【0035】ステップ103ではDMA 転送要求制御部3
へのDMA 転送要求を行なう。DMA 転送要求制御部3への
DMA 転送要求はDMA 転送要求信号30をアサートして行
ない、ソースへのアクセス要求ではソースアクセス要求
信号31をアサートし、デスティネーションへのアクセ
ス要求ではソースアクセス要求信号31をネゲートす
る。転送データサイズは、DMA 転送するデバイスへ1度
に転送できるデータサイズ、未転送のデータサイズの2
者、もしくはDMA バッファフラグ18が他のいずれかの
チャネルでセットされている場合はDMA バッファ5の残
量も含めた3者のうち最も値の小さいものを転送データ
サイズ信号33として出力する。アドレスはステップ1
02で判断されたソース/デスティネーションへのアク
セスのいずれかの結果に基づいて、ソースの場合は、制
御レジスタ6のソースアドレスのフィールドの値(イニ
シャルアドレス)にソースデータカウンタ20の値を加
えたものを、デスティネーションの場合は、制御レジス
タ6のデスティネーションアドレスのフィールドの値
(イニシャルアドレス)にデスティネーションデータカウ
ンタ21の値を加えたものをアドレス32として出力す
る。
In step 103, the DMA transfer request control unit 3
Make a DMA transfer request to the To the DMA transfer request controller 3
The DMA transfer request is performed by asserting the DMA transfer request signal 30, the source access request signal 31 is asserted for a source access request, and the source access request signal 31 is negated for a destination access request. The transfer data size is the data size that can be transferred to the device that performs DMA transfer at one time, and the data size that has not been transferred.
If the DMA buffer flag 18 is set in any of the other channels, the smallest one of the three including the remaining amount of the DMA buffer 5 is output as the transfer data size signal 33. Address is Step 1
In the case of the source, the value of the source data counter 20 is added to the value (initial address) of the source address field of the control register 6 based on one of the results of the access to the source / destination determined in 02. In the case of the destination, the value of the field of the destination address of the control register 6
(Initial address) plus the value of the destination data counter 21 is output as the address 32.

【0036】ステップ104では、DMA 転送要求がDMA
転送要求制御部3に許可されたかを判断する。DMA 転送
要求制御部3からのDMA 転送許可信号35が要求を行な
っているチャネルに対してアサートされた場合、DMA 転
送の許可がチャネルに与えられたと判断し、DMA バッフ
ァフラグ18の該当するチャネルのフィールドをセット
して、DMA 転送要求生成部2はステップ105へ遷移
し、ネゲートされている場合は、ステップ102へ遷移
する。
In step 104, the DMA transfer request
It is determined whether the transfer request is permitted by the transfer request control unit 3. When the DMA transfer permission signal 35 from the DMA transfer request control unit 3 is asserted for the channel making the request, it is determined that the DMA transfer permission has been given to the channel, and the DMA buffer flag 18 The field is set, and the DMA transfer request generation unit 2 transitions to step 105, and if negated, transitions to step 102.

【0037】ステップ105では、DMA チャネル起動か
らの一連のDMA 転送が終了したかを判断する。デスティ
ネーションデータカウンタ21の値が、制御レジスタ6
の転送データサイズの値に達している場合は、一連のDM
A 転送が終了したと判断し、DMA バッファフラグ18と
DMA バッファロックフラグ19の該当するチャネルのフ
ィールドをクリアしてステップ107へ遷移し、そうで
ない場合にはステップ106へ遷移する。
In step 105, it is determined whether or not a series of DMA transfer from the start of the DMA channel has been completed. The value of the destination data counter 21 is stored in the control register 6
If the transfer data size value of the
A It is determined that the transfer has been completed, and the DMA buffer flag 18 and
The field of the corresponding channel of the DMA buffer lock flag 19 is cleared, and the routine goes to Step 107. If not, the routine goes to Step 106.

【0038】ステップ106では、ソースへのアクセス
要求を行なっていた場合にはソースデータカウンタ20
を、デスティネーションの場合にはデスティネーション
データカウンタ21の値を、転送データサイズ信号33
として出力していた値だけインクリメントする。
In step 106, if an access request to the source has been made, the source data counter 20
In the case of the destination, the value of the destination data counter 21 is
Is incremented by the value that was output as.

【0039】ステップ107では、制御レジスタ6のDM
A 転送要求フラグのフィールドをクリアする。
In step 107, the DM of the control register 6
A Clear the transfer request flag field.

【0040】図4にはDMA 転送要求制御部3の制御のフ
ローチャートを示す。
FIG. 4 shows a flowchart of the control of the DMA transfer request controller 3.

【0041】ステップ201では、DMA 転送要求生成部
2からのDMA 転送要求の有無を調べる。DMA 転送要求信
号30がいずれかのチャネルについてアサートされてい
る場合は、ステップ202へ遷移する。
In step 201, it is checked whether or not there is a DMA transfer request from the DMA transfer request generator 2. If the DMA transfer request signal 30 has been asserted for any of the channels, the process proceeds to step 202.

【0042】ステップ202では、DMA バッファ5がDM
A 転送要求を行なってきたチャネルによってロックされ
ているかを判断する。DMA 転送要求生成部2はDMA バッ
ファがあるチャネルによって専有されていることを示す
ロックフラグ19の示すチャネル以外からのDMA 転送要
求を受け付けない。DMA バッファロックフラグ19のセ
ットされていて、かつDMA バッファ5をロックしている
チャネルからの要求がない場合はステップ202で待機
し、そうでない場合はステップ203に遷移する。
In step 202, the DMA buffer 5
A Determine whether the channel is locked by the channel that made the transfer request. The DMA transfer request generation unit 2 does not accept a DMA transfer request from a channel other than the channel indicated by the lock flag 19 indicating that the DMA buffer is occupied by a certain channel. If the DMA buffer lock flag 19 is set and there is no request from the channel locking the DMA buffer 5, the process waits in step 202, and if not, the process proceeds to step 203.

【0043】ステップ203では、DMA 転送要求を行な
ってきたチャネルのうち、優先順位に基づいてどのチャ
ネルにアクセス権を与えるかを決定するアービトレーシ
ョンを行なう。DMA バッファロックフラグ19の示すチ
ャネルからの要求は必ずアービトレーションに勝つ。
In step 203, arbitration is performed to determine which channel is to be granted an access right based on the priority order among the channels that have made DMA transfer requests. Requests from the channel indicated by the DMA buffer lock flag 19 always win arbitration.

【0044】ステップ204では、アービトレーション
に勝ってアクセス権の与えられるチャネル以外のチャネ
ルが、DMA バッファ5を利用しているかを判断する。DM
A 転送要求生成部2はDMA バッファフラグ18がセット
されていれば、これが示すチャネルがDMA バッファ5を
利用していると判断する。アービトレーションに勝って
アクセス権の与えられるチャネル以外のチャネルが、DM
A バッファ5を利用している場合にはステップ205
に、そうでない場合にはステップ206に遷移する。
In step 204, it is determined whether or not a channel other than the channel to which the arbitration has been won and the access right is given uses the DMA buffer 5. DM
If the DMA buffer flag 18 is set, the transfer request generation unit 2 determines that the channel indicated by the DMA buffer flag 18 uses the DMA buffer 5. Channels other than the channel to which arbitration has been granted access rights are DM
Step A 205 when the buffer 5 is used
Otherwise, the process proceeds to step 206.

【0045】ステップ205では、DMA バッファ5にデ
ータ格納可能な容量があるかを判断する。DMA 転送要求
生成部2はDMA バッファフルフラグ17がセットされて
いれば、DMA バッファに書き込む容量がないと判断しス
テップ202に、 セットされていない場合には、ステ
ップ206に遷移する。
In step 205, it is determined whether or not the DMA buffer 5 has a capacity capable of storing data. If the DMA buffer full flag 17 is set, the DMA transfer request generator 2 determines that there is no capacity to write to the DMA buffer, and proceeds to step 202. If not, the process proceeds to step 206.

【0046】ステップ206では、実際にバスアクセス
の制御を行なっているバスコントローラ1003に対す
るアクセス要求を行なう。DMA 転送要求生成部2はDMA
転送要求信号1020をアサートして要求をおこない、
DMA バッファロックフラグ19の示すDMA バッファ5を
ロックしているチャネル、もしくはステップ203のア
ービトレーションで決定したチャネルのソースアクセス
要求信号31、アドレス32、転送データサイズ信号3
3を、それぞれソースアクセス要求信号1021、アド
レス1022、転送データサイズ信号1023として出
力する。
In step 206, an access request is made to the bus controller 1003 which is actually controlling the bus access. DMA transfer request generation unit 2
Assert the transfer request signal 1020 to make a request,
The source access request signal 31, the address 32, and the transfer data size signal 3 of the channel that locks the DMA buffer 5 indicated by the DMA buffer lock flag 19 or the channel determined by the arbitration in step 203
3 are output as a source access request signal 1021, an address 1022, and a transfer data size signal 1023, respectively.

【0047】ステップ207では、バスコントローラ1
003がDMA 転送要求に対する許可をDMA 転送許可信号
1024をアサートしてきた場合、DMA 転送要求生成部
2に対してDMA 転送が受理されたことをDMA 転送許可信
号35をアサートして通知する。ここで、DMA バッファ
フラグ18のいずれかのチャネルでセットされている場
合は、DMA バッファロックフラグ19のDMA 転送許可す
るチャネルのフィールドをセットする。
In step 207, the bus controller 1
When 003 asserts the DMA transfer request signal 1024 to permit the DMA transfer request, the DMA transfer request generation unit 2 is notified by asserting the DMA transfer permission signal 35 that the DMA transfer has been accepted. If the channel is set in one of the DMA buffer flags 18, the field of the channel for which DMA transfer is permitted in the DMA buffer lock flag 19 is set.

【0048】図5には、DMA バッファ制御部4の制御の
フローチャートを示す。
FIG. 5 shows a flowchart of the control of the DMA buffer controller 4.

【0049】ステップ301では、バスコントローラ1
003からのリードデータアクノリッジ信号1025が
アサートされた場合、DMA バッファへのデータ書き込み
制御のため、ステップ302に遷移し、アサートされて
いない場合には、ステップ304に遷移する。
In step 301, the bus controller 1
If the read data acknowledge signal 1025 from 003 is asserted, the process proceeds to step 302 for controlling data writing to the DMA buffer. If not, the process proceeds to step 304.

【0050】ステップ302では、DMA バッファライト
ポインタ15の指すDMA バッファ5の領域にDMA データ
バス10のデータを、リードデータアクノリッジ信号1
025に基づくタイミングで書き込む。
In step 302, the data of the DMA data bus 10 is transferred to the area of the DMA buffer 5 pointed to by the DMA buffer write pointer 15, and the read data acknowledge signal 1
025.

【0051】ステップ303では、書き込んだデータサ
イズの分、DMA バッファライトポインタ15をインクリ
メントする。この際、DMA バッファライトポインタ15
が上限値に達した場合には、ラップアラウンドして0に
戻り、そこから再びインクリメントする。インクリメン
トしてDMA バッファリードポインタ16の1つ手前の値
になった場合にはDMA バッファフルフラグ17をセット
する。
In step 303, the DMA buffer write pointer 15 is incremented by the size of the written data. At this time, the DMA buffer write pointer 15
Has reached the upper limit, wrap-around returns to 0, and then increments again. When the value is incremented to reach a value immediately before the DMA buffer read pointer 16, the DMA buffer full flag 17 is set.

【0052】ステップ304では、バスコントローラ1
003からのライトデータアクノリッジ信号1026が
アサートされた場合、DMA バッファからののデータ読み
だし制御のため、ステップ305に遷移し、アサートさ
れていない場合には、ステップ301に遷移する。
In step 304, the bus controller 1
When the write data acknowledge signal 1026 from 003 is asserted, the process proceeds to step 305 to control the reading of data from the DMA buffer, and when it is not asserted, the process proceeds to step 301.

【0053】ステップ305では、DMA バッファリード
ポインタ16の指すDMA バッファ5の領域のデータを、
ライトデータアクノリッジ信号1026に基づくタイミ
ングで読み出す。
In step 305, the data in the area of the DMA buffer 5 indicated by the DMA buffer read pointer 16 is
Reading is performed at a timing based on the write data acknowledge signal 1026.

【0054】ステップ306では、読み出したデータサ
イズの分、DMA バッファリードポインタ16をインクリ
メントする。この際、DMA バッファフルフラグ17をク
リアする。DMA バッファリードポインタ16が上限値に
達した場合には、ラップアラウンドして0に戻り、そこ
から再びインクリメントする。
In step 306, the DMA buffer read pointer 16 is incremented by the read data size. At this time, the DMA buffer full flag 17 is cleared. When the DMA buffer read pointer 16 reaches the upper limit value, it wraps around and returns to 0, and then increments again.

【0055】図6にはDMA バッファ5の構造について示
したものである。DMA バッファ5のサイズとしては、転
送効率の向上という点から、バス上のデバイスに一度に
転送可能なデータサイズの2倍であることが望ましく、
本発明の目的から、FIFOのようなものではなく、データ
がバッファの複数の番地から読み出せる必要がある。図
6の例ではDMA バッファ5はライトデータセレクタ5
1、リードデータセレクタ52、データバッファ53で
構成され、ライトデータセレクタ51はDMA バッファラ
イトポインタ15の、リードデータセレクタ52はDMA
バッファリードポインタ16の指す番地をセレクトす
る。
FIG. 6 shows the structure of the DMA buffer 5. The size of the DMA buffer 5 is desirably twice the data size that can be transferred to a device on the bus at one time from the viewpoint of improving the transfer efficiency.
For the purposes of the present invention, it is necessary that the data can be read from multiple addresses in the buffer, rather than being like a FIFO. In the example of FIG. 6, the DMA buffer 5 is a write data selector 5
1, a read data selector 52 and a data buffer 53. The write data selector 51 is for the DMA buffer write pointer 15 and the read data selector 52 is for the DMA buffer.
The address indicated by the buffer read pointer 16 is selected.

【0056】以上のように構成されたDMA コントローラ
1の動作について図7のタイミングチャートを用いて説
明する。
The operation of the DMA controller 1 configured as described above will be described with reference to the timing chart of FIG.

【0057】図7はチャネル1でソースアドレス0x000
2、デスティネーションアドレス0x0010、転送データサ
イズ24バイトのDMA 転送、チャネル2でソースアドレス
0x1000、デスティネーションアドレス0x1010、転送デー
タサイズ16バイトのDMA 転送を行なう場合の例である。
この例ではチャネル2の優先順位がチャネル1より高
く、DMA バッファ5の容量が32バイト、1回のアクセス
で転送可能なデータサイズは4バイト×4の16バイトとす
る。
FIG. 7 shows the source address 0x000 in channel 1.
2, DMA transfer of destination address 0x0010, transfer data size 24 bytes, source address in channel 2
This is an example of performing a DMA transfer of 0x1000, destination address 0x1010, and transfer data size of 16 bytes.
In this example, the priority of the channel 2 is higher than that of the channel 1, the capacity of the DMA buffer 5 is 32 bytes, and the data size that can be transferred by one access is 16 bytes of 4 bytes × 4.

【0058】まずチャネル1のDMA が先に起動され、DM
A 転送要求生成部2はチャネル1のDMA 転送要求信号3
0、ソースアクセス信号31をアサートし、アドレスに
0x0002、転送データサイズ信号に0x08を出力する。この
要求はDMA 転送要求制御部3によってサンプリングタイ
ミングS1で許可され、4バイト×2回のソースからのDMA
転送が行なわれる。
First, the DMA of channel 1 is activated first,
A The transfer request generation unit 2 outputs a DMA transfer request signal 3 for channel 1.
0, the source access signal 31 is asserted and the address is
0x0002, 0x08 is output as the transfer data size signal. This request is granted by the DMA transfer request control unit 3 at the sampling timing S1, and 4 bytes × 2 times the DMA from the source.
The transfer is performed.

【0059】さらに残りのデータをソースから転送する
ため、DMA 転送要求生成部2はチャネル1のDMA 転送要
求信号30、ソースアクセス要求信号31をアサート
し、アドレスに0x0004、転送データサイズ信号に0x10を
出力する。この要求はサンプリングタイミングS2で許可
され、4バイト×4回のソースからのDMA 転送が行なわれ
る。
In order to transfer the remaining data from the source, the DMA transfer request generator 2 asserts the DMA transfer request signal 30 and the source access request signal 31 of the channel 1, and sets the address to 0x0004 and the transfer data size signal to 0x10. Output. This request is permitted at the sampling timing S2, and 4 bytes × 4 DMA transfers from the source are performed.

【0060】次にチャネル2のDMA が起動され、DMA 転
送要求生成部2はチャネル1のデスティネーションへの
転送要求と、チャネル2のソースからの転送要求を行な
う。ここでチャネル2は16バイトの転送をしたいところ
であるが、DMA バッファ5の残量が8 バイトなので8 バ
イトの転送要求を行なう。具体的には、チャネル1のDM
A 転送要求信号30、ソースアクセス信号31をネゲー
トし、アドレスに0x0010、転送データサイズ信号に0x10
を出力し、チャネル2ではDMA 転送要求信号30、ソー
スアクセス信号31をアサートし、アドレスに0x1000、
転送データサイズ信号に0x08を出力する。サンプリング
タイミングS3でDMA 転送要求制御部3は、優先度の高い
チャネル2の転送を許可し、以後サンプリングタイミン
グS6でチャネル2のデスティネーションへのアクセスを
許可するまで、チャネル2の転送を行なう。
Next, the DMA of the channel 2 is activated, and the DMA transfer request generator 2 issues a transfer request to the destination of the channel 1 and a transfer request from the source of the channel 2. Here, the channel 2 is to transfer 16 bytes, but since the remaining capacity of the DMA buffer 5 is 8 bytes, an 8-byte transfer request is made. Specifically, the channel 1 DM
A The transfer request signal 30 and the source access signal 31 are negated, and the address is 0x0010 and the transfer data size signal is 0x10.
And the channel 2 asserts the DMA transfer request signal 30 and the source access signal 31, and sets the address to 0x1000,
Outputs 0x08 to the transfer data size signal. At the sampling timing S3, the DMA transfer request control unit 3 permits the transfer of the channel 2 having the higher priority, and thereafter performs the transfer of the channel 2 until the access to the destination of the channel 2 is permitted at the sampling timing S6.

【0061】チャネル2の転送完了によってサンプリン
グタイミングS7以降、DMA バッファ5に格納されていた
チャネル1のデータのデスティネーションへの転送が行
なわれ、サンプリングタイミングS8で許可した転送で、
チャネル1についても一連の転送が完了する。
Upon completion of the transfer of the channel 2, after the sampling timing S7, the data of the channel 1 stored in the DMA buffer 5 is transferred to the destination.
A series of transfers is completed for channel 1 as well.

【0062】[0062]

【発明の効果】請求項1記載のDMA コントローラによれ
ば、あるチャネルが利用しているDMAバッファの残量
を、より優先度の高いチャネルのDMA 転送用に用いるこ
とによって、チャネル毎にバッファを設けることなくし
かも回路規模の増加をさけるとともに、従来のようにあ
るチャネルが極端に長い時間DMA バッファを利用し続け
ることによって、別のチャネルがチャネルの遷移待ち時
間のペナルティで要求される処理時間をみたせなくなる
ことを防ぎ、転送効率を向上させる効果がある。
According to the DMA controller according to the first aspect of the present invention, the remaining amount of the DMA buffer used by a certain channel is used for the DMA transfer of the channel with a higher priority, so that the buffer is provided for each channel. Without the provision of a circuit and avoiding an increase in circuit size, as one channel continues to use the DMA buffer for an extremely long time as in the past, the processing time required by another channel due to the penalty of the channel transition waiting time is reduced. This has the effect of preventing loss of performance and improving transfer efficiency.

【0063】請求項2記載のDMA コントローラによれ
ば、請求項1と同様な効果のほか、チャネルが利用して
るDMA バッファの残量があるチャネル行なおうとする転
送データサイズより少ない場合に、DMA バッファの残量
でDMA 転送可能な複数回の転送に分割して行なうこと
で、DMA バッファの残量が少ないために、DMA 転送が行
なえず、チャネルの遷移待ち時間のペナルティが発生す
ることを防ぐ効果がある。
According to the DMA controller of the second aspect, in addition to the same effects as those of the first aspect, when the remaining amount of the DMA buffer used by the channel is smaller than the transfer data size to be transmitted to a certain channel, the DMA Dividing into multiple transfers that can be DMA-transferred based on the buffer remaining capacity prevents the DMA transfer from being performed due to the low DMA buffer remaining capacity and preventing the occurrence of a channel transition wait time penalty. effective.

【図面の簡単な説明】[Brief description of the drawings]

【図1】本発明のDMA コントローラ1の構成図である。FIG. 1 is a configuration diagram of a DMA controller 1 of the present invention.

【図2】本発明のDMA コントローラ1を用いた情報シス
テムの構成図である。
FIG. 2 is a configuration diagram of an information system using a DMA controller 1 of the present invention.

【図3】DMA 転送要求生成部2の制御フローチャートで
ある。
FIG. 3 is a control flowchart of a DMA transfer request generation unit 2.

【図4】DMA 転送要求制御部3の制御フローチャートで
ある。
FIG. 4 is a control flowchart of a DMA transfer request control unit 3;

【図5】DMA バッファ制御部4の制御フローチャートで
ある。
FIG. 5 is a control flowchart of a DMA buffer control unit 4;

【図6】DMA バッファ5の構成図である。FIG. 6 is a configuration diagram of a DMA buffer 5;

【図7】DMA コントローラ1のDMA 転送動作を示すタイ
ミングチャートである。
FIG. 7 is a timing chart showing a DMA transfer operation of the DMA controller 1.

【図8】従来のDMA コントローラ情報システムの構成図
である。
FIG. 8 is a configuration diagram of a conventional DMA controller information system.

【図9】DMA バッファを利用し続けるDMA 転送の例を示
したアドレス図である。
FIG. 9 is an address diagram showing an example of a DMA transfer using a DMA buffer continuously.

【符号の説明】[Explanation of symbols]

1 DMA コントローラ 2 DMA 転送要求生成部 3 DMA 転送要求制御部 4 DMA バッファ制御部 5 DMA バッファ 6 制御レジスタ 10 DMA データバス 11 制御バス 15 DMA バッファライトポインタ 16 DMA バッファリードポインタ 17 DMA バッファフルフラグ 18 DMA バッファフラグ 30 DMA 転送要求信号 31 ソースアクセス要求信号 32 アドレス 33 転送データサイズ信号 35 DMA 転送許可信号 1020 DMA 転送要求信号 1021 ソースアクセス要求信号 1022 アドレス 1023 転送データサイズ信号 1024 DMA 転送許可信号 1025 リードデータアクノリッジ 1026 ライトデータアクノリッジ 1 DMA controller 2 DMA transfer request generator 3 DMA transfer request controller 4 DMA buffer controller 5 DMA buffer 6 Control register 10 DMA data bus 11 Control bus 15 DMA buffer write pointer 16 DMA buffer read pointer 17 DMA buffer full flag 18 DMA Buffer flag 30 DMA transfer request signal 31 Source access request signal 32 Address 33 Transfer data size signal 35 DMA transfer enable signal 1020 DMA transfer request signal 1021 Source access request signal 1022 Address 1023 Transfer data size signal 1024 DMA transfer enable signal 1025 Read data acknowledge 1026 Write data acknowledge

Claims (2)

【特許請求の範囲】[Claims] 【請求項1】 デバイス間でDMA 転送されるデータを、
複数バイトのデータサイズのDMA バッファに一時的に退
避させることによってDMA 転送を行なうDMAコントロー
ラであって、前記DMA バッファと、複数のチャネルから
のDMA 転送要求信号に基づいて、前記DMA バッファを利
用するチャネルを前記複数のチャネルから決定するDMA
転送要求制御部と、前記DMA バッファへのデータアクセ
ス制御を行なうDMA バッファ制御部とを備え、前記DMA
バッファを利用している前記チャネルより、優先度の高
いチャネルからの転送要求があった場合には、前記DMA
転送要求制御部が、前記DMA バッファにデータ格納可能
な容量があれば、前記優先度の高いチャネルに対し前記
DMA バッファを利用してDMA 転送することを許可するこ
とを特徴とするDMA コントローラ。
1. A method for transferring data to be DMA-transferred between devices,
A DMA controller for performing a DMA transfer by temporarily saving data to a DMA buffer having a data size of a plurality of bytes, wherein the DMA controller uses the DMA buffer based on the DMA buffer and DMA transfer request signals from a plurality of channels. DMA for determining a channel from the plurality of channels
A transfer request control unit; and a DMA buffer control unit that controls data access to the DMA buffer.
If there is a transfer request from a higher priority channel than the channel using the buffer, the DMA
If the transfer request control unit has a capacity capable of storing data in the DMA buffer, the transfer request control unit
A DMA controller which permits a DMA transfer using a DMA buffer.
【請求項2】 優先度の高いチャネルの要求する転送デ
ータサイズが、DMAバッファにデータ格納可能な容量を
上回る場合に、前記優先度の高いチャネルの要求に対応
した要求を、前記DMA バッファにデータ格納可能な転送
データサイズのDMA 転送制御を複数回に分けて前記DMA
転送要求制御部に対し行なうDMA 転送要求生成部を有す
る請求項1記載のDMA コントローラ。
2. When the transfer data size requested by a high-priority channel exceeds the capacity that can be stored in the DMA buffer, a request corresponding to the request of the high-priority channel is sent to the DMA buffer. DMA of transfer data size that can be stored
2. The DMA controller according to claim 1, further comprising a DMA transfer request generation unit for performing a transfer request control unit.
JP1564799A 1999-01-25 1999-01-25 Dma controller Pending JP2000215154A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP1564799A JP2000215154A (en) 1999-01-25 1999-01-25 Dma controller

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP1564799A JP2000215154A (en) 1999-01-25 1999-01-25 Dma controller

Publications (1)

Publication Number Publication Date
JP2000215154A true JP2000215154A (en) 2000-08-04

Family

ID=11894522

Family Applications (1)

Application Number Title Priority Date Filing Date
JP1564799A Pending JP2000215154A (en) 1999-01-25 1999-01-25 Dma controller

Country Status (1)

Country Link
JP (1) JP2000215154A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2007199815A (en) * 2006-01-24 2007-08-09 Megachips Lsi Solutions Inc Memory control device and memory control method
JP2009211682A (en) * 2008-02-07 2009-09-17 Yokogawa Electric Corp Data transfer device and semiconductor testing device
CN103106164A (en) * 2011-11-09 2013-05-15 深圳市德赛微电子技术有限公司 Highly efficient direct memory access (DMA) controller
CN114116553A (en) * 2021-11-30 2022-03-01 海光信息技术股份有限公司 Data processing device, method and system

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2007199815A (en) * 2006-01-24 2007-08-09 Megachips Lsi Solutions Inc Memory control device and memory control method
JP2009211682A (en) * 2008-02-07 2009-09-17 Yokogawa Electric Corp Data transfer device and semiconductor testing device
CN103106164A (en) * 2011-11-09 2013-05-15 深圳市德赛微电子技术有限公司 Highly efficient direct memory access (DMA) controller
CN114116553A (en) * 2021-11-30 2022-03-01 海光信息技术股份有限公司 Data processing device, method and system

Similar Documents

Publication Publication Date Title
JP3598321B2 (en) Buffering data exchanged between buses operating at different frequencies
US7171526B2 (en) Memory controller useable in a data processing system
US7650453B2 (en) Information processing apparatus having multiple processing units sharing multiple resources
US8683093B2 (en) Memory system having high data transfer efficiency and host controller
US20040107265A1 (en) Shared memory data transfer apparatus
US20070136503A1 (en) Systems for implementing SDRAM controllers, and buses adapted to include advanced high performance bus features
JPH04306748A (en) Information processor
US6633926B1 (en) DMA transfer device capable of high-speed consecutive access to pages in a memory
US20020059393A1 (en) Multicore DSP device having coupled subsystem memory buses for global DMA access
US5353416A (en) CPU lock logic for corrected operation with a posted write array
JPH1196072A (en) Memory access control circuit
US20070043910A1 (en) Memory control apparatus executing prefetch instruction
US7185122B2 (en) Device and method for controlling data transfer
JP2000215154A (en) Dma controller
US20080016296A1 (en) Data processing system
US6938118B1 (en) Controlling access to a primary memory
US5889948A (en) Apparatus and method for inserting an address in a data stream through a FIFO buffer
JPH0696007A (en) Dma transfer system
US7228367B2 (en) Direct memory access controller for carrying out data transfer by determining whether or not burst access can be utilized in an external bus and access control method thereof
JP3599692B2 (en) Data transmission equipment
US20050223129A1 (en) Arbitration of data transfer requests
JPH06250970A (en) Memory controller
JPH01125644A (en) Data transfer equipment
JP2966038B2 (en) Digital data processing unit arbitration apparatus and method
JP3669616B2 (en) Microcomputer and data processing system