JP5380392B2 - Semiconductor device, bus interface device, and computer system - Google Patents
Semiconductor device, bus interface device, and computer system Download PDFInfo
- Publication number
- JP5380392B2 JP5380392B2 JP2010175000A JP2010175000A JP5380392B2 JP 5380392 B2 JP5380392 B2 JP 5380392B2 JP 2010175000 A JP2010175000 A JP 2010175000A JP 2010175000 A JP2010175000 A JP 2010175000A JP 5380392 B2 JP5380392 B2 JP 5380392B2
- Authority
- JP
- Japan
- Prior art keywords
- tlb
- access
- address
- control circuit
- request
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Expired - Fee Related
Links
Images
Landscapes
- Storage Device Security (AREA)
Description
本発明は外部バスインターフェースにてプロセッサ内部の機密情報を保護することのできるマイクロプロセッサに関する。 The present invention relates to a microprocessor capable of protecting confidential information inside a processor with an external bus interface.
特許文献1では、メモリへのデータアクセスを制限するためにメモリインターフェース回路とメモリの間にセキュリティ回路を設け、正しい手順でメモリアクセスが行われているかを監視している。このセキュリティ回路には鍵アドレスが設けてあり、この鍵アドレスに対応する特定の手順でアクセスが発生することで、メモリ空間へアクセス可能な範囲を拡大したり、予測するメモリアクセスからは使用しないメモリ空間を保護しデータ転送が実行されないようにすることが可能であった。また、メモリ保護機能が解除されていないアドレスに対してのアクセスが発生した場合、読み出されたデータの保障は行われないという提案であった。
In
従来は外部メモリ空間のみの保護機能であり、プロセッサ内部メモリのデータに関しては保障されない。また、プロセッサ内部のメモリ空間全てにこの機能を搭載したとすると冗長論理が増大し、プロセッサの肥大化を招いてしまう。 Conventionally, the protection function is only for the external memory space, and the data in the processor internal memory is not guaranteed. Further, if this function is installed in the entire memory space inside the processor, the redundant logic increases, leading to an enlargement of the processor.
また、メモリ空間に対するアドレスの発行順序によって、メモリ保護の合否をハードウェアで行うため、汎用性に乏しい。 Moreover, since the memory protection is accepted or rejected by hardware depending on the address issue order to the memory space, the versatility is poor.
また、保護機能を持たないプロセッサでは、外部バスからプロセッサ内部のレジスタやローカルメモリの読み出しや改変が可能であったため、暗号鍵などの機密データが閲覧されたり、開発したソフトウェアがコピーされてしまう可能性があった。 In addition, because a processor without a protection function can read and modify the internal registers and local memory from the external bus, confidential data such as encryption keys can be browsed or developed software can be copied. There was sex.
本発明はこのような問題を鑑みてなされたものであり、プロセッサが外部デバイスと通信する汎用バスを用いた不正アクセス防止を目的とする。 The present invention has been made in view of such a problem, and an object thereof is to prevent unauthorized access using a general-purpose bus through which a processor communicates with an external device.
この発明に係るプロセッサは、PCIバスなどのプロセッサ外部の汎用バスとプロセッサの内部バスの間でデータ転送を制御するアクセス制御装置と、アクセスできる範囲が格納されているTLBと、TLBの内容を更新するTLB制御回路を具備する。 The processor according to the present invention updates an access control device that controls data transfer between a general-purpose bus outside the processor, such as a PCI bus, and an internal bus of the processor, a TLB in which an accessible range is stored, and the contents of the TLB A TLB control circuit is provided.
プロセッサ内部からのアクセスによってのみTLBを更新するTLB制御回路によってTLBの内容を更新し、その更新した内容はPCIバスなどのプロセッサ外部の汎用バスからのアクセスによって、アクセス制御回路から参照される。 The contents of the TLB are updated by a TLB control circuit that updates the TLB only by access from the inside of the processor, and the updated contents are referred to from the access control circuit by access from a general-purpose bus outside the processor such as a PCI bus.
アクセス制御回路からのリクエストによりTLBはアクセス可能領域であるかどうかをアクセス制御回路へ返答し、その結果によって、内部バスへリクエストを出すか、破棄するかを決定し、プロセッサ内部の機密情報を保護する。 In response to a request from the access control circuit, the TLB responds to the access control circuit as to whether or not it is an accessible area, and based on the result, decides whether to issue a request to the internal bus or discard it, and protects confidential information inside the processor To do.
本発明を適用することで、プロセッサ内部の機密情報や、プロセッサに接続するローカルメモリやフラッシュメモリなど外部メモリの内容を保護し、外部からの不正読み出しを防止することが可能となる。 By applying the present invention, it is possible to protect confidential information inside the processor and the contents of an external memory such as a local memory or a flash memory connected to the processor and prevent unauthorized reading from the outside.
本発明の実施例について図面を参照して説明する。図1に本発明を適用したコンピュータシステムの構成例を示す。なお簡略化のため、本発明の適用と直接関係のない部分は省略する。 Embodiments of the present invention will be described with reference to the drawings. FIG. 1 shows a configuration example of a computer system to which the present invention is applied. For simplification, portions not directly related to the application of the present invention are omitted.
メインCPU1と高速バスインターフェースを持つノースブリッジ3へプロセッサバス2を用いて接続する。ノースブリッジ3は主記憶装置5とメモリバス4で接続し、また低速バスインターフェースを持つサウスブリッジ7とブリッジ間接続バス6を用いて接続する。
The
サウスブリッジ7からPCIバス8へ接続され、PCIバス8上にメディアプロセッサ100a、100bを2個接続している。各々のメディアプロセッサ100a、100bはそれぞれローカルメモリ201a、201bへローカルメモリバス200a、200bを用いて接続する。また、フラッシュメモリ203a、203bへフラッシュメモリバス202a、202bを用いて接続する。尚、本実施例のメディアプロセッサ及びそれに相当する部分は1チップで構成されるが、複数チップにて実現することも可能である。
The south bridge 7 is connected to the PCI bus 8, and two
メディアプロセッサ100a内部は内部バス109を用いて、演算を行うプロセッサコア101、PCIバス8と接続するためのPCIバスインターフェース102、プロセッサコア101の演算補助を行うコプロセッサ103、ローカルメモリへのアクセスを制御するメモリインターフェース104、I/Oインターフェースを制御するI/Oインターフェース105、暗号処理を行う暗号処理演算回路108が接続されている。暗号処理としては、Multi2/DES等がある。また、コプロセッサ103にコプロセッサ用メモリバス107を用いてコプロセッサ用メモリ106へ接続されている。
The
さらに、PCIバスインターフェース102は動作設定を行うためのPCIバスインターフェースPIOレジスタ116を、プロセッサコア101はプロセッサコアPIOレジスタ117を、コプロセッサ103はコプロセッサPIOレジスタ118を、メモリインターフェース104はメモリインターフェースPIOレジスタ119を、I/Oインターフェース105はI/OインターフェースPIOレジスタ120を、暗号処理演算回路108は暗号処理演算回路PIOレジスタ121を、それぞれ持っている。
Further, the
メディアプロセッサ100aのブート時、I/Oインターフェース105がフラッシュメモリ203aからプログラムをロードし、内部バス109を通してプロセッサコア101がそのプログラムを実行することで、まずPCIバスインターフェース102内のTLB制御回路112へTLB書き換えリクエストを発生する。そのリクエストに応じてTLB制御回路112はTLB更新信号115をTLB111へ出すことでTLB111内部を変更し、起動時アクセス可能であったプロセッサ内部と、メディアプロセッサ100aの持つローカルメモリ201aとフラッシュメモリ203aの全領域のうち、ある特定の領域のみをアクセスできるようにする。
When the
メインCPU1からメディアプロセッサ100aへのリードアクセスが発生した場合には、そのリクエスト信号はノースブリッジ3、サウスブリッジ7へと送られ、PCIバス8を通してメディアプロセッサ100a内部のPCIバスインターフェース102が受ける。リクエスト信号を受けたアクセス制御回路110は、リードするアドレスがアクセス可能であるかどうかをTLB111へTLB判定信号113を通して問い合わせる。その信号を受け取ったTLB111は設定されているアドレスと比較し、その合否をTLB合否信号114を通してアクセス制御回路へ返答する。返答がアクセス可能であることを示していた場合、内部バス109へリクエストを出し、目的のデータを引き出し、PCIバス8を通してサウスブリッジ7、ノースブリッジ3を経由しメインCPUへとデータを返す。しかし、アクセスできない領域へのリードリクエストであった場合にはアクセス制御回路110は不定のデータをメインCPU1へ返す。
When a read access from the
また、ライトリクエストがメインCPU1からメディアプロセッサ100aへ出された場合、リードリクエストと同じ経路でPCIバスインターフェース102へと送られる。ライトリクエストを受け取ったアクセス制御回路110は、ライトするアドレスがアクセス可能であるかどうかをTLB111へTLB判定信号113を通して問い合わせる。その信号を受け取ったTLB111は内部のアドレスと比較し、その合否をTLB合否信号114を通してアクセス制御回路へ返答する。返答がアクセス可能であることを示していた場合であり、内部バス109へリクエストを出し、書き換えを行う。しかし、アクセスできない領域へのライトリクエストであった場合にはアクセス制御回路110はその要求を破棄する。
When a write request is issued from the
さらに、他のPCIデバイスであるメディアプロセッサ100bからのリードリクエストやライトリクエストも、メインCPU1からのアクセスと同様に判定が行われアクセス制限が行われる。
Further, read requests and write requests from the
特に、TLB111の変更はプロセッサコア101からのみ変更可能であり、メインCPU1や他のPCIデバイスからの変更は一切行うことができない。
In particular, the TLB 111 can be changed only from the
図2は汎用バスインターフェース123を持つメディアプロセッサ126の構成図である。汎用バスインターフェースとはアドレスバスとデータバス、リクエストなどの制御信号を持つバスである。リードリクエストとアドレスを発行することでデータバスに、要求したアドレスのデータを得ることができ、また、ライトリクエストとアドレスを発行し、データバスに書き込むデータを送信することで、変更するアドレスのデータを書き換えることができる。
FIG. 2 is a configuration diagram of the
メディアプロセッサ126は内部バス109を持ち、その内部バス109にプロセッサコア101、コプロセッサ103、メモリインターフェース104、I/Oインターフェース105、暗号処理演算回路108、汎用バスインターフェース123が接続されている。コプロセッサ103はコプロセッサ用メモリバス107を用いてコプロセッサ用メモリ106へ接続、メモリインターフェース104はローカルメモリバス200を用いてローカルメモリ201へ接続、I/Oインターフェース105はフラッシュメモリバス202を用いてフラッシュメモリ203へ接続している。
The
さらに、汎用バスインターフェース123は動作設定を行うための汎用バスインターフェースPIOレジスタ116を、プロセッサコア101はプロセッサコアPIOレジスタ117を、コプロセッサ103はコプロセッサPIOレジスタ118を、メモリインターフェース104はメモリインターフェースPIOレジスタ119を、I/Oインターフェース105はI/OインターフェースPIOレジスタ120を、暗号処理演算回路108は暗号処理演算回路PIOレジスタ121を、それぞれ持っている。
Furthermore, the general-
メディアプロセッサ126がブートすることで、フラッシュメモリ203からI/Oインターフェース105がブートプログラムを内部バス109を通してプロセッサコア101へ送る。そのプログラムによってプロセッサコア101より内部バス109を用いてTLB制御回路112へTLB書き換えリクエストを発生し、汎用バスインターフェース123内のTLB111を更新する。その更新によって、起動時アクセス可能であったプロセッサ内部と、メディアプロセッサ102の持つローカルメモリ201とフラッシュメモリ203の全領域のうち、ある特定の領域のみをアクセスできるようにする。
When the
汎用バス122を用いてメディアプロセッサ126と通信を行う汎用プロセッサ125は汎用プロセッサ用フラッシュメモリ127を汎用プロセッサ用フラッシュメモリバス128を用いて接続されており、また汎用プロセッサ用ローカルメモリ129と汎用プロセッサ用ローカルメモリバス130を用いて接続している構成である。この汎用プロセッサ125からメディアプロセッサ126へのリードリクエストによりアクセス制御回路124が、リードするアドレスがアクセス可能であるかどうかをTLB111へTLB判定信号113を通して問い合わせる。その信号を受け取ったTLB111は設定されているアドレスと比較し、その合否をTLB合否信号114を通してアクセス制御回路へ返答する。返答がアクセス可能であることを示していた場合、内部バス109へリクエストを出し、目的のデータを引き出し、汎用バス122を通して汎用プロセッサ125へ返答する。
The general-
また、ライトリクエストが汎用プロセッサ125からメディアプロセッサ126へ出された場合、リードリクエストと同様にアクセス可能領域であるかどうかを判定する。判定の結果、アクセス可能である場合には内部バス109を通して目的のアドレスを書き換えるが、アクセス禁止領域の場合にはライトデータは書き込まれず破棄される。
Further, when a write request is issued from the general-
特に、TLB111の変更はプロセッサコア101からのみ変更可能であり、汎用プロセッサ125からの変更は一切行うことができない。
In particular, the
演算専用のデジタルシグナルプロセッサ(以下DSP)131に本発明を採用した実施例を図3に示す。 FIG. 3 shows an embodiment in which the present invention is applied to a digital signal processor (hereinafter referred to as DSP) 131 dedicated to computation.
DSP131は、内部バス109を持ち、その内部バス109に演算を行うプロセッサコア101、メモリインターフェース104、I/Oインターフェース105、汎用バスインターフェース123が接続されている。メモリインターフェース104はローカルメモリバス200を用いてローカルメモリ201へ接続、I/Oインターフェース105はフラッシュメモリバス202を用いてフラッシュメモリ203へ接続している。
The
汎用バスインターフェース123は動作設定を行うための汎用バスインターフェースPIOレジスタ116を、プロセッサコア101はプロセッサコアPIOレジスタ117を、メモリインターフェース104はメモリインターフェースPIOレジスタ119を、I/Oインターフェース105はI/OインターフェースPIOレジスタ120を、それぞれ持っている。
The general-
汎用バスインターフェース122にはホストCPUとなる汎用プロセッサ125が接続されており、その汎用プロセッサ125には汎用プロセッサ用フラッシュメモリ127が汎用プロセッサ用フラッシュメモリ128を用いて接続され、また汎用プロセッサ用ローカルメモリ129が汎用プロセッサ用ローカルメモリバス130を用いて接続されている。この汎用プロセッサ125から、通常全てのDSP131内部へアクセスすることが可能であり、このとき、DSP131は汎用プロセッサフラッシュメモリからプログラムをロードしてブートし、DSP131の初期設定もあわせて行う。初期設定が完了し、DSP131は内部バス109から、I/Oインターフェース105を通してフラッシュメモリ203から汎用バスインターフェース123内のTLB111の設定を行う。プロセッサコア101からのTLB書き換えリクエストを受けたTLB制御回路112はTLB更新信号115をTLB111へ出すことでTLB111内部を変更し、起動時にアクセス可能であったDSP内部と、DSP131の持つローカルメモリ201とフラッシュメモリ203の全領域のうち、ある特定の領域のみをアクセスできるようにする。
A general-
この汎用プロセッサ125からDSP131へのリードリクエストによりアクセス制御回路124が、リードするアドレスがアクセス可能であるかどうかをTLB111へTLB判定信号113を通して問い合わせる。その信号を受け取ったTLB111は設定されているアドレスと比較し、その合否をTLB合否信号114を通してアクセス制御回路へ返答する。返答がアクセス可能であることを示していた場合、内部バス109へリクエストを出し、目的のデータを引き出し、汎用バス122を通して汎用プロセッサ125へ返答する。
In response to a read request from the general-
また、ライトリクエストが汎用プロセッサ125からDSP131へ出された場合、リードリクエストと同様にアクセス可能領域であるかどうかを判定する。判定の結果、アクセス可能である場合には内部バス109を通して目的のアドレスを書き換えるが、アクセス禁止領域の場合にはライトデータは書き込まれず破棄される。
Further, when a write request is issued from the general-
図4は外部バス140と内部バス141を接続するためのバスインターフェース回路に本発明を適応した構成図を示したものである。
FIG. 4 shows a configuration diagram in which the present invention is applied to a bus interface circuit for connecting the
アクセス制御回路124は外部バス140と内部バス141へ接続されており、双方のバス間のデータ転送を行う。アクセス制御回路124からアクセス可能であるかどうかを調査するために照会アドレス142を用いてTLB111へ接続する。それを受けたTLB111はアクセス可能であるかどうかの合否判定を行い、その結果であるTLB合否信号143と、TLB111を用いてアドレス変換を行った結果のアドレス144をアクセス制御回路124へ送る。その結果を用いてアクセス制御回路は内部バス141へのリクエストを出力する。また、内部バス141を通してのみTLB111は書き換え可能であるため、内部バス141からのTLB更新要求をTLB制御回路147が受け、TLB更新信号145とTLB111内のどのエントリを変更するかを通知するアドレスをエントリアドレス146を通して、TLB111へ送る。送られてきたアドレスを元にTLB111内部を更新し、アクセスの制限を行うことが可能となる。
The
ここで、TLB更新要求はプロセッサコア101から発行される。また、上記TLB更新要求は、アクセス制御回路にも送信されるが、内部バスのアドレスからアクセス制御回路とTLB制御回路のどちらかへの要求と判断される。
Here, the TLB update request is issued from the
図5は図4とは別の実現方法で本発明を適応した実施例を示したものである。アクセス制御回路150は外部バス151と内部バス152へ接続されており、双方のバス間のデータ転送を行う。許可ビット制御回路161は内部バス152に接続されたプロセッサコア等からのリクエストを随時受け付けており、外部バス151からのアクセスの制限を変更したい場合に要求が送られる。
FIG. 5 shows an embodiment in which the present invention is applied by a method different from that shown in FIG. The
まず、外部バス151からリード、もしくはライトリクエストにより、アドレスがアクセス制御回路150とアクセス判定回路153内部のアドレスデコーダ154へと送られる。アドレスデコーダ154へと送られたアドレスにより領域選択信号155をセレクタ156へ送る。許可ビット群160から許可ビット信号158、159を通してセレクタ156へ常に送られている許可ビット信号の一つを領域選択信号155により、その一つを選択しアクセス合否信号157を通してアクセス制御回路150へ結果を送る。ここで、ビット群は、レジスタ群に格納されたビット情報の意である。その信号を受けたアクセス制御回路150は要求のあったアドレスに対して破棄するかを決定し、アクセス可能領域であるならば内部バス152へリクエストを発生させる。
First, an address is sent from the
また、許可ビット群160の書き換えは内部バス152より発生した書き換え要求を許可ビット制御回路161へ送り、その要求によって変更するビットへ許可ビット変更信号162、163を通して、許可ビット群160を変更する。特に、許可ビット群160の変更は内部バス152からのみ変更可能であり、外部バス151からの変更は一切行うことができない。
Further, the rewriting of the
図6は、アクセス制御のフローチャートである。まず、メディアプロセッサが起動し(400)、TLBの設定401を行う。TLB初期値402からデータを読み出し、TLBの設定を行うが、この初期設定値はフラッシュメモリ等の不揮発性メモリに収められている。TLBの設定401後に、メディアプロセッサは、プログラムの読み込み403において、TLB初期値402同様にフラッシュメモリに収められたプログラム404をメディアプロセッサ自身のローカルメモリへ読み出す。
FIG. 6 is a flowchart of access control. First, the media processor is activated (400) and TLB setting 401 is performed. Data is read from the TLB
そのプログラムを実行中に外部からのアクセス405が発生したかどうかを判定し、発生していない場合はプログラム実行を継続し、発生した場合はTLBの参照406を行う。TLBの参照406の結果、許可領域のアクセス407であるかどうかを判別し、許可領域ではなかった場合はそのリクエストを破棄し、プログラムの実行を継続し、外部からのアクセス405が発生するまで待機する。許可領域のアクセスであった場合にはデータ転送408を行い、リードリクエストであればメモリ409からデータを読み出し、ライトリクエストであればメモリ409へ書き込みを行う。この時のメモリ409はローカルメモリや内部メモリ、内部レジスタが対象となる。
It is determined whether or not an
TLB内部の構造を図7に示す。まず、TLB111内部の情報を書き換えるため、TLB更新信号115を受信する。TLB更新信号115にはTLBエントリデータ300とTLBアドレス301が含まれる。TLBアドレス301の信号はデコーダ302に送信され、デコーダ302で書き換えるべきTLB111のエントリが確定する。そのアドレスに対して、TLBエントリデータ300が書き込まれ、TLB111の内容である有効ビット303、仮想ページ番号304、アクセスサイズ305が更新される。
The internal structure of the TLB is shown in FIG. First, the
更新されたTLB111内の比較器310では、外部からのアクセスによるアクセスアドレス307とTLB111に格納された内容と比較をする。このとき、有効ビット303は有効ビット信号311を通して比較器310へ送られ、有効なエントリとのみ比較を行う。有効なエントリの仮想ページ番号304は、アクセスが許可されるアドレスの先頭番地を示しており、アクセスサイズ305を足した値が終了番地を示している。そのため、これらの信号をそれぞれ仮想ページ番号信号308とアクセスサイズ信号309として比較器310へ送り、アクセスアドレス307がその範囲内のアクセスであるか否かを判定し、比較結果312をエントリ毎に出力する。
The updated
エントリ毎に出力された比較結果312はOR回路313によって論理和をとり、アクセス判定信号314を返す。このような回路によってアクセスの許可、不許可を決定する。
The
さらにアドレス変換機能を持った場合のTLB内部の構造を図8に示す。TLB111内部の情報を書き換えるため、TLB更新信号115があり、その信号はTLBエントリデータ300とTLBアドレス301の信号である。TLBアドレス301の信号をデコーダ302によって書き換えるべきTLB111のエントリが確定する。そのアドレスに対して、TLBエントリデータ300が書き込まれ、TLB111の内容である有効ビット303、仮想ページ番号304、アクセスサイズ305、物理ページ番号316が更新される。尚、本実施例では、上記パラメータを更新すべきパラメータとして選択したが、常に上記パラメータの更新を要するものではない。
Further, FIG. 8 shows the internal structure of the TLB when it has an address conversion function. In order to rewrite information in the
例えば、有効ビットを選択しない場合は、最初はすべて同じデータを物理ページ番号、アクセスサイズに入れておいて、かつ、アクセスサイズは全領域アクセス可能にすることが考えられる。 For example, when a valid bit is not selected, it is conceivable that all the same data is initially placed in the physical page number and the access size, and the access size can be accessed in the entire area.
また、物理ページ番号、アクセスサイズは、始点、終点を示し、どこからどこまでをアクセスできるかを記述しているが、これらのパラメータを選択しない場合は、物理ページ領域を始点として固定領域をアクセス可能にすることも可能である。 In addition, the physical page number and access size indicate the start point and end point, and describe from where to where it can be accessed. If these parameters are not selected, the fixed area can be accessed from the physical page area. It is also possible to do.
更新されたTLB111は外部からのアクセスによるアクセスアドレス307が、比較器310でTLB111の内容と比較をする。このとき、有効ビット303を有効ビット信号311を通して比較器310へ送り、有効なエントリとのみ比較を行う。有効なエントリの仮想ページ番号304は、アクセスが許可されるアドレスの先頭番地を示しており、アクセスサイズ305を足した値が終了番地を示している。そのため、これらの信号をそれぞれ仮想ページ番号信号308とアクセスサイズ信号309として、比較器310へ送り、比較器310ではアクセスアドレス307がその範囲内をアクセスしているかを判定し、比較結果312を各エントリ毎に出力する。この信号はOR回路313と、該当するエントリの物理ページ番号を選択するセレクタ318へ送られる。OR回路313へ送られた比較結果312は論理和をとり、アクセス判定信号314を返す。また、セレクタ318では、n個ある物理ページ番号(PPN)316のうちの一つを選択し、変換後アドレス319を出力する。この変換は、外部バスからのアクセスが発生した場合、外部バス上のアドレスで行われる。そのアドレスはTLB111を搭載するプロセッサ内部のアドレスとは違うため、アドレスの変換を行う必要がある。このアドレス変換でのボトルネックを解消するために物理ページ番号への変換機能を持たせ、プロセッサ内部をアクセスできるアドレスへ高速に変換することが可能である。
The updated
TLB111にアクセス可能領域、不可領域を設定した場合を図9に示す。TLB111内のエントリA330によってローカルメモリ334を参照可能領域に設定している。また、エントリB331によってローカルメモリ336を参照可能領域に設定している。ローカルメモリ335とローカルメモリ337はTLB111によって参照可能領域に設定されていないため、外部からのアクセスは遮断される領域となる。
A case where an accessible area and an inaccessible area are set in the
また、エントリC332によってコプロセッサ用メモリ338の領域を参照することが可能である。しかし、コプロセッサ用メモリ339の領域はTLB111によって参照可能領域に設定されていないため、外部からのアクセスは遮断される。同様に、レジスタマップの領域のうち、エントリD333によってレジスタマップ341が参照可能領域となっている。レジスタマップ341の前後の空間である、レジスタマップ340とレジスタマップ342は参照不可領域であり、プロセッサ外部からのアクセスは遮断され、リード、ライトすることができない。
Further, the area of the
ただし、アクセス不可領域は外部からのアクセスのみ遮断し、プロセッサ内部からは、制限なくアクセスすることができる。 However, the inaccessible area is blocked only from the outside, and can be accessed without restriction from the inside of the processor.
また、図10にはPCIのベースアドレスレジスタ(以下、BAR)を用いてメモリ空間のアクセスできる領域を制限する方法を示す。 FIG. 10 shows a method of limiting the accessible area of the memory space using a PCI base address register (hereinafter referred to as BAR).
まず、PCIのBARを用いてメモリ空間のアクセスできる領域を制限する方法の概要を示す。 First, an outline of a method for limiting the accessible area of the memory space using the PCI BAR will be described.
PCIデバイスには、そのデバイスが必要とするメモリ空間があり、各デバイスによってそのサイズは様々である。現在のPCIの規格ではPCIは4GBのメモリ空間を持っているが、その空間上に、PCIデバイスのメモリ空間を割り当てている。例えば、PCIデバイスAが0x4000のメモリ空間を持っていたとき、PCI空間の0x1000から割り当てると、PCIバス0x1000〜0x4fffをアクセスすると、PCIデバイスAのメモリ空間を操作することが可能となる。ここで、該メモリ空間を設定するときに使用するものがBARであり、デバイス側が必要に応じて自分自身のBARのサイズを変更できるようにするものである。具体的には、PCIデバイスは128MBのメモリを持っていたとき、本来、PCI空間には128MB分の空間を割り当てることができる。しかし、故意に64MBしか割り当てないようにする(実現方法は図10、11)ことで、PCIから残りの64MBを見えないようにすることができる。 A PCI device has a memory space required by the device, and the size varies depending on each device. In the current PCI standard, PCI has a memory space of 4 GB, but the memory space of the PCI device is allocated on the space. For example, when the PCI device A has a memory space of 0x4000, if the PCI device A is allocated from 0x1000 of the PCI space, it is possible to operate the memory space of the PCI device A by accessing the PCI buses 0x1000 to 0x4fff. Here, the BAR is used when setting the memory space, and allows the device side to change the size of its own BAR as necessary. Specifically, when the PCI device has 128 MB of memory, a space of 128 MB can be originally allocated to the PCI space. However, by intentionally allocating only 64 MB (the implementation method is shown in FIGS. 10 and 11), it is possible to hide the remaining 64 MB from the PCI.
例えば、PCIバス上にリクエストが発生したとき、各PCIデバイスはそのリクエストのアドレスをBARの内容と比較し、そのアドレスが自分宛と判断したときに返答をする。つまり、PCIデバイスのPCIインターフェースは設定されたBARとリクエストアドレスを比較し、自分のメモリ空間へのアクセスかを判定している。しかし、BARがあらかじめ64MBしかないと設定されていれば、65MBのアクセスがきたとしても、自分へのアクセスではないと判断する。 For example, when a request occurs on the PCI bus, each PCI device compares the address of the request with the contents of the BAR, and replies when it is determined that the address is addressed to itself. That is, the PCI interface of the PCI device compares the set BAR with the request address to determine whether to access its own memory space. However, if the BAR is set to have only 64 MB in advance, even if 65 MB is accessed, it is determined that it is not access to itself.
次に、PCIのBARを用いてメモリ空間のアクセスできる領域を制限する具体的な方法を示す。 Next, a specific method for restricting the accessible area of the memory space using the PCI BAR will be described.
プロセッサの外部より入力されるBARの領域を指定するBAR設定信号350が、電源が投入、もしくはソフトウェアリセットや外部リセットボタンによるリセットが発生した場合等にデータ保持レジスタ354によって保持される。リセット信号351が論理値1の時にリセット期間であることを表す場合、クロック信号353とともにAND回路352に入力して論理積をとり、リセット信号351が論理値1を取ったときにデータ保持レジスタ354を更新する。保持データ355はデコーダ356によってBARへ送るデータが確定する。
A
確定した信号は、BAR363のnビット目364、n+1ビット目365、n+2ビット目366、n+3ビット目367用にそれぞれデコード結果358、359、360、361をAND回路362へ送る。それらの信号とBAR変更信号357と論理積がとられ、その結果がBAR363のnビット目364、n+1ビット目365、n+2ビット目366、n+3ビット目367に反映される。
The determined signals send
この図10の方法の場合、デコーダ356からデコード結果358、359、360、361へ全て論理値1が出力されていた場合、BAR変更信号357によってnビット目364を含めた上位のビットは変更することが可能である。この領域は、PCI空間へ割り当てられる最小領域であり、メモリ空間は2^nを持つこととなる。このようにして、PCI空間へ最大2^(n+3)の領域を割り当てることが可能である。このような設定ができるプロセッサにおいて2^(n+3)のローカルメモリを持っていたとして、BARへ2^nを設定できるようにする。この場合、番地0〜(2^n−1)まではPCI空間から参照可能であるが、番地(2^n)〜(2^(n+3)−1)まではPCI空間に割り当てられないため、外部のデバイスからは不可視となり、アクセスすることはできない。このような方法を用いてアクセスを抑制することができる。
In the case of the method shown in FIG. 10, when all the
図10のデータ保持レジスタ354をプロセッサ内部から変更する場合を図11に示す。セレクタ369を用いて選択信号370によって、データ保持レジスタ354かプロセッサ内部からのBAR領域を指定するBAR設定信号368を選択する。選択したデータを再度データ保持レジスタ354を更新する。保持データ355はデコーダ356によってBARへ送るデータが確定する。確定した信号は、BAR363のnビット目364、n+1ビット目365、n+2ビット目366、n+3ビット目367用にそれぞれデコード結果358、359、360、361をAND回路362へ送る。それらの信号とBAR変更信号357と論理積がとられ、その結果がBAR363のnビット目364、n+1ビット目365、n+2ビット目366、n+3ビット目367に反映される。
FIG. 11 shows a case where the
つまり、ベース・アドレス・レジスタのある特定のビットを論理値0固定する機能を有するPCIバスインターフェースにおいて、ある特定のベース・アドレス・レジスタのビットを論理値0固定にすることで、PCIデバイスが持つローカルメモリよりも小さいメモリ空間を、PCIバス上のメモリ空間へ割り当て、ローカルメモリを持つPCIデバイス自身は全空間にアクセスすることが可能であるが、それ以外のPCIデバイスはPCIバス上のメモリ空間へ割り当てた小さいメモリ空間にのみアクセスできる。
In other words, in a PCI bus interface having a function of fixing a specific bit of the base address register to a
このような方法によってもBARを変更することが可能であり、アクセス不可領域を指定することが可能である。 The BAR can also be changed by such a method, and an inaccessible area can be designated.
本発明を採用したメディアプロセッサを搭載したセット・トップ・ボックス(以下、STB)を図12に示す。 FIG. 12 shows a set top box (hereinafter referred to as STB) equipped with a media processor employing the present invention.
STB380は、メディアプロセッサ100と、ローカルメモリバス200を用いてローカルメモリ201、フラッシュメモリバス202を用いてフラッシュメモリ203、汎用バス381を用いてサービスポート382が接続、搭載されている。また、本システムはSTBであるため、映像信号の入出力を行うビデオ入出力386、音声信号の入出力を行うオーディオ入出力387、映像信号の解読などに使用する暗号鍵を保持する暗号記憶カードインターフェース信号388、外部の記憶装置と高速にデータ通信を行うための高速デジタルバス389、BSデジタルチューナから映像信号を受けるトランスポート・ストリーム・インターフェース信号390を持つ。
The
また、サービスポート382は故障診断時に保守端末391を接続するためのものであり、サービスポート382と汎用インターフェース信号383を用いて接続する。汎用インターフェース信号383は保守用プロセッサ392と接続されており、保守プロセッサ自身もローカルメモリバス393を用いてローカルメモリ394が接続されている。
The
保守端末391が接続された場合には、STB内部のメモリがリード、ライトできる状態ではなく、ローカルメモリ上のアクセス可能領域385のみ、読み書き可能である。ローカルメモリ上のアクセス不可領域384はSTB380に搭載されているメディアプロセッサ100からのみアクセス可能であり、保守を行う場合はアクセス可能領域385を用いてメディアプロセッサ100と通信を行うこととなる。
When the
このため、保守端末以外がサービスポート382へ接続され、メディアプロセッサ100内の重要なデータである、暗号解読に使用する暗号鍵や、メディアプロセッサ100を動作させるソフトウェアを保護することが可能である。
For this reason, a terminal other than the maintenance terminal is connected to the
また、外部からの不正なアクセスにより、メディアプロセッサ内部の機密事項である暗号鍵やソフトウェアが格納されているメモリへのアクセスを遮断することができ、そのアクセス範囲はアプリケーションによって自由に変更可能である。尚、本実施例でアクセス制限がかかるのは物理的な領域であるが、論理的な領域について制限をかけてもよい。 In addition, unauthorized access from the outside can block access to the encryption key and the memory that stores software, which are confidential matters inside the media processor, and the access range can be freely changed by the application. . In this embodiment, the access restriction is applied to the physical area, but the logical area may be restricted.
本発明は、上述の実施の形態に限定されるものではなく、適用分野に関わらず、要旨を逸脱しない範囲で変更し実施し得ることは述べるまでもない。 The present invention is not limited to the above-described embodiment, and it goes without saying that the present invention can be modified and implemented without departing from the gist, regardless of the application field.
1…メインCPU、3…ノースブリッジ、5…主記憶装置、7…サウスブリッジ、100…メディアプロセッサ、101…プロセッサコア、102…PCIバスインターフェース、110…アクセス制御回路、111…TLB、112…TLB制御回路、125…汎用プロセッサ、131…デジタルシグナルプロセッサ、201…ローカルメモリ、203…フラッシュメモリ、303…有効ビット、304…仮想ページ番号、305…アクセスサイズ、316…物理ページ番号
DESCRIPTION OF
Claims (14)
前記外部バスインターフェースは、前記外部バスからのリクエストを受けるアクセス制御回路と、前記アクセス制御回路に接続され前記外部バスアクセスの可否を判定するTLBと、前記プロセッサコアからの要求により前記TLBを書き換えるTLB制御回路を有し、
前記外部バスからのリクエストを受けたアクセス制御回路は、該リクエストのアドレスが、前記TLB内に設定されたアクセス許可範囲内のアドレスか否か問い合わせるTLB判定信号を前記TLBへ送信し、
前記TLBは、前記リクエストのアドレスが、前記TLB内に設定されたアクセス許可範囲内のアドレスか否かを検索し、アクセス可否を示すTLB合否信号を前記アクセス制御回路へ返答し、
前記アクセス制御回路は、前記TLB合否信号がアクセス可であることを示している場合、前記内部バスへアクセスを許可し、前記TLB合否信号がアクセス否であることを示している場合、前記リクエストを破棄し、
さらに、前記TLBは、前記内部バスからのみ設定可能であり、前記外部バスからのアクセスが行われた際に前記内部バスのアドレスに変換する機能を有し、
前記プロセッサコアは、前記TLBの設定を更新する要求であるTLB更新要求を前記内部バスへ発行し、
前記TLB制御回路は、前記プロセッサコアから発行された前記TLB更新要求を前記内部バスから受信し、受信した前記TLB更新要求に基づいてTLB更新信号と前記TLB内のどのエントリを変更するかを通知するためのエントリアドレスとを前記TLBへ送信し、
前記TLBは、前記TLB制御回路から送信されてきた前記TLB更新信号と前記エントリアドレスとに基づいて前記TLB内部を更新し、
前記TLB更新要求は前記アクセス制御回路と前記TLB制御回路とに共通に送信され、前記TLB更新要求が前記アクセス制御回路と前記TLB制御回路とのどちらへの要求かが前記内部バスのアドレスから判断される
ことを特徴とする半導体装置。 A processor core for performing an operation; an external bus interface for connecting to an external bus; a memory interface for controlling access to a local memory; and an internal bus connecting the processor core, the external bus interface, and the memory interface; A semiconductor device comprising:
The external bus interface includes an access control circuit that receives a request from the external bus, a TLB that is connected to the access control circuit and determines whether the external bus can be accessed, and a TLB that rewrites the TLB in response to a request from the processor core. Having a control circuit,
The access control circuit that has received the request from the external bus transmits a TLB determination signal inquiring whether the address of the request is an address within an access permission range set in the TLB, to the TLB,
The TLB searches whether the address of the request is an address within an access permission range set in the TLB, and returns a TLB pass / fail signal indicating whether access is possible to the access control circuit,
The access control circuit grants access to the internal bus when the TLB pass / fail signal indicates that access is possible, and grants the request when the TLB pass / fail signal indicates that access is not allowed. Destroy,
Further, the TLB can be set only from the internal bus, and has a function of converting to an address of the internal bus when accessed from the external bus,
The processor core issues a TLB update request, which is a request for updating the TLB setting, to the internal bus,
The TLB control circuit receives the TLB update request issued from the processor core from the internal bus, and notifies the TLB update signal and which entry in the TLB is changed based on the received TLB update request. To the TLB, and an entry address for
The TLB updates the inside of the TLB based on the TLB update signal and the entry address transmitted from the TLB control circuit,
The TLB update request is transmitted in common to the access control circuit and the TLB control circuit, and it is determined from the address of the internal bus whether the TLB update request is a request to the access control circuit or the TLB control circuit. A semiconductor device that is characterized in that:
前記TLB制御回路は、前記プロセッサコアが出力するTLB更新要求に基づき、前記アクセス許可範囲を変更可能である
ことを特徴とする半導体装置。 The semiconductor device according to claim 1,
The TLB control circuit is capable of changing the access permission range based on a TLB update request output from the processor core.
前記外部バスは、PCIバスである
ことを特徴とする半導体装置。 The semiconductor device according to claim 1,
The semiconductor device, wherein the external bus is a PCI bus.
前記外部バスは、汎用バスである
ことを特徴とする半導体装置。 The semiconductor device according to claim 1,
The semiconductor device according to claim 1, wherein the external bus is a general-purpose bus.
前記内部バスに接続され、暗号処理を行う暗号演算回路をさらに有し、
前記アクセス制御回路は、当該暗号演算回路の秘密鍵や暗号処理方法を決定するレジスタへのアクセスを制限する
ことを特徴とする半導体装置。 The semiconductor device according to claim 1,
A cryptographic operation circuit connected to the internal bus for performing cryptographic processing;
The semiconductor device characterized in that the access control circuit restricts access to a register that determines a secret key and a cryptographic processing method of the cryptographic operation circuit.
前記アクセス制御回路は、前記TLB合否信号がアクセス可であることを示している場合、前記内部バス、前記メモリインターフェースを介して前記ローカルメモリへのアクセスを許可する
ことを特徴とする半導体装置。 The semiconductor device according to claim 1,
The access control circuit permits access to the local memory via the internal bus and the memory interface when the TLB pass / fail signal indicates that access is possible.
前記半導体装置内の内部バスに接続され、前記半導体装置内には演算を行うプロセッサコアを有し、
前記外部バスからのリクエストを受けるアクセス制御回路と、前記アクセス制御回路に接続され前記外部バスアクセスの可否を判定するTLBと、前記プロセッサコアからの要求により前記TLBを書き換えるTLB制御回路を有し、
前記外部バスからのリクエストを受けたアクセス制御回路は、該リクエストのアドレスが、前記TLB内に設定されたアクセス許可範囲内のアドレスか否か問い合わせるTLB判定信号を前記TLBへ送信し、
前記TLBは、前記リクエストのアドレスが、前記TLB内に設定されたアクセス許可範囲内のアドレスか否かを検索し、アクセス可否を示すTLB合否信号を前記アクセス制御回路へ返答し、
前記アクセス制御回路は、前記TLB合否信号がアクセス可であることを示している場合、前記内部バスへアクセスを許可し、前記TLB合否信号がアクセス否であることを示している場合、前記リクエストを破棄し、
さらに、前記TLBは、前記内部バスからのみ設定可能であり、前記外部バスからのアクセスが行われた際に前記内部バスのアドレスに変換する機能を有し、
前記プロセッサコアは、前記TLBの設定を更新する要求であるTLB更新要求を前記内部バスへ発行し、
前記TLB制御回路は、前記プロセッサコアから発行された前記TLB更新要求を前記内部バスから受信し、受信した前記TLB更新要求に基づいてTLB更新信号と前記TLB内のどのエントリを変更するかを通知するためのエントリアドレスとを前記TLBへ送信し、
前記TLBは、前記TLB制御回路から送信されてきた前記TLB更新信号と前記エントリアドレスとに基づいて前記TLB内部を更新し、
前記TLB更新要求は前記アクセス制御回路と前記TLB制御回路とに共通に送信され、前記TLB更新要求が前記アクセス制御回路と前記TLB制御回路とのどちらへの要求かが前記内部バスのアドレスから判断される
ことを特徴とするバスインターフェース装置。 A bus interface device in a semiconductor device connected to an external bus,
Connected to an internal bus in the semiconductor device, the semiconductor device has a processor core for performing operations,
An access control circuit that receives a request from the external bus, a TLB that is connected to the access control circuit and determines whether the external bus can be accessed, and a TLB control circuit that rewrites the TLB in response to a request from the processor core,
The access control circuit that has received the request from the external bus transmits a TLB determination signal inquiring whether the address of the request is an address within an access permission range set in the TLB, to the TLB,
The TLB searches whether the address of the request is an address within an access permission range set in the TLB, and returns a TLB pass / fail signal indicating whether access is possible to the access control circuit,
The access control circuit grants access to the internal bus when the TLB pass / fail signal indicates that access is possible, and grants the request when the TLB pass / fail signal indicates that access is not allowed. Destroy,
Further, the TLB can be set only from the internal bus, and has a function of converting to an address of the internal bus when accessed from the external bus,
The processor core issues a TLB update request, which is a request for updating the TLB setting, to the internal bus,
The TLB control circuit receives the TLB update request issued from the processor core from the internal bus, and notifies the TLB update signal and which entry in the TLB is changed based on the received TLB update request. To the TLB, and an entry address for
The TLB updates the inside of the TLB based on the TLB update signal and the entry address transmitted from the TLB control circuit,
The TLB update request is transmitted in common to the access control circuit and the TLB control circuit, and it is determined from the address of the internal bus whether the TLB update request is a request to the access control circuit or the TLB control circuit. A bus interface device.
前記外部バスからアクセスされたアドレスを前記内部バスで用いるためのアドレスに変換するデコーダを有し、
前記アクセス制御回路は、前記デコーダで変換されたアドレスを用いて前記内部バスへリクエストを送信する
ことを特徴とするバスインターフェース装置。 The bus interface device according to claim 7, wherein
A decoder for converting an address accessed from the external bus into an address for use in the internal bus;
The access control circuit transmits a request to the internal bus using the address converted by the decoder.
前記半導体装置内部の所定のアドレス空間がアクセス可能であるかを示す許可ビット群を格納したレジスタと、前記外部バスからのアクセスが示すアドレスが当該半導体装置内部のアクセス可能な領域のアドレスか否かを判定するアクセス判定回路を有し、
前記アクセス判定回路は、前記デコーダと当該デコーダに接続されたセレクタを備え、
前記デコーダで変換されたアドレスから領域選択信号を生成し、前記許可ビット群のレジスタから出力される許可ビット信号と、前記領域選択信号を比較し、
前記領域選択信号と、前記許可ビット信号とが一致した場合は、アクセスが可であることを示すアクセス合否信号を出力し、
前記領域選択信号と、前記許可ビット信号とが一致しない場合は、アクセスが否であることを示すアクセス合否信号を出力する
ことを特徴とするバスインターフェース装置。 The bus interface device according to claim 8, wherein
A register storing a permission bit group indicating whether or not a predetermined address space in the semiconductor device is accessible, and whether or not the address indicated by the access from the external bus is an address of an accessible area in the semiconductor device An access determination circuit for determining
The access determination circuit includes the decoder and a selector connected to the decoder,
Generate an area selection signal from the address converted by the decoder, compare the area selection signal with the permission bit signal output from the register of the permission bit group,
When the area selection signal and the permission bit signal match, an access pass / fail signal indicating that access is possible is output,
The bus interface apparatus, wherein when the area selection signal and the permission bit signal do not match, an access pass / fail signal indicating that access is not allowed is output.
前記許可ビット群に格納されたデータの更新を行う許可ビット制御回路をさらに有し、
前記許可ビット制御回路は、前記内部バスを介して送信される書き換え要求信号に基づき、前記許可ビット群に格納されたデータを変更可能である
ことを特徴とするバスインターフェース装置。 The bus interface device according to claim 9, wherein
A permission bit control circuit for updating data stored in the permission bit group;
The bus interface apparatus, wherein the permission bit control circuit is capable of changing data stored in the permission bit group based on a rewrite request signal transmitted via the internal bus.
前記第1の半導体装置は、
演算を行うプロセッサコアと、前記外部バスに接続されるための外部バスインターフェースと、前記記憶装置へのアクセスを制御するメモリインターフェースと、前記プロセッサコアと前記外部バスインターフェースと前記メモリインターフェースとを接続する内部バスとを有し、
前記第2の半導体装置から前記記憶装置へのアクセスがあった場合、
前記第1の半導体装置は、該アクセスのアドレスが、当該第1の半導体装置内のTLBに予め設定されたアクセス許可範囲内のアドレスか否かを判断し、
前記アクセスのアドレスが、前記アクセス許可範囲内のアドレスに含まれる場合、前記内部バスを介して前記記憶装置へのアクセスを許可し、
前記アクセスのアドレスが、前記アクセス許可範囲内のアドレスに含まれない場合、前記アクセスを破棄し前記記憶装置へのアクセスを許可せず、
さらに、前記TLBは、前記内部バスからのみ設定可能であり、前記外部バスからのアクセスが行われた際に前記内部バスのアドレスに変換する機能を有し、
前記プロセッサコアは、前記TLBの設定を更新する要求であるTLB更新要求を前記内部バスへ発行し、
TLB制御回路は、前記プロセッサコアから発行された前記TLB更新要求を前記内部バスから受信し、受信した前記TLB更新要求に基づいてTLB更新信号と前記TLB内のどのエントリを変更するかを通知するためのエントリアドレスとを前記TLBへ送信し、
前記TLBは、前記TLB制御回路から送信されてきた前記TLB更新信号と前記エントリアドレスとに基づいて前記TLB内部を更新し、
前記TLB更新要求はアクセス制御回路と前記TLB制御回路とに共通に送信され、前記TLB更新要求が前記アクセス制御回路と前記TLB制御回路とのどちらへの要求かが前記内部バスのアドレスから判断される
ことを特徴とするコンピュータシステム。 A computer system having a first semiconductor device to which a storage device is connected, a second semiconductor device, and the first semiconductor device and an external bus connecting the second semiconductor device,
The first semiconductor device includes:
A processor core that performs an operation, an external bus interface to be connected to the external bus, a memory interface that controls access to the storage device, and the processor core, the external bus interface, and the memory interface are connected to each other. An internal bus,
When the storage device is accessed from the second semiconductor device,
The first semiconductor device determines whether the access address is an address within an access permission range set in advance in the TLB in the first semiconductor device;
When the address of the access is included in the address within the access permission range, permit access to the storage device via the internal bus;
If the address of the access is not included in the address within the access permission range, the access is discarded and access to the storage device is not permitted,
Further, the TLB can be set only from the internal bus, and has a function of converting to an address of the internal bus when accessed from the external bus,
The processor core issues a TLB update request, which is a request for updating the TLB setting, to the internal bus,
The TLB control circuit receives the TLB update request issued from the processor core from the internal bus, and notifies the TLB update signal and which entry in the TLB is changed based on the received TLB update request. And an entry address for the TLB,
The TLB updates the inside of the TLB based on the TLB update signal and the entry address transmitted from the TLB control circuit,
The TLB update request is transmitted in common to the access control circuit and the TLB control circuit, and it is determined from the address of the internal bus whether the TLB update request is a request to the access control circuit or the TLB control circuit. A computer system characterized by that.
前記外部バスインターフェースは、前記外部バスからのリクエストを受けるアクセス制御回路と、前記アクセス制御回路に接続され前記外部バスアクセスの可否を判定するTLBと、前記プロセッサコアからの要求により前記TLBを書き換えるTLB制御回路を有し、
前記外部バスからのリクエストを受けたアクセス制御回路は、該リクエストのアドレスが、前記TLB内に設定されたアクセス許可範囲内のアドレスか否か問い合わせるTLB判定信号を前記TLBへ送信し、
前記TLBは、前記リクエストのアドレスが、前記TLB内に設定されたアクセス許可範囲内のアドレスか否かを検索し、アクセス可否を示すTLB合否信号を前記アクセス制御回路へ返答し、
前記アクセス制御回路は、前記TLB合否信号がアクセス可であることを示している場合、前記内部バスへアクセスを許可し、前記TLB合否信号がアクセス否であることを示している場合、前記リクエストを破棄する
ことを特徴とするコンピュータシステム。 12. A computer system according to claim 11, comprising:
The external bus interface includes an access control circuit that receives a request from the external bus, a TLB that is connected to the access control circuit and determines whether the external bus can be accessed, and a TLB that rewrites the TLB in response to a request from the processor core. Having a control circuit,
The access control circuit that has received the request from the external bus transmits a TLB determination signal inquiring whether the address of the request is an address within an access permission range set in the TLB, to the TLB,
The TLB searches whether the address of the request is an address within an access permission range set in the TLB, and returns a TLB pass / fail signal indicating whether access is possible to the access control circuit,
The access control circuit grants access to the internal bus when the TLB pass / fail signal indicates that access is possible, and grants the request when the TLB pass / fail signal indicates that access is not allowed. A computer system characterized by discarding.
前記外部バスに接続される他の装置から前記モジュールへのアクセスがあった場合、
前記半導体装置は、該アクセスのアドレスが、当該半導体装置内のTLBに予め設定されたアクセス許可範囲内のアドレスか否かを判断し、
前記アクセスのアドレスが、前記アクセス許可範囲内のアドレスに含まれる場合、前記内部バスを介して前記モジュールへのアクセスを許可し、
前記アクセスのアドレスが、前記アクセス許可範囲内のアドレスに含まれない場合、前記アクセスを破棄し記憶装置へのアクセスを許可せず、
さらに、前記TLBは、前記内部バスからのみ設定可能であり、前記外部バスからのアクセスが行われた際に前記内部バスのアドレスに変換する機能を有し、
プロセッサコアは、前記TLBの設定を更新する要求であるTLB更新要求を前記内部バスへ発行し、
TLB制御回路は、前記プロセッサコアから発行された前記TLB更新要求を前記内部バスから受信し、受信した前記TLB更新要求に基づいてTLB更新信号と前記TLB内のどのエントリを変更するかを通知するためのエントリアドレスとを前記TLBへ送信し、
前記TLBは、前記TLB制御回路から送信されてきた前記TLB更新信号と前記エントリアドレスとに基づいて前記TLB内部を更新し、
前記TLB更新要求はアクセス制御回路と前記TLB制御回路とに共通に送信され、前記TLB更新要求が前記アクセス制御回路と前記TLB制御回路とのどちらへの要求かが前記内部バスのアドレスから判断される
ことを特徴とする半導体装置。 A semiconductor device having a module having an arbitrary function, an external bus interface to be connected to an external bus, and an internal bus connecting the module and the external bus interface,
When there is access to the module from another device connected to the external bus,
The semiconductor device determines whether the access address is an address within an access permission range set in advance in the TLB in the semiconductor device;
When the access address is included in an address within the access permission range, permit access to the module via the internal bus;
If the address of the access is not included in the address within the access permission range, the access is discarded and access to the storage device is not permitted,
Further, the TLB can be set only from the internal bus, and has a function of converting to an address of the internal bus when accessed from the external bus,
The processor core issues a TLB update request, which is a request for updating the TLB setting, to the internal bus,
The TLB control circuit receives the TLB update request issued from the processor core from the internal bus, and notifies the TLB update signal and which entry in the TLB is changed based on the received TLB update request. And an entry address for the TLB,
The TLB updates the inside of the TLB based on the TLB update signal and the entry address transmitted from the TLB control circuit,
The TLB update request is transmitted in common to the access control circuit and the TLB control circuit, and it is determined from the address of the internal bus whether the TLB update request is a request to the access control circuit or the TLB control circuit. A semiconductor device.
当該半導体装置には記憶装置が接続されており、
前記記憶装置へのアクセスを制御するメモリインターフェースをさらに有し、
前記アクセスのアドレスが、前記アクセス許可範囲内のアドレスに含まれる場合、前記内部バス、前記メモリインターフェースを介して前記記憶装置へのアクセスを許可する
ことを特徴とする半導体装置。 A semiconductor device according to claim 13,
A storage device is connected to the semiconductor device,
A memory interface for controlling access to the storage device;
When the access address is included in an address within the access permission range, the semiconductor device permits access to the storage device via the internal bus and the memory interface.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2010175000A JP5380392B2 (en) | 2010-08-04 | 2010-08-04 | Semiconductor device, bus interface device, and computer system |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2010175000A JP5380392B2 (en) | 2010-08-04 | 2010-08-04 | Semiconductor device, bus interface device, and computer system |
Related Parent Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2003072919A Division JP4945053B2 (en) | 2003-03-18 | 2003-03-18 | Semiconductor device, bus interface device, and computer system |
Related Child Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2012032569A Division JP5324676B2 (en) | 2012-02-17 | 2012-02-17 | Processor, bus interface device, and computer system |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2010244584A JP2010244584A (en) | 2010-10-28 |
JP5380392B2 true JP5380392B2 (en) | 2014-01-08 |
Family
ID=43097445
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2010175000A Expired - Fee Related JP5380392B2 (en) | 2010-08-04 | 2010-08-04 | Semiconductor device, bus interface device, and computer system |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP5380392B2 (en) |
Family Cites Families (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH0784884A (en) * | 1993-09-10 | 1995-03-31 | Hitachi Ltd | Virtual computer system |
US6854003B2 (en) * | 1996-12-19 | 2005-02-08 | Hyundai Electronics America | Video frame rendering engine |
JP3672695B2 (en) * | 1997-05-16 | 2005-07-20 | 株式会社ルネサステクノロジ | Semiconductor memory device, microcomputer, and data processing device |
JP3584977B2 (en) * | 2001-06-04 | 2004-11-04 | 日本電気株式会社 | PCI device, PCI bus system including the same, and data collection method |
US7073059B2 (en) * | 2001-06-08 | 2006-07-04 | Hewlett-Packard Development Company, L.P. | Secure machine platform that interfaces to operating systems and customized control programs |
-
2010
- 2010-08-04 JP JP2010175000A patent/JP5380392B2/en not_active Expired - Fee Related
Also Published As
Publication number | Publication date |
---|---|
JP2010244584A (en) | 2010-10-28 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP4945053B2 (en) | Semiconductor device, bus interface device, and computer system | |
KR101477080B1 (en) | Memory access security management | |
TWI705353B (en) | Integrated circuit, method and article of manufacture for allowing secure communications | |
JP5581403B2 (en) | Store secure mode page table data in secure and non-secure areas of memory | |
JP4818793B2 (en) | Microcomputer and memory access control method | |
JP5914145B2 (en) | Memory protection circuit, processing device, and memory protection method | |
US8677457B2 (en) | Security for codes running in non-trusted domains in a processor core | |
US7681044B2 (en) | Secure processor and system | |
US7594042B2 (en) | Effective caching mechanism with comparator coupled to programmable registers to store plurality of thresholds in order to determine when to throttle memory requests | |
US10303621B1 (en) | Data protection through address modification | |
JP7213879B2 (en) | Memory protection device for indirect access memory controller | |
US20050165783A1 (en) | Secure direct memory access through system controllers and similar hardware devices | |
JP7201686B2 (en) | Equipment for adding protection features for indirect access memory controllers | |
JP5380392B2 (en) | Semiconductor device, bus interface device, and computer system | |
JP5324676B2 (en) | Processor, bus interface device, and computer system | |
JP2006293516A (en) | Bus access control unit | |
CN112836245A (en) | An access control device and a processor including the same | |
JP2007109053A (en) | Bus access controller | |
US20240070091A1 (en) | Isolation of memory regions in trusted domain | |
JP2011222055A (en) | Microcomputer and control method for memory access |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20100804 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20110830 |
|
A02 | Decision of refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A02 Effective date: 20111122 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20130930 |
|
R150 | Certificate of patent or registration of utility model |
Ref document number: 5380392 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 Free format text: JAPANESE INTERMEDIATE CODE: R150 |
|
S531 | Written request for registration of change of domicile |
Free format text: JAPANESE INTERMEDIATE CODE: R313531 |
|
R350 | Written notification of registration of transfer |
Free format text: JAPANESE INTERMEDIATE CODE: R350 |
|
LAPS | Cancellation because of no payment of annual fees |