JP2015222487A - DMA controller - Google Patents

DMA controller Download PDF

Info

Publication number
JP2015222487A
JP2015222487A JP2014106365A JP2014106365A JP2015222487A JP 2015222487 A JP2015222487 A JP 2015222487A JP 2014106365 A JP2014106365 A JP 2014106365A JP 2014106365 A JP2014106365 A JP 2014106365A JP 2015222487 A JP2015222487 A JP 2015222487A
Authority
JP
Japan
Prior art keywords
bus
transfer
dma
master port
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.)
Granted
Application number
JP2014106365A
Other languages
Japanese (ja)
Other versions
JP6364951B2 (en
Inventor
直俊 西岡
Naotoshi Nishioka
直俊 西岡
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.)
Yamaha Corp
Original Assignee
Yamaha 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 Yamaha Corp filed Critical Yamaha Corp
Priority to JP2014106365A priority Critical patent/JP6364951B2/en
Publication of JP2015222487A publication Critical patent/JP2015222487A/en
Application granted granted Critical
Publication of JP6364951B2 publication Critical patent/JP6364951B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

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

Abstract

PROBLEM TO BE SOLVED: To improve data transfer efficiency in a structure comprising two or more buses.SOLUTION: A DMA controller 50 for transferring data from a source address to a destination address comprises: master ports P1-P4 disposed corresponding to buses, and respectively connected to corresponding buses; an address table 514 for associating addresses of modules connected to the buses with the connected buses and storing them; an identification part 512 for identifying a transfer source bus to which the module of the source address belongs, and a transfer destination bus to which the module of the destination address belongs, by referring to the address table 514; and a transfer control part 502 for setting a path for transferring the data from the source address to the destination address, to the transfer source bus, the master port connected to the transfer source bus, the master port connected to the transfer destination bus, and the transfer destination bus.

Description

本発明は、DMA(Direct Memory Access)方式によりデータを転送するDMAコントローラに関する。   The present invention relates to a DMA controller that transfers data by a DMA (Direct Memory Access) method.

例えばバスマスタとしてのCPU(Central Processing Unit)と、様々な機能を提供する複数のバススレーブとでシステムを構築する場合、これらが単一のバスで接続されることはない。この主な理由は、データの転送性能がバススレーブ毎に異なるためである。このため、転送性能の高いバススレーブや、CPU、DMAコントローラを高速バスに接続するとともに、転送性能の低いバススレーブを低速バスに接続して、高速バスおよび低速バス同士をバスブリッジで接続する構成が一般的である。   For example, when a system is constructed by a CPU (Central Processing Unit) as a bus master and a plurality of bus slaves that provide various functions, they are not connected by a single bus. The main reason is that the data transfer performance differs for each bus slave. For this reason, a bus slave with high transfer performance, a CPU and a DMA controller are connected to a high-speed bus, a bus slave with low transfer performance is connected to a low-speed bus, and the high-speed bus and low-speed bus are connected by a bus bridge. Is common.

この構成において、データがDMA転送される場合、当該転送が低速バスで完結するにもかかわらず、DMA転送が高速バスを介して制御されるので、DMAコントローラによって高速バスが占有される。このため、CPUによるデータ転送が実行できず、高速バスの利用効率が低下する。
そこで、DMA転送が低速バスで完結する場合には、高速バスを切り離すとともに、DMAコントローラにおける処理をバスブリッジに移行させる技術が知られている(特許文献1参照)。この技術では、低速バスで完結するデータ転送をバスブリッジに実行させる。これにより、DMAコントローラは、別の転送処理を実行するので、高速バスの利用効率の低下が防止される。
In this configuration, when data is DMA-transferred, the DMA controller occupies the high-speed bus because DMA transfer is controlled via the high-speed bus even though the transfer is completed by the low-speed bus. For this reason, data transfer by the CPU cannot be executed, and the utilization efficiency of the high-speed bus is reduced.
Therefore, a technique is known in which when the DMA transfer is completed with a low-speed bus, the high-speed bus is disconnected and the processing in the DMA controller is transferred to the bus bridge (see Patent Document 1). In this technology, the data transfer that is completed by the low-speed bus is executed by the bus bridge. As a result, the DMA controller executes another transfer process, thereby preventing a reduction in the utilization efficiency of the high-speed bus.

特許第3328246号Japanese Patent No. 3328246

しかしながら、上記技術において、バスブリッジを介して高速バスおよび低速バスの双方を使用したデータ転送は、低速バスの転送性能に律速されてしまう。すなわち、高速バスでは、より高速なデータ転送が可能であるにもかかわらず、低速バスの転送性能以上でデータを転送することができないのである。このため、高速バスの占有時間が長くなり、システム全体でみたときの効率が低下する、という問題があった。   However, in the above technique, data transfer using both the high-speed bus and the low-speed bus via the bus bridge is limited by the transfer performance of the low-speed bus. In other words, the high-speed bus cannot transfer data at a speed higher than that of the low-speed bus, although it can transfer data at a higher speed. For this reason, the occupation time of the high-speed bus becomes long, and there is a problem that the efficiency when viewed in the whole system is lowered.

一方、近年では、1つの半導体チップに必要とされる一連の機能(モジュールとしてのバススレーブ)を複数集積して、特定の用途に特化したSoC(System on Chip)が知られている。SoCで必要とされるバススレーブの転送性能は、非常に多岐にわたり、複数種類のバスを用いたデータ転送の効率化が要求されている。このため、バスとして、多数の3つ以上のバスを用意しなければならないが、上記技術では、そもそも2種類のバスしか想定されていない。   On the other hand, in recent years, SoC (System on Chip) specialized for a specific application by integrating a plurality of functions (bus slave as a module) required for one semiconductor chip is known. The transfer performance of bus slaves required for SoC is very diverse, and it is required to improve the efficiency of data transfer using a plurality of types of buses. For this reason, a large number of three or more buses must be prepared as buses. However, in the above technique, only two types of buses are assumed in the first place.

本発明は、このような事情に鑑みてなされたものであり、その目的の一つは、転送性能の異なる3つ以上のバスを有する構成において、データの転送効率の改善を図ったDMAコントローラを提供することにある。   The present invention has been made in view of such circumstances, and one of its purposes is to provide a DMA controller that improves data transfer efficiency in a configuration having three or more buses having different transfer performances. It is to provide.

上記目的を達成するために、本発明の一態様に係るDMAコントローラは、ソースアドレスからディスティネーションアドレスにデータを転送するDMAコントローラであって、少なくとも3つ以上のバスに対応して設けられ、それぞれが対応するバスに接続されるマスターポートと、前記バスに接続されたモジュールのアドレスを、当該接続されたバスに対応付けて記憶するアドレステーブルと、当該ソースアドレスのモジュールが属する転送元バスと、当該ディスティネーションアドレスのモジュールが属する転送先バスとを、前記アドレステーブルを参照して特定する特定部と、前記ソースアドレスから前記ディスティネーションアドレスにデータを転送する経路を、前記転送元バス、前記転送元バスに接続されたマスターポート、前記転送先バスに接続されたマスターポート、および、前記転送先バスに設定する転送制御部と、を具備することを特徴とする。   In order to achieve the above object, a DMA controller according to an aspect of the present invention is a DMA controller that transfers data from a source address to a destination address, and is provided corresponding to at least three buses, A master port connected to the corresponding bus, an address table that stores the address of the module connected to the bus in association with the connected bus, a transfer source bus to which the module of the source address belongs, A specifying unit that specifies a transfer destination bus to which the module of the destination address belongs by referring to the address table, a path for transferring data from the source address to the destination address, the transfer source bus, the transfer Master port connected to former bus, front Connected master port to the destination bus, and characterized by comprising a transfer control unit for setting the transfer destination bus.

上記一態様に係るDMAコントローラによれば、ソースアドレスからディスティネーションアドレスへのデータが、転送元バスから転送先バスにダイレクトに転送される。このため、上記一態様によれば、3つ以上のバスを有する構成において、転送元バスおよび転送先バスの間にあるバスや、バス間のバスブリッジを経由させずに、最短経路でデータが転送されるので、テータの転送速度を改善することができる。   According to the DMA controller according to the above aspect, data from the source address to the destination address is directly transferred from the transfer source bus to the transfer destination bus. Therefore, according to the above aspect, in a configuration having three or more buses, data can be transmitted in the shortest path without passing through a bus between the transfer source bus and the transfer destination bus or a bus bridge between the buses. Since the data is transferred, the data transfer speed can be improved.

上記一態様において、前記3つ以上のバスに対応して設けられたマスターポートのうち、少なくとも2つ以上は、互いに異なる転送帯域で、それぞれに対応するバスにデータ転送する構成が好ましい。ここで、転送帯域とは、単位時間において実際に転送可能なデータ量をいい、主にバス幅、動作周波数、レイテンシ(遅延)によって定まる。
また、上記一態様において、前記3つ以上のバスが、バスブリッジを介して直列に接続される構成としても良い。
ここでいう直列に接続される、とは、例えば第1バスから第4バスまでの4つを有するのであれば、第1バスと第2バスとの間にバスブリッジが、第2バスと第3バスとの間にバスブリッジが、第3バスと第4バスとの間にバスブリッジが、それぞれ設けられて、バス間同士のデータ転送が可能な構成をいう。
In the one aspect, it is preferable that at least two or more master ports provided corresponding to the three or more buses are configured to transfer data to buses corresponding to the master ports in different transfer bands. Here, the transfer band refers to the amount of data that can actually be transferred in a unit time, and is mainly determined by the bus width, operating frequency, and latency (delay).
In the above aspect, the three or more buses may be connected in series via a bus bridge.
Here, for example, if there are four buses from the first bus to the fourth bus, the bus bridge is connected between the first bus and the second bus, and the second bus and the second bus. A bus bridge is provided between the three buses and a bus bridge is provided between the third bus and the fourth bus, respectively, so that data can be transferred between the buses.

上記一態様において、前記マスターポートは、リードマスターポートおよびライトマスターポートの組である構成が好ましい。この構成によれば、同じバスにおいてリードマスターポートを介したリード転送と、ライトマスターポートを介したライト転送とが実行可能であるので、DMAコントローラを含むシステム全体の効率を向上させることができる。   In the one aspect, it is preferable that the master port is a set of a read master port and a write master port. According to this configuration, read transfer via the read master port and write transfer via the write master port can be executed on the same bus, so that the efficiency of the entire system including the DMA controller can be improved.

上記一態様において、前記転送元バスおよび転送先バスが同一である場合、当該転送元バスのリードマスターポートを介してリード転送されたデータが、当該転送先バスのライトマスターポートを介してライト転送される構成としても良い。
また、前記3つ以上のバスが、それぞれバスブリッジを介して直列に接続され、前記転送先バスが、前記転送元バスに前記バスブリッジを介して接続されたバスである場合、当該転送元バスまたは当該転送先バスのいずれかに対応するマスターポートと、当該バスブリッジとを介してデータが転送される構成としても良い。
In the above aspect, when the transfer source bus and the transfer destination bus are the same, the data read-transferred through the read master port of the transfer source bus is write-transferred through the write master port of the transfer destination bus. It is good also as a structure made.
When the three or more buses are connected in series via a bus bridge, and the transfer destination bus is a bus connected to the transfer source bus via the bus bridge, the transfer source bus Alternatively, data may be transferred via a master port corresponding to one of the transfer destination buses and the bus bridge.

上記一態様において、前記転送制御部によってデータ転送の機能が割り当てられる転送チャネルを複数有し、前記転送制御部は、前記複数の転送チャネルのうち、一の転送チャネルに、一のソースアドレスから一のディスティネーションアドレスへのデータ転送を割り当てた場合に、当該一のソースアドレスのモジュールが属する転送元バスに接続されたリードマスターポートと、当該一のディスティネーションアドレスのモジュールが属する転送先バスに接続されたライトマスターポートとを、他の転送チャネルによるデータ転送の経路に設定していなければ、当該一の転送チャネルに、割り当てたデータ転送を許可する構成としても良い。
この構成によれば、データ転送が割り当てられた一の転送チャネルは、リードマスターポートとライトマスターポートとが他の転送チャネルに使用されていない限り、データ転送を実行する。
In the above aspect, the transfer control unit has a plurality of transfer channels to which a function of data transfer is assigned, and the transfer control unit assigns one transfer channel to one transfer channel from one source address. When data transfer to the destination address is assigned, the read master port connected to the transfer source bus to which the module with the one source address belongs and the transfer destination bus to which the module with the one destination address belongs If the assigned write master port is not set as a data transfer path by another transfer channel, the assigned data transfer may be permitted to the one transfer channel.
According to this configuration, one transfer channel to which data transfer is assigned performs data transfer unless the read master port and the write master port are used for other transfer channels.

実施形態に係るDMAコントローラを含むシステムの構成を示す図である。It is a figure which shows the structure of the system containing the DMA controller which concerns on embodiment. DMAコントローラの構成を示すブロック図である。It is a block diagram which shows the structure of a DMA controller. DMAコントローラにおけるアドレステーブルの一例を示す図である。It is a figure which shows an example of the address table in a DMA controller. DMAコントローラの動作を示すフローチャートである。It is a flowchart which shows operation | movement of a DMA controller. システムにおけるデータ転送経路の一例を示す図である。It is a figure which shows an example of the data transfer path | route in a system. DMAコントローラにおいて設定された転送経路の一例を示す図である。It is a figure which shows an example of the transfer path | route set in the DMA controller. システムにおけるデータ転送経路の一例を示す図である。It is a figure which shows an example of the data transfer path | route in a system. DMAコントローラにおいて設定された転送経路の一例を示す図である。It is a figure which shows an example of the transfer path | route set in the DMA controller. DMAコントローラにおいて設定された転送経路の一例を示す図である。It is a figure which shows an example of the transfer path | route set in the DMA controller. DMAコントローラにおいて設定された転送経路の一例を示す図である。It is a figure which shows an example of the transfer path | route set in the DMA controller. DMAコントローラにおいて設定された転送経路の一例を示す図である。It is a figure which shows an example of the transfer path | route set in the DMA controller. 比較例のDMAコントローラにおけるデータ転送経路の例を示す図である。It is a figure which shows the example of the data transfer path | route in the DMA controller of a comparative example.

以下、本発明の実施形態について図面を参照して説明する。   Embodiments of the present invention will be described below with reference to the drawings.

図1は、実施形態に係るDMAコントローラ50を含むシステム1の全体の構成を示すブロック図である。
この図に示されるように、システム1は、バス(A)110、バス(B)120、バス(C)130およびバス(D)140と、これらのバスの各々に接続されたDMAコントローラ50と、バス同士を接続するバスブリッジ12、23、34とを含み、各バスには、1または複数のモジュールが次のように接続されている。
FIG. 1 is a block diagram showing an overall configuration of a system 1 including a DMA controller 50 according to the embodiment.
As shown in this figure, the system 1 includes a bus (A) 110, a bus (B) 120, a bus (C) 130 and a bus (D) 140, and a DMA controller 50 connected to each of these buses. The bus bridges 12, 23, and 34 for connecting the buses to each other, and one or a plurality of modules are connected to each bus as follows.

すなわち、バス(A)110には、CPU112、動画デコーダ114、描画エンジン116およびSRAM(Static Random Access Memory)118が接続され、バス(B)120には、DRAM(Dynamic Random Access Memory)122、および、電源が遮断されても、記憶したデータを保持する不揮発性のメモリ124が接続される。また、バス(C)130には、サウンド回路(音源)132が接続され、バス(D)140には、SPI(Serial Peripheral Interface)142、I2C(Inter-Integrated Circuit)144、GPIO(General Purpose Input/Output)146、および、ROM(Read Only Memory)148が接続される。   That is, a CPU 112, a moving picture decoder 114, a rendering engine 116, and an SRAM (Static Random Access Memory) 118 are connected to the bus (A) 110, and a DRAM (Dynamic Random Access Memory) 122, and Even when the power is cut off, a nonvolatile memory 124 that holds stored data is connected. A sound circuit (sound source) 132 is connected to the bus (C) 130, and an SPI (Serial Peripheral Interface) 142, an I2C (Inter-Integrated Circuit) 144, a GPIO (General Purpose Input) is connected to the bus (D) 140. / Output) 146 and ROM (Read Only Memory) 148 are connected.

DMAコントローラ50の詳細については後述するが、バスの各々に対応したマスターポートP1〜P4を有し、マスターポートP1〜P4の各々は、「R」と表記されたリードマスターポートと、「W」と表記されたライトマスターポートとの組をそれぞれ有する。マスターポートP1〜P4のうち、マスターポートP1は、バス(A)110に対応し、同様に、マスターポートP2、P3、P4は、バス(B)120、バス(C)130、バス(D)140に対応する。   Although details of the DMA controller 50 will be described later, each of the master ports P1 to P4 corresponds to each of the buses, and each of the master ports P1 to P4 includes a read master port denoted as “R” and “W”. Each has a pair with a light master port written as. Of the master ports P1 to P4, the master port P1 corresponds to the bus (A) 110. Similarly, the master ports P2, P3, and P4 include the bus (B) 120, the bus (C) 130, and the bus (D). 140.

一方、バス(A)110、バス(B)120、バス(C)130、バス(D)140の各々は、指定されたアドレス(ソースアドレス)のモジュールから読み出されたデータを転送するリードバスと、指定されたアドレス(ディスティネーションアドレス)に書き込むデータを転送するライトバスと、の独立した2つの単方向バスをそれぞれ有する。
なお、各バスにおける動作周波数(転送速度)は、互いに異なっている。図の例では、バスの転送速度は、速い順に、
バス(B)120>バス(A)110>バス(C)130>バス(D)140
となっている。
On the other hand, each of the bus (A) 110, the bus (B) 120, the bus (C) 130, and the bus (D) 140 is a read bus that transfers data read from a module at a specified address (source address). And two independent unidirectional buses each having a write bus for transferring data to be written to a designated address (destination address).
Note that the operating frequencies (transfer rates) in each bus are different from each other. In the example in the figure, the bus transfer speed is ascending order.
Bus (B) 120> Bus (A) 110> Bus (C) 130> Bus (D) 140
It has become.

バス(A)110、バス(B)120、バス(C)130、バス(D)140の各々には、DMAコントローラ50にアクセスするためのポイントApがそれぞれ2つずつ設けられる。2つのポイントApの一方は、対応するマスターポートのリードマスターポートに接続され、他方は、ライトマスターポートに接続される。   Each of the bus (A) 110, the bus (B) 120, the bus (C) 130, and the bus (D) 140 is provided with two points Ap for accessing the DMA controller 50. One of the two points Ap is connected to the read master port of the corresponding master port, and the other is connected to the write master port.

バスブリッジ12は、バス(A)110およびバス(B)120の間において、バスアクセスを双方向に変換する。同様に、バスブリッジ23はバス(B)120およびバス(C)130の間において、また、バスブリッジ34はバス(C)130およびバス(D)140の間において、それぞれバスアクセスを双方向に変換する。このようにして、バス(A)110、バス(B)120、バス(C)130およびバス(D)140は、バスブリッジを介して直列に接続される。   The bus bridge 12 converts the bus access between the bus (A) 110 and the bus (B) 120 in both directions. Similarly, the bus bridge 23 provides bidirectional bus access between the bus (B) 120 and the bus (C) 130, and the bus bridge 34 provides bidirectional bus access between the bus (C) 130 and the bus (D) 140. Convert. In this way, the bus (A) 110, the bus (B) 120, the bus (C) 130, and the bus (D) 140 are connected in series via the bus bridge.

図2は、DMAコントローラ50の構成を示すブロック図である。
図に示されるように、DMAコントローラ50は、上述したマスターポートP1〜P4のほか、転送制御部502、選択部504、特定部512、アドレステーブル514、および、DMAチャネル(転送チャネル)Ch0〜Ch15を含む。
FIG. 2 is a block diagram showing a configuration of the DMA controller 50.
As shown in the figure, in addition to the master ports P1 to P4 described above, the DMA controller 50 includes a transfer control unit 502, a selection unit 504, a specifying unit 512, an address table 514, and DMA channels (transfer channels) Ch0 to Ch15. including.

転送制御部502は、CPU112からDMA転送命令を受け取ったとき、後述する処理を実行して、DMAコントローラ50の各部を制御したり、各部を設定したりする。
DMAチャネルCh0〜Ch15の各々は、それぞれ転送制御部502による制御にしたがって、ソースアドレスから読み出したデータを、図示省略したFIFO(Fast In Fast Out)メモリにバッファリングした上で、ディスティネーションアドレスに転送する。このとき、リードマスターポートからDMAチャネルの入力端までの経路、および、DMAチャネルの出力端からライトマスターポートまでの経路は、それぞれ転送制御部502の制御にしたがって選択部504で設定される。
When the transfer control unit 502 receives a DMA transfer command from the CPU 112, the transfer control unit 502 executes processing described later to control each part of the DMA controller 50 or set each part.
Each of the DMA channels Ch0 to Ch15 buffers the data read from the source address in a FIFO (Fast In Fast Out) memory (not shown) and transfers it to the destination address according to the control by the transfer control unit 502. To do. At this time, the path from the read master port to the input end of the DMA channel and the path from the output end of the DMA channel to the write master port are set by the selection unit 504 according to the control of the transfer control unit 502, respectively.

選択部504は、DMAチャネルCh0〜Ch15の各々における入出力端と、マスターポートP1〜P4におけるリードマスターポートとライトマスターポートとを接続して、DMAコントローラ50での経路を設定する。なお、転送制御部502が経路を設定するために必要な情報を記憶する構成がアドレステーブル514であり、当該アドレステーブル514から必要な情報を特定し、転送制御部502に通知する構成が特定部512である。   The selection unit 504 connects the input / output terminals of each of the DMA channels Ch0 to Ch15 and the read master port and the write master port of the master ports P1 to P4 to set a path in the DMA controller 50. The configuration for storing information necessary for the transfer control unit 502 to set a route is the address table 514. The configuration for identifying the necessary information from the address table 514 and notifying the transfer control unit 502 is the identifying unit. 512.

図3は、アドレステーブル514の内容の一例を示す図である。この図に示されるように、アドレステーブル514では、バス(A)110、バス(B)120、バス(C)130、バス(D)140毎に、接続されたモジュールのアドレス範囲が対応付けられて記憶されている。このため、特定部512が、アドレステーブル514を参照することで、指定されたアドレスのモジュールがどのバスに接続されているのかを特定できるようになっている。
なお、CPU112については、DMA転送を命令するモジュールであり、CPU112自身はDMA転送の対象にならないので、アドレステーブル514の記載対象外となっている。
FIG. 3 is a diagram illustrating an example of the contents of the address table 514. As shown in this figure, in the address table 514, the address range of the connected module is associated with each of the bus (A) 110, the bus (B) 120, the bus (C) 130, and the bus (D) 140. Is remembered. For this reason, the identifying unit 512 refers to the address table 514 to identify which bus the module of the designated address is connected to.
Note that the CPU 112 is a module for instructing DMA transfer, and the CPU 112 itself is not a target of DMA transfer, and thus is not described in the address table 514.

次に、DMAコントローラ50の動作について、図面を参照して説明する。   Next, the operation of the DMA controller 50 will be described with reference to the drawings.

図4は、DMAコントローラ50における転送制御部502の制御内容を示すフローチャートである。
まず、転送制御部502は、DMA転送命令を受け取ったとき、DMAチャネルCh0〜Ch15のうち、未割当のチャネル(空きチャネル)、すなわち、DMA転送に関与していないDMAチャネルがあるか否かを判別する(ステップSa11)。転送制御部502は、空きチャネルがないと判別すれば(ステップSa11の判別結果が「No」であれば)、処理手順をステップSa11に戻す。このため、空きチャネルが発生するまで、転送制御部502は、当該DMA転送命令をステップSa11で待機(キュー)させることになる。
なお、DMA転送を完了したDMAチャネルは、後述するように割当が解除されるので、DMA転送命令を受け取ったときに空きチャネルがなく、判別結果が当初「No」であっても、ステップSa11で待機していれば、やがて「Yes」に転じることになる。
FIG. 4 is a flowchart showing the control contents of the transfer control unit 502 in the DMA controller 50.
First, when receiving a DMA transfer instruction, the transfer control unit 502 determines whether there is an unallocated channel (empty channel) among the DMA channels Ch0 to Ch15, that is, whether there is a DMA channel not involved in the DMA transfer. It discriminate | determines (step Sa11). If the transfer control unit 502 determines that there is no free channel (if the determination result in step Sa11 is “No”), the transfer control unit 502 returns the processing procedure to step Sa11. For this reason, the transfer control unit 502 waits (queues) the DMA transfer instruction in step Sa11 until an empty channel is generated.
Since the DMA channel that has completed the DMA transfer is deallocated as described later, even if there is no empty channel when the DMA transfer command is received and the determination result is initially “No”, in step Sa11 If you are waiting, you will eventually turn to “Yes”.

転送制御部502は、空きチャネルがあると判別すれば(ステップSa11の判別結果が「Yes」であれば)、当該空きチャネルの1つを、当該DMA転送命令を実行させるチャネルとして割り当てる(ステップSa12)。   If the transfer control unit 502 determines that there is an empty channel (if the determination result of step Sa11 is “Yes”), the transfer control unit 502 assigns one of the empty channels as a channel for executing the DMA transfer instruction (step Sa12). ).

次に、転送制御部502は、特定部512に対し、当該DMA転送命令に係るソースアドレスとディスティネーションアドレスとを通知して、転送元バスと転送先バスとの特定を指示する(ステップSa13)。この指示によって特定部512は、アドレステーブル514を参照して、ソースアドレスに対応するバスを転送元バスと特定し、ディスティネーションアドレスに対応するバスを転送先バスと特定して、転送制御部502に返送する。   Next, the transfer control unit 502 notifies the specifying unit 512 of the source address and the destination address related to the DMA transfer instruction, and instructs the specification of the transfer source bus and the transfer destination bus (step Sa13). . With this instruction, the specifying unit 512 refers to the address table 514, specifies the bus corresponding to the source address as the transfer source bus, specifies the bus corresponding to the destination address as the transfer destination bus, and transfers the transfer control unit 502. Return to

転送制御部502は、割り当てたDMAチャネルが特定部512によって特定された転送元バスおよび転送先バスを用いてDMA転送が可能であるか否かを判別する(ステップSa14)。
詳細には、転送制御部502は、転送元バスのリードマスターポートと転送先バスのライトマスターポートとの少なくとも一方が割り当てたDMAチャネル以外の他のDMAチャネルによってDMA転送に使用されていれば、割り当てたDMAチャネルによるDMA転送を不可と判別し(ステップSa14の判別結果を「No」とし)、処理手順をステップSa14に戻す。なお、DMA転送が不可と判別されても、他のDMAチャネルによるDMA転送の完了によって、リードマスターポート、ライトマスターポートが使用されなくなる。このため、ステップSa14の判別結果が当初「No」であっても、当該ステップSa14で待機していれば、やがて「Yes」に転じることになる。
The transfer control unit 502 determines whether the assigned DMA channel is capable of DMA transfer using the transfer source bus and the transfer destination bus specified by the specifying unit 512 (step Sa14).
Specifically, if the transfer control unit 502 is used for DMA transfer by a DMA channel other than the DMA channel assigned by at least one of the read master port of the transfer source bus and the write master port of the transfer destination bus, It is determined that DMA transfer by the assigned DMA channel is not possible (the determination result of step Sa14 is “No”), and the processing procedure is returned to step Sa14. Even if it is determined that the DMA transfer is impossible, the read master port and the write master port are not used when the DMA transfer by another DMA channel is completed. For this reason, even if the determination result in step Sa14 is initially “No”, if the process waits in step Sa14, it will eventually turn to “Yes”.

転送制御部502は、割り当てたDMAチャネルによるDMA転送が可能であると判別すれば(ステップSa14の判別結果が「Yes」であれば)、選択部504に対して次のような経路を設定させる(ステップSa15)。
すなわち、転送制御部502は、割り当てたDMAチャネルの入力端と転送元バスのリードマスターポートとを接続する経路と、当該DMAチャネルの出力端と転送先バスのライトマスターポートとを接続する経路と、を選択部504に設定するように制御する。選択部504は、この制御にしたがった経路を設定する。
If the transfer control unit 502 determines that the DMA transfer by the assigned DMA channel is possible (if the determination result of step Sa14 is “Yes”), the transfer control unit 502 causes the selection unit 504 to set the following route: (Step Sa15).
That is, the transfer control unit 502 includes a path connecting the input end of the assigned DMA channel and the read master port of the transfer source bus, and a path connecting the output end of the DMA channel and the write master port of the transfer destination bus. Are set in the selection unit 504. The selection unit 504 sets a route according to this control.

転送制御部502は、選択部504に対して経路を設定させると、割り当てたDMAチャネルに対してDMA転送を指示する(ステップSa16)。これにより、当該DMAチャネルがDMA転送命令に係るデータのDMA転送を開始する。   When the transfer control unit 502 causes the selection unit 504 to set a route, the transfer control unit 502 instructs the DMA transfer to the assigned DMA channel (step Sa16). As a result, the DMA channel starts DMA transfer of data related to the DMA transfer command.

転送制御部502は、割り当てたDMAチャネルによるDMA転送が終了したか否かを判別する(ステップSa17)。
転送制御部502は、割り当てたDMAチャネルによるDMA転送が進行中であると判別すれば(ステップSa17の判別結果が「No」であれば)、処理手順をステップSa17に戻す。すなわち、当該DMA転送が終了するまで、転送制御部502は、ステップSa17で待機する。
一方、割り当てたDMAチャネルによるDMA転送が終了したと判別すれば(ステップSa17の判別結果が「Yes」であれば)、転送制御部502は、当該DMAチャネルの割り当てを解除する(ステップSa18)。これにより、次のDMA転送命令を受け取ったときに、当該DMAチャネルを割り当てて、次のDMA転送を実行させることができる。
The transfer control unit 502 determines whether or not the DMA transfer by the assigned DMA channel has been completed (step Sa17).
If the transfer control unit 502 determines that the DMA transfer by the assigned DMA channel is in progress (if the determination result of step Sa17 is “No”), the transfer control unit 502 returns the processing procedure to step Sa17. That is, the transfer control unit 502 stands by in step Sa17 until the DMA transfer is completed.
On the other hand, if it is determined that the DMA transfer by the allocated DMA channel has been completed (if the determination result of step Sa17 is “Yes”), the transfer control unit 502 cancels the allocation of the DMA channel (step Sa18). Thus, when the next DMA transfer command is received, the DMA channel can be allocated and the next DMA transfer can be executed.

ステップSa18の後、転送制御部502において、DMA転送命令を受け取ったときの処理が終了する。転送制御部502は、DMA転送命令を受け取る毎に、図4に示した処理を実行する。   After step Sa18, the transfer control unit 502 ends the process when the DMA transfer command is received. The transfer control unit 502 executes the processing shown in FIG. 4 every time it receives a DMA transfer command.

次に、DMA転送の具体例について説明する。図5は、DMA転送によるデータの経路の一例を示す図であり、次のような条件を想定して設定される。詳細には、この例では、当該DMA転送命令において、DMAチャネルCh0が未割当であるために(ステップSa11)、当該DMAチャネルCh0にDMA転送が割り当てられた場合(ステップSa12)を想定している。
また、当該DMA転送命令において、ソースアドレスで示されるモジュール(転送元)がROM148であり、ディスティネーションアドレスで示されるモジュール(転送先)がSRAM118である場合を想定している。この場合、特定部512は、アドレステーブル514を参照して、ソースアドレスに対応する転送元バスがバス(D)140であることを特定し、ディスティネーションアドレスに対応する転送先バスがバス(A)110であることを特定する(ステップSa13)。
Next, a specific example of DMA transfer will be described. FIG. 5 is a diagram showing an example of a data path by DMA transfer, and is set assuming the following conditions. Specifically, in this example, it is assumed that DMA transfer is assigned to the DMA channel Ch0 (step Sa12) because the DMA channel Ch0 is not assigned in the DMA transfer instruction (step Sa11). .
In the DMA transfer instruction, it is assumed that the module (transfer source) indicated by the source address is the ROM 148, and the module (transfer destination) indicated by the destination address is the SRAM 118. In this case, the specifying unit 512 refers to the address table 514 to specify that the transfer source bus corresponding to the source address is the bus (D) 140, and the transfer destination bus corresponding to the destination address is the bus (A ) 110 (step Sa13).

ここで、マスターポートP4のリードマスターポートと、マスターポートP1のライトマスターポートと、の双方が他のDMAチャネルで使用されていなければ(ステップSa14の判別結果が「Yes」であれば)、図6に示されるように、DMAチャネルCh0の入力端がマスターポートP4のリードマスターポートに接続され、DMAチャネルCh0の出力端がマスターポートP1のライトマスターポートに接続されて、DMAコントローラ50内における転送経路が設定される(ステップSa15)。   Here, if both the read master port of the master port P4 and the write master port of the master port P1 are not used in other DMA channels (if the determination result in step Sa14 is “Yes”), FIG. 6, the input end of the DMA channel Ch0 is connected to the read master port of the master port P4, the output end of the DMA channel Ch0 is connected to the write master port of the master port P1, and the transfer in the DMA controller 50 is performed. A route is set (step Sa15).

このように転送経路が設定された状態においてDMAチャネルCh0に転送指示がなされると、当該DMAチャネルCh0は、図5および図6に示されるように、ROM148から読み出したデータを、ROM148→バス(D)140→マスターポートP4のリードマスターポート→DMAチャネルCh0(FIFOメモリ)という経路でリード転送して、一旦、FIFOメモリに蓄積する。このため、DMA転送のうち、ROM148からの読み出しについていえば、ROM148の読出速度またはバス(D)140の転送速度で決定され、他のバスの転送速度の影響を受けない。
一方、蓄積後、DMAチャネルCh0は、FIFOメモリから読み出したデータを、DMAチャネルCh0(FIFOメモリ)→マスターポートP1のライトマスターポート→バス(A)110→SRAM118という経路で、データを転送する。このため、当該DMA転送のうち、SRAM118への書き込みについていえば、SRAM118の書込速度またはバス(A)110の転送速度で決定され、他のバスの転送速度の影響を受けない。
When a transfer instruction is given to the DMA channel Ch0 in the state where the transfer path is set in this way, the DMA channel Ch0 sends the data read from the ROM 148 to the ROM 148 → bus (as shown in FIGS. 5 and 6). D) Read transfer is performed by a route of 140 → read master port of the master port P4 → DMA channel Ch0 (FIFO memory), and temporarily accumulates in the FIFO memory. For this reason, in the DMA transfer, the reading from the ROM 148 is determined by the reading speed of the ROM 148 or the transfer speed of the bus (D) 140 and is not affected by the transfer speed of other buses.
On the other hand, after accumulation, the DMA channel Ch0 transfers the data read from the FIFO memory through a path of DMA channel Ch0 (FIFO memory) → write master port of the master port P1 → bus (A) 110 → SRAM 118. Therefore, in the DMA transfer, the writing to the SRAM 118 is determined by the writing speed of the SRAM 118 or the transfer speed of the bus (A) 110, and is not affected by the transfer speed of other buses.

そして、このような経路によるDMA転送が完了すると(ステップSa17の判別結果が「Yes」になると)、DMAチャネルCh0の割当が解除される(ステップSa18)。これにより、他のDMA転送命令が発行されたとき、DMAチャネルCh0が割当可能となる。   When the DMA transfer through such a path is completed (when the determination result at step Sa17 is “Yes”), the assignment of the DMA channel Ch0 is released (step Sa18). Thereby, when another DMA transfer instruction is issued, the DMA channel Ch0 can be allocated.

次に、本実施形態に係るDMAコントローラ50の優位性について、従来のDMAコントローラと比較して説明する。   Next, the superiority of the DMA controller 50 according to this embodiment will be described in comparison with a conventional DMA controller.

図12は、比較例に係るDMAコントローラを含むシステムの構成を示す図である。図に示されるように、比較例に係るDMAコントローラ52は、1つのバス、この図の例では、バス(C)130のみに接続された構成となっている。このような構成において、DMAコントーラ52を基準とした場合、転送元のバススレーブの位置が遠ければ、それだけリードレイテンシ(遅延)が増加するので、読み出しに係るバスの占有時間が長くなる。同様に、転送先(書込先)のモジュールの位置が遠ければ、それだけライトレイテンシが増加するので、書き込みに係るバスの占有時間が長くなる。バスの占有時間が長くなると、他のバスマスタ(CPU112)のアクセスレイテンシも増加するので、システム全体の効率が低下してしまう。   FIG. 12 is a diagram illustrating a configuration of a system including a DMA controller according to a comparative example. As shown in the figure, the DMA controller 52 according to the comparative example is configured to be connected to only one bus, that is, the bus (C) 130 in this example. In such a configuration, when the DMA controller 52 is used as a reference, the read latency (delay) increases as the transfer source bus slave is farther away, so the bus occupation time for reading becomes longer. Similarly, if the module of the transfer destination (write destination) is far away, the write latency increases accordingly, and the bus occupation time for writing becomes longer. As the bus occupation time increases, the access latency of the other bus master (CPU 112) also increases, and the efficiency of the entire system decreases.

また、リードの転送性能は、転送元のバススレーブの読出性能と、当該バススレーブが接続されたバスと、DMAコントーラ52が接続されたバスと、途中を経由するバスとのうち、転送性能が最も低いバスに律速されてしまう。同様に、ライトの転送性能は、転送先のバススレーブの書込性能と、当該バススレーブが接続されたバスと、DMAコントーラ52が接続されたバスと、途中を経由するバスとのうち、転送性能が最も低いバスに律速されてしまう。   The read transfer performance includes the read performance of the transfer source bus slave, the transfer performance of the bus to which the bus slave is connected, the bus to which the DMA controller 52 is connected, and the bus through the middle. It will be limited to the lowest bus. Similarly, the write transfer performance includes the write performance of the transfer destination bus slave, the bus to which the bus slave is connected, the bus to which the DMA controller 52 is connected, and the bus through the middle. The speed is limited to the bus with the lowest performance.

例えば、この比較例では、DMAコントローラ52が、ROM148からSRAM118にDMA転送する場合、ROM148(リードポート)→バス(D)140→バスブリッジ34→バス(C)130(→DMAコントローラ52)という経路でデータを読み出す。この経路でのリードの転送性能は、ROM148の読出性能が十分に速い場合、バス(C)130の転送性能が高くても、低い方のバス(D)140の転送性能に律速されてしまう。
同様に、DMAコントローラ52は、(DMAコントローラ52→)バス(C)130→バスブリッジ23→バス(B)120→バスブリッジ12→バス(A)110→SRAM118(ライトポート)という経路で、データを書き込む。この経路でのライトの転送性能は、SRAM118の書込性能が十分に速い場合、バス(A)110、バス(B)120の転送性能が高くても、低い方のバス(C)130の転送性能に律速されてしまう。
For example, in this comparative example, when the DMA controller 52 performs DMA transfer from the ROM 148 to the SRAM 118, a path of ROM 148 (read port) → bus (D) 140 → bus bridge 34 → bus (C) 130 (→ DMA controller 52). Read data with. When the read performance of the ROM 148 is sufficiently fast, the read transfer performance on this path is limited by the transfer performance of the lower bus (D) 140 even if the transfer performance of the bus (C) 130 is high.
Similarly, the DMA controller 52 performs data transfer via the path (DMA controller 52 →) bus (C) 130 → bus bridge 23 → bus (B) 120 → bus bridge 12 → bus (A) 110 → SRAM 118 (write port). Write. When the write performance of the SRAM 118 is sufficiently fast, the transfer performance of the write on this path is the transfer of the lower bus (C) 130 even if the transfer performance of the bus (A) 110 and the bus (B) 120 is high. Limited by performance.

これに対して、本実施形態に係るDMAコントローラ50は、データの読出経路としては転送元バスのみが用いられ、データの書込経路としては転送先バスのみが用いられるので、リードの転送性能においても、ライトの転送性能においても、他のバスの転送性能に律速されることはない。
これについて、図5で示した経路のDMA転送で説明すると、データの読出経路としては転送元のバス(D)140のみが用いられる。このため、リードの転送性能において、他のバスの転送性能に律速されることはないので、転送元となるバススレーブの転送性能(読出性能)を最大限に引き出すことができる。
同様に、データの書込経路としては転送先のバス(A)110のみが用いられる。このため、ライトの転送性能において、他のバスの転送性能に律速されることはないので、転送先となるバススレーブの転送性能(書込性能)を最大限に引き出すことができる。
このように、本実施形態に係るDMAコントローラ50によれば、4つのバスを有する構成において、転送元バスから転送先バスに最短経路でデータがDMA転送されるので、テータの転送速度を改善することができる。
On the other hand, in the DMA controller 50 according to the present embodiment, only the transfer source bus is used as the data read path and only the transfer destination bus is used as the data write path. However, the write transfer performance is not limited by the transfer performance of other buses.
This will be explained with reference to the DMA transfer of the path shown in FIG. 5. Only the transfer source bus (D) 140 is used as the data read path. Therefore, the read transfer performance is not limited by the transfer performance of other buses, so that the transfer performance (read performance) of the bus slave that is the transfer source can be maximized.
Similarly, only the transfer destination bus (A) 110 is used as a data write path. For this reason, the write transfer performance is not limited by the transfer performance of other buses, so that the transfer performance (write performance) of the bus slave as the transfer destination can be maximized.
As described above, according to the DMA controller 50 according to the present embodiment, in a configuration having four buses, data is DMA-transferred from the transfer source bus to the transfer destination bus through the shortest path, thereby improving the transfer rate of the data. be able to.

また、本実施形態に係るDMAコントローラ50では、DMAチャネルCh0〜Ch15を有し、DMA転送に割り当てられた各チャネルにおいてDMA転送が可能であれば(ステップSa14の判別結果が「Yes」であれば)、同時並行してDMA転送が実行される。   In addition, the DMA controller 50 according to the present embodiment has DMA channels Ch0 to Ch15, and can perform DMA transfer on each channel assigned to DMA transfer (if the determination result in step Sa14 is “Yes”). ), DMA transfer is executed in parallel.

例えば、DMAチャネルCh0がROM148からSRAM118にDMA転送している状態において(図5参照)、DMAチャネルCh1に対してメモリ124からSPI142へのDMA転送命令が割り当てられたとき、転送元バスのバス(B)120に接続されたマスターポートP2のリードマスターポートと、転送先バスのバス(D)140に接続されたマスターポートP4のライトマスターポートとがいずれもDMAチャネルCh0によって使用されていないので、当該DMAチャネルCh1に対しては転送指示がなされる。
さらに、DMAチャネルCh0、Ch1がDMA転送している状態において、DMAチャネルCh15に対してサウンド回路132からDRAM122へのDMA転送命令が割り当てられたとき、転送元バスのバス(C)130に接続されたマスターポートP3のリードマスターポートと、転送先バスのバス(B)120に接続されたマスターポートP2のライトマスターポートとがいずれも、DMAチャネルCh0、Ch1によって使用されていないので、当該DMAチャネルCh15に対しては転送指示がなされる。
For example, in a state where the DMA channel Ch0 performs DMA transfer from the ROM 148 to the SRAM 118 (see FIG. 5), when a DMA transfer instruction from the memory 124 to the SPI 142 is assigned to the DMA channel Ch1, the bus of the transfer source bus ( B) Since the read master port of the master port P2 connected to 120 and the write master port of the master port P4 connected to the bus (D) 140 of the transfer destination bus are not used by the DMA channel Ch0, A transfer instruction is issued to the DMA channel Ch1.
Further, when a DMA transfer command from the sound circuit 132 to the DRAM 122 is assigned to the DMA channel Ch15 in a state where the DMA channels Ch0 and Ch1 are performing DMA transfer, the DMA channel Ch15 is connected to the bus (C) 130 of the transfer source bus. Since neither the read master port of the master port P3 nor the write master port of the master port P2 connected to the bus (B) 120 of the transfer destination bus is used by the DMA channels Ch0 and Ch1, the DMA channel A transfer instruction is given to Ch15.

図7は、このようにしてDMAチャネルCh0、Ch1、Ch15がDMA転送している場合におけるデータの転送経路を示す図であり、図8は、DMAコントローラ50におおて設定された転送経路を示す図である。
この図に示されるように、本実施形態では、3つのDMA転送が同時並行で実行されるので、システム全体でみたときの効率を、さらに向上させることができる。
また、図7、図8で示されるように、マスターポートP1のリードマスターポートと、マスターポートP3のライトマスターポートとはいずれも使用されていない。このため、転送元バスをバス(A)110とし、転送先バスをバス(C)130とするDMA転送が他のDMAチャネルによって可能となっている。
FIG. 7 is a diagram showing a data transfer path when DMA channels Ch0, Ch1, and Ch15 are DMA-transferred in this way, and FIG. 8 shows a transfer path set in the DMA controller 50. FIG.
As shown in this figure, in this embodiment, since three DMA transfers are executed simultaneously in parallel, the efficiency as viewed in the entire system can be further improved.
Further, as shown in FIGS. 7 and 8, neither the read master port of the master port P1 nor the write master port of the master port P3 is used. For this reason, DMA transfer using the transfer source bus as the bus (A) 110 and the transfer destination bus as the bus (C) 130 is enabled by other DMA channels.

DMAコントローラ50において、転送元バスと転送先バスとが同一であっても良いのはもちろんである。
図9は、DMAコントローラ50が、転送元バスと転送先バスとが同じバス(D)140である場合におけるデータの転送経路の一例を示す図である。この図の例では、いずれかのDMAチャネルが、ROM148からI2C144にDMA転送する場合に、ROM148(リードポート)→バス(D)140(→DMAコントローラ50)という経路でデータを読み出す一方、(DMAコントローラ50→)バス(D)140→バス(D)140→I2C114(ライトポート)という経路でデータを書き込む。
Of course, in the DMA controller 50, the transfer source bus and the transfer destination bus may be the same.
FIG. 9 is a diagram illustrating an example of a data transfer path when the DMA controller 50 has the same bus (D) 140 as the transfer source bus and the transfer destination bus. In the example of this figure, when any DMA channel performs DMA transfer from the ROM 148 to the I2C 144, data is read out through the path of ROM 148 (read port) → bus (D) 140 (→ DMA controller 50), while (DMA Data is written through the path of the controller 50->) bus (D) 140-> bus (D) 140-> I2C 114 (write port).

また、DMAコントローラ50において、いずれかのバスブリッジを介して接続された2つのバスのうち、一方のバスのモジュールから、他方のバスのモジュールにDMA転送する場合、当該バスブリッジを介しても良い。
図10は、バスブリッジ23を介して接続されたバス(B)120、バス(C)130において、バス(C)130に属するサウンド回路132から、バス(B)120に属するメモリ122にDMA転送する場合におけるデータの転送経路を示す図である。この図の例では、いずれかのDMAチャネルが、サウンド回路132(リードポート)→バス(C)130→バスブリッジ23→バス(B)120(→DMAコントローラ50)という経路でデータを読み出す一方、(DMAコントローラ50→)バス(B)130→メモリ122(ライトポート)という経路でデータを書き込む。
In addition, in the DMA controller 50, when two DMA buses connected via one of the bus bridges perform DMA transfer from a module of one bus to a module of the other bus, the bus bridge may be used. .
FIG. 10 shows DMA transfer from the sound circuit 132 belonging to the bus (C) 130 to the memory 122 belonging to the bus (B) 120 in the bus (B) 120 and the bus (C) 130 connected via the bus bridge 23. It is a figure which shows the transfer path | route of the data in the case of doing. In the example of this figure, one of the DMA channels reads data through a path of sound circuit 132 (read port) → bus (C) 130 → bus bridge 23 → bus (B) 120 (→ DMA controller 50), Data is written through a path of (DMA controller 50 →) bus (B) 130 → memory 122 (write port).

なお、この場合に、DMAコントローラ50のマスターポートP2ではなく、図11に示されるように、マスターポートP3を用いても良い。詳細には、同図に示されるように、いずれかのDMAチャネルが、サウンド回路132(リードポート)→バス(C)130(→DMAコントローラ50)という経路でデータを読み出す一方、(DMAコントローラ50→)バス(C)130→バスブリッジ23→バス(B)120→メモリ122(ライトポート)という経路でデータを書き込む。
このように、本説明において、最短経路でデータの転送には、隣り合うバスにわたってバスブリッジを経由する転送を含み得る。
In this case, instead of the master port P2 of the DMA controller 50, the master port P3 may be used as shown in FIG. Specifically, as shown in the figure, one of the DMA channels reads data through the path of the sound circuit 132 (read port) → bus (C) 130 (→ DMA controller 50), while the (DMA controller 50 →) Data is written through the path of bus (C) 130 → bus bridge 23 → bus (B) 120 → memory 122 (write port).
Thus, in this description, the transfer of data through the shortest path can include a transfer via a bus bridge across adjacent buses.

本発明は、上述した実施形態に限定されるものではなく、例えば次に述べるような各種の応用・変形が可能である。また、次に述べる応用・変形の態様は、任意に選択された一または複数を適宜に組み合わせることもできる。   The present invention is not limited to the above-described embodiments, and various applications and modifications as described below are possible, for example. In addition, one or more arbitrarily selected aspects of application / deformation described below can be appropriately combined.

上述した実施形態では、バス幅については言及していなかったが、バス(A)110、バス(B)120、バス(C)130およびバス(D)140のバス幅については、互いに異なっていても良い。なお、バス幅が異なっている場合のバス幅変換については、DMAコントローラ50(またはバスブリッジ12、23、34)が実行することになる。
また、実施形態では、DMAコントローラ50に接続されたバス数(およびマスターポート数)を「4」としたが、「3」以上であれば良い。3つ以上のバスにおいて、少なくとも2つのバスの転送帯域が異なっていれば良い。
In the above-described embodiment, the bus width is not mentioned, but the bus widths of the bus (A) 110, the bus (B) 120, the bus (C) 130, and the bus (D) 140 are different from each other. Also good. Note that the DMA controller 50 (or the bus bridges 12, 23, and 34) executes the bus width conversion when the bus widths are different.
In the embodiment, the number of buses (and the number of master ports) connected to the DMA controller 50 is “4”, but may be “3” or more. It is sufficient that at least two buses have different transfer bands in three or more buses.

50…DMAコントローラ、110…バス(A)、112…CPU、120…バス(B)、122…DRAM、124…メモリ、130…バス(C)、132…サウンド回路、140…バス(D)、142…SPI、148…ROM、502…転送制御部、504…選択部、512…特定部、514…アドレステーブル。
50 ... DMA controller, 110 ... bus (A), 112 ... CPU, 120 ... bus (B), 122 ... DRAM, 124 ... memory, 130 ... bus (C), 132 ... sound circuit, 140 ... bus (D), 142 ... SPI, 148 ... ROM, 502 ... transfer control unit, 504 ... selection unit, 512 ... identification unit, 514 ... address table.

Claims (7)

ソースアドレスからディスティネーションアドレスにデータを転送するDMAコントローラであって、
少なくとも3つ以上のバスに対応して設けられ、それぞれが対応するバスに接続されるマスターポートと、
前記バスに接続されたモジュールのアドレスを、当該接続されたバスに対応付けて記憶するアドレステーブルと、
当該ソースアドレスのモジュールが属する転送元バスと、当該ディスティネーションアドレスのモジュールが属する転送先バスとを、前記アドレステーブルを参照して特定する特定部と、
前記ソースアドレスから前記ディスティネーションアドレスにデータを転送する経路を、前記転送元バス、前記転送元バスに接続されたマスターポート、前記転送先バスに接続されたマスターポート、および、前記転送先バスに設定する転送制御部と、
を具備することを特徴とするDMAコントローラ。
A DMA controller for transferring data from a source address to a destination address,
A master port provided corresponding to at least three or more buses, each connected to a corresponding bus;
An address table for storing addresses of modules connected to the bus in association with the connected bus;
A specifying unit that specifies a transfer source bus to which the module of the source address belongs and a transfer destination bus to which the module of the destination address belongs by referring to the address table;
A path for transferring data from the source address to the destination address is transferred to the transfer source bus, a master port connected to the transfer source bus, a master port connected to the transfer destination bus, and the transfer destination bus. A transfer control unit to be set;
A DMA controller comprising:
前記3つ以上のバスに対応して設けられたマスターポートのうち、少なくとも2つ以上は、互いに異なる転送帯域で、それぞれに対応するバスにデータ転送する
ことを特徴とする請求項1に記載のDMAコントローラ。
2. The master port provided corresponding to the three or more buses, at least two or more of them transfer data to the buses corresponding to each of them in different transfer bands. DMA controller.
前記3つ以上のバスが、バスブリッジを介して直列に接続される
ことを特徴とする請求項1または2に記載のDMAコントローラ。
The DMA controller according to claim 1, wherein the three or more buses are connected in series via a bus bridge.
前記マスターポートは、
リードマスターポートおよびライトマスターポートの組である、
ことを特徴とする請求項1または2に記載のDMAコントローラ。
The master port is
A set of read master port and write master port,
The DMA controller according to claim 1 or 2, characterized in that
前記転送元バスおよび転送先バスが同一である場合、
当該転送元バスのリードマスターポートを介してリード転送されたデータが、当該転送先バスのライトマスターポートを介してライト転送される、
ことを特徴とする請求項4に記載のDMAコントローラ。
When the transfer source bus and the transfer destination bus are the same,
Data read-transferred through the read master port of the transfer source bus is write-transferred through the write master port of the transfer destination bus.
The DMA controller according to claim 4.
前記3つ以上のバスが、それぞれバスブリッジを介して直列に接続され、
前記転送先バスが、前記転送元バスに前記バスブリッジを介して接続されたバスである場合、当該転送元バスまたは当該転送先バスのいずれかに対応するマスターポートと、当該バスブリッジとを介してデータが転送される、
ことを特徴とする請求項4に記載のDMAコントローラ。
The three or more buses are connected in series via a bus bridge,
When the transfer destination bus is a bus connected to the transfer source bus via the bus bridge, a master port corresponding to either the transfer source bus or the transfer destination bus and the bus bridge Data is transferred,
The DMA controller according to claim 4.
前記転送制御部によってデータ転送の機能が割り当てられる転送チャネルを複数有し、
前記転送制御部は、
前記複数の転送チャネルのうち、一の転送チャネルに、一のソースアドレスから一のディスティネーションアドレスへのデータ転送を割り当てた場合に、
当該一のソースアドレスのモジュールが属する転送元バスに接続されたリードマスターポートと、当該一のディスティネーションアドレスのモジュールが属する転送先バスに接続されたライトマスターポートとを、他の転送チャネルによるデータ転送の経路に設定していなければ、
当該一の転送チャネルに、割り当てたデータ転送を許可する、
ことを特徴とする請求項4、5または6に記載のDMAコントローラ。
A plurality of transfer channels to which data transfer functions are assigned by the transfer control unit;
The transfer control unit
When data transfer from one source address to one destination address is assigned to one transfer channel among the plurality of transfer channels,
Data by another transfer channel is transmitted between the read master port connected to the transfer source bus to which the module with the one source address belongs and the write master port connected to the transfer destination bus to which the module with the one destination address belongs. If it is not set as the transfer route,
Allow the assigned data transfer to the one transfer channel,
The DMA controller according to claim 4, 5 or 6.
JP2014106365A 2014-05-22 2014-05-22 DMA controller Expired - Fee Related JP6364951B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2014106365A JP6364951B2 (en) 2014-05-22 2014-05-22 DMA controller

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2014106365A JP6364951B2 (en) 2014-05-22 2014-05-22 DMA controller

Publications (2)

Publication Number Publication Date
JP2015222487A true JP2015222487A (en) 2015-12-10
JP6364951B2 JP6364951B2 (en) 2018-08-01

Family

ID=54785458

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2014106365A Expired - Fee Related JP6364951B2 (en) 2014-05-22 2014-05-22 DMA controller

Country Status (1)

Country Link
JP (1) JP6364951B2 (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH11232212A (en) * 1998-02-09 1999-08-27 Mitsubishi Electric Corp Bus system
JP2004213142A (en) * 2002-12-27 2004-07-29 Renesas Technology Corp Semiconductor integrated circuit device
JP2006318139A (en) * 2005-05-11 2006-11-24 Matsushita Electric Ind Co Ltd Data transfer device, data transfer method and program
JP2007299237A (en) * 2006-04-28 2007-11-15 Toshiba Corp Information transfer device, and information transfer method
JP2008165463A (en) * 2006-12-28 2008-07-17 Sharp Corp Bus controller
US20090125648A1 (en) * 2007-11-14 2009-05-14 Yin-Hsi Huang Direct memory access system and method

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH11232212A (en) * 1998-02-09 1999-08-27 Mitsubishi Electric Corp Bus system
JP2004213142A (en) * 2002-12-27 2004-07-29 Renesas Technology Corp Semiconductor integrated circuit device
JP2006318139A (en) * 2005-05-11 2006-11-24 Matsushita Electric Ind Co Ltd Data transfer device, data transfer method and program
JP2007299237A (en) * 2006-04-28 2007-11-15 Toshiba Corp Information transfer device, and information transfer method
JP2008165463A (en) * 2006-12-28 2008-07-17 Sharp Corp Bus controller
US20090125648A1 (en) * 2007-11-14 2009-05-14 Yin-Hsi Huang Direct memory access system and method

Also Published As

Publication number Publication date
JP6364951B2 (en) 2018-08-01

Similar Documents

Publication Publication Date Title
US9426099B2 (en) Router, method for controlling router, and program
JP6880402B2 (en) Memory access control device and its control method
JP2006318139A (en) Data transfer device, data transfer method and program
US9961005B2 (en) Bus system and computer program
US9471521B2 (en) Communication system for interfacing a plurality of transmission circuits with an interconnection network, and corresponding integrated circuit
JP6146128B2 (en) Data processing device
KR20130106392A (en) Allocation of memory buffers in computing system with multiple memory channels
KR20120040535A (en) Bus system and operating method thereof
TWI704488B (en) Network device, memory system for the network device, and method for operating the network device
KR20180030985A (en) Method and system for USB 2.0 bandwidth reservation
JP2016173798A (en) Semiconductor device
US8495268B2 (en) Card host LSI and set device including the same
US9146693B2 (en) Storage control device, storage system, and storage control method
US20120198173A1 (en) Router and many-core system
JP2005084907A (en) Memory band control unit
JP6364951B2 (en) DMA controller
JP4789269B2 (en) Vector processing apparatus and vector processing method
JP2009116702A (en) Semiconductor integrated circuit
JP6611011B2 (en) Communication input / output device
WO2013062109A1 (en) I/o device control system and method for controlling i/o device
KR20110127707A (en) Memory control device and method for controlling same
KR20140076839A (en) Semiconductor memory system and operating method thereof
US9747231B2 (en) Bus access arbiter and method of bus arbitration
JP6978670B2 (en) Arithmetic processing unit and control method of arithmetic processing unit
US7519848B2 (en) Data transfer apparatus

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20170324

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20180209

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20180227

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20180417

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20180605

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20180618

R151 Written notification of patent or utility model registration

Ref document number: 6364951

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R151

LAPS Cancellation because of no payment of annual fees