JP2000148658A - Dma transfer system - Google Patents

Dma transfer system

Info

Publication number
JP2000148658A
JP2000148658A JP10322314A JP32231498A JP2000148658A JP 2000148658 A JP2000148658 A JP 2000148658A JP 10322314 A JP10322314 A JP 10322314A JP 32231498 A JP32231498 A JP 32231498A JP 2000148658 A JP2000148658 A JP 2000148658A
Authority
JP
Japan
Prior art keywords
address
register
data
dma transfer
dma
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
JP10322314A
Other languages
Japanese (ja)
Inventor
Atsuki Muramatsu
篤樹 村松
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 JP10322314A priority Critical patent/JP2000148658A/en
Publication of JP2000148658A publication Critical patent/JP2000148658A/en
Pending legal-status Critical Current

Links

Landscapes

  • Debugging And Monitoring (AREA)
  • Bus Control (AREA)

Abstract

PROBLEM TO BE SOLVED: To avoid the DMA transfer of data to a write-inhibited area in a main storage means and to prevent the data on the memory from being destroyed by providing a storage means stored with an area, to which DMA transfer can be carried out in the main storage means and performing the DMA transfer to only the area stored in the storage means of the main storage means. SOLUTION: This system is provided with a CPU 10, a main memory 30 as the main storage means, a memory controller 20 as a control means which controls the main memory 30, and a nonvolatile memory 40 as the storage means stored with the area which is usable in the main memory 30 for DMA transfer. In the storage means, the area to which the DMA transfer can be carried out in the main storage means 30 is stored, and the DMA transfer is performed to only the area stored in the storage means of the main storage means 30. Consequently, data will not be transferred by DMA to the write- inhibited area in the main storage means 30, and the data on the memory are prevented from being destroyed.

Description

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

【0001】[0001]

【発明の属する技術分野】本発明は、DMA(Dire
ct Memory Access)転送方式に関す
る。
BACKGROUND OF THE INVENTION 1. Field of the Invention
ct Memory Access) transfer method.

【0002】[0002]

【従来の技術】図5は、一般的なコンピュータシステム
におけるメモリアクセス方式を示す図であり、(a)は
メモリマップトI/O方式におけるメモリアクセスを示
す図、(b)はI/Oアドレス方式とにおけるメモリア
クセスを示す図である。
2. Description of the Related Art FIGS. 5A and 5B show a memory access method in a general computer system. FIG. 5A shows a memory access in a memory mapped I / O method, and FIG. 5B shows an I / O address method. FIG. 6 is a diagram showing memory access in the embodiment.

【0003】図5に示すように、一般的に、コンピュー
タシステムのメモリアクセスにおいては、CPU110
からのアクセスと周辺装置120からのアクセスとがあ
り、この内、周辺装置120からのアクセスにおいて
は、DMA転送があり、メモリマップトI/O方式とI
/Oアドレス方式との2つの方式がある。
As shown in FIG. 5, in general, in a memory access of a computer system, a CPU 110 is used.
There is an access from the peripheral device 120 and an access from the peripheral device 120. Of these, a DMA transfer is used in the access from the peripheral device 120, and the memory-mapped I / O method and the I / O
There are two methods, the / O address method.

【0004】[0004]

【発明が解決しようとする課題】しかしながら、上述し
たようなメモリアクセスにおいては、DMA転送で周辺
装置から主記憶装置への書き込み動作を行う場合、直接
メモリをアクセスするため、MMU(Memory M
anagement Unit)による制御を行うこと
ができない。そのため、ドライバのバグ等の影響で、ア
クセスしてはいけないメモリ空間のアドレスを指定して
そこに周辺装置からのデータを書き込んでしまい、主記
憶装置に記憶されていたデータを破壊してしまう虞れが
ある。
However, in the above-described memory access, when a write operation from a peripheral device to a main storage device is performed by DMA transfer, the memory is directly accessed, so that an MMU (Memory M) is used.
(Analysis Unit) cannot be performed. For this reason, due to a driver bug or the like, there is a possibility that data from a peripheral device is written to an address of a memory space that should not be accessed and data stored in the main storage device is destroyed. There is.

【0005】この時、破壊されてしまうデータがOSや
他のドライバのプログラムであった場合、PANICの
発生等の障害になり、システムダウンが生じてしまう虞
れがある。
[0005] At this time, if the data to be destroyed is an OS or another driver program, it may cause a failure such as the occurrence of a PANIC and cause a system down.

【0006】本発明は、上述したような従来の技術が有
する問題点に鑑みてなされたものであって、メモリ上の
データの破壊を防止することができるDMA転送方式を
提供することを目的とする。
SUMMARY OF THE INVENTION The present invention has been made in view of the above-mentioned problems of the prior art, and has as its object to provide a DMA transfer system capable of preventing data on a memory from being destroyed. I do.

【0007】[0007]

【課題を解決するための手段】上記目的を達成するため
に本発明は、CPU、主記憶手段及び複数の周辺装置が
バスを介して互いに接続され、前記CPU及び複数の周
辺装置からのデータが前記主記憶手段にDMA転送され
るDMA転送方式において、前記主記憶手段内における
前記DMA転送可能な領域が格納された格納手段を有
し、前記DMA転送は、前記格納手段に格納された領域
に対してのみ行われることを特徴とする。
According to the present invention, a CPU, a main storage means and a plurality of peripheral devices are connected to each other via a bus, and data from the CPU and the plurality of peripheral devices are transmitted. In the DMA transfer method in which the DMA transfer is performed to the main storage unit, the DMA transfer method includes a storage unit in which the DMA transferable area in the main storage unit is stored, and the DMA transfer is performed in an area stored in the storage unit. It is performed only for

【0008】また、前記DMA転送を行うデータ領域が
前記格納手段に格納された領域と一致しないものであっ
た場合、前記DMA転送の設定をやり直すことを特徴と
する。
Further, when the data area for performing the DMA transfer does not match the area stored in the storage means, the setting of the DMA transfer is performed again.

【0009】また、前記格納手段は、不揮発性メモリで
あることを特徴とする。
Further, the storage means is a nonvolatile memory.

【0010】また、互いにバスを介して接続されたCP
U、主記憶手段及び複数の周辺装置と、前記主記憶手段
を制御する制御手段とを有し、前記CPU及び複数の周
辺装置からのデータが前記主記憶手段にDMA転送され
るDMA転送方式において、前記制御手段は、予め決め
られた特権領域が格納されたレジスタと、前記CPU及
び複数の周辺装置からDMA転送されたアドレスが入力
されるアドレスレジスタと、前記CPU及び複数の周辺
装置からDMA転送されたデータが入力されるデータレ
ジスタと、前記レジスタに格納された特権領域と前記ア
ドレスレジスタに入力されたアドレスとを比較し、前記
アドレスレジスタに入力されたアドレスが前記レジスタ
に格納された特権領域外であった場合のみ、前記アドレ
スレジスタに入力されたアドレスを出力する検出手段と
を有し、前記データレジスタに入力されたデータのう
ち、前記検出手段から出力されたアドレスを有するデー
タのみが前記主記憶手段に対してDMA転送されること
を特徴とする。
Also, CPs connected to each other via a bus
U, a main storage means, a plurality of peripheral devices, and a control means for controlling the main storage means, wherein the data from the CPU and the plurality of peripheral devices is DMA-transferred to the main storage means. The control means includes: a register storing a predetermined privileged area; an address register receiving an address DMA-transferred from the CPU and the plurality of peripheral devices; and a DMA transfer from the CPU and the plurality of peripheral devices. A data register to which the input data is input, a privileged area stored in the register, and an address input to the address register are compared, and the address input to the address register is compared to the privileged area stored in the register. Detecting means for outputting an address input to the address register only when the address is outside the Among the data input to the register, characterized in that only the data having the address output from said detection means is DMA transferred to the main memory unit.

【0011】また、前記検出手段は、前記アドレスレジ
スタに入力されたアドレスが前記レジスタに格納された
特権領域内であった場合、前記DMA転送を停止すると
ともに前記CPUに対してエラー信号を出力することを
特徴とする。
When the address input to the address register is within a privileged area stored in the register, the detecting means stops the DMA transfer and outputs an error signal to the CPU. It is characterized by the following.

【0012】また、前記検出手段は、前記アドレスレジ
スタに入力されたアドレスが前記レジスタに格納された
特権領域内であった場合、前記データレジスタに入力さ
れたデータのうち、該アドレスを有するデータを破棄す
ることを特徴とする。
[0012] When the address input to the address register is within the privileged area stored in the register, the detecting means may change the data having the address out of the data input to the data register. It is characterized by being discarded.

【0013】(作用)上記のように構成された本発明に
おいては、格納手段内に、主記憶手段内におけるDMA
転送可能な領域が格納されており、DMA転送時には、
主記憶手段の、格納手段に格納された領域に対してのみ
DMA転送が行われるので、主記憶手段内における書き
込み禁止領域にデータがDMA転送されることはなく、
メモリ上のデータの破壊が事前に防止される。
(Operation) In the present invention configured as described above, in the storage means, the DMA in the main storage means is provided.
A transferable area is stored. At the time of DMA transfer,
Since the DMA transfer is performed only to the area of the main storage unit stored in the storage unit, the data is not DMA-transferred to the write-protected area in the main storage unit.
Destruction of data on the memory is prevented in advance.

【0014】また、主記憶手段を制御する制御手段内に
設けられた検出手段において、レジスタに予め格納され
た特権領域とアドレスレジスタに入力されたアドレスと
が比較され、アドレスレジスタに入力されたアドレスが
レジスタに格納された特権領域外であった場合のみ、ア
ドレスレジスタに入力されたアドレスを有するデータが
主記憶手段に転送され、また、アドレスレジスタに入力
されたアドレスがレジスタに格納された特権領域内であ
った場合は、DMA転送が停止されるので、OSやドラ
イバが格納されていて破壊されると困る領域にデータが
DMA転送されることはない。
In the detecting means provided in the control means for controlling the main storage means, the privilege area stored in the register is compared with the address inputted in the address register, and the address inputted in the address register is compared. Is transferred to the main storage means only when the address is outside the privileged area stored in the register, and when the address inputted in the address register is stored in the register. If it is within the range, the DMA transfer is stopped, so that the data is not DMA-transferred to an area where the OS and the driver are stored and are not likely to be destroyed.

【0015】[0015]

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

【0016】(第1の実施の形態)図1は、本発明のD
MA転送方式の第1の実施の形態を示す図である。
(First Embodiment) FIG.
FIG. 2 is a diagram illustrating a first embodiment of an MA transfer method.

【0017】本形態は図1に示すように、CPU10
と、主記憶手段であるメインメモリ30と、メインメモ
リ30を制御する制御手段であるメモリコントローラ2
0と、メインメモリ30においてDMA転送時に使用可
能な領域が格納される格納手段である不揮発性メモリ4
0と、I/Oバス70を介して互いに接続された周辺装
置80a,80bと、CPU10、メモリコントローラ
20及び不揮発性メモリ40を互いに接続するCPU−
メモリバス50と、CPU−メモリバス50とI/Oバ
ス70とを接続するバスブリッジ60とから構成されて
いる。
In this embodiment, as shown in FIG.
A main memory 30 serving as a main storage unit; and a memory controller 2 serving as a control unit for controlling the main memory 30.
0 and a non-volatile memory 4 which is a storage means for storing an area available for DMA transfer in the main memory 30.
0, a peripheral device 80a, 80b connected to each other via an I / O bus 70, and a CPU connecting the CPU 10, the memory controller 20, and the nonvolatile memory 40 to each other.
It comprises a memory bus 50, and a bus bridge 60 connecting the CPU-memory bus 50 and the I / O bus 70.

【0018】以下に、上記のように構成されたDMA転
送方式におけるDMA転送動作について説明する。
Hereinafter, a DMA transfer operation in the DMA transfer system configured as described above will be described.

【0019】図2は、図1に示したDMA転送方式にお
けるDMA転送動作を説明するためのフローチャートで
ある。
FIG. 2 is a flowchart for explaining a DMA transfer operation in the DMA transfer system shown in FIG.

【0020】コンピュータシステムの電源がON状態に
なる等によってスタートすると、まずITFが実行さ
れ、システム内のハードウェアが初期化される(ステッ
プS1)。
When the computer system is started, for example, when the power of the computer system is turned on, the ITF is first executed, and the hardware in the system is initialized (step S1).

【0021】次に、OS(オペレーティングシステム)
がハードデスク等からロードされ、メインメモリ30上
に展開される(ステップS2)。
Next, an OS (operating system)
Is loaded from a hard desk or the like and expanded on the main memory 30 (step S2).

【0022】ステップS2においてメインメモリ30上
にOSが展開されると、次に、コンピュータシステムで
使用されるドライバがメインメモリ30上に展開される
(ステップS3)。
When the OS is loaded on the main memory 30 in step S2, the driver used in the computer system is loaded on the main memory 30 (step S3).

【0023】ここで、OSにおいて、DMA転送時に使
用が許可される領域が不揮発性メモリ40内に格納され
る(ステップS4)。これでコンピュータシステムの準
備が終了し、アプリケーションによる動作を開始するこ
とができる。
Here, in the OS, an area permitted to be used at the time of DMA transfer is stored in the non-volatile memory 40 (step S4). Thus, the preparation of the computer system is completed, and the operation by the application can be started.

【0024】次に、DMA転送により周辺装置80aか
らデータを転送する場合を考える。
Next, consider a case where data is transferred from the peripheral device 80a by DMA transfer.

【0025】システムが起動し(ステップS5)、周辺
装置80aのDMA転送が起動されると(ステップS
6)、周辺装置80aのDMA転送を起動するドライバ
において、ドライバにて使用されるメモリ領域と、OS
によって許可され、不揮発性メモリ40に格納された領
域とがDMA転送前にチェックされる(ステップS
7)。
When the system is started (step S5) and the DMA transfer of the peripheral device 80a is started (step S5).
6) In the driver that starts the DMA transfer of the peripheral device 80a, the memory area used by the driver and the OS
And the area stored in the non-volatile memory 40 is checked before the DMA transfer (step S).
7).

【0026】ステップS7におけるチェックの結果、ド
ライバにて使用される領域と不揮発性メモリ40に格納
された領域とが一致する場合は、周辺装置80aからの
DMA転送が開始され(ステップS8)、次の処理へ移
行する(ステップS9)。
As a result of the check in step S7, if the area used by the driver matches the area stored in the non-volatile memory 40, the DMA transfer from the peripheral device 80a starts (step S8). (Step S9).

【0027】一方、ステップS7におけるチェックの結
果、ドライバにて使用される領域と不揮発性メモリ40
に格納された領域とが一致しない場合は、DMA転送を
行う領域が変更されて再設定が行われ(ステップS1
0)、その後、再度ステップS6に戻り、チェックが行
われる。
On the other hand, as a result of the check in step S7, the area used by the driver and the nonvolatile memory 40
If the area stored in the area does not match, the area for DMA transfer is changed and reset (step S1).
0) Then, the process returns to step S6 again, and a check is performed.

【0028】(第2の実施の形態)図1に示した不揮発
性メモリ40を用いずに本発明を構成することもでき
る。
(Second Embodiment) The present invention can be configured without using the nonvolatile memory 40 shown in FIG.

【0029】図3は、本発明のDMA転送方式の第2の
実施の形態を示す図であり、図1に示した不揮発性メモ
リ40を用いない場合のメモリコントローラ20の構成
例を示す。
FIG. 3 is a diagram showing a second embodiment of the DMA transfer system according to the present invention, and shows a configuration example of the memory controller 20 when the nonvolatile memory 40 shown in FIG. 1 is not used.

【0030】本形態におけるメモリコントローラ20は
図3に示すように、予め決められた特権領域が格納され
たレジスタ21と、CPU−メモリバス50を介してD
MA転送アドレスが入力されるアドレスレジスタ22
と、CPU−メモリバス50を介してDMA転送データ
が入力されるデータレジスタ23と、レジスタ21に格
納された特権領域とアドレスレジスタ22に入力された
アドレスとを比較し、アドレスレジスタ22に入力され
たアドレスがレジスタ21に格納された特権領域外であ
った場合にアドレスレジスタ22に入力されたアドレス
を出力し、アドレスレジスタ22に入力されたアドレス
がレジスタ21に格納された特権領域内であった場合に
エラー信号を出力する検出回路24と、検出回路24か
ら出力されたアドレスをメインメモリ30に対して出力
するメモリアドレスレジスタ25とから構成されてい
る。なお、レジスタ21に格納される特権領域において
は、OSやドライバが格納されていて、破壊されると困
る領域が設定される。
As shown in FIG. 3, the memory controller 20 according to the present embodiment is provided with a register 21 in which a predetermined privileged area is stored, and a memory 21 via a CPU-memory bus 50.
Address register 22 to which MA transfer address is input
And the data register 23 to which the DMA transfer data is input via the CPU-memory bus 50, and compares the privileged area stored in the register 21 with the address input to the address register 22. If the address is outside the privileged area stored in the register 21, the address input to the address register 22 is output, and the address input to the address register 22 is within the privileged area stored in the register 21. A detection circuit 24 outputs an error signal in a case, and a memory address register 25 outputs an address output from the detection circuit 24 to the main memory 30. In the privileged area stored in the register 21, an area in which the OS and the driver are stored and which is difficult to be destroyed is set.

【0031】以下に、上記のように構成されたDMA転
送方式におけるDMA転送動作について図1及び図3を
用いて説明する。
Hereinafter, a DMA transfer operation in the DMA transfer system configured as described above will be described with reference to FIGS.

【0032】図4は、図3に示したメモリコントローラ
を有するDMA転送方式におけるDMA転送動作を説明
するためのフローチャートである。
FIG. 4 is a flowchart for explaining a DMA transfer operation in the DMA transfer system having the memory controller shown in FIG.

【0033】コンピュータシステムの電源がON状態に
なる等によってスタートすると、まずITFが実行さ
れ、システム内のハードウェアが初期化される(ステッ
プS11)。
When the computer system is started, for example, when the power of the computer system is turned on, the ITF is executed first, and the hardware in the system is initialized (step S11).

【0034】次に、OS(オペレーティングシステム)
がハードデスク等からロードされ、メインメモリ30上
に展開される(ステップS12)。
Next, an OS (operating system)
Is loaded from a hard desk or the like and expanded on the main memory 30 (step S12).

【0035】ステップS12においてメインメモリ30
上にOSが展開されると、次に、コンピュータシステム
で使用されるドライバがメインメモリ30上に展開され
る(ステップS13)。
In step S12, the main memory 30
When the OS is expanded on the upper side, the driver used in the computer system is expanded on the main memory 30 (step S13).

【0036】ここで、CPU10において、OSやドラ
イバが格納されていて破壊されると困る領域が特権領域
としてレジスタ21に設定される(ステップS14)。
Here, in the CPU 10, an area in which the OS and the driver are stored and which is not likely to be destroyed is set in the register 21 as a privileged area (step S14).

【0037】次に、DMA転送により周辺装置80aか
らデータを転送する場合を考える。
Next, consider a case where data is transferred from the peripheral device 80a by DMA transfer.

【0038】システムが起動し(ステップS15)、周
辺装置80aのDMA転送が起動されると(ステップS
16)、CPU−メモリバス50に最初のDMA転送ア
ドレスとデータが流れ、アドレスレジスタ22とデータ
レジスタ23にそれぞれ入力される。
When the system is started (step S15) and the DMA transfer of the peripheral device 80a is started (step S15).
16), the first DMA transfer address and data flow through the CPU-memory bus 50, and are input to the address register 22 and the data register 23, respectively.

【0039】次に、検出回路24において、アドレスレ
ジスタ22に入力されたDMA転送アドレスとステップ
S14にて設定された特権領域とが比較され、それによ
り、DMA転送が特権領域へのアクセスかどうかが判断
される(ステップS17)。
Next, in the detection circuit 24, the DMA transfer address input to the address register 22 is compared with the privileged area set in step S14, whereby whether the DMA transfer is an access to the privileged area is determined. It is determined (step S17).

【0040】ステップS17において、アドレスレジス
タ22に入力されたアドレスがレジスタ21に格納され
た特権領域外であった場合は、アドレスレジスタ22に
入力されたアドレスがメインアドレスレジスタ25を介
してメインメモリ30に出力されるとともに、データレ
ジスタ23に入力されたデータがメインメモリ30に出
力され、それにより、メインメモリ30にDMA転送デ
ータが書き込まれ(ステップS18)、次の処理に移行
する(ステップS19)。
In step S17, if the address input to the address register 22 is outside the privileged area stored in the register 21, the address input to the address register 22 is transferred to the main memory 30 via the main address register 25. And the data input to the data register 23 is output to the main memory 30, whereby the DMA transfer data is written to the main memory 30 (step S18), and the process proceeds to the next processing (step S19). .

【0041】一方、ステップS17において、アドレス
レジスタ22に入力されたアドレスがレジスタ21に格
納された特権領域内であった場合は、DMA転送アドレ
スに問題が発生したと認識されてDMA転送が停止する
とともに(ステップS20)、CPU10に対してエラ
ー信号が出力される(ステップS21)。なお、この
時、メインメモリ30に対するデータ書き込み動作は行
われず、CPU−メモリバス50を介してデータレジス
タ23に入力されたデータは破棄される。
On the other hand, in step S17, if the address input to the address register 22 is within the privileged area stored in the register 21, it is recognized that a problem has occurred in the DMA transfer address, and the DMA transfer is stopped. At the same time (step S20), an error signal is output to the CPU 10 (step S21). At this time, the data write operation to the main memory 30 is not performed, and the data input to the data register 23 via the CPU-memory bus 50 is discarded.

【0042】また、転送のシーケンスについては、次の
転送を行うことができるように正常終了し、次のDMA
転送を待機する状態となる。
The transfer sequence ends normally so that the next transfer can be performed, and the next DMA
It is in a state of waiting for transfer.

【0043】これにより、コンピュータシステムをスト
ールさせることなく、メモリ上のOS、ドライバのプロ
グラムを保護することができる。
Thus, the OS and driver programs on the memory can be protected without stalling the computer system.

【0044】[0044]

【発明の効果】以上説明したように本発明においては、
主記憶手段内におけるDMA転送可能な領域が格納され
た格納手段を設け、DMA転送時に、主記憶手段の、格
納手段に格納された領域に対してのみDMA転送が行わ
れる構成としたため、主記憶手段内における書き込み禁
止領域に対するデータのDMA転送を避けることがで
き、それにより、メモリ上のデータの破壊を事前に防止
することができる。
As described above, in the present invention,
A storage unit in which a DMA transferable area is stored in the main storage unit is provided, and the DMA transfer is performed only to the area of the main storage unit stored in the storage unit during the DMA transfer. DMA transfer of data to the write-inhibited area in the means can be avoided, and thereby destruction of data on the memory can be prevented in advance.

【0045】また、主記憶手段を制御する制御手段内
に、レジスタに予め格納された特権領域とアドレスレジ
スタに入力されたアドレスとを比較する検出手段を設
け、アドレスレジスタに入力されたアドレスがレジスタ
に格納された特権領域外であった場合のみ、アドレスレ
ジスタに入力されたアドレスを有するデータが主記憶手
段に転送され、また、アドレスレジスタに入力されたア
ドレスがレジスタに格納された特権領域内であった場合
は、DMA転送が停止する構成としたため、OSやドラ
イバが格納されていて破壊されると困る領域に対するデ
ータのDMA転送を避けることができ、それにより、メ
モリ上のデータの破壊を事前に防止することができる。
In the control means for controlling the main storage means, detection means for comparing the privilege area stored in the register with the address inputted in the address register is provided, and the address inputted in the address register is stored in the register. The data having the address input to the address register is transferred to the main storage means only when the address is outside the privileged area stored in the address area, and the address input to the address register is stored in the privileged area stored in the register. In such a case, the DMA transfer is stopped, so that it is possible to avoid DMA transfer of data to an area where the OS or driver is stored and is not likely to be destroyed. Can be prevented.

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

【図1】本発明のDMA転送方式の第1の実施の形態を
示す図である。
FIG. 1 is a diagram showing a first embodiment of a DMA transfer system according to the present invention.

【図2】図1に示したDMA転送方式におけるDMA転
送動作を説明するためのフローチャートである。
FIG. 2 is a flowchart for explaining a DMA transfer operation in the DMA transfer method shown in FIG.

【図3】本発明のDMA転送方式の第2の実施の形態を
示す図である。
FIG. 3 is a diagram showing a second embodiment of the DMA transfer system of the present invention.

【図4】図3に示したメモリコントローラを有するDM
A転送方式におけるDMA転送動作を説明するためのフ
ローチャートである。
4 is a DM having the memory controller shown in FIG.
5 is a flowchart for explaining a DMA transfer operation in the A transfer method.

【図5】一般的なコンピュータシステムにおけるメモリ
アクセス方式を示す図であり、(a)はメモリマップト
I/O方式におけるメモリアクセスを示す図、(b)は
I/Oアドレス方式とにおけるメモリアクセスを示す図
である。
5A and 5B are diagrams showing a memory access method in a general computer system, wherein FIG. 5A shows a memory access in a memory mapped I / O method, and FIG. 5B shows a memory access in an I / O address method; FIG.

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

10 CPU 20 メモリコントローラ 21 レジスタ 22 アドレスレジスタ 23 データレジスタ 24 検出回路 25 メモリアドレスレジスタ 30 メインメモリ 40 不揮発性メモリ 50 CPU−メモリバス 60 バスブリッジ 70 I/Oバス 80a,80b 周辺装置 10 CPU 20 Memory Controller 21 Register 22 Address Register 23 Data Register 24 Detection Circuit 25 Memory Address Register 30 Main Memory 40 Non-Volatile Memory 50 CPU-Memory Bus 60 Bus Bridge 70 I / O Bus 80a, 80b Peripheral Device

Claims (6)

【特許請求の範囲】[Claims] 【請求項1】 CPU、主記憶手段及び複数の周辺装置
がバスを介して互いに接続され、前記CPU及び複数の
周辺装置からのデータが前記主記憶手段にDMA転送さ
れるDMA転送方式において、 前記主記憶手段内における前記DMA転送可能な領域が
格納された格納手段を有し、 前記DMA転送は、前記格納手段に格納された領域に対
してのみ行われることを特徴とするDMA転送方式。
1. A DMA transfer system in which a CPU, a main storage means, and a plurality of peripheral devices are connected to each other via a bus, and data from the CPU and the plurality of peripheral devices are DMA-transferred to the main storage means. A DMA transfer method, comprising: storage means for storing the DMA transferable area in a main storage means, wherein the DMA transfer is performed only for the area stored in the storage means.
【請求項2】 請求項1に記載のDMA転送方式におい
て、 前記DMA転送を行うデータ領域が前記格納手段に格納
された領域と一致しないものであった場合、前記DMA
転送の設定をやり直すことを特徴とするDMA転送方
式。
2. The DMA transfer method according to claim 1, wherein the data area to be subjected to the DMA transfer does not match the area stored in the storage means.
A DMA transfer method characterized in that transfer settings are redone.
【請求項3】 請求項1または請求項2に記載のDMA
転送方式において、 前記格納手段は、不揮発性メモリであることを特徴とす
るDMA転送方式。
3. The DMA according to claim 1 or 2,
In the transfer method, the storage means is a nonvolatile memory.
【請求項4】 互いにバスを介して接続されたCPU、
主記憶手段及び複数の周辺装置と、前記主記憶手段を制
御する制御手段とを有し、前記CPU及び複数の周辺装
置からのデータが前記主記憶手段にDMA転送されるD
MA転送方式において、 前記制御手段は、 予め決められた特権領域が格納されたレジスタと、 前記CPU及び複数の周辺装置からDMA転送されたア
ドレスが入力されるアドレスレジスタと、 前記CPU及び複数の周辺装置からDMA転送されたデ
ータが入力されるデータレジスタと、 前記レジスタに格納された特権領域と前記アドレスレジ
スタに入力されたアドレスとを比較し、前記アドレスレ
ジスタに入力されたアドレスが前記レジスタに格納され
た特権領域外であった場合のみ、前記アドレスレジスタ
に入力されたアドレスを出力する検出手段とを有し、 前記データレジスタに入力されたデータのうち、前記検
出手段から出力されたアドレスを有するデータのみが前
記主記憶手段に対してDMA転送されることを特徴とす
るDMA転送方式。
4. A CPU connected to each other via a bus,
A main storage unit and a plurality of peripheral devices; and a control unit for controlling the main storage unit. Data from the CPU and the plurality of peripheral devices is DMA-transferred to the main storage unit.
In the MA transfer method, the control means includes: a register storing a predetermined privileged area; an address register receiving an address DMA-transferred from the CPU and a plurality of peripheral devices; A data register to which data transferred by DMA from the device is input, a privileged area stored in the register and an address input to the address register are compared, and an address input to the address register is stored in the register. Detecting means for outputting an address input to the address register only when the address is outside the privileged area, and having an address output from the detecting means among data input to the data register. DMA wherein only data is DMA-transferred to said main storage means. Transmission system.
【請求項5】 請求項4に記載のDMA転送方式におい
て、 前記検出手段は、前記アドレスレジスタに入力されたア
ドレスが前記レジスタに格納された特権領域内であった
場合、前記DMA転送を停止するとともに前記CPUに
対してエラー信号を出力することを特徴とするDMA転
送方式。
5. The DMA transfer system according to claim 4, wherein said detecting means stops said DMA transfer when an address input to said address register is within a privileged area stored in said register. And outputting an error signal to the CPU.
【請求項6】 請求項5に記載のDMA転送方式におい
て、 前記検出手段は、前記アドレスレジスタに入力されたア
ドレスが前記レジスタに格納された特権領域内であった
場合、前記データレジスタに入力されたデータのうち、
該アドレスを有するデータを破棄することを特徴とする
DMA転送方式。
6. The DMA transfer method according to claim 5, wherein the detecting unit is configured to input the address input to the data register when the address input to the address register is within a privileged area stored in the register. Of the data
A DMA transfer method for discarding data having the address.
JP10322314A 1998-11-12 1998-11-12 Dma transfer system Pending JP2000148658A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP10322314A JP2000148658A (en) 1998-11-12 1998-11-12 Dma transfer system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP10322314A JP2000148658A (en) 1998-11-12 1998-11-12 Dma transfer system

Publications (1)

Publication Number Publication Date
JP2000148658A true JP2000148658A (en) 2000-05-30

Family

ID=18142255

Family Applications (1)

Application Number Title Priority Date Filing Date
JP10322314A Pending JP2000148658A (en) 1998-11-12 1998-11-12 Dma transfer system

Country Status (1)

Country Link
JP (1) JP2000148658A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2018092486A (en) * 2016-12-06 2018-06-14 日立オートモティブシステムズ株式会社 Automobile electronic controller and abnormality detection method of dma controller

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2018092486A (en) * 2016-12-06 2018-06-14 日立オートモティブシステムズ株式会社 Automobile electronic controller and abnormality detection method of dma controller

Similar Documents

Publication Publication Date Title
US5951685A (en) Computer system with system ROM including serial-access PROM coupled to an auto-configuring memory controller and method of shadowing BIOS code from PROM
US9798679B2 (en) Information processing device and processor
JPH09171488A (en) Microcontroller for restriction of access to internal memory
JP2000148658A (en) Dma transfer system
US5652837A (en) Mechanism for screening commands issued over a communications bus for selective execution by a processor
JPH1078919A (en) Device for preventing illegal access
JPS58181160A (en) Controlling system of emergency operation
JPH09167117A (en) Microcomputer and real time system using the microcomputer
JPH0317760A (en) Data write confirming system
JP2779300B2 (en) CPU mounted integrated circuit chip and emulator pod
JP3127737B2 (en) Digital signal processor
JP3168845B2 (en) Digital signal processor
JPH09101910A (en) Information processing system
JPH07253931A (en) Destruction prevention system for program data storage area
JP3039479B2 (en) Extended BIOS protection system
JP2000207235A (en) Information processor
JPH05342094A (en) Computer device
JPH10247187A (en) One-chip microcomputer
JPS63250753A (en) Memory access checking system
JPH0782447B2 (en) DMA data transfer control device
JPH03252831A (en) Method for collecting ras information by dma transfer
JPH10333992A (en) Flash memory write data and flash memory loading equipment
JP2001243174A (en) Bus system and wrong operation prevention device for bus system
JPS60112148A (en) Memory device
JPS6227855A (en) Deleting system for initial program loading fixed memory device