JP3206013B2 - Direct memory access transfer controller - Google Patents

Direct memory access transfer controller

Info

Publication number
JP3206013B2
JP3206013B2 JP09600291A JP9600291A JP3206013B2 JP 3206013 B2 JP3206013 B2 JP 3206013B2 JP 09600291 A JP09600291 A JP 09600291A JP 9600291 A JP9600291 A JP 9600291A JP 3206013 B2 JP3206013 B2 JP 3206013B2
Authority
JP
Japan
Prior art keywords
transfer
address
dma
memory
request
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.)
Expired - Fee Related
Application number
JP09600291A
Other languages
Japanese (ja)
Other versions
JPH04326150A (en
Inventor
一郎 香園
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.)
NEC Corp
Original Assignee
NEC Corp
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 NEC Corp filed Critical NEC Corp
Priority to JP09600291A priority Critical patent/JP3206013B2/en
Publication of JPH04326150A publication Critical patent/JPH04326150A/en
Application granted granted Critical
Publication of JP3206013B2 publication Critical patent/JP3206013B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Description

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

【0001】[0001]

【産業上の利用分野】本発明は、ダイレクト・メモリ・
アクセス(以下DMAという)方式により、領域の異な
るメモリ間、およびメモリと周辺装置との間でデータの
高速転送を行うDMA転送制御装置に関する。
BACKGROUND OF THE INVENTION The present invention relates to a direct memory
The present invention relates to a DMA transfer control device that performs high-speed data transfer between memories in different areas and between a memory and a peripheral device by an access (hereinafter, referred to as DMA) method.

【0002】[0002]

【従来の技術】DMA方式は、広く採用されている高速
度のデータ転送方式の一つであり、DMA転送を行うた
めの制御装置は、情報処理装置に不可欠なものとなって
いる。このDMA転送方式には、メモリ内の指定された
領域のデータを読み出して別の領域へ転送する場合(以
下メモリ間のDMA転送という)と、周辺装置とメモリ
との間でデータ転送する場合とがあり、ここではメモリ
間のDMA転送を説明する。
2. Description of the Related Art The DMA system is one of widely used high-speed data transfer systems, and a control device for performing the DMA transfer is indispensable for an information processing device. This DMA transfer method includes a case where data in a specified area in a memory is read and transferred to another area (hereinafter referred to as a DMA transfer between memories), a case where data is transferred between a peripheral device and a memory, and the like. Here, DMA transfer between memories will be described.

【0003】このDMA転送形態には、指定された領域
のデータを1回のDMA要求により全て転送する形態
と、DMA要求信号が活性化している期間中にのみ転送
する形態とがあるが、一般にメモリ間のDMA転送で
は、DMA要求信号によりDMAの実行を制御する形態
は不向きであり、ほとんどが1回のDAM要求により全
てのデータを連続して転送する形態で行われる。
The DMA transfer mode includes a mode in which data in a designated area is all transferred by one DMA request, and a mode in which data is transferred only while a DMA request signal is active. In a DMA transfer between memories, a form in which the execution of DMA is controlled by a DMA request signal is not suitable, and almost all data is transferred continuously by one DAM request.

【0004】図5は、従来のDMA転送制御装置を含む
情報処理装置の一例を示すブロック図である。DMA転
送制御装置303は、DMA要求信号100を受け付け
ると、転送制御部314から中央処理装置300(以下
CPUという)のバス制御回路301に、バス制御要求
信号310をアクティブにして、バスの使用権を要求す
る。バス制御回路301では、演算処理回路302、リ
フレッシュ制御装置306などからのバスの制御要求を
調停し、DMAのバス制御要求により優先順位の高い要
求がない場合に、バス制御許可信号311をアクティブ
にし、DMA転送制御装置303にアドレスバス32
0、データ入出力バス321と使用を許可する。
FIG. 5 is a block diagram showing an example of an information processing device including a conventional DMA transfer control device. Upon receiving the DMA request signal 100, the DMA transfer control device 303 activates the bus control request signal 310 from the transfer control unit 314 to the bus control circuit 301 of the central processing unit 300 (hereinafter, referred to as CPU), thereby granting the right to use the bus. Request. The bus control circuit 301 arbitrates bus control requests from the arithmetic processing circuit 302, the refresh control device 306, and the like, and activates the bus control permission signal 311 when there is no request with a higher priority due to a DMA bus control request. The address bus 32 to the DMA transfer control device 303.
0, permit use with the data input / output bus 321.

【0005】DMA転送制御装置303は、バスの使用
権が得られると、転送制御部314によって、次の
(1)〜(3)の動作を繰返すことによりDMA転送を
行う。 (1)メモリ304内、またはメモリ305内の転送元
(以下ソースという)領域のアドレスをアドレスバス3
20に出力し、データ入出力バス321を介してデータ
を読み出す。また、アドレスを更新する。 (2)続いて、メモリ304内、またはメモリ305内
の転送先(以下デスティネーションという)領域のアド
レスをアドレスバス320に出力し、データ入出力バス
321を介してソース領域から読み出したデータを書き
込む。また、アドレスを更新する。 (3)転送回数をカウントするために、上記1回のデー
タ転送ごとにカウンタの内容を更新(インクリメント)
する。
When the right to use the bus is obtained, the DMA transfer control device 303 performs DMA transfer by repeating the following operations (1) to (3) by the transfer control unit 314. (1) An address of a transfer source (hereinafter referred to as a source) area in the memory 304 or in the memory 305 is assigned to the address bus 3
20 and read data via the data input / output bus 321. Also, the address is updated. (2) Subsequently, the address of the transfer destination (hereinafter referred to as destination) area in the memory 304 or the memory 305 is output to the address bus 320, and the data read from the source area via the data input / output bus 321 is written. . Also, the address is updated. (3) In order to count the number of transfers, the contents of the counter are updated (incremented) each time the data is transferred once.
I do.

【0006】ここで転送回数が予め指定された値に到達
する、即ち指定領域のデータ転送を全て終了すると、バ
ス制御要求信号310をインアクティブにし、バスの使
用要求を取り下げ、バスの使用権をCPU300に戻
す。また、DMA要求信号100に対応したDMA終了
信号110をアクティブにし、DMA要求元に対して転
送終了を知らせる。CPU300は、メモリ304、お
よびメモリ305のデータ処理を行なった後、再びDM
A転送を行なうために、DMA転送制御装置303など
に対して制御情報を再設定する。
Here, when the number of transfers reaches a value specified in advance, that is, when all data transfers in the specified area are completed, the bus control request signal 310 is made inactive, the bus use request is canceled, and the right to use the bus is released. Return to CPU 300. Further, the DMA end signal 110 corresponding to the DMA request signal 100 is activated to notify the DMA request source of the transfer end. After performing data processing of memory 304 and memory 305, CPU 300 again executes DM processing.
In order to perform the A transfer, the control information is reset for the DMA transfer control device 303 and the like.

【0007】この他DMA転送制御装置303は、複数
の転送径路(以下チャネルという)を備えており、要求
元に応じたチャネルを選択し、実行する。各チャネルに
は、それぞれDMA処理の優先順位が付けられている。
複数のチャネルに対するDMA要求が同時期に発生した
場合には、優先順位制御部315で優先順位を判定し、
まず優先順位の最も高いチャネルからDMA転送が行わ
れる。
In addition, the DMA transfer control device 303 has a plurality of transfer paths (hereinafter referred to as channels), and selects and executes a channel according to a request source. Each channel is assigned a priority for DMA processing.
When DMA requests for a plurality of channels occur at the same time, the priority control unit 315 determines the priority,
First, DMA transfer is performed from the channel with the highest priority.

【0008】[0008]

【発明が解決しようとする課題】このように従来のDM
A転送制御装置におけるメモリ間のDMA転送では、予
め指定された領域の全データを1回のDMA要求により
連続して転送する方法しかなかった。そのためソース領
域とデスティネーション領域の大きさは同一でなければ
ならず、デスティネーション側がバッファメモリなどあ
まり大きな領域を有しない場合などのアプリケーション
に最適なものがなかった。
As described above, the conventional DM
In the DMA transfer between memories in the A transfer control device, there has been only a method of continuously transferring all data in a predetermined area by one DMA request. Therefore, the size of the source area and the destination area must be the same, and there is no one that is optimal for applications such as when the destination side does not have a very large area such as a buffer memory.

【0009】従って、ソース領域の指定をデスティネー
ション領域に合わせて細分化する方法が考えられるが、
1度に転送可能な領域が狭くなるために転送終了状態が
頻繁に発生し、その都度DMA開始アドレス、転送デー
タ数の再設定などの処理が必要とされ、CPUにおける
ソフトウェア処理負担が大きかった。また、CPUにお
けるこれらの処理が終了するまで次のDMA要求を受け
付けられないことによるDMA転送効率の悪化を招いて
いた。
Therefore, a method of subdividing the designation of the source area according to the destination area can be considered.
Since the area that can be transferred at one time is narrowed, a transfer end state frequently occurs. Each time, processing such as resetting the DMA start address and the number of transfer data is required, and the software processing load on the CPU is large. Further, the DMA transfer efficiency is deteriorated because the next DMA request cannot be accepted until the CPU finishes these processes.

【0010】また、デスティネーション領域のデータ単
位ごとに各々DMAチャネルを割当てる、例えば、ソー
ス領域が1024バイト、デスティネーション領域が2
56バイトのときには、4チャネルを使用し、各チャネ
ルでそれぞれ256バイトの転送を行なうといった方法
を用いていた。しかし、この方法では、複数のDMAチ
ャネルを占有するために他の目的にDMA転送が利用で
きなくなるなど、ソフトウェア処理負担の増加、メモリ
の使用効率が悪くなるといった二次的な問題が生じてい
た。
A DMA channel is allocated to each data unit of the destination area. For example, the source area is 1024 bytes, and the destination area is 2 bytes.
In the case of 56 bytes, a method was used in which four channels were used and each channel transferred 256 bytes. However, in this method, secondary problems have occurred such as an increase in software processing load and a decrease in memory use efficiency, such as occupying a plurality of DMA channels and making DMA transfer unavailable for other purposes. .

【0011】本発明の目的は、DMAによるデータ転送
を1回のDMA要求ごとにデスティネーション領域に応
じて分割転送できる機能を簡単なハードウェアで実現
し、CPU、周辺装置における処理負担を大幅に軽減で
き、また用途に応じて最適設計が可能なDMA転送制御
装置を提供することにある。
An object of the present invention is to realize, with simple hardware, a function capable of performing data transfer by DMA in accordance with a destination area for each DMA request, thereby greatly reducing the processing load on the CPU and peripheral devices. An object of the present invention is to provide a DMA transfer control device which can reduce the number of times and which can be optimally designed according to the application.

【0012】[0012]

【課題を解決するための手段】本発明の構成は、転送元
メモリから転送先メモリへのメモリ内の指定アドレスの
データをダイレクト・メモリ・アクセス方式によって転
送を行うダイレクト・メモリ・アクセス(DMA)転送
制御装置において、前記DMA転送の対象となる前記転
送先メモリ内のアドレスを生成し、更新するアドレス生
成回路と、前記転送元メモリと転送先メモリのメモリ領
の大きさを判定し前記DMA転送の終了状態を制御
転送終了制御回路と、前記DMA転送制御に関する各
種パラメータを記憶する記憶回路と、有効なDMA転送
要求の発生を検知してバスの使用要求を制御するバス制
御手段と、前記バスの使用要求に応答したバスの使用許
可状態に応じて転送サイクルを順次発生し前記アドレス
と各種パラメータを用いてDMA転送を実行する転送制
御回路と、1回のDMA転送要求により所定アドレスの
転送が実行されたことを前記転送先アドレス値との一致
検出することにより行うアドレス検出手段とを有し、
このアドレス検出手段の出力によりDMA転送の一時
させDMA転送を分割制御できるようにしたことを特
徴とする。
According to the present invention, a transfer source
In direct memory access (DMA) transfer control device for transferring by direct memory access method of the data of the specified address in the memory to the transfer destination memory from the memory, the rolling to be the DMA transfer
It generates an address of Okusaki in memory, and an address generation circuit for updating, the transfer Ru source memory and to control the termination state before Symbol DMA transfer to determine the size of the memory area of the transfer destination memory <br/> Transfer An end control circuit, a storage circuit for storing various parameters related to the DMA transfer control, a bus control means for detecting occurrence of a valid DMA transfer request and controlling a bus use request, and responding to the bus use request. a transfer control circuit for executing DMA transfer by using the address and various parameters sequentially generating a transfer cycle in accordance with the use permission state of the bus, said that the predetermined address transfer is executed by one DMA transfer request Match with transfer destination address value
And an address detection means by detecting a
The output of the address detector is <br/> pause the DMA transfer is characterized in that to be able to split DMA transfer control.

【0013】本発明において、アドレス検出手段が、1
回のDMA転送要求により到達するメモリの転送終了ア
ドレスを設定するアドレスレジスタと、このアドレスレ
ジスタの内容とDMAアドレスとを比較してその一致状
態を検出する比較回路とを有するものとすることがで
き、また、転送終了制御回路が、アドレス検出手段の一
致状態の検出回数に基づいて転送終了制御を行うものと
することができる。
In the present invention, the address detecting means may include one
An address register for setting a transfer end address in the memory to reach the times of the DMA transfer request, by comparing the content and DMA address of the address register can be made to have a comparison circuit for detecting the coincidence state in addition, the transfer end control circuit, and performs a transfer end control based on the number of detected coincidence state of the address detecting means
It can be.

【0014】[0014]

【実施例】図1は、本発明のダイレクト・メモリ・アク
セス(DMA)転送制御装置の一実施例を示すブロック
図である。このDMA転送制御装置は、周辺装置からの
DMA要求信号100を入力し、DMA要求を制御する
DMA要求制御回路200と、CPU、周辺装置などに
DMA終了信号110を出力するDMA応答制御回路2
01と、DMAアクセス裁定回路202と、DMA転送
の対象となるメモリの転送元アドレス(以下DMAソー
スアドレスという)を格納するソースアドレス204と
メモリの転送先アドレス(以下DMAデスティネーショ
ンアドレスという)を格納するデスティネーションアド
レスレジスタ205と1DMA転送ごとにソース、およ
びデスティネーションアドレスレジスタの内容を更新す
るアドレス加減算回路206からなり、DMAアドレス
を生成、更新するDMAアドレス生成回路203と、ト
ータルの転送データ数を格納するターミナル・カウント
レジスタ208と1DMA転送の実行ごとにターミナル
・カウントレジスタ208の内容を減少する減算回路2
09とからなり、DMA転送の対象となるメモリ内のト
ータルにデータ数、即ちソース領域のサイズを制御する
ターミナル・カウント制御回路207と、1回のDMA
要求により到達するデスティネーション領域メモリのア
ドレスを検出するアドレス検出回路210と、DMAソ
ースアドレス、およびDMAデスティネーションアドレ
スを供給するDMAアドレスライン120とから構成さ
れる。
FIG. 1 is a block diagram showing one embodiment of a direct memory access (DMA) transfer control device according to the present invention. This DMA transfer control device receives a DMA request signal 100 from a peripheral device and controls a DMA request, and a DMA response control circuit 2 that outputs a DMA end signal 110 to a CPU, a peripheral device and the like.
01, a DMA access arbitration circuit 202, a source address 204 for storing a source address of a memory to be subjected to DMA transfer (hereinafter referred to as a DMA source address), and a destination address of the memory (hereinafter referred to as a DMA destination address). A destination address register 205, a source for each DMA transfer, and an address addition / subtraction circuit 206 for updating the contents of the destination address register. A DMA address generation circuit 203 for generating and updating DMA addresses, and a total number of transfer data Terminal count register 208 to be stored and subtraction circuit 2 for reducing the contents of terminal count register 208 each time one DMA transfer is executed
09, a terminal count control circuit 207 for controlling the total number of data in the memory to be DMA-transferred, that is, the size of the source area, and one DMA transfer.
It comprises an address detection circuit 210 for detecting an address of the destination area memory reached by the request, and a DMA address line 120 for supplying a DMA source address and a DMA destination address.

【0015】ソースアドレスレジスタ204、デスティ
ネーションアドレスレジスタ205、ターミナル・カウ
ントレジスタ208、アドレス検出回路210は、CP
Uのアドレスバス320(図5)、データ入出力バス3
21(図5)を介してCPU300(図5)と接続され
ており、CPU300は、DMA転送の実行に先だち、
これらのラインを介して、ソース領域メモリの転送開始
アドレスをソースアドレスレジスタ204に、デスティ
ネーション領域メモリの転送開始アドレスをデスティネ
ーションアドレスレジスタ205に、トータルの転送デ
ータ数をターミナル・カウントレジスタ208に、デス
ティネーション領域メモリの転送終了アドレスをアドレ
ス検出手段210に、それぞれ設定する。
The source address register 204, destination address register 205, terminal count register 208, and address detection circuit 210
U address bus 320 (FIG. 5), data input / output bus 3
21 (FIG. 5), and is connected to the CPU 300 (FIG. 5).
Via these lines, the transfer start address of the source area memory is stored in the source address register 204, the transfer start address of the destination area memory is stored in the destination address register 205, the total number of transfer data is stored in the terminal count register 208, The transfer end address of the destination area memory is set in the address detecting means 210, respectively.

【0016】DMA要求制御回路200は、DMA要求
信号100を監視しており、有効なDMA転送要求を受
け付けると、DMA要求フラグ信号130をアクティブ
にし、DMAアクセス裁定回路202にDMA要求の発
生を知らせる。DMAアクセス裁定回路202は、所定
のタイミングにCPUのバス制御回路301(図5)に
対してバス制御要求信号310をアクティブにし、CP
U300に代わって、DMA転送制御装置がアドレスバ
ス、データ入出力バス(以下これらを総称してバスとい
う)の制御を行うことを要求する。
The DMA request control circuit 200 monitors the DMA request signal 100, and upon receiving a valid DMA transfer request, activates the DMA request flag signal 130 to notify the DMA access arbitration circuit 202 of the occurrence of the DMA request. . The DMA access arbitration circuit 202 activates the bus control request signal 310 to the bus control circuit 301 (FIG. 5) of the CPU at a predetermined timing,
Instead of U300, it requests that the DMA transfer control device control an address bus and a data input / output bus (hereinafter, these are collectively referred to as a bus).

【0017】バス制御回路301は、バスの使用権の調
停を行い、DMA転送によるバスの使用要求より優先順
位の高い要求がない場合にバス制御許可信号311をア
クティブにすることで応答する。バス制御許可信号31
1がアクティブになるとDMAアクセス裁定回路202
は、DMA実行許可信号140の一つを活性化し、DM
Aの実行サイクルを起動する。
The bus control circuit 301 arbitrates the right to use the bus, and responds by activating the bus control permission signal 311 when there is no request having a higher priority than the bus use request by the DMA transfer. Bus control permission signal 31
When 1 becomes active, the DMA access arbitration circuit 202
Activates one of the DMA execution permission signals 140
Start the execution cycle of A.

【0018】DMAの実行サイクルでは、次の(1)〜
(6)を繰返しソース領域からデスティネーション領域
へ順次データ転送を行う。 (1)実行中のチャネルのソースアドレスレジスタ20
4の内容を読み出し、DMAアドレスを生成する。DM
Aアドレスライン120を介して出力し、このアドレス
からデータを読み出す。 (2)アドレス加減算回路206で演算し、再びソース
アドレスレジスタ204に書き戻すことによってDMA
ソースアドレスの更新を行う。 (3)実行中のチャネルのデスティネーションアドレス
レジスタ205の内容を読み出し、DMAアドレスを生
成する。DMAアドレスライン120を介して出力し、
該アドレスへソース領域から読み出したデータを書き込
む。 (4)アドレス加減算回路206で演算し、再びデステ
ィネーションアドレスレジスタ205に書き戻すことに
よってDMAデスティネーションアドレスの更新を行
う。 (5)アドレス検出回路210でデスティネーションア
ドレスが所定の値(アドレス)に達したかを判定する。 (6)ターミナル・カウントレジスタ208の内容を読
み出し、減算回路209で減少させ、再び書き戻すこと
によってトータルの転送データ数を制御する。 (7)ここでアドレス検出回路210において、デステ
ィネーションアドレスが予め設定されている転送終了ア
ドレスに達したことを検出すると一致検出信号160を
アクティブにする。この一致検出信号160は、DMA
要求制御回路200に供給されており、DMA要求制御
回路200では、一致検出信号160がアクティブとな
ることによりDMA要求フラグ信号130をリセット
し、DMA転送を停止する。また、デスティネーション
アドレスレジスタ205は、デスティネーション領域メ
モリの転送開始アドレスに再設定される。
In the execution cycle of the DMA, the following (1) to (1)
(6) is repeated to sequentially transfer data from the source area to the destination area. (1) Source address register 20 of channel being executed
4 is read, and a DMA address is generated. DM
The data is output via the A address line 120, and data is read from this address. (2) The operation is performed by the address addition / subtraction circuit 206 and written back to the source address
Update the source address. (3) Read the contents of the destination address register 205 of the channel being executed, and generate a DMA address. Output via DMA address line 120;
The data read from the source area is written to the address. (4) The operation is performed by the address addition / subtraction circuit 206, and the DMA destination address is updated by writing back to the destination address register 205 again. (5) The address detection circuit 210 determines whether the destination address has reached a predetermined value (address). (6) The contents of the terminal count register 208 are read out, reduced by the subtraction circuit 209, and written back again to control the total number of transfer data. (7) Here, when the address detection circuit 210 detects that the destination address has reached the preset transfer end address, the match detection signal 160 is activated. This match detection signal 160
The DMA request control circuit 200 resets the DMA request flag signal 130 when the coincidence detection signal 160 becomes active, and stops the DMA transfer. Further, the destination address register 205 is reset to the transfer start address of the destination area memory.

【0019】再び、DMA要求が発生すると、この
(1)〜(7)を繰り返しDMA転送を実行する。さら
に、ターミナル・カウントレジスタ208、減算回路2
09によって予め設定されたトータルの転送データ数を
カウントすると、DMA終了検出信号150をアクティ
ブにする。
When a DMA request occurs again, the above (1) to (7) are repeated to execute DMA transfer. Further, the terminal count register 208, the subtraction circuit 2
When the preset total number of transfer data is counted by 09, the DMA end detection signal 150 is activated.

【0020】DMA応答制御回路201では、DMA終
了検出信号150がアクティブとなったことを検知する
と、CPU、周辺装置などに対して、DMAによる一連
のデータ転送の終了を知らせる。
When the DMA response control circuit 201 detects that the DMA end detection signal 150 has become active, it notifies the CPU and peripheral devices of the end of a series of data transfer by DMA.

【0021】図2は、図1のアドレス検出回路210の
ブロック図である。このアドレス検出回路は、1回のD
MA要求により到達するデスティネーション領域メモリ
の転送終了アドレスを設定する転送終了アドレスレジス
タ10と、比較回路20と、ANDゲート30とから構
成される。
FIG. 2 is a block diagram of the address detection circuit 210 of FIG. This address detection circuit performs one D
It comprises a transfer end address register 10 for setting a transfer end address of the destination area memory reached by the MA request, a comparison circuit 20, and an AND gate 30.

【0022】転送終了アドレスレジスタ10は、CPU
のアドレスバス320、データ入出力バス321を介し
てCPU300と接続されており、CPU300は、D
MA転送の実行に先だち、これらのラインを介して、1
回のDMA要求により到達すべきデスティネーション領
域メモリの転送終了アドレスを設定する。比較回路20
は、転送終了アドレスレジスタ10の設定値とDMAア
ドレスライン120上に出力されるアドレスとを比較
し、両者が等しいときに一致信号40をアクティブにす
る。ANDゲート30は、DMA実行許可信号140と
一致信号40と、デスティネーションサイクル期間信号
41とを入力し、一致検出信号160を生成する。
The transfer end address register 10 has a CPU
Are connected to the CPU 300 via an address bus 320 and a data input / output bus 321 of the CPU.
Prior to performing the MA transfer, 1
The transfer end address of the destination area memory to be reached by the DMA request is set. Comparison circuit 20
Compares the value set in the transfer end address register 10 with the address output on the DMA address line 120, and activates the coincidence signal 40 when both are equal. The AND gate 30 receives the DMA execution permission signal 140, the coincidence signal 40, and the destination cycle period signal 41, and generates a coincidence detection signal 160.

【0023】次に、このアドレス検出回路210の動作
について説明する。図3はアドレス検出回路の動作タイ
ミング図である。本実施例では、デスティネーション領
域メモリの転送開始アドレスを‘256’、転送終了ア
ドレスを‘511’とする。即ち、デスティネーション
領域メモリのサイズが256バイトの場合を例にとって
説明する。
Next, the operation of the address detection circuit 210 will be described. FIG. 3 is an operation timing chart of the address detection circuit. In this embodiment, the transfer start address of the destination area memory is "256", and the transfer end address is "511". That is, a case where the size of the destination area memory is 256 bytes will be described as an example.

【0024】バスサイクル(A)において、DMA要求
が発生し、DMA要求フラグ信号130がアクティブ
“1”になる。このときDMAよりもバス使用要求順位
の高いものがなく、DMAによるバスの使用が許可され
ると、バスサイクル(B)からDMA実行許可信号14
0がアクティブとなり、DMA転送が開始される。デス
ティネーションアドレスレジスタ205は、DMA実行
許可信号140とデスティネーションサイクル期間信号
41が共にハイレベルの期間にインクリメントされ、バ
スサイクル(C)では、デスティネーションアドレスは
“257”となる。
In the bus cycle (A), a DMA request occurs, and the DMA request flag signal 130 becomes active "1". At this time, if there is no bus use request higher than the DMA and the bus use by the DMA is permitted, the DMA execution permission signal 14 starts from the bus cycle (B).
0 becomes active, and DMA transfer is started. The destination address register 205 is incremented during a period when both the DMA execution permission signal 140 and the destination cycle period signal 41 are at the high level, and the destination address becomes “257” in the bus cycle (C).

【0025】同様にしてDMA転送を繰り返し、バスサ
イクル(X)、(Y)でもインクリメントされて、デス
ティネーションアドレスは、それぞれ“510”、“5
11”と順次インクリメントされる。転送終了アドレス
レジスタ10には、“511”が設定されているので、
バスサイクル(Y)において転送終了アドレスレジスタ
とデスティネーションアドレスとが一致し、一致検出信
号160がアクティブとなる。一致検出信号160がア
クティブになると、DMA要求フラグ信号130はリセ
ットされ、DMA転送は停止する。再び、DMA要求が
発生すると、バスサイクル(Z)では、デスティネーシ
ョンアドレスは“256”となり、ソースアドレスは、
次アドレスから転送を再開する。
Similarly, the DMA transfer is repeated and incremented in the bus cycles (X) and (Y), so that the destination addresses are "510" and "5", respectively.
11 ”. Since“ 511 ”is set in the transfer end address register 10,
In the bus cycle (Y), the transfer end address register matches the destination address, and the match detection signal 160 becomes active. When the match detection signal 160 becomes active, the DMA request flag signal 130 is reset, and the DMA transfer stops. When a DMA request occurs again, in the bus cycle (Z), the destination address becomes “256” and the source address becomes
Resume transfer from the next address.

【0026】このように本実施例では、デスティネーシ
ョンアドレスが所定の値(転送終了アドレス)に達した
ことを検出し、DMA要求フラグ信号をリセットするこ
とによって、DMA転送の停止制御を行なっている。従
って、ソース領域のデータを1回のDMA要求ごとにデ
スティネーション領域に応じて分割して転送することが
できる。
As described above, in this embodiment, the stop control of the DMA transfer is performed by detecting that the destination address has reached the predetermined value (transfer end address) and resetting the DMA request flag signal. . Therefore, the data in the source area can be divided and transferred according to the destination area for each DMA request.

【0027】また、本実施例では、特にDMA要求信号
の数、種類について触れなかったが要求信号の数、種類
に制約されることがなく、また1回のDMA要求で転送
する容量が増減した場合にも容易に実現できる。
In this embodiment, the number and types of the DMA request signals are not particularly mentioned, but the number and types of the request signals are not restricted, and the capacity to be transferred by one DMA request is increased or decreased. In this case, it can be easily realized.

【0028】図4は本発明の第2の実施例のDMA転送
制御装置を示すブロック図であり、第1の実施例と重複
する部分、信号には同一の番号を付している。本実施例
は、ターミナル・カウント制御回路217が一致検出信
号160を入力し、一致検出状態が発生するごとにター
ミナル・カウントレジスタ208の内容を減算回路20
9により減少させる。即ち、1回のDMA要求によるデ
スティネーション領域への転送が終了するごとにディク
リメントする。
FIG. 4 is a block diagram showing a DMA transfer control device according to a second embodiment of the present invention, where the same parts as those in the first embodiment are denoted by the same reference numerals. In this embodiment, the terminal count control circuit 217 receives the coincidence detection signal 160 and subtracts the content of the terminal count register 208 every time a coincidence detection state occurs.
Decrease by 9 That is, it is decremented each time transfer to the destination area by one DMA request is completed.

【0029】ターミナル・カウント制御回路217から
出力するDMA終了検出信号150は、第1の実施例と
同じようにDMA応答制御回路201に供給される。こ
のため、デスティネーション領域への分割転送が何回行
なわれたかで、ソース領域のトータルのデータ数を制御
できる。
The DMA end detection signal 150 output from the terminal count control circuit 217 is supplied to the DMA response control circuit 201 as in the first embodiment. Therefore, the total number of data in the source area can be controlled depending on how many times the division transfer to the destination area is performed.

【0030】このように本実施例では、ターミナル・カ
ウント制御回路217では、デスティネーション領域へ
の分割転送が何回行なわれたかを制御すればよく、この
ため、ターミナル・カウントレジスタ、減算回路等のハ
ードウェアが簡単になる。
As described above, in the present embodiment, the terminal count control circuit 217 only needs to control how many times the divided transfer to the destination area has been performed. Hardware is simplified.

【0031】[0031]

【発明の効果】以上説明したように、本発明は、デステ
ィネーションアドレスが所定の値(転送終了アドレス)
に達したことを検出し、DMA要求フラグ信号をリセッ
トすることによってDMA転送の停止制御を行なってい
るため次のような効果がある。 (1)メモリ内の指定領域の容量に応じたデータ数を1
回のDMA要求ごとに分割して転送制御できる機能を簡
単なハードウェアで実現できるため、バッファメモリな
ど、比較的少容量の領域とのメモリ間のDAM転送をす
るといったアプリケーションをはじめとして、用途に応
じた最適設計が可能となる。 (2)ソース領域の指定をデスティネーション領域に合
わせて細分化するなどの場合のように、1度に転送可能
な領域が狭くなるために転送終了状態が頻繁に発生し、
その都度DMA開始アドレス、転送データ数の再設定な
どの処理を必要とせず、CPUのソフトウェア処理の負
担を大幅に軽減できる。また、処理が終了するまで次の
DMA要求が受け付けられないといったことがないた
め、DMA転送効率を向上できる。 (3)デスティネーション領域のデータ単位ごとに各々
DMAチャネルを割当てる場合などのように、複数のD
MAチャネルを占有することなく、1つのDMAチャネ
ルのみで実現できるため、メモリ、およびDMAチャネ
ルの使用効率が著しく向上する。 (4)分割転送した回数をメモリのトータルの領域判定
制御に使用できるため、ターミナル・カウントレジス
タ、減算回路等のハードウェアが簡単になる。
As described above, according to the present invention, the destination address has a predetermined value (transfer end address).
Has been reached, and the DMA transfer stop signal is reset by resetting the DMA request flag signal. This has the following effects. (1) The number of data according to the capacity of the designated area in the memory is 1
Since the function of dividing and controlling the transfer for each DMA request can be realized with simple hardware, it can be used for applications such as applications such as DAM transfer between memories with a relatively small capacity area such as a buffer memory. An optimal design according to the requirement can be achieved. (2) As in the case where the designation of the source area is subdivided in accordance with the destination area, the transfer end state frequently occurs because the area that can be transferred at one time is narrowed.
Each time, processing such as resetting of the DMA start address and the number of transfer data is not required, and the load of software processing on the CPU can be greatly reduced. Further, since the next DMA request is not accepted until the processing is completed, the DMA transfer efficiency can be improved. (3) A plurality of D channels are allocated, as in the case where a DMA channel is assigned to each data unit in the destination area.
Since it can be realized with only one DMA channel without occupying the MA channel, the use efficiency of the memory and the DMA channel is significantly improved. (4) Since the number of times of division transfer can be used for the total area determination control of the memory, hardware such as a terminal count register and a subtraction circuit is simplified.

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

【図1】本発明のDMA転送制御装置の一実施例を示す
ブロック図。
FIG. 1 is a block diagram showing one embodiment of a DMA transfer control device of the present invention.

【図2】図1におけるアドレス検出回路の一例のブロッ
ク図。
FIG. 2 is a block diagram illustrating an example of an address detection circuit in FIG. 1;

【図3】図1のDMA領域制御の動作タイミング図。FIG. 3 is an operation timing chart of the DMA area control of FIG. 1;

【図4】本発明の第2の実施例のDMA転送制御装置の
ブロック図。
FIG. 4 is a block diagram of a DMA transfer control device according to a second embodiment of the present invention.

【図5】従来のDMA転送制御装置を含む情報処理装置
のブロック図。
FIG. 5 is a block diagram of an information processing device including a conventional DMA transfer control device.

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

10 転送終了アドレスレジスタ 20 比較回路 30 アンドゲート 40 一致信号 41 デスティネーションサイクル期間信号 100 DMA終了信号 110 DMA応答信号 120 DMAアドレスライン 130 DMA要求フラグ信号 140 DMA実行許可信号 150 DMA終了検出信号 160 一致検出信号 200 DMA要求制御回路 201 DMA応答制御回路 202 DMAアクセス裁定回路 203 DMAアドレス生成回路 204 ソースアドレスレジスタ 205 デスティネーションアドレスレジスタ 206 アドレス加減算回路 207,217 ターミナル・カウント制御回路 208 ターミナル・カウントレジスタ 209 カウント減算回路 210 アドレス検出回路 300 CPU 301 バス制御回路 302 演算処理回路 303 DMA転送制御装置 304 第1のメモリ 305 第2のメモリ 306 リフレッシュ制御装置 310,313 バス制御要求信号 311 バス制御許可信号 314 転送制御部 315 優先順位制御部 320 アドレスバス 321 データ入出力バス Reference Signs List 10 Transfer end address register 20 Comparison circuit 30 AND gate 40 Match signal 41 Destination cycle period signal 100 DMA end signal 110 DMA response signal 120 DMA address line 130 DMA request flag signal 140 DMA execution enable signal 150 DMA end detection signal 160 Match detection Signal 200 DMA request control circuit 201 DMA response control circuit 202 DMA access arbitration circuit 203 DMA address generation circuit 204 Source address register 205 Destination address register 206 Address addition / subtraction circuit 207, 217 Terminal count control circuit 208 Terminal count register 209 Count subtraction Circuit 210 Address detection circuit 300 CPU 301 Bus control circuit 302 Arithmetic processing circuit 30 3 DMA transfer control device 304 First memory 305 Second memory 306 Refresh control device 310,313 Bus control request signal 311 Bus control permission signal 314 Transfer control unit 315 Priority control unit 320 Address bus 321 Data input / output bus

Claims (3)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】 転送元メモリから転送先メモリへのメモ
リ内の指定アドレスのデータをダイレクト・メモリ・ア
クセス方式によって転送を行うダイレクト・メモリ・ア
クセス(DMA)転送制御装置において、前記DMA転
送の対象となる前記転送先メモリ内のアドレスを生成
し、更新するアドレス生成回路と、前記転送元メモリと
転送先メモリのメモリ領域の大きさを判定し前記DMA
転送の終了状態を制御する転送終了制御回路と、前記D
MA転送制御に関する各種パラメータを記憶する記憶回
路と、有効なDMA転送要求の発生を検知してバスの使
用要求を制御するバス制御手段と、前記バスの使用要求
に応答したバスの使用許可状態に応じて転送サイクルを
順次発生し前記アドレスと各種パラメータを用いてDM
A転送を実行する転送制御回路と、1回のDMA転送要
求により所定アドレスの転送が実行されたことを前記転
送先アドレス値との一致を検出することにより行うアド
レス検出手段とを有し、このアドレス検出手段の出力
よりDMA転送の一時停止させDMA転送を分割制御
きるようにしたことを特徴とするダイレクト・メモリ・
アクセス転送制御装置。
A direct memory access (DMA) transfer control device for transferring data at a specified address in a memory from a transfer source memory to a transfer destination memory by a direct memory access method. An address generation circuit for generating and updating an address in the transfer destination memory to be subjected to the DMA transfer ;
Before SL DMA determines the size of the memory area of the transfer destination memory
A transfer end control circuit for controlling a transfer end state;
A storage circuit for storing various parameters related to MA transfer control, a bus control means for detecting the occurrence of a valid DMA transfer request and controlling a bus use request, and a bus use permission state in response to the bus use request A transfer cycle is sequentially generated according to the address and the DM using the address and various parameters.
The rolling and transfer control circuit for executing A transfer that by one DMA transfer request in a predetermined address transfer is executed
And a address <br/> less detection means by detecting a coincidence between Okusaki address value, a split controls DMA transfer is paused DMA transfer from <br/> the output of the address detector
Direct memory, characterized in that it has been cut way
Access transfer control device.
【請求項2】 アドレス検出手段が、1回のDMA転送
要求により到達するメモリの転送終了アドレスを設定す
るアドレスレジスタと、このアドレスレジスタの内容と
DMAアドレスとを比較してその一致状態を検出する比
較回路とを有するものである請求項1記載のダイレクト
・メモリ・アクセス転送制御装置。
2. An address detecting means for comparing an address register for setting a transfer end address of a memory reached by one DMA transfer request with a content of the address register and a DMA address, 2. The direct memory access transfer control device according to claim 1, further comprising a comparison circuit for detecting a state.
【請求項3】 転送終了制御回路が、アドレス検出手段
の一致状態の検出回数に基づいて転送終了制御を行うも
のである請求項1記載のダイレクト・メモリ・アクセス
転送制御装置。
3. The direct memory access transfer control device according to claim 1, wherein the transfer end control circuit controls the transfer end based on the number of times the address detecting means detects the coincidence state.
JP09600291A 1991-04-26 1991-04-26 Direct memory access transfer controller Expired - Fee Related JP3206013B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP09600291A JP3206013B2 (en) 1991-04-26 1991-04-26 Direct memory access transfer controller

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP09600291A JP3206013B2 (en) 1991-04-26 1991-04-26 Direct memory access transfer controller

Publications (2)

Publication Number Publication Date
JPH04326150A JPH04326150A (en) 1992-11-16
JP3206013B2 true JP3206013B2 (en) 2001-09-04

Family

ID=14152915

Family Applications (1)

Application Number Title Priority Date Filing Date
JP09600291A Expired - Fee Related JP3206013B2 (en) 1991-04-26 1991-04-26 Direct memory access transfer controller

Country Status (1)

Country Link
JP (1) JP3206013B2 (en)

Also Published As

Publication number Publication date
JPH04326150A (en) 1992-11-16

Similar Documents

Publication Publication Date Title
US5497501A (en) DMA controller using a predetermined number of transfers per request
JP2978539B2 (en) Data transfer control device
JP3055917B2 (en) Data transfer control device
US5287486A (en) DMA controller using a programmable timer, a transfer counter and an or logic gate to control data transfer interrupts
US6782433B2 (en) Data transfer apparatus
USRE40261E1 (en) Apparatus and method of partially transferring data through bus and bus master control device
EP0969384A2 (en) Method and apparatus for processing information, and providing medium
JP3206013B2 (en) Direct memory access transfer controller
US20060047866A1 (en) Computer system having direct memory access controller
JP4151362B2 (en) Bus arbitration method, data transfer device, and bus arbitration method
JPH03122745A (en) Dma control system
JP3205992B2 (en) Direct memory access transfer controller
JPH06250970A (en) Memory controller
JP3105554B2 (en) Interrupt controller
JP2765267B2 (en) Direct memory access transfer controller
JP2819705B2 (en) Data transfer control device
JP2972557B2 (en) Data transfer control device and control method
JP3202272B2 (en) DMA controller
JP2837698B2 (en) Direct memory access controller
JP2570271B2 (en) Semiconductor memory controller
JPH02278362A (en) Data transfer control system
JPH02219157A (en) Bus arbiter in computer system
JPH02280261A (en) Dma controller
JPH09297730A (en) Method for transferring data through bus and bus master controller
JPH0512219A (en) Process transferring system

Legal Events

Date Code Title Description
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20010605

LAPS Cancellation because of no payment of annual fees