JPH02222052A - Direct memory access controller - Google Patents

Direct memory access controller

Info

Publication number
JPH02222052A
JPH02222052A JP4379989A JP4379989A JPH02222052A JP H02222052 A JPH02222052 A JP H02222052A JP 4379989 A JP4379989 A JP 4379989A JP 4379989 A JP4379989 A JP 4379989A JP H02222052 A JPH02222052 A JP H02222052A
Authority
JP
Japan
Prior art keywords
memory
buffers
buffer
dma
ram
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
JP4379989A
Other languages
Japanese (ja)
Inventor
Yasuyuki Yasuma
安間 恭之
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 JP4379989A priority Critical patent/JPH02222052A/en
Publication of JPH02222052A publication Critical patent/JPH02222052A/en
Pending legal-status Critical Current

Links

Landscapes

  • Bus Control (AREA)
  • Information Transfer Systems (AREA)

Abstract

PURPOSE:To attain the direct memory access(DMA) control even in a system where no memory is shared between two CPUs by switching the buffers with an FF whose output is inverted for each memory access. CONSTITUTION:When the output of an FF 10 is set at 1 by a preset signal PRST, a buffer and bidirectional buffers 3/7 and 4/8 are set in the enable and disable states respectively. Therefore the address received from a DMA controller 9 is supplied to a RAM 5 only via the buffer 3. The read data received from the RAM 5 is stored in a register of the controller 9 via the buffer 7 with no conflict produced with the data on a RAM 6 since the buffer 8 is kept disable. When a reading job is over and a memory read control signal MRC has a fall, the Q output of an FF 10 is inverted with the states of buffers 3/7 and 4/8 also inverted. Thus the data can be written into the RAM 6 with no conflict, and the DMA control is attained between two CPUs which share no memory.

Description

【発明の詳細な説明】 [産業上の利用分野] 本発明はメモリ間でダイレクトメモリアクセス(以下、
DMAと呼ぶ)転送を行うためのDMA制御装置に関し
、特に2つの中央処理装置(以下、CPUと呼ぶ)を備
えたシステムに使用されるDMA制御装置に関する。
[Detailed Description of the Invention] [Industrial Application Field] The present invention provides direct memory access (hereinafter referred to as
The present invention relates to a DMA control device for performing transfer (referred to as DMA), and particularly relates to a DMA control device used in a system equipped with two central processing units (hereinafter referred to as CPUs).

[従来の技術] 従来、メモリ間のDMA転送は以下の手順によって行わ
れていた。即ち、先ずDMAコントローラは、CPUに
ホールド要求を送出する。これを受けたCPUからのホ
ールド承認信号がDMAコントローラに入力されたら、
アドレスバス、データバスが空き状態となるので、DM
Aコントローラからアドレスバスにアドレスを送出し、
これにより特定のメモリからデータバス上に読み出され
たデータを他のメモリに書き込む。
[Prior Art] Conventionally, DMA transfer between memories has been performed by the following procedure. That is, first, the DMA controller sends a hold request to the CPU. When the hold approval signal from the CPU that receives this is input to the DMA controller,
Since the address bus and data bus are empty, the DM
Send the address from the A controller to the address bus,
As a result, data read from a specific memory onto the data bus is written to another memory.

また、2つのCPUがメモリを共有するシステムにおい
ては、2つのCPUに対してホールド信号が送出され、
2つのCPUからホールド承認信号が入力される点を除
き、基2本的には上記と同様の手順でDMA転送が行わ
れる。
Furthermore, in a system where two CPUs share memory, a hold signal is sent to the two CPUs,
DMA transfer is basically performed in the same procedure as above, except that hold approval signals are input from the two CPUs.

[発明が解決しようとする課題] しかしながら、上述した従来のDMAコントローラでは
、2つのCPU間でメモリを共有しないシステムに使用
した場合、メモリ間でアドレスが重複することがあり、
複数のメモリからの多重読み出し及び複数のメモリに対
する多重書き込みが発生して適切なりMA転送を行うこ
とができないという問題点があった。
[Problems to be Solved by the Invention] However, when the conventional DMA controller described above is used in a system in which memory is not shared between two CPUs, addresses may overlap between the memories.
There is a problem in that multiple reading from a plurality of memories and multiple writing to a plurality of memories occur, making it impossible to properly perform MA transfer.

本発明はかかる問題点に鑑みてなされたものであって、
2つのCPtJ間でメモリを共有しないシステムにおい
てもDMA転送制御を行うことができるDMA制御装置
を提供することを目的とする。
The present invention has been made in view of such problems, and includes:
An object of the present invention is to provide a DMA control device that can perform DMA transfer control even in a system in which memory is not shared between two CPtJs.

[課題を解決するための手段] 本発明に係るダイレクトメモリアクセス制御装置は、第
1の中央処理装置からアクセスされる第1のメモリと、
第2の中央処理装置からアクセスされる第2のメモリと
の間に設けられ、これら第1及び第2のメモリ間のダイ
レクトアクセス制御を行うダイレクトメモリアクセス制
御部と、前記第1のメモリと前記ダイレクトメモリアク
セス制御部との間のアドレスバス及びデータバスに夫々
介挿された第1及び第2のバッファと、前記第2のメモ
リと前記ダイレクトメモリアクセス制御部との間のアド
レスバス及びデータバスに夫々介挿された第3及び第4
のバッファと、ダイレクトメモリアクセスに先立ってそ
の出力が初期化されると共にその出力で前記第1及び第
2のバッファと前記第3及び第4のバッファとを選択的
に能動状態にさせ、更に前記第1及び第2のメモリに対
するメモ、リアクセスの度にその出力が反転するフリッ
プフロップ回路とを具備したことを特徴とする。
[Means for Solving the Problems] A direct memory access control device according to the present invention includes a first memory accessed from a first central processing unit;
a direct memory access control unit that is provided between a second memory accessed by a second central processing unit and performs direct access control between the first and second memories; first and second buffers respectively inserted in an address bus and a data bus between the direct memory access control unit; and an address bus and a data bus between the second memory and the direct memory access control unit. 3rd and 4th respectively inserted in
a buffer, the output of which is initialized and selectively activates the first and second buffers and the third and fourth buffers prior to direct memory access; The present invention is characterized in that it includes memories for the first and second memories, and a flip-flop circuit whose output is inverted each time it is reaccessed.

[作用] 本発明によれば、メモリアクセスの度にその出力を反転
させるフリップフロップ回路が第1及び第2のバッファ
と、第3及び第4のバッファとを選択的に能動状態にす
る。第1及び第2のバッファは、DMA制御部と第1の
メモリとの間のアドレスバス及びデータバスに介挿され
ており、第3及び第4のバッファは、DMA制御部と第
2のメモリとの間のアドレスバス及びデータバスに介挿
されている。このため、第1のメモリと第2のメモリと
は交互にDMA制御部からアクセスされ、両メモリから
同時にデータが読み出されたり、同時にデータが書き込
まれたりすることがない。
[Operation] According to the present invention, a flip-flop circuit that inverts its output every time a memory is accessed selectively activates the first and second buffers and the third and fourth buffers. The first and second buffers are inserted into an address bus and data bus between the DMA control unit and the first memory, and the third and fourth buffers are inserted between the DMA control unit and the second memory. It is inserted into the address bus and data bus between the Therefore, the first memory and the second memory are accessed alternately by the DMA control unit, and data is not read from or written to both memories at the same time.

従って、本発明によれば、2つのCPUがメモリを共有
しないシステムにおいても、一方、のメモリからデータ
が読み出され、他方のメモリにそれが書き込まれる動作
を繰返すことにより、DMA転送制御を行うことができ
る。
Therefore, according to the present invention, even in a system where two CPUs do not share memory, DMA transfer control is performed by repeating the operation of reading data from one memory and writing it to the other memory. be able to.

[実施例コ 以下、添付の図面を参照しながら本発明の実施例につい
て説明する。
[Embodiments] Hereinafter, embodiments of the present invention will be described with reference to the accompanying drawings.

第1図は本発明の実施例に係るDMA制御装置を備えた
システムの構成を示すブロック図である。
FIG. 1 is a block diagram showing the configuration of a system including a DMA control device according to an embodiment of the present invention.

本実施例のDMA制御装置は、CPU1によりアクセス
されるRAM (ランダム・アクセス・メモリ)5と、
CPU2によりアクセスされるRAM6との間のDMA
転送制御を司るもので、以下のように構成されている。
The DMA control device of this embodiment includes a RAM (random access memory) 5 accessed by the CPU 1,
DMA with RAM6 accessed by CPU2
It controls transfer control and is configured as follows.

即ち、DMAコントローラ(以下、DMACと呼ぶ)9
は、このDMA制御装置の主体をなすもので、CPUI
、2にホールド要求信号HLDRQを送出し、CPUI
、2からのホールド承認信号HLDAK1.2のAND
ゲート15による論理積HLDAKが入力されると、D
MA転送のためにRAM5.6をアクセスする。このD
MAC9とRAM5との間のアドレスバス21及びデー
タバス22には、夫々イネーブル端子付きのバッファ3
及び双方向バッファ7が介挿されている。
That is, a DMA controller (hereinafter referred to as DMAC) 9
is the main body of this DMA control device, and the CPU
, 2, and sends a hold request signal HLDRQ to the CPUI.
, AND of the hold acknowledge signal HLDAK1.2 from 2
When the logical product HLDAK from gate 15 is input, D
Access RAM5.6 for MA transfer. This D
The address bus 21 and data bus 22 between the MAC 9 and the RAM 5 each have a buffer 3 with an enable terminal.
and a bidirectional buffer 7 are inserted.

また、−DMAC9とRAM6との間のアドレスバス2
1及びデータバス22には、夫々イネーブル端子付きの
バッファ4及び双方向バッファ8が介挿されている。
Also, the address bus 2 between -DMAC9 and RAM6
A buffer 4 and a bidirectional buffer 8 each having an enable terminal are inserted into the data bus 1 and the data bus 22, respectively.

これらバッファ3,4.7.8は、プリセット入力付き
フリップフロップ10によってイネーブル状態を制御さ
れる。フリップフロップ10は、リセット信号R3T及
びプリセット信号PR3Tの立下がりでリセット及びプ
リセットされ、ANDゲート15から出力されるホール
ド承認信号HLDAKと、DMA転送時のメモリライト
コントロール信号MWCと、DMA転送時のメモリリー
ドコントロール信号MRCとのANDゲート11による
論理積結果をクロック信号として入力し、その立上がり
で出力Qを反転させる。この出力Qは、ORゲート12
の一方の入力に入力されると共に、インバータ13を介
してORゲート14の一方の入力に入力されている。ま
た、ORゲート12.14の他方の入力には、ホールド
承認信号HLDAKのインバータ16による反転信号が
入力されている。そして、ORゲート12の出力は、バ
ッファ4及び双方向バッファ8のイネーブル端子に入力
され、ORゲー14の出力は、バッファ3及び双方向バ
ッファ7のイネーブル端子に入力されている。
The enable states of these buffers 3, 4, 7, and 8 are controlled by a flip-flop 10 with a preset input. The flip-flop 10 is reset and preset at the falling edge of the reset signal R3T and the preset signal PR3T, and outputs a hold acknowledge signal HLDAK from the AND gate 15, a memory write control signal MWC during DMA transfer, and a memory write control signal MWC during DMA transfer. The logical product result of the AND gate 11 with the read control signal MRC is input as a clock signal, and the output Q is inverted at the rising edge of the clock signal. This output Q is the OR gate 12
It is also input to one input of the OR gate 14 via the inverter 13. Further, an inverted signal of the hold acknowledge signal HLDAK by the inverter 16 is input to the other input of the OR gate 12.14. The output of the OR gate 12 is input to the enable terminals of the buffer 4 and the bidirectional buffer 8, and the output of the OR gate 14 is input to the enable terminals of the buffer 3 and the bidirectional buffer 7.

次に、上記のように構成された本実施例のDMA制御装
置の動作について説明する。
Next, the operation of the DMA control device of this embodiment configured as described above will be explained.

先ず、CPU1のRAM5からCPU2のRAM6へD
MA転送を行う場合について、第2図のタイミング図を
参照しながら説明する。
First, D from RAM5 of CPU1 to RAM6 of CPU2.
The case of performing MA transfer will be explained with reference to the timing diagram of FIG. 2.

この場合には、I10コマンドによってプリセット信号
PR3Tがフリップフロップ10に与えられ、出力Qが
“1”に設定される。
In this case, the preset signal PR3T is applied to the flip-flop 10 by the I10 command, and the output Q is set to "1".

続いてDMAC9から、CPUI、2に対してホールド
要求信号HLDRQが出力される。これを受けてCPU
1.2からは、ホールド承認信号HLDAKI、2が出
力される。そして、これらの論理積であるホールド承認
信号HLDAKがANDゲート15から出力され、DM
AC9に入力されると、これを受けてDMAC9は、ア
ドレスバス21に読み出しアドレスADを出力すると共
にバッファ3,4にアドレスストローブ信号ADSTB
を出力する。このとき、フリップフロップ10の出力Q
は“1”であるから、バッファ3゜7はイネーブル状態
、バッファ4.8はディスエーブル状態になっている。
Subsequently, the DMAC9 outputs a hold request signal HLDRQ to the CPUI,2. In response to this, the CPU
1.2, a hold approval signal HLDAKI,2 is output. Then, a hold approval signal HLDAK, which is the logical product of these, is output from the AND gate 15, and the DM
When input to AC9, in response to this, DMAC9 outputs read address AD to address bus 21 and sends address strobe signal ADSTB to buffers 3 and 4.
Output. At this time, the output Q of the flip-flop 10
is "1", so buffer 3.7 is enabled and buffer 4.8 is disabled.

従って、RAM6にはアドレスが供給されず、RAM5
にのみアドレスが供給される。
Therefore, no address is supplied to RAM6, and RAM5
Addresses are provided only to

次に、メモリリードコントロール信号MRCが立下がる
と、RAM5からデータが読み出され、このデータが双
方向バッファ7及びデータバス22を介してDMAC9
の図示しないテンポラリレジスタに格納される。なお、
このとき双方向バッファ8はディスエーブル状態である
がら、RAMG側のデニタがRAM5がら読み出された
データと衝突することがない。
Next, when the memory read control signal MRC falls, data is read from the RAM 5, and this data is transferred to the DMAC 9 via the bidirectional buffer 7 and the data bus 22.
is stored in a temporary register (not shown). In addition,
At this time, although the bidirectional buffer 8 is in a disabled state, the data read from the RAM 5 does not collide with the data read from the RAM 5.

読み出しが終了すると、MRC信号の立上がりでフリッ
プフロップ10が反転して、出力Qが“O″となる。こ
れにより、バッファのイネーブル状態が切り替わり、バ
ッファ3,7がディスエーブル、バッファ4.8がイネ
ーブルとなる。この状態からDMAC9は書込動作に入
る。即ち、先ずDMAC9は、書込アドレスADをアド
レスバス21に出力する。このアドレスはRAM6のみ
に与えられる。そして、メモリライトコントロール信号
MWCの立下がりで、DMAC9のテンポラリレジスタ
からデータバス22及び双方向バッファ8を介してRA
M6にデータが書き込まれる。
When the reading is completed, the flip-flop 10 is inverted at the rising edge of the MRC signal, and the output Q becomes "O". This switches the enable states of the buffers, with buffers 3 and 7 being disabled and buffers 4 and 8 being enabled. From this state, the DMAC 9 starts a write operation. That is, first, the DMAC 9 outputs the write address AD to the address bus 21. This address is given only to RAM6. Then, at the fall of the memory write control signal MWC, the RA is transferred from the temporary register of the DMAC 9 via the data bus 22 and the bidirectional buffer 8.
Data is written to M6.

RAM6への書込が終了し、メモリライトコントロール
信号MWCが立上がると、フリップフロップ10の出力
Qは再び“1″になり、バッファ3.7がイネーブル、
バッファ4,8がディスエーブルになる。
When the writing to the RAM 6 is completed and the memory write control signal MWC rises, the output Q of the flip-flop 10 becomes "1" again, and the buffer 3.7 is enabled.
Buffers 4 and 8 are disabled.

このような動作をDMAC9に初期設定されたバイト数
だけ繰返すことにより、RAM5からRAM6へのデー
タのDMA転送が終了する。
By repeating this operation by the number of bytes initialized in the DMAC 9, the DMA transfer of data from the RAM 5 to the RAM 6 is completed.

また、CPU2のRAM6からCPUIのRAM5へD
MA転送を行う場合には、I10コマンドによりリセッ
ト信号R3Tを発生させ、フリップフローツブ10をリ
セットして出力Qを“O”にしてからDMA転送動作を
開始させることで、上記と全く同様の手順でRAM6か
らRAM5へのDMA転送を行うことができる; なお、DMA転送をしていないときには、ホールド承認
信号HLDAKが“0”なので、バッファ3,4.7.
8は全てディスエーブル状態であリ、バスの競合は起こ
らず、CPUI、CPtJ2は共に正常に動作をする。
Also, D from RAM6 of CPU2 to RAM5 of CPUUI.
When performing MA transfer, the reset signal R3T is generated by the I10 command, the flip-flop block 10 is reset and the output Q is set to "O", and then the DMA transfer operation is started, and the procedure is exactly the same as above. DMA transfer from RAM 6 to RAM 5 can be performed with DMA transfer; when DMA transfer is not being performed, hold acknowledge signal HLDAK is "0", so buffers 3, 4, 7, .
8 are all in a disabled state, no bus contention occurs, and both the CPUI and CPtJ2 operate normally.

[発明の効果コ 以上説明したように本発明によれば、メモリアクセスの
度にフリップフロップの出力が反転し、この出力でバッ
ファの切り替えが行われてバス上でデータが競合しない
ようにしたから、2つのCPU間でメモリを共有しない
システムにおいてもDMA転送制御を行うことができる
。
[Effects of the Invention] As explained above, according to the present invention, the output of the flip-flop is inverted every time a memory is accessed, and buffer switching is performed using this output to prevent data contention on the bus. , DMA transfer control can be performed even in a system in which memory is not shared between two CPUs.

【図面の簡単な説明】[Brief explanation of the drawing]

第1図は本発明の実施例に係るDMA制御装置のブロッ
ク図、第2図は同装置の動作を説明するためのタイミン
グ図である。
FIG. 1 is a block diagram of a DMA control device according to an embodiment of the present invention, and FIG. 2 is a timing diagram for explaining the operation of the device.

Claims (1)

【特許請求の範囲】[Claims] (1)第1の中央処理装置からアクセスされる第1のメ
モリと、第2の中央処理装置からアクセスされる第2の
メモリとの間に設けられ、これら第1及び第2のメモリ
間のダイレクトアクセス制御を行うダイレクトメモリア
クセス制御部と、前記第1のメモリと前記ダイレクトメ
モリアクセス制御部との間のアドレスバス及びデータバ
スに夫々介挿された第1及び第2のバッファと、前記第
2のメモリと前記ダイレクトメモリアクセス制御部との
間のアドレスバス及びデータバスに夫々介挿された第3
及び第4のバッファと、ダイレクトメモリアクセスに先
立ってその出力が初期化されると共にその出力で前記第
1及び第2のバッファと前記第3及び第4のバッファと
を選択的に能動状態にさせ、更に前記第1及び第2のメ
モリに対するメモリアクセスの度にその出力が反転する
フリップフロップ回路とを具備したことを特徴とするダ
イレクトメモリアクセス制御装置。
(1) Provided between a first memory accessed from a first central processing unit and a second memory accessed from a second central processing unit, and between these first and second memories. a direct memory access control unit that performs direct access control; first and second buffers respectively inserted in an address bus and a data bus between the first memory and the direct memory access control unit; a third memory inserted into the address bus and the data bus between the second memory and the direct memory access control unit, respectively;
and a fourth buffer, the output of which is initialized and selectively activates the first and second buffers and the third and fourth buffers prior to direct memory access. . A direct memory access control device further comprising a flip-flop circuit whose output is inverted each time the first and second memories are accessed.
JP4379989A 1989-02-23 1989-02-23 Direct memory access controller Pending JPH02222052A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP4379989A JPH02222052A (en) 1989-02-23 1989-02-23 Direct memory access controller

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP4379989A JPH02222052A (en) 1989-02-23 1989-02-23 Direct memory access controller

Publications (1)

Publication Number Publication Date
JPH02222052A true JPH02222052A (en) 1990-09-04

Family

ID=12673796

Family Applications (1)

Application Number Title Priority Date Filing Date
JP4379989A Pending JPH02222052A (en) 1989-02-23 1989-02-23 Direct memory access controller

Country Status (1)

Country Link
JP (1) JPH02222052A (en)

Similar Documents

Publication Publication Date Title
US5119480A (en) Bus master interface circuit with transparent preemption of a data transfer operation
US4449183A (en) Arbitration scheme for a multiported shared functional device for use in multiprocessing systems
US5014247A (en) System for accessing the same memory location by two different devices
US5717873A (en) Deadlock avoidance mechanism and method for multiple bus topology
US5463740A (en) Data control device generating different types of bus requests and transmitting requests directly to one of a number of arbiters for obtaining access to a respective bus
JP2000047974A (en) Bus arbitration method for bus control controller, bus control controller, and system for electronic device
US6026455A (en) Architecture and method for providing guaranteed access for a retrying bus master to a data transfer bridge connecting two buses in a computer system
US5627968A (en) Data transfer apparatus which allows data to be transferred between data devices without accessing a shared memory
US5446847A (en) Programmable system bus priority network
JPH03122745A (en) Dma control system
JPS61166647A (en) Accessing for reading out information microprocessor and addressable memory
JPH0343804A (en) Sequence controller
JPS6341103B2 (en)
JPH0560625B2 (en)
JP2574821B2 (en) Direct memory access controller
JPH02207363A (en) Data transfer system, device controller, and memory controller
JPH0351943A (en) Sharing system for high/low speed bus lines
EP0373393A1 (en) Information processing system
JPH0375959A (en) Data transfer device for multiprocessor
JPH03189755A (en) Inter-memory transfer device
JPH034349A (en) Dma transfer system
JPS60151894A (en) Refresh circuit of dynamic ram
JPH0575140B2 (en)
JPH036762A (en) Image memory direct access method
JPH0293971A (en) Memory access circuit