JP2009037479A - Data transfer control device and electronic device - Google Patents
Data transfer control device and electronic device Download PDFInfo
- Publication number
- JP2009037479A JP2009037479A JP2007202055A JP2007202055A JP2009037479A JP 2009037479 A JP2009037479 A JP 2009037479A JP 2007202055 A JP2007202055 A JP 2007202055A JP 2007202055 A JP2007202055 A JP 2007202055A JP 2009037479 A JP2009037479 A JP 2009037479A
- Authority
- JP
- Japan
- Prior art keywords
- data
- register
- host
- data transfer
- control device
- 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
Links
Images
Landscapes
- Information Transfer Systems (AREA)
- Bus Control (AREA)
Abstract
Description
本発明は、データ転送制御装置及び電子機器に関する。 The present invention relates to a data transfer control device and an electronic device.
近年、ストレージデバイス等のシリアルインターフェースとして、シリアルATA(Serial AT Attachment)と呼ばれる規格が脚光を浴びている。このシリアルATAは、パラレルATA(IDE)との間のソフトウェアレベルでの互換性を備えた規格である。そして最初の規格であるシリアルATA Iのデータ転送速度は1.5Gbpsであったが、次の規格であるシリアルATA II Gen2ではデータ転送速度が3.0Gbpsに高速化している。このシリアルATAを用いれば、電子機器が内蔵する回路基板間の配線本数を減らすことができ、電子機器のコンパクト化を図れる。 In recent years, a standard called Serial ATA (Serial AT Attachment) has been spotlighted as a serial interface for storage devices and the like. This serial ATA is a standard having compatibility at the software level with parallel ATA (IDE). The data transfer rate of serial ATA I, which is the first standard, was 1.5 Gbps, but the data transfer rate has been increased to 3.0 Gbps in serial ATA II Gen2, which is the next standard. If this serial ATA is used, the number of wires between circuit boards built in the electronic device can be reduced, and the electronic device can be made compact.
ところが、電子機器のホスト(ホストデバイス、ホスト基板)は、パラレルATA(以下、適宜、PATAと呼ぶ)のインターフェース(以下、適宜、I/Fと呼ぶ)は備えているが、シリアルATA(以下、適宜、SATAと呼ぶ)のI/Fについては備えていないものが多い。このため、PATAI/Fのみを備えた既存のホストに対しては、SATAのデバイスを接続できないという問題がある。従って、PATAとSATAのブリッジ機能を有するデータ転送制御装置の提供が望まれる。 However, the host (host device, host substrate) of the electronic device has a parallel ATA (hereinafter referred to as PATA as appropriate) interface (hereinafter referred to as I / F as appropriate), but a serial ATA (hereinafter referred to as PATA). Many of them do not have an I / F (referred to as SATA as appropriate). For this reason, there is a problem that a SATA device cannot be connected to an existing host having only the PATA I / F. Therefore, it is desired to provide a data transfer control device having a PATA and SATA bridge function.
ところで、ATAのホストは、デバイスの特性パラメータを知るために、アイデンティファイ・デバイス・コマンド(Identify Device Command)をデバイスに対して発行する。そしてデバイスからの各種情報を取得した後に、ホストとデバイスとの間のデータ転送速度やその他のやり取りについて決定して、データ転送を実行する。 Incidentally, the ATA host issues an identify device command to the device in order to know the device characteristic parameters. Then, after acquiring various information from the device, the data transfer speed and other exchanges between the host and the device are determined and data transfer is executed.
しかしながら、SATAデバイスはPATAデバイスに比べて高速に動作する。従って、ブリッジ機能を有するデータ転送制御装置にSATAデバイスをブリッジ接続した場合に、SATAデバイスが、ホストから発行されたアイデンティファイ・デバイス・コマンド(アイデンティファイ・パケット・デバイス・コマンド)に対して、データ転送制御装置のハードウェア能力以上の特性パラメータを返す可能性がある。そしてこの場合には、ホストとSATAデバイスとの間に、データ転送制御装置が介在することで、両者の転送の整合性が取れなくなるおそれがある。
本発明は、以上のような課題に鑑みてなされたものであり、本発明に係る幾つかの態様によれば、パラレルATAとシリアルATAのバスブリッジ機能を実現しながらホストとシリアルATAデバイスとの間の転送の整合性についても適正に維持できる。 The present invention has been made in view of the above problems. According to some aspects of the present invention, a host and a serial ATA device can be connected to each other while realizing a bus bridge function of parallel ATA and serial ATA. It is also possible to properly maintain the consistency of transfer between.
本発明は、パラレルATAとシリアルATAのバスブリッジ機能を有するデータ転送制御装置であって、パラレルATAバスに接続され、ホストとの間のインターフェースを行うパラレルATAインターフェースと、シリアルATAバスに接続され、シリアルATAのデバイスとの間のインターフェースを行うシリアルATAインターフェースと、転送シーケンス制御を行うシーケンスコントローラを含み、前記パラレルATAインターフェースは、タスクファイル・レジスタを有し、前記シリアルATAインターフェースは、前記ホストによりアイデンティファイ・デバイス・コマンドが発行された場合に、前記アイデンティファイ・デバイス・コマンドに対応するレジスタFISを前記シリアルATAの前記デバイスに送信し、前記シーケンスコントローラは、前記アイデンティファイ・デバイス・コマンドの返値であるアイデンティファイ・デバイス情報が設定されたデータFISを、前記シリアルATAインターフェースが受信した場合に、前記アイデンティファイ・デバイス情報の書き換え処理を行うデータ転送制御装置に関係する。 The present invention is a data transfer control device having a parallel ATA and serial ATA bus bridge function, connected to a parallel ATA bus and connected to a host, and connected to a serial ATA bus. A serial ATA interface for interfacing with a serial ATA device; and a sequence controller for performing transfer sequence control. The parallel ATA interface has a task file register. The serial ATA interface is identified by the host. When a proof device command is issued, a register FIS corresponding to the identify device command is transmitted to the device of the serial ATA, and the When the serial ATA interface receives the data FIS in which the identified device information, which is a return value of the identified device command, is received by the serial ATA interface, the instance controller rewrites the identified device information. The present invention relates to a data transfer control device that performs processing.
本発明によれば、ホストがアイデンティファイ・デバイス・コマンドを発行すると、アイデンティファイ・デバイス・コマンドに対応するレジスタFISがシリアルATAのデバイスに送信される。そしてアイデンティファイ・デバイス情報が設定されたデータFISをデバイスから受信すると、アイデンティファイ・デバイス情報の書き換え処理が行われる。そして書き換え後のアイデンティファイ・デバイス情報は、例えばタスクファイル・レジスタのデータレジスタに設定されて、ホストに知らされる。このようにすれば、パラレルATAとシリアルATAのバスブリッジ機能を実現しながらホストとシリアルATAデバイスとの間の転送の整合性についても適正化できる。 According to the present invention, when the host issues an identify device command, a register FIS corresponding to the identify device command is transmitted to the device of the serial ATA. When the data FIS in which the identified device information is set is received from the device, rewriting processing of the identified device information is performed. The rewritten identification device information is set in the data register of the task file register, for example, and is notified to the host. In this way, it is possible to optimize transfer consistency between the host and the serial ATA device while realizing a bus bridge function of parallel ATA and serial ATA.
また本発明では、前記ホスト、前記デバイス間で転送されるデータのバッファリングを行うデータバッファを含み、前記シーケンスコントローラは、前記データバッファに、前記アイデンティファイ・デバイス情報が書き込まれた後、書き込まれた前記アイデンティファイ・デバイス情報を読み出し、読み出された前記アイデンティファイ・デバイス情報の書き換え処理を行って、前記データバッファに書き戻してもよい。 The present invention further includes a data buffer for buffering data transferred between the host and the device, and the sequence controller writes the identifier device information after the identifier device information is written to the data buffer. The identified device information may be read out, the read-out identification device information may be rewritten, and written back to the data buffer.
このようにすれば、データバッファに書き込まれたアイデンティファイ・デバイス情報の中から、書き換えが必要な情報だけを抽出して書き換え処理を行うことが可能になる。 In this way, it is possible to perform rewrite processing by extracting only the information that needs to be rewritten from the identified device information written in the data buffer.
また本発明では、前記シーケンスコントローラは、前記デバイスからシリアルATA側でのPIOリード転送のPIOセットアップFISを受信した後、PIOリード転送のデータFISを受信した場合に、前記アイデンティファイ・デバイス情報として、1セクタ分のリードデータが前記データバッファに書き込まれるまでウェイトし、1セクタ分の前記リードデータが前記データバッファに書き込まれた後に、前記リードデータである前記アイデンティファイ・デバイス情報の書き換え処理を行い、その後に前記タスクファイル・レジスタのステータスレジスタのビジービットをクリアすると共にデータリクエストビットをセットしてもよい。 In the present invention, the sequence controller receives the PIO setup transfer FIS for PIO read transfer on the serial ATA side from the device and then receives the data FIS for PIO read transfer as the identified device information. Wait until the read data for one sector is written in the data buffer, and after the read data for one sector is written in the data buffer, the rewrite processing of the identified device information that is the read data After that, the busy bit of the status register of the task file register may be cleared and the data request bit may be set.
このようにすれば、1セクタ分のリードデータがデータバッファに書き込まれて、アイデンティファイ・デバイス情報の書き換え処理が完了しない限り、ホストからのデータリクエストが行われないようになり、適正な書き換え処理を実現できる。 In this way, the read request for one sector is written to the data buffer, and the data request from the host is not performed unless the rewrite processing of the identification device information is completed. Processing can be realized.
また本発明では、前記シーケンスコントローラは、前記タスクファイル・レジスタの前記ステータスレジスタのビットを設定した後に、前記パラレルATAインターフェースに対してパラレルATA側でのPIOリード転送の開始を指示してもよい。 In the present invention, the sequence controller may instruct the parallel ATA interface to start PIO read transfer on the parallel ATA side after setting the status register bit of the task file register.
このようにすれば、PIOリード転送の開始指示時には、確実に転送すべきデータが存在していることになり、転送開始が指示されたものの転送すべきデータが存在しないという事態を防止できる。 In this way, when the PIO read transfer start instruction is given, there is data to be transferred reliably, and it is possible to prevent a situation in which there is no data to be transferred although transfer start is instructed.
また本発明では、前記パラレルATAインターフェースは、前記リードデータがバッファリングされるパラレルATA用データバッファを有し、前記タスクファイル・レジスタの前記ステータスレジスタのビットが設定された場合に非アクティブになり、書き換え後の前記アイデンティファイ・デバイス情報であるリードデータが前記パラレルATA用データバッファに蓄積された場合にアクティブになるIORDY信号を生成してもよい。 According to the present invention, the parallel ATA interface has a parallel ATA data buffer in which the read data is buffered, and becomes inactive when a bit of the status register of the task file register is set, An IORDY signal that becomes active when read data that is the device information after rewriting is stored in the data buffer for parallel ATA may be generated.
このようにすれば、転送を開始したものの、転送すべきデータが存在せず、IORDY信号によりホストが無駄に待たされてしまい、IORDY信号のアサートタイミング違反が発生してしまう事態を防止できる。 By doing so, it is possible to prevent a situation in which there is no data to be transferred but there is no data to be transferred and the host is unnecessarily waited for by the IORDY signal, and an IORDY signal assert timing violation occurs.
また本発明では、前記シーケンスコントローラは、前記書き換え処理として、前記アイデンティファイ・デバイス情報のIORDYパラメータの書き替え処理を行ってもよい。 In the present invention, the sequence controller may perform an IORDY parameter rewrite process of the identified device information as the rewrite process.
このようにすれば、IORDY信号の適正な制御を実現できる。 In this way, proper control of the IORDY signal can be realized.
また本発明では、前記シーケンスコントローラは、前記書き換え処理として、前記アイデンティファイ・デバイス情報の転送能力パラメータを、データ転送制御装置の転送能力に応じたパラメータに書き替える処理を行ってもよい。 In the present invention, the sequence controller may perform a process of rewriting the transfer capability parameter of the identified device information to a parameter corresponding to the transfer capability of the data transfer control device as the rewrite process.
このようにすれば、データ転送制御装置の転送能力に応じた適正なデータ転送制御を実行できる。 In this way, appropriate data transfer control according to the transfer capability of the data transfer control device can be executed.
また本発明では、初期化シーケンス管理機能を有しない前記シリアルATAの前記デバイスに代わって初期化シーケンス管理を代行する初期化シーケンス管理部を含み、前記初期化シーケンス管理部は、マスタ・スレーブ設定端子によりデータ転送制御装置がマスタ側に設定された場合には、ハードリセット後にスレーブ検知処理と自己診断処理を行い、前記マスタ・スレーブ設定端子によりデータ転送制御装置がスレーブ側に設定された場合には、ハードリセット後にスレーブ検知信号、自己診断信号の制御を行ってもよい。 The present invention further includes an initialization sequence management unit that performs initialization sequence management on behalf of the device of the serial ATA that does not have an initialization sequence management function, and the initialization sequence management unit includes a master / slave setting terminal When the data transfer control device is set on the master side by the slave detection processing and self-diagnosis processing after hard reset, and when the data transfer control device is set on the slave side by the master / slave setting terminal The slave detection signal and the self-diagnosis signal may be controlled after the hard reset.
このようにシリアルATAのデバイスに代わって初期化シーケンス処理を代行すれば、マスタ、スレーブの区別の概念の無いシリアルATAのデバイスを、マスタ、スレーブの区別が可能なパラレルATAのデバイスのように扱うことが可能になると共に、パラレルATAに準拠した適正な初期化シーケンス処理を実現できる。 If the initialization sequence process is performed instead of the serial ATA device in this way, the serial ATA device without the concept of master / slave distinction is treated as a parallel ATA device that can distinguish master / slave. In addition, it is possible to realize proper initialization sequence processing conforming to parallel ATA.
また本発明では、前記シーケンスコントローラは、前記書き換え処理として、スレーブ検知結果、自己診断結果を前記ホストに通知するための書き替え処理を行ってもよい。 In the present invention, the sequence controller may perform a rewrite process for notifying the host of a slave detection result and a self-diagnosis result as the rewrite process.
このようにすれば、初期化シーケンス管理を代行した場合にも、スレーブ検知結果や自己診断結果を適正にホストに通知できる。 In this way, the slave detection result and self-diagnosis result can be appropriately notified to the host even when the initialization sequence management is performed.
また本発明では、前記パラレルATAインターフェースは、タスクファイル・レジスタを有し、前記シリアルATAインターフェースは、前記タスクファイル・レジスタとの間でレジスタ値が転送されるシャドウ・タスクファイル・レジスタを含み、前記シーケンスコントローラは、データ転送制御装置がマスタ側に設定されているときに、前記ホストがマスタへのATAコマンドを発行した場合には、前記タスクファイル・レジスタのレジスタ値をそのまま前記シャドウ・タスクファイル・レジスタに転送し、データ転送制御装置がスレーブ側に設定されているときに、前記ホストがスレーブへのATAコマンドを発行した場合には、前記タスクファイル・レジスタのデバイス/ヘッドレジスタのDEVビットをマスタ設定に書き換えて前記タスクファイル・レジスタのレジスタ値を前記シャドウ・タスクファイル・レジスタに転送してもよい。 In the present invention, the parallel ATA interface includes a task file register, and the serial ATA interface includes a shadow task file register in which a register value is transferred to and from the task file register, When the data transfer control device is set to the master side and the host issues an ATA command to the master, the sequence controller uses the register value of the task file register as it is. When the host issues an ATA command to the slave while the data transfer control device is set to the slave side, the DEV bit of the task file register device / head register is set as the master. Before rewriting the settings The register value of the task file register may be transferred to the shadow task file register.
このようにすれば、マスタ・スレーブ設定端子の状態に応じた適正な値に、デバイス/ヘッドレジスタのDEVビットが書き換えられるため、データ転送制御装置が例えばスレーブ側に設定された場合にも、ホストから、自身をマスタと認識しているシリアルATAデバイスに対して、コマンド、パラメータ等の適正な転送処理を実現できる。 In this way, since the DEV bit of the device / head register is rewritten to an appropriate value according to the state of the master / slave setting terminal, even when the data transfer control device is set to the slave side, for example, Therefore, it is possible to realize appropriate transfer processing of commands, parameters, etc., to the serial ATA device that recognizes itself as a master.
また本発明では、前記シーケンスコントローラは、データ転送制御装置がマスタ側に設定されているときに、前記ホストからのATAコマンドに対応するFISを前記シリアルATAインターフェースが前記デバイスから受信した場合には、前記シャドウ・タスクファイル・レジスタのレジスタ値を前記タスクファイル・レジスタにそのままに転送し、データ転送制御装置がスレーブ側に設定されているときに、前記ホストからのATAコマンドに対応するFISを前記シリアルATAインターフェースが前記デバイスから受信した場合には、前記シャドウ・タスクファイル・レジスタのデバイス/ヘッドレジスタのDEVビットをスレーブ設定に書き換えて前記シャドウ・タスクファイル・レジスタのレジスタ値を前記タスクファイル・レジスタに転送してもよい。 Also, in the present invention, when the serial ATA interface receives an FIS corresponding to an ATA command from the host when the data transfer control device is set on the master side, the sequence ATA interface receives the FIS from the device. The register value of the shadow task file register is transferred to the task file register as it is, and when the data transfer control device is set to the slave side, the FIS corresponding to the ATA command from the host is transferred to the serial number. When the ATA interface receives from the device, the DEV bit of the device / head register of the shadow task file register is rewritten to the slave setting, and the register value of the shadow task file register is changed to the task file record. It may be transferred to the register.
このようにすれば、マスタ・スレーブ設定端子の状態に応じた適正な値に、デバイス/ヘッドレジスタのDEVビットが書き換えられるため、データ転送制御装置が例えばスレーブ側に設定された場合にも、自身をマスタと認識しているシリアルATAデバイスから、ホストに対して、ステータス等の適正な転送処理を実現できる。 In this way, since the DEV bit of the device / head register is rewritten to an appropriate value according to the state of the master / slave setting terminal, even when the data transfer control device is set to the slave side, for example. From the serial ATA device that recognizes the device as a master, it is possible to implement appropriate transfer processing such as status to the host.
また本発明では、前記シーケンスコントローラは、前記書き換え処理として、前記アイデンティファイ・デバイス情報のチェックサムパラメータを無効設定に書き替える処理を行ってもよい。 In the present invention, the sequence controller may perform a process of rewriting the checksum parameter of the identified device information to an invalid setting as the rewriting process.
このようにすれば、アイデンティファイ・デバイス情報が書き換えられることで、誤ったチェックサム結果がホストに通知されるのを防止できる。 In this way, it is possible to prevent an incorrect checksum result from being notified to the host by rewriting the identified device information.
また本発明では、前記シリアルATAインターフェースは、前記パラレルATAバスを介して前記ホストがATAコマンドを発行した場合に、発行された前記ATAコマンドを含むレジスタFISを前記シリアルATAバスを介して前記デバイスに送信し、前記シーケンスコントローラは、前記レジスタFISに対応するFISを前記シリアルATAインターフェースが前記デバイスから受信した場合に、前記ホストから発行された前記ATAコマンドの転送シーケンス制御として、受信したFISの種類に応じた転送シーケンス制御を行うと共に、前記ホストから発行された前記ATAコマンドが前記アイデンティファイ・デバイス・コマンドであった場合には、前記アイデンティファイ・デバイス情報が設定されたデータFISを受信したときに、前記アイデンティファイ・デバイス・コマンドに対応する転送シーケンス制御を行ってもよい。 In the present invention, when the host issues an ATA command via the parallel ATA bus, the serial ATA interface sends a register FIS including the issued ATA command to the device via the serial ATA bus. When the serial ATA interface receives the FIS corresponding to the register FIS from the device, the sequence controller sets the received FIS type as the transfer sequence control of the ATA command issued from the host. In response to the transfer sequence control according to the command, if the ATA command issued from the host is the identified device command, the data FIS in which the identified device information is set is received. Occasionally, you may be subjected to transfer sequence control corresponding to the identify device command.
このようにすれば、データ転送制御装置は、ホストが発行したATAコマンドの詳細な内容をデコードすることなく、ATAコマンドを含むレジスタFISをそのままデバイスに送信できる。そしてレジスタFISに対してデバイスが返却して来たFISの種類によって、転送シーケンスが制御される。従って、ATAコマンドのデコーダ回路を節約でき、データ転送制御装置の小規模化を図れる。また、新規コマンドの追加が発生しても、これに容易に対応できるようになる。またアイデンティファイ・デバイス・コマンドに応じた適正な転送シーケンス制御を実現できるため、パラレルATAとシリアルATAのバスブリッジ機能を実現しながらホストとシリアルATAのデバイスとの間の転送の整合性についても適正に維持できる。 In this way, the data transfer control device can directly transmit the register FIS including the ATA command to the device without decoding the detailed contents of the ATA command issued by the host. The transfer sequence is controlled by the type of FIS returned by the device to the register FIS. Therefore, the decoder circuit for the ATA command can be saved, and the data transfer control device can be reduced in size. In addition, even if a new command is added, this can be easily handled. In addition, since proper transfer sequence control according to the identify device command can be realized, the consistency of transfer between the host and the serial ATA device is realized while realizing the bus bridge function of the parallel ATA and the serial ATA. It can be maintained properly.
また本発明は、上記のいずれかに記載のデータ転送制御装置と、前記データ転送制御装置に接続される前記ホストと、前記データ転送制御装置に接続される前記デバイスとを含む電子機器に関係する。 According to another aspect of the invention, there is provided an electronic apparatus including the data transfer control device according to any one of the above, the host connected to the data transfer control device, and the device connected to the data transfer control device. .
以下、本発明の好適な実施の形態について詳細に説明する。なお以下に説明する本実施形態は特許請求の範囲に記載された本発明の内容を不当に限定するものではなく、本実施形態で説明される構成の全てが本発明の解決手段として必須であるとは限らない。 Hereinafter, preferred embodiments of the present invention will be described in detail. The present embodiment described below does not unduly limit the contents of the present invention described in the claims, and all the configurations described in the present embodiment are indispensable as means for solving the present invention. Not necessarily.
1.データ転送制御装置の構成
図1(A)、図1(B)に本実施形態のデータ転送制御装置の構成例を示す。このデータ転送制御装置はPATA(Parallel AT Attachment)とSATA(Serial AT Attachment)のバスブリッジ機能を有する。
1. Configuration of Data Transfer Control Device FIGS. 1A and 1B show a configuration example of the data transfer control device of this embodiment. This data transfer control device has a PATA (Parallel AT Attachment) and SATA (Serial AT Attachment) bus bridge function.
なお本実施形態のデータ転送制御装置は図1(A)、図1(B)の構成に限定されず、その構成要素の一部(例えばデータバッファ)を省略したり、他の構成要素(例えば外部I/F回路、CPU、タイマ)を追加するなどの種々の変形実施が可能である。例えば本実施形態のデータ転送制御装置は、PATAとSATAのバスブリッジ機能以外にも、PATAとUSB、PATAとSD(Secure Digital)カードインターフェス、PATAとCE−ATAのバスブリッジ機能を実現できるようにしてもよい。 The data transfer control device according to the present embodiment is not limited to the configuration shown in FIGS. 1A and 1B, and some of the components (for example, a data buffer) may be omitted or other components (for example, Various modifications such as addition of an external I / F circuit, a CPU, and a timer are possible. For example, in addition to the PATA and SATA bus bridge functions, the data transfer control device of the present embodiment can realize a PATA and USB, PATA and SD (Secure Digital) card interface, and a PATA and CE-ATA bus bridge function. It may be.
PATAI/F10(パラレルATAインターフェース)は、PATAバス(ATAバス、IDEバス)に接続され、ホスト2(ホストデバイス)との間のインターフェースを行う。具体的にはPATAI/F10は、ホスト2が有するホスト側のPATAI/FにPATAバスを介して接続される。そしてATAで規格化された後述する各種信号によりやり取りを行い、PATA(IDE)のデータ転送を実現する。またPATAI/F10は、データバッファ70を介したSATAI/F50との間のデータ転送制御も行う。このPATAI/F10は、PATAとSATAのブリッジ用に擬似的(仮想的)に設けられたタスクファイル・レジスタ12(以下、適宜、TFRと呼ぶ)を含むことができる。
The PATA I / F 10 (parallel ATA interface) is connected to the PATA bus (ATA bus, IDE bus) and performs an interface with the host 2 (host device). Specifically, the PATA I /
なおホスト2としては、例えばCPU、MPU、DSPなどのプロセッサや、専用制御ICや、これらのプロセッサ又は専用制御ICが実装されたホスト回路基板などが考えられる。またデバイス4としては、ハードディスクドライブ(HDD)、光ディスクドライブ(CD、DVD)、磁気ディスクドライブなどのSATAI/Fを備える各種デバイスが考えられる。
As the
SATAI/F50(シリアルATAインターフェース)は、SATAバス(高速シリアルバス)に接続され、SATAのデバイス4との間のインターフェースを行う。具体的にはSATAI/F50は、デバイス4が有するデバイス側のSATAI/Fに接続され、小振幅の差動信号によりやり取りを行い、SATAのデータ転送を実現する。またSATAI/F50は、データバッファ70を介したPATAI/F10との間のデータ転送制御も行う。このSATAI/F50は、SATA規格のシャドウ・タスクファイル・レジスタ52(以下、適宜SFRと呼ぶ)を含むことができる。
The SATA I / F 50 (serial ATA interface) is connected to a SATA bus (high-speed serial bus) and interfaces with the
シーケンスコントローラ30は転送のシーケンス制御を行う。具体的には、PATAとSATAのブリッジ機能を実現するために、PATAI/F10、SATAI/F50、データバッファ70の間のデータ転送のシーケンス制御を行ったり、レジスタ値の転送シーケンス制御を行う。
The
データバッファ70は、ホスト2(PATAI/F)、デバイス4(SATAI/F)の間で転送されるデータのバッファリングを行う。そしてPATA側とSATA側のクロック周波数の差を吸収するための緩衝用のバッファ(FIFO)として機能する。即ちPATA側のクロック周波数が例えば50MHz(或いは60MHz)で、SATA側のクロック周波数が例えば37.5MHzである場合に、データバッファ70を設けることでこのクロック周波数の差を吸収できる。このデータバッファ70は、例えば50MHz(第1の周波数)でデータが入出力されるPATAI/F10側の第1のポートと、例えば37.5MHz(第2の周波数)でデータが入出力されるSATAI/F50側の第2のポートとを有するデュアルポートのメモリ(RAM)などにより実現できる。
The
図1(A)、図1(B)の構成によれば、ホスト2がPATAI/Fしか備えていない場合にも、SATAI/Fを有するデバイス4をデータ転送制御装置を介してホスト2に接続できる。従って、ホスト2のファームウェア、ソフトウェアとして、既存のPATA(IDE)用のファームウェア、ソフトウェアを使用できる。これにより電子機器の開発期間の短縮化や低コスト化を図れる。またデバイス4として、市場供給量が多い大容量のHDDをホスト2に接続できるようになり、電子機器の内蔵HDDの大容量化を図れる。
1A and 1B, even when the
またホスト2が搭載される回路基板とデバイス4が搭載される回路基板の間を、シリアルバスであるSATAバスで接続できるため、回路基板間の配線本数を減らすことができ、電子機器のコンパクト化を図れる。
In addition, since the circuit board on which the
そして実施形態では図1(A)に示すように、SATAI/F50は、ホスト2によりアイデンティファイ・デバイス・コマンド(Identify Device Command)が発行された場合に、アイデンティファイ・デバイス・コマンドに対応するレジスタFISをSATAのデバイス4に送信する。
In the embodiment, as shown in FIG. 1A, the SATA I /
そして図1(B)に示すように、SATAI/F50は、アイデンティファイ・デバイス・コマンド(ATAPIにおけるアイデンティファイ・パケット・デバイス・コマンドを含む)の返値であるアイデンティファイ・デバイス情報が設定されたデータFISを、デバイス4から受信する。
As shown in FIG. 1 (B), the SATA I /
するとシーケンスコントローラ30は、受信したデータFISに設定されたアイデンティファイ・デバイス情報の書き換え処理を行う。この書き換え処理は、例えばシーケンスコントローラ30が有するパラメータ書き換え部36により行われる。
Then, the
そしてシーケンスコントローラ30は、書き換え後のアイデンティファイ・デバイス情報を、TFR12のデータレジスタに設定する。これによりホスト2には、デバイス4の特性パラメータ等として、書き換え後のアイデンティファイ・デバイス情報が通知されるようになる。
Then, the
例えば高速に動作するSATAのデバイス4は、ホスト2が発行したアイデンティファイ・デバイス・コマンドの返値として、データ転送制御装置(LSI)のハードウェア能力以上の特性パラメータを返す場合がある。このような場合にも、本実施形態によれば、シーケンスコントローラ30によりデバイス4の特性パラメータ等の書き換え処理が行われるため、ホスト2とデバイス4の間のデータ転送の整合性が取れなくなる事態を防止できる。
For example, the
なお図1(A)、図1(B)では、シーケンスコントローラ30が、初期化シーケンス管理機能を有しないSATAのデバイス4に代わって初期化シーケンス管理を代行する初期化シーケンス管理部34を含む。そして初期化シーケンス管理部34は、ハードリセット(ハードウェアリセット)等の後に初期化シーケンス処理を実行する。
1A and 1B, the
例えばSATAのデバイス4にはマスタ、スレーブの区別の概念が無いため、SATAのデバイス4はスレーブ検知等の初期化シーケンス管理機能を有しない。従って、PATAとSATAのブリッジ機能を有するデータ転送制御装置のSATAバスにSATAのデバイス4を接続する場合に、初期化シーケンス管理を行う処理主体が無くなってしまう。
For example, since the
この点、図1(A)、図1(B)では初期化シーケンス管理部34が、初期化シーケンス管理機能を有しないSATAのデバイス4に代わって初期化シーケンス管理を代行して、初期化シーケンス処理を実行する。従って、ホスト2上で動作するドライバソフトウェアは、マスタ、スレーブの区別の概念の無いSATAのデバイス4を、マスタ、スレーブの区別が可能なPATAのデバイスのように扱うことが可能になり、利便性を向上できる。
In this regard, in FIGS. 1A and 1B, the initialization
2.詳細な構成例
図2にデータ転送制御装置の詳細な構成例を示す。PATAI/F10はタスクファイル・レジスタTFR12、転送コントローラ14を含む。ここでTFR12は、PATAとSATAのバスブリッジ用に擬似的に設けられたレジスタである。このTFR12を設けることで、ホスト2は、SATAのデバイス4を、あたかもPATAのデバイスのように扱ってデータのリードやライトを行うことが可能になる。即ちホスト2は、既存のPATA用のファームウェアやソフトウェアを使用して、SATAのデバイス4を制御できるようになる。
2. Detailed Configuration Example FIG. 2 shows a detailed configuration example of the data transfer control device. The PATA I /
転送コントローラ14は、PATA用の信号XCS〜XPDIAGを用いてPATA(IDE)のインターフェースを実現したり、データ転送用の制御信号を用いて、データバッファ70との間のデータ転送を制御する。
The
データバッファ70は、メモリコントローラ72、FIFOメモリ(FIFORAM)74を含む。メモリコントローラ72は、FIFOメモリ74のデータの書き込み制御や読み出し制御を行う。またPATAI/F10やSATAI/F50との間で、例えばREQ信号やACK信号などの制御信号を用いたデータ転送制御を行う。
The
SATAI/F50は、シャドウ・タスクファイル・レジスタSFR52、トランスポートコントローラ110、リンクコントローラ150、物理層回路200を含む。
The SATA I /
トランスポートコントローラ110、リンクコントローラ150、物理層回路200は、各々、SATA規格のトランスポート層、リンク層、物理層の処理を行う回路である。
The
シャドウ・タスクファイル・レジスタSFR52はSATAで規格化されているレジスタである。即ちSATAでは、従来のPATA(IDE)との間でソフトウェアレベルでの互換性が維持されており、タスクファイル・レジスタが2つ存在することが特徴になっている。即ちホスト(HBA)側のシャドウ・タスクファイル・レジスタとデバイス側の本来のタスクファイル・レジスタである。 The shadow task file register SFR52 is a register standardized by SATA. That is, SATA is characterized in that compatibility at the software level is maintained with conventional PATA (IDE), and there are two task file registers. That is, the shadow task file register on the host (HBA) side and the original task file register on the device side.
一方、PATAI/F10に設けられたTFR12はSATAで規格化されるレジスタではなく、PATAとSATAのブリッジ用に設けられた擬似的なレジスタである。ホスト2は、TFR12をPATAのタスクファイル・レジスタとして認識してアクセスし、レジスタ値を書き込んだり、レジスタ値を読み出す。すると本実施形態のデータ転送制御装置が、TFR12のレジスタ値をSFR52に転送したり、SFR52のレジスタ値をTFR12に転送するなどの処理を行う。
On the other hand, the
このようにすれば、ホスト2が、PATAのTFR12にレジスタ値を書き込むと、そのレジスタ値がSATAのSFR52に転送されて書き込まれ、SATAバスを介してFIS(Frame Information Structure)によりデバイス4に転送されるようになる。またデバイス4からのFISによりSFR52に書き込まれたレジスタ値が、TFR12に転送されてホスト2に読み出されるようになる。従ってホスト2は、SATAのデバイス4を、あたかもPATAのデバイスのように扱ってデータのリードやライトを行うことが可能になり、PATAとSATAのブリッジ機能を効率良く実現できる。
In this way, when the
なおTFR12とSFR52の間のレジスタ値の転送は次のような手法により実現できる。即ちTFR12のレジスタ群のビット(全ビット)とSFR52のレジスタ群のビット(全ビット)を、シーケンスコントローラ30を介して信号線により接続しておく。そしてレジスタ値の転送を行う場合には、シーケンスコントローラ30が転送トリガ信号を生成し、この転送トリガ信号に基づいて、TFR12のレジスタ値をSFR52に転送したり、SFR52のレジスタ値をTFR12に転送すればよい。
Note that transfer of register values between the
3.PATAI/F
次に、PATAI/F10のデータ転送処理について、図2の構成及び図3(A)〜図4(B)の信号波形を用いて説明する。
3. PATAI / F
Next, the data transfer process of the PATA I /
XCS[1:0]は、PATAの各レジスタにアクセスするために使用するチップセレクト信号である。DA[2:0]は、データ又はデータポートにアクセスするためのアドレス信号である。DMARQ、XDMACKは、DMA転送に使用される信号である。データ転送の準備が整った時にデバイス側がDMARQをアクティブ(アサート)にし、これに応答して、ホスト側がXDMACKをアクティブにする。 XCS [1: 0] is a chip select signal used for accessing each register of PATA. DA [2: 0] is an address signal for accessing data or a data port. DMARQ and XDMACK are signals used for DMA transfer. When the device side is ready for data transfer, the device side activates (asserts) DMARQ, and in response, the host side activates XDMACK.
XDIOWは、レジスタ又はデータポートの書き込み時に使用するライト信号である。XDIORは、レジスタ又はデータポートの読み出し時に使用するリード信号である。IORDYは、デバイス側のデータ転送の準備が整っていない時のウェイト信号等に使用される。 XDIOW is a write signal used when writing to a register or a data port. XDIOR is a read signal used when reading a register or data port. IORDY is used as a wait signal when the device side is not ready for data transfer.
INTRQは、デバイス側が、ホスト側に対して割り込みを要求するために使用される信号である。このINTRQがアクティブになった後、ホスト側がデバイス側のTFR12のステータスレジスタの内容を読むと、所定時間後にデバイス側はINTRQを非アクティブ(ネゲート)にする。このINTRQを用いることで、デバイス側は、コマンド処理の終了をホスト側に通知できる。
INTRQ is a signal used by the device side to request an interrupt from the host side. After the INTRQ becomes active, when the host reads the contents of the status register of the
図3(A)、図3(B)は、PIO(Programmed I/O)リード、PIOライトの信号波形例である。PATAのTFR12のステータスレジスタのリードは図3(A)のPIOリードにより行い、コマンドレジスタへのライトは図3(B)のPIOライトにより行う。例えばホスト2によるATAコマンドの発行は、PIOライトにより実現できる。
FIGS. 3A and 3B are signal waveform examples of PIO (Programmed I / O) read and PIO write. The
図4(A)、図4(B)は、DMAリード、DMAライトの信号波形例である。データ転送の準備ができると、デバイス側(データ転送制御装置)が、DMARQをアクティブにする。そして、それを受けて、ホスト側が、XDMACKをアクティブにして、DMA転送を開始する。その後、XDIOR(リード時)又はXDIOW(ライト時)を使用して、データDD[15:0]のDMA転送を行う。 4A and 4B are signal waveform examples of DMA read and DMA write. When preparation for data transfer is completed, the device side (data transfer control device) activates DMARQ. In response to this, the host side activates XDMACK and starts DMA transfer. Thereafter, DMA transfer of data DD [15: 0] is performed using XDIOR (during reading) or XDIOW (during writing).
4.SATAI/F
次にSATAI/F50のデータ転送処理について説明する。図5はSATAの送信側のデータ転送処理の流れを示し、図6は受信側のデータ転送処理の流れを示している。
4). SATAI / F
Next, the data transfer process of the SATA I /
図5に示すように送信側のトランスポートコントローラ(トランスポート層)では、シャドウ・タスクファイル・レジスタに書き込まれたコマンドやデータポートに入力されたデータによりFIS(Frame Information Structure)が生成される。ここでFISは、フレームのペイロード部であり、Dword(32ビット)単位で構成される。またフレームは、ホストとデバイスの間で交換される情報ユニットであり、SOF(Start Of Frame)プリミティブと、FISと、FISに対して計算されたCRC(Cyclic Redundancy Check)と、EOF(End Of Frame)プリミティブにより構成される。 As shown in FIG. 5, in the transport controller (transport layer) on the transmission side, FIS (Frame Information Structure) is generated based on the command written in the shadow task file register and the data input to the data port. Here, FIS is a payload portion of a frame, and is configured in units of Dword (32 bits). The frame is an information unit exchanged between the host and the device. The SOF (Start Of Frame) primitive, the FIS, the CRC (Cyclic Redundancy Check) calculated for the FIS, and the EOF (End Of Frame) are used. ) Consists of primitives.
送信側のリンクコントローラでは、FISに対するCRCが演算されてFISの最後尾に付加される。そしてFIS及びCRCとスクランブルデータとの排他的論理和(XOR)をとるスクランブル処理が行われる。このようにスクランブルされたFIS及びCRCに対して、8b/10bのエンコードが行われる。ここで8b/10bエンコードは、8ビットのデータを10ビットの伝送キャラクタに変換するデータ伝送符号化のアルゴリズムであり、符号列内の1と0の数を揃え、連続的な伝送を保証する。そして8b/10bエンコード後のFIS及びCRCに対してSOF、EOFなどのプリミティブが付加される。 In the link controller on the transmission side, the CRC for the FIS is calculated and added to the end of the FIS. Then, a scramble process is performed to obtain an exclusive OR (XOR) of the FIS and CRC and the scramble data. The 8b / 10b encoding is performed on the scrambled FIS and CRC. Here, 8b / 10b encoding is a data transmission encoding algorithm that converts 8-bit data into 10-bit transmission characters. The number of 1's and 0's in the code string is aligned to guarantee continuous transmission. Then, primitives such as SOF and EOF are added to the FIS and CRC after 8b / 10b encoding.
送信側の物理層回路では、リンクコントローラからのパラレルデータがシリアルデータに変換され、小振幅の差動信号としてSATAバスに送信される。 In the physical layer circuit on the transmission side, parallel data from the link controller is converted into serial data and transmitted to the SATA bus as a differential signal with a small amplitude.
図6に示すように受信側の物理層回路では、SATAバスを介して受信したシリアルデータがパラレルデータに変換される。 As shown in FIG. 6, in the physical layer circuit on the receiving side, serial data received via the SATA bus is converted into parallel data.
受信側のリンクコントローラでは、FIS及びCRCに付加されたプリミティブに対するデコードが行われる。またFIS及びCRCに対する8b/10bのデコードが行われる。即ち10ビットの伝送キャラクタが8ビットのデータに変換される。次に、スクランブルされたFIS及びCRCとスクランブルデータとの排他的論理和をとるデスクランブル処理が行われる。そしてFISの最後尾に付加されたCRCがチェックされる。 The link controller on the receiving side decodes the primitives added to the FIS and CRC. In addition, 8b / 10b decoding for FIS and CRC is performed. That is, a 10-bit transmission character is converted into 8-bit data. Next, a descrambling process is performed to obtain an exclusive OR of the scrambled FIS and CRC and the scrambled data. Then, the CRC added at the end of the FIS is checked.
受信側のトランスポートコントローラでは、FISのコマンドがシャドウ・タスクファイル・レジスタに書き込まれ、ステータスや割り込みが出力されると共に、データがデータポートを介して出力される。 In the transport controller on the receiving side, the FIS command is written to the shadow task file register, status and interrupt are output, and data is output via the data port.
なお図7にATAのタスクファイル・レジスタのフォーマット例を示す。タスクファイル・レジスタはコントロールブロックレジスタとコマンドブロックレジスタを有し、チップセレクト信号XCS0、XCS1が、Hレベル(ネゲート)、Lレベル(アサート)である場合にはコントロールブロックレジスタが選択され、Lレベル、Hレベルである場合にはコマンドブロックレジスタが選択される。またコマンドブロックレジスタには、ステータスレジスタ(Status)やATAコマンドレジスタ(ATA Command)が設けられる。 FIG. 7 shows a format example of the ATA task file register. The task file register has a control block register and a command block register. When the chip select signals XCS0 and XCS1 are H level (negate) and L level (assert), the control block register is selected, and the L level, When it is at the H level, the command block register is selected. The command block register is provided with a status register (Status) and an ATA command register (ATA Command).
また図8(A)〜図8(D)に、SATAI/F50により送受信されるFISのフォーマット例を示す。図8(A)はホストからデバイスへのレジスタFIS、図8(B)はデバイスからホストへのレジスタFIS、図8(C)はPIOセットアップFIS、図8(D)はDMAアクティベートFISのフォーマットである。
8A to 8D show examples of FIS formats transmitted and received by the SATA I /
5.アイデンティファイ・デバイス情報の書き換え
次に本実施形態のアイデンティファイ・デバイス情報の書き換え手法について詳細に説明する。
5). Rewriting the Identified Device Information Next, the method for rewriting the identified device information according to the present embodiment will be described in detail.
5.1 構成
図9に本実施形態のアイデンティファイ・デバイス情報の書き換え手法を実現するデータ転送制御装置の具体的な構成例を示す。
5.1 Configuration FIG. 9 shows a specific configuration example of a data transfer control device that realizes the method of rewriting the identified device information according to the present embodiment.
図9においてホスト2がアイデンティファイ・デバイス・コマンドを発行して、TFR12のコマンドレジスタ(図7のATA Command)に書き込まれると、書き込まれたコマンドやそのパラメータなどのレジスタ値が、TFR12からシーケンスコントローラ30を介してSFR52に転送される。この場合にシーケンスコントローラ30は、ATAコマンドのうちアイデンティファイ・デバイス・コマンドについてはデコードして解析し、アイデンティファイ・デバイス・コマンドが発行されたことを記憶しておく。
9, when the
即ち後述するように本実施形態では、ホスト2がTFR12に対してコマンドパラメータを書き込んだ後にATAコマンドを発行すると、そのコマンドライトを検出して、書き込まれたATAコマンドをデコードすることなく、TFR12のレジスタ値をそのままSFR52に転送(コピー)する。そしてデバイス4から返ってくるFISの種類を判別して、その後の転送シーケンスを制御する手法を採用している。このような手法を採用することで、ATAのコマンドデコード回路を節約でき、処理の簡素化や回路の小規模化を図れる。
That is, as described later, in the present embodiment, when the
しかしながら本実施形態では、アイデンティファイ・デバイス・コマンドについては、上記手法の例外として、発行されたコマンドをデコードして判別する。そしてアイデンティファイ・デバイス・コマンドが発行されたことを記憶しておき、その後の転送シーケンス制御を実行する。即ちホスト2から発行されたATAコマンドがアイデンティファイ・デバイス・コマンドであった場合には、アイデンティファイ・デバイス情報が設定されたデータFISを受信したときに、アイデンティファイ・デバイス・コマンドに対応する転送シーケンス制御を行う。このようにすれば、アイデンティファイ・デバイス・コマンド以外のコマンドについてはデコードしないことで、コマンドデコード回路の節約を図りながら、アイデンティファイ・デバイス情報の適正な書き換え処理を実現できる。
However, in the present embodiment, the issued device command is determined by decoding the issued command as an exception to the above method. Then, the fact that the identify device command has been issued is stored, and the subsequent transfer sequence control is executed. In other words, when the ATA command issued from the
ホスト2によりアイデンティファイ・デバイス・コマンドが発行されて、TFR12からSFR52にレジスタ値が転送されると、SATAI/F50は、SFR52のレジスタ値に基づいて、アイデンティファイ・デバイス・コマンドに対応するレジスタFIS(図8(A)参照)を生成して、デバイス4に送信し、PIOリードのデータ転送を実行する。
When the identify device command is issued by the
すると、このレジスタFISを受信したデバイス4は、PIOセットアップFISの送信後に、アイデンティファイ・デバイス・コマンドの返値であるアイデンティファイ・デバイス情報が設定されたデータFISを送信する。即ちPIOセットアップFIS及びデータFISにより構成されるPIOリードのユニット転送が行われる。そしてSATAI/F50が、これらのPIOセットアップFIS、データFISを受信する。
Then, after transmitting the PIO setup FIS, the
この場合にPIOセットアップFISに設定されたステータス等のレジスタ値は、SFR52からシーケンスコントローラ30を介してTFR12に転送(コピー)される。
In this case, register values such as status set in the PIO setup FIS are transferred (copied) from the
一方、データFISに設定されたアイデンティファイ・デバイス情報は、SATAI/F50から出力されて、データバッファ70(FIFOメモリ70)に書き込まれる。
On the other hand, the identified device information set in the data FIS is output from the SATA I /
そしてシーケンスコントローラ30は、アイデンティファイ・デバイス情報が設定されたデータFISを受信すると、アイデンティファイ・デバイス情報の書き換え処理を行う。そして書き換え後のアイデンティファイ・デバイス情報はTFR12のデータレジスタに設定される。
When the
具体的にはシーケンスコントローラ30は、データバッファ70に、アイデンティファイ・デバイス情報が書き込まれた後、書き込まれたアイデンティファイ・デバイス情報をデータバッファ70から読み出す。そして読み出されたアイデンティファイ・デバイス情報の書き換え処理を行って、データバッファ70に書き戻す。この場合の書き換え処理はシーケンスコントローラ30のパラメータ書き換え部36により行われる。
Specifically, the
更に具体的にはシーケンスコントローラ30は、デバイス4からシリアルATA側でのPIOリード転送のPIOセットアップFISを受信した後、PIOリード転送のデータFISを受信した場合に、アイデンティファイ・デバイス情報として、1セクタ分(512バイト)のリードデータがデータバッファ70に書き込まれるまでウェイトする。そして1セクタ分のリードデータがデータバッファ70に書き込まれた後に、TFR12のステータスレジスタ(図7のStatus)のBUSYビットを0にクリアすると共にDRQ(データリクエスト)ビットを1にセットする。即ちステータスレジスタを58hに設定して、ホスト2に対してデータリクエスト状態であることを知らせる。
More specifically, when the
そしてシーケンスコントローラ30は、このようにTFR12のステータスレジスタのビットを設定(58h)した後に、PATAI/F10に対してパラレルATA側でのPIOリード転送の開始を指示する。具体的にはPATAI/F10に出力する転送開始指示信号PATATranGoをアクティブ(アサート)にする。
The
例えばシーケンスコントローラ30は、データバッファ70に1セクタ分のリードデータが蓄積されたか否かを、データバッファ70からの信号FIFORemainに基づいて判断する。また1セクタ分のデータサイズについては、SATAI/F50からの信号FISCountに基づいて判断する。
For example, the
ここで信号FIFORemainは、データバッファ70(FIFOメモリ74)の蓄積データサイズ(残りデータサイズ)を示す信号であり、シーケンスコントローラ30は、この信号FIFORemainを用いて、データバッファ70に蓄積されたデータのサイズを判断する。また信号FISCountは、PIOリード転送のPIOセットアップFISの転送カウント値(図8(C)のTransfer Count)を示す信号(例えば16ビットの信号)であり、シーケンスコントローラ30は、この信号FISCountを用いて、データFISにより転送される1セクタ分のリードデータのサイズを判断する。
Here, the signal FIFOmain is a signal indicating the accumulated data size (remaining data size) of the data buffer 70 (FIFO memory 74), and the
そしてシーケンスコントローラ30は、データバッファ70に蓄積されたリードデータのサイズが、1セクタ分のデータサイズ(FISCount)に一致すると(超えると)、蓄積されたリードデータであるアイデンティファイ・デバイス情報をデータバッファ70から読み出す。
Then, when the size of the read data stored in the
具体的にはシーケンスコントローラ30は、アイデンティファイ・デバイス情報のうち、書き換え処理が必要なパラメータを、信号ADDRによりアドレス指定して、信号DINとしてデータバッファ70から読み出す。そしてパラメータ書き換え部36が、読み出されたアイデンティファイ・デバイス情報のパラメータの書き換え処理を行う。そして書き換え後のパラメータを、信号ADDRによりアドレス指定して、信号DOUTとしてデータバッファ70に対して書き戻す。
Specifically, the
そしてシーケンスコントローラ30は、その後にTFR12のステータスレジスタのBUSYビットを0にクリアすると共にDRQビットを1にセットする。これによりホスト2に対してデータリクエスト状態であることが知らされる。
Subsequently, the
次に、シーケンスコントローラ30は、PATAI/F10への転送開始指示信号PATATranGoをアクティブにして、PATAI/F10でのPIOリード転送を起動する。これによりデータバッファ70に蓄積された1セクタ分のリードデータ(書き換え後のアイデンティファイ・デバイス情報)が、PATAI/F10に設けられたPATA用データバッファ16に転送されて書き込まれる。そしてホスト2により、PATA用データバッファ16に書き込まれたリードデータ(書き換え後のアイデンティファイ・デバイス情報)が読み出されることになる。
Next, the
本実施形態では、以上のような手法により、アイデンティファイ・デバイス情報の書き換え処理を実現している。このようにすれば、デバイス4からのデータFISに設定されたアイデンティファイ・デバイス情報の中から、書き換えが必要な情報だけを抽出して書き換え処理を行い、書き換え後のアイデンティファイ・デバイス情報をホスト2に転送することが可能になる。
In the present embodiment, the rewriting process of the identified device information is realized by the method as described above. In this way, only the information that needs to be rewritten is extracted from the identified device information set in the data FIS from the
5.2 アイデンティファイ・デバイス情報
次に本実施形態の書き換え処理の対象となるアイデンティファイ・デバイス情報について詳細に説明する。
5.2 IDENTIFIED DEVICE INFORMATION Next, detailed description will be given of identified device information that is a target of the rewrite processing of the present embodiment.
図10にATAのアイデンティファイ・デバイス情報のフォーマットを抜粋して示す。アイデンティファイ・デバイス情報は、256ワード(512バイト)の情報であり、各ワードのビットに対してパラメータが設定されている。 FIG. 10 shows an excerpt of the format of ATA's identified device information. The identified device information is 256 words (512 bytes) of information, and parameters are set for the bits of each word.
例えば図10のE1に示すように、アイデンティファイ・デバイス情報のワード49のビット11、10には、IORDYパラメータが設定される。具体的には、ワード49のビット11を1にセットすると、IORDY信号をサポートする設定になり、ビット10を1にセットすると、IORYD信号を無効(ディスエーブル)にする設定になる。
For example, as indicated by E1 in FIG. 10, the IORDY parameter is set in
即ちビット11を1にセットすると、ホストとデバイスの間で図3(A)、図3(B)に示すようなIORDY信号を使用したPIO転送を行うことが選択される。一方、ビット10を1にセットすると、IORDY信号を使用しないことが選択される。
That is, when
そして本実施形態ではデータ転送制御装置は、図3(A)、図3(B)で説明したように、IORDY信号を使用したPIO転送を行うように設計されている。従って、シーケンスコントローラ30(パラメータ書き換え部36)は、アイデンティファイ・デバイス情報のIORDYパラメータを、IORDYをサポートする設定に書き替える。具体的には、デバイス4により、ワード49のビット11が0に設定されていたり、ビット10が1に設定されていた場合にも、ビット11、10を、各々、1、0に書き換える(1、0を上書きする)。なおデバイス4により、ワード49のビット11、10が、元々、1、0に設定されていた場合には、書き換え処理後のワード49のビット11、10も、各々、1、0のままになる。
In this embodiment, the data transfer control device is designed to perform PIO transfer using the IORDY signal as described with reference to FIGS. 3A and 3B. Therefore, the sequence controller 30 (parameter rewriting unit 36) rewrites the IORDY parameter of the identifier device information to a setting that supports IORDY. Specifically, even if
また図10のE2に示すように、アイデンティファイ・デバイス情報のワード88のビット6〜0には、転送能力パラメータ(DMAの転送モード)が設定される。具体的にはビット6を1にセットすると、ウルトラDMAモード6以下(ウルトラDMAモード6〜0)をサポートする設定になる。同様に、ビット5、4、3、2、1、0を1にセットすると、各々、ウルトラDMAモード5以下、4以下、3以下、2以下、1以下、0をサポートする設定になる。
As indicated by E2 in FIG. 10, a transfer capability parameter (DMA transfer mode) is set in
SATAデバイス4は一般的に高速であるため、最高速のウルトラDMAモード6で動作するデバイスも存在する。ところがデータ転送制御装置の高速動作には限界があり、ブリッジ接続されるSATAデバイス4がウルトラDMAモード6で動作可能であっても、データ転送制御装置についてはウルトラDMAモード6では動作できない場合がある。
Since the
そこで本実施形態では、アイデンティファイ・デバイス情報のワード88のビット6〜0等の転送能力パラメータを、データ転送制御装置の転送能力に応じたパラメータに書き替える。例えばSATAデバイス4がウルトラDMAモード6で動作可能である場合には、SATAデバイス4は、ワード88のビット6〜0を(1111111)に設定する。この時、データ転送制御装置が、ウルトラDMAモード5以下では動作可能であるが、ウルトラDMAモード6では動作できない場合には、シーケンスコントローラ30は、ワード88のビット6〜0を(0111111)に書き換える(上書きする)。このようにすれば、SATAデバイス4が、自身が高速なDMA転送に対応していることをホスト2に通知しようとした場合にも、これを書き換えて、データ転送制御装置の転送能力に応じた適正なデータ転送制御を実行できる。
Therefore, in this embodiment, the transfer capability parameters such as
また図10のE3に示すように、アイデンティファイ・デバイス情報のワード93には、後述するスレーブ検知(XDASP)や自己診断(XPDIAG)の結果が設定される。
Further, as shown at E3 in FIG. 10, the result of slave detection (XDASP) and self-diagnosis (XPDIAG) described later is set in the
そこで本実施形態では、このようなスレーブ検知結果や自己診断結果をホスト2に通知するための書き替え処理(反映させるための書き換え処理)を行う。
Therefore, in this embodiment, a rewrite process (a rewrite process for reflecting) for notifying the
例えば図11(A)は、後述する手法によりデータ転送制御装置がマスタ側に設定された場合のワード93の設定例である。
For example, FIG. 11A shows a setting example of the
例えばワード93のビット5が1にセットされると、マスタ側であるデータ転送制御装置がスレーブの存在を検知したことが(XDASP=L)、ホスト2に通知される。一方、ビット5が0にクリアされると、スレーブの存在を検知しなかったことが(XDASP=H)、ホスト2に通知される。
For example, when
またワード93のビット4が1にセットされると、マスタ側であるデータ転送制御装置がスレーブの自己診断のパスを検知したことが(XPDIAG=L)、ホスト2に通知される。一方、ビット4が0にクリアされると、スレーブの自己診断のフェイルを検知したことが(XPDIAG=H)、ホスト2に通知される。
When
またワード93のビット3が1にセットされると、自身(マスタ)の自己診断がパスしたことが、ホスト2に通知される。一方、ビット3が0にクリアされると、自身(マスタ)の自己診断がフェイルしたことが、ホスト2に通知される。
When
一方、図11(B)は、データ転送制御装置がスレーブ側に設定された場合のワード93の設定例である。
On the other hand, FIG. 11B shows a setting example of the
例えばワード93のビット11が1にセットされると、自身(スレーブ)の自己診断がパスしたことが、ホスト2に通知される。一方、ビット11が0にクリアされると、自身(スレーブ)の自己診断がフェイルしたことが、ホスト2に通知される。
For example, when
以上のようにすれば、後述するように初期化シーケンス管理部34が、SATAデバイス4に代わって初期化シーケンス管理を代行した場合に、その初期化シーケンス処理の結果(スレーブ検知結果、自己診断結果)を、アイデンティファイ・デバイス情報に反映させて、ホスト2に通知することが可能になる。これにより、データ転送制御装置が初期化シーケンス管理を代行した場合にも、初期化シーケンス処理の結果をホストに対して適正に通知できる。
As described above, when the initialization
また図10のE4に示すように、アイデンティファイ・デバイス情報のワード255のビット15〜8には、チェックサムパラメータが設定される。本実施形態では、このチェックサムパラメータを無効設定に書き替える。具体的には、SATAデバイス4によりチェックサムが計算され、チェックサムの結果がワード255のビット15〜8に書き込まれた場合にも、このビット15〜8のチェックサムを(00000000)に書き換える(上書きする)。このようにチェックサムを(00000000)に設定すると、そのチェックサムは無効になり、チェックサムを計算しなかったことと同じ扱いになる。
Also, as indicated by E4 in FIG. 10, a checksum parameter is set in
即ち本実施形態では、SATAデバイス4により設定されたアイデンティファイ・デバイス情報を、データ転送制御装置側で書き換えている。従って、SATAデバイス4側で計算したチェックサムは、書き換え後のアイデンティファイ・デバイス情報においては意味をなさないものであり、誤ったチェックサムになる。従って、このような誤ったチェックサムをホスト2に通知すると、誤動作等が生じるおそれがある。この場合に、書き換え後のアイデンティファイ・デバイス情報について、再度、チェックサムを計算し直す手法も考えられるが、これは処理負荷の増加や回路の大規模化を招く。
That is, in this embodiment, the identify device information set by the
そこで本実施形態では、チェックサムパラメータを無効設定に書き換えて、誤ったチェックサムの結果がホスト2に通知されるのを防止している。
Therefore, in this embodiment, the checksum parameter is rewritten to an invalid setting to prevent the
なおアイデンティファイ・デバイス情報の書き換え処理は図10、図11に限定されない。例えばマスタ、スレーブの設定を常にジャンパによる設定にするなどの書き換え処理を行ってもよい。 Note that the rewrite processing of the identifier device information is not limited to FIGS. 10 and 11. For example, rewriting processing such as setting the master and slave to always be set by jumpers may be performed.
5.3 動作
次に本実施形態の動作の詳細について図12のフローチャートを用いて説明する。
5.3 Operation Next, details of the operation of the present embodiment will be described with reference to the flowchart of FIG.
ホスト2がアイデンティファイ・デバイス・コマンドを発行すると、シーケンスコントローラ30はTFR12のステータスレジスタのBUSYビットを1にセットする(ステップS71、S72)。これによりホスト2に対してビジー状態であることが通知される。
When the
次に、SATAI/F50がレジスタFISをデバイス4に送信する(ステップS73)。そしてPIOセットアップFISをデバイス4から受信し、それに続いて、アイデンティファイ・デバイス情報がデータフィールドに設定されたデータFISをデバイス4から受信する(ステップS74、S75)。これによりSATAバス側での1ユニットのPIO転送が実行される。
Next, the SATA I /
次に、シーケンスコントローラ30は、データバッファ70(緩衝用FIFO)の蓄積データサイズが1セクタ分の転送バイト数(512バイト)に一致したか否か(超えたか否か)を判断する(ステップS76)。即ち、図9の信号FIFORemain、信号FISCountに基づいて、データバッファ70に1セクタ分のリードデータが蓄積されたか否かを判断する。
Next, the
そして、蓄積データサイズが1セクタ分の転送バイト数に一致すると、データバッファ70に書き込まれたアイデンティファイ・デバイス情報(リードデータ)の書き換え処理を行う(ステップS77)。具体的には図10、図11で説明したように、転送能力パラメータの書き換え、IORDYパラメータの書き換え、スレーブ検知結果(XDASP)、自己診断結果(XPDIAG)を反映させる書き換え、チェックサムパラメータの書き換えなどを行う。
When the accumulated data size matches the number of transfer bytes for one sector, the rewriting process of the identification device information (read data) written in the
次に、TFR12のステータスレジスタのBUSYビットを0にクリアすると共にDRQビットを1にセットする(ステップS78)。これによりデータリクエスト状態であることがホストに通知される。そして、その後にPATAI/F10に対してPIOリード転送の開始を指示する(ステップS79)。具体的には図9のPATATranGoをアクティブにする。これによりホスト2がデータリードを開始し(ステップS80)、ホスト2に対して、書き換え後のアイデンティファイ・デバイス情報が転送される。
Next, the BUSY bit of the status register of the
5.4 IORDY信号
PATA(IDE)では、図13に示すように、IORDY信号がLレベル(非アクティブ、ネゲート)になるウェイト期間tBが規定されている。即ちPIOリードでは、デバイス側がIORDY信号をLレベル(非アクティブ、ネゲート)にした後、Hレベル(アクティブ、アサート)にすることで、リードデータの準備が出来たことが(データがレディー状態であることが)、ホストに通知される。そしてホストは、IORDY信号がLレベルからHレベルに変化すると、XDIOR信号をLレベルからHレベルに変化させて、データDD[15:0]のリード動作を行う。
5.4 IORDY signal PATA (IDE) defines a wait period tB in which the IORDY signal is at L level (inactive, negated) as shown in FIG. That is, in PIO read, the device side sets the IORDY signal to L level (inactive, negated) and then to H level (active, asserted), so that read data is ready (data is ready). The host is notified). When the IORDY signal changes from the L level to the H level, the host changes the XDIOR signal from the L level to the H level, and performs the read operation of the data DD [15: 0].
従って、ウェイト期間tBが長くなってしまうと、ホストが不必要に長期間待たされることになる。このため、ウェイト期間tBについてはその長さが規格で決められており、ウェイト期間tBが所定期間よりも長くなると、IORDY信号のアサートタイミング違反になる。 Therefore, if the wait period tB becomes long, the host waits unnecessarily for a long time. For this reason, the length of the wait period tB is determined by the standard, and if the wait period tB is longer than the predetermined period, the IORDY signal assert timing is violated.
ところが、本実施形態のようなPATAとSATAのブリッジ機能を有するデータ転送制御装置では、SATA側のデータ転送が遅れると、図13の期間tBについての規格を遵守できなくなるおそれがある。そこで本実施形態では以下に説明するようなIORDY信号の生成手法を採用している。 However, in the data transfer control device having the PATA-SATA bridge function as in this embodiment, if the data transfer on the SATA side is delayed, there is a possibility that the standard for the period tB in FIG. 13 cannot be observed. Therefore, in the present embodiment, a method for generating an IORDY signal as described below is adopted.
例えば図9において、PATA用データバッファ16には、ライト時にはホスト2からのデータがバッファリングされて、PATA用データバッファ16のデータがデータバッファ70に格納される。またPATA用データバッファ16には、リード時にはデータバッファ70からのデータがバッファリングされて、PATA用データバッファ16のデータがホスト2に出力される。
For example, in FIG. 9, the data from the
また図9のI/F信号生成回路18は、図2に示すPATA用の信号XCS〜XPDIAGを生成する。そしてこのI/F信号生成回路18は、IORDY信号生成回路19を含む。IORDY信号生成回路19は、PATA用の信号のうちIORDY信号を生成する。IORDY信号は、PIOリード転送時にホスト2へのデータレディ信号(ウェイト信号)として機能する。
Further, the I / F
このIORDY信号生成回路19には、図14(A)に示すように、例えばPATAI/F10のTFR12のセットタイミング信号と、PATA用データバッファ16のempty信号が入力される。
As shown in FIG. 14A, for example, a set timing signal of the
ここでセットタイミング信号は、例えばSFR52に設定されたレジスタ値がTFR12に転送されて書き込まれるタイミングでアクティブになる。具体的には、図12のステップS78に示すように、TFR12のステータスレジスタのビットが設定(BUSY=0、DRQ=1)されたタイミングで、アクティブになる。一方、PATA用データバッファ16のempty信号は、PATA用データバッファ16にデータが格納されていない場合にアクティブになる。
Here, the set timing signal becomes active, for example, at the timing when the register value set in the
このようなセットタイミング信号、empty信号が入力されることで、IORDY信号生成回路19は、図14(B)に示すようなタイミングのIORDY信号を生成する。具体的には、TFR12のステータスレジスタのビットが設定(BUSY=0、DRQ=1)された場合(タイミングTG1)に非アクティブ(Lレベル)になり、書き換え後のアイデンティファイ・デバイス情報であるリードデータがPATA用データバッファ16に蓄積された場合(タイミングTG2)にアクティブ(Hレベル)になるIORDY信号を生成する。
When such a set timing signal and empty signal are input, the IORDY
即ち、図14(A)のセットタイミング信号がアクティブになると、図14(B)のタイミングTG1でIORDY信号が非アクティブ(Lレベル)になる。また図14(A)のempty信号が非アクティブになり、PATA用データバッファ16にデータが蓄積されると、図14(B)のタイミングTG2でIORDY信号がアクティブ(Hレベル)になる。そしてIORDY信号がアクティブになると、ホスト2は、XDIOR信号をHレベルにして、データDD[15:0]をPATA用データバッファ16から読み出すことになる。
That is, when the set timing signal in FIG. 14A becomes active, the IORDY signal becomes inactive (L level) at the timing TG1 in FIG. 14B. When the empty signal in FIG. 14A becomes inactive and data is accumulated in the
このようにすれば、例えば図12のステップS78でTFR12のステータスレジスタにビットが設定されると、図14(B)のタイミングTG1でIORDY信号が非アクティブになる。また図12のステップS79でPIOリード転送の開始が指示されると、図14(B)のタイミングTG2でIORDY信号がアクティブになる。従って、データ転送制御装置を介してSATAデバイス4をブリッジ接続した場合にも、ウェイト期間tBを最小限の長さに抑えることができ、IORDY信号のアサートタイミング違反の発生を効果的に防止できる。
In this way, for example, when a bit is set in the status register of the
6.初期化シーケンス
次に、本実施形態の初期化シーケンス処理手法について具体的に説明する。
6). Initialization Sequence Next, the initialization sequence processing method of the present embodiment will be specifically described.
6.1 CSEL端子
PATAデバイスのシステムでは、PATAバスに対して最大で2台のデバイスを接続でき、これらの2台のデバイスのうちの一方がマスタになり、他方がスレーブになる。そして各デバイスは、自身がマスタなのかスレーブなのかを、ジャンパピンの設定又はケーブルセレクトの設定により判断する。またPATAバスに対して2台のデバイスを接続した場合にも、同じアドレスが2台のデバイスで共有して使用される。従って、ATAレジスタ(タスクファイル・レジスタ)に対してホストから書き込み動作があった場合には、マスタ及びスレーブの両方のデバイスが、PATAのデータDD[15:0](図2参照)のバスからそのデータを受け取り、各デバイスは、DEVビット等に基づいて、そのデータが自身に宛てたデータなのか否かを判断する。またATAレジスタに対するホストからの読み出し動作があった場合には、マスタ、スレーブの各デバイスは、その時点でのDEVビットの状態と自身のデバイス番号を比較し、一致した場合にのみ、アクセスされたATAレジスタの内容をデータDD[15:0]のバスに出力する。
6.1 CSEL Terminal In a PATA device system, up to two devices can be connected to the PATA bus, and one of these two devices becomes a master and the other becomes a slave. Each device determines whether it is a master or a slave by setting a jumper pin or setting a cable select. Also, when two devices are connected to the PATA bus, the same address is shared between the two devices. Therefore, when there is a write operation from the host to the ATA register (task file register), both the master and slave devices are connected from the PATA data DD [15: 0] (see FIG. 2) bus. Receiving the data, each device determines whether the data is addressed to itself based on the DEV bit or the like. When there is a read operation from the host to the ATA register, the master and slave devices compare the DEV bit state at that time with their own device numbers, and are accessed only when they match. The contents of the ATA register are output to the bus of data DD [15: 0].
このようにPATAデバイスにおいては、マスタ、スレーブの区別の概念があり、例えばATAのマスタ側にHDD等のデバイスを接続し、スレーブ側にCD、DVD等の光ディスクドライブのデバイスを接続するなどのシステム構成が可能になる。 As described above, the PATA device has a concept of distinguishing between master and slave. For example, a system in which a device such as an HDD is connected to the master side of the ATA and a device of an optical disk drive such as a CD or DVD is connected to the slave side. Configuration is possible.
ところが、SATAデバイスにはマスタ、スレーブの区別の概念が無く、SATAデバイスはマスタとして取り扱われる。従って、データ転送制御装置にPATAとSATAのブリッジ機能を持たせた場合に、何ら工夫をしないと、例えばSATAデバイスをマスタとしてのみ取り扱うことができるマスタ専用のデータ転送制御装置になってしまう。従って、例えば光ディスクドライブなどのSATAデバイスを、スレーブとして、本実施形態のデータ転送制御装置を介してPATAバスにブリッジ接続するようなシステム構成等を実現できないという問題がある。 However, the SATA device has no concept of distinguishing between master and slave, and the SATA device is treated as a master. Therefore, when the data transfer control device is provided with a PATA and SATA bridge function, if the device is not devised, for example, it becomes a data transfer control device dedicated to the master that can handle the SATA device only as the master. Therefore, for example, there is a problem that a system configuration or the like in which a SATA device such as an optical disk drive is connected as a slave to the PATA bus via the data transfer control device of this embodiment cannot be realized.
そこで本実施形態では、マスタ・スレーブの設定端子(決定端子)であるCSEL端子をデータ転送制御装置に設けている。そしてデータ転送制御装置は、このCSEL端子の状態(電圧設定状態)により、自身がマスタ側なのかスレーブ側なのかを判断するようにしている。 Therefore, in this embodiment, a CSEL terminal which is a master / slave setting terminal (determination terminal) is provided in the data transfer control device. The data transfer control device determines whether it is the master side or the slave side based on the state (voltage setting state) of the CSEL terminal.
例えば図15(A)では、CSEL端子がLレベル(GNDレベル)に設定されており、この場合には本実施形態のデータ転送制御装置3は、自身がマスタ側に設定されたと判断する。そしてデータ転送制御装置3とそれに接続されるSATAデバイス4により、PATAのマスタ側が構成される。これにより、本実施形態のデータ転送制御装置3を含むPATAのマスタ側と、PATAのスレーブ側とが、PATAバスに接続されるシステム構成を実現できる。
For example, in FIG. 15A, the CSEL terminal is set to L level (GND level), and in this case, the data
一方、図15(B)では、CSEL端子がHレベル(VDDレベル)に設定されており、この場合には本実施形態のデータ転送制御装置3は、自身がスレーブ側に設定されたと判断する。そしてデータ転送制御装置3とそれに接続されるSATAデバイス4により、PATAのスレーブ側が構成される。これにより、PATAのマスタ側と、本実施形態のデータ転送制御装置3を含むPATAのスレーブ側とが、PATAバスに接続されるシステム構成を実現できる。
On the other hand, in FIG. 15B, the CSEL terminal is set to H level (VDD level). In this case, the data
以上のように本実施形態では、PATAとSATAのブリッジ機能を有するデータ転送制御装置3に対して、マスタ・スレーブの設定端子であるCSEL端子を設けているため、例えば本来はマスタ、スレーブの区別の概念が無く、マスタとしてのみ取り扱われるSATAデバイス4を、データ転送制御装置3を介してPATAバスにブリッジ接続して、PATAのスレーブ側を構成することが可能になる。この結果、例えばSATAインターフェースを有する光ディスクドライブなどを、スレーブとして、PATAバスにブリッジ接続するシステム構成等を実現でき、利便性を大幅に向上できる。
As described above, in the present embodiment, since the CSEL terminal which is the master / slave setting terminal is provided for the data
6.2 初期化シーケンス管理の代行
前述のように、SATAデバイスにはマスタ、スレーブの区別の概念が無く、SATAデバイスはマスタとしてのみ取り扱われる。従って、SATAデバイスは、マスタ、スレーブを区別するための初期化シーケンス管理機能を有しない。従って、このようなSATAデバイスを、PATAとSATAのブリッジ機能を有するデータ転送制御装置を介してPATAバスにブリッジ接続した場合に、初期化シーケンスの処理を行う処理主体が存在しなくなってしまうという問題がある。
6.2 Proxy for Initialization Sequence Management As described above, there is no concept of master / slave differentiation in SATA devices, and SATA devices are handled only as masters. Therefore, the SATA device does not have an initialization sequence management function for distinguishing between a master and a slave. Accordingly, when such a SATA device is bridge-connected to the PATA bus via a data transfer control device having a PATA-SATA bridge function, there is no problem that there is no processing entity that performs the initialization sequence process. There is.
そこで本実施形態では、図1(A)、図1(B)の初期化シーケンス管理部34が、PATAにおける初期化シーケンス管理機能を有しないSATAデバイス4に代わって初期化シーケンス管理を代行する。例えば初期化シーケンス管理部34は、ハードリセット後、デバイス存在検知期間(10ms)内にSATAデバイス4の存在が検知された場合に、初期化シーケンス処理を実行する。具体的にはハードリセット後に、ホスト側であるSATAI/F50はOOBシーケンスにおけるCOMRESETを発行し、SATAデバイス4からのCOMINITを検出する。そして初期化シーケンス管理部34は、デバイス存在検知期間(10ms)内にSATAデバイス4からのCOMINITが検知された場合には、SATAデバイス4が存在すると判断して、本実施形態の初期化シーケンス処理を実行する。
Therefore, in the present embodiment, the initialization
更に具体的には初期化シーケンス管理部34は、図15(A)のようにCSEL端子(マスタ・スレーブ設定端子)によりデータ転送制御装置3がマスタ側に設定された場合には、ハードリセット後にスレーブ検知処理と自己診断処理を行う。一方、図15(B)のようにCSEL端子によりデータ転送制御装置3がスレーブ側に設定された場合には、ハードリセット後にスレーブ検知信号の制御と自己診断信号の制御を行う。
More specifically, the initialization
このようにすれば、SATAデバイス4が初期化シーケンス管理機能を有しない場合にも、データ転送制御装置3が、この初期化シーケンス管理を代行して、スレーブ検知等のPATAにおける初期化シーケンス処理を実行できる。従って、マスタとしてのみ取り扱われるSATAデバイス4を、例えばデータ転送制御装置3を介してPATAバスにブリッジ接続して、PATAのスレーブ側を構成した場合に、PATA規格に準拠した適正な初期化シーケンス処理を実行できるようになる。
In this way, even when the
次に初期化シーケンス処理の詳細について図16、図17を用いて説明する。図16はホスト側の動作を説明するためのフローチャートであり、図17はデバイス側の動作を説明するためのフローチャートである。 Next, the details of the initialization sequence process will be described with reference to FIGS. FIG. 16 is a flowchart for explaining the operation on the host side, and FIG. 17 is a flowchart for explaining the operation on the device side.
図16に示すようにホスト側は、ハードリセット信号をアクティブ(アサート状態)にした後、非アクティブ(ネゲート状態)にする(ステップS21、S22)。そしてステータスレジスタのBUSYビットが1から0にクリアされるのをウェイトし、0にクリアされるとホストアイドル状態に移行する(ステップS23、S24)。 As shown in FIG. 16, the host side makes the hard reset signal active (asserted) and then inactive (negated) (steps S21 and S22). Then, it waits for the BUSY bit of the status register to be cleared from 1 to 0, and when it is cleared to 0, it shifts to the host idle state (steps S23 and S24).
一方、図17に示すようにデバイス側は、ハードリセットが行われると、リリースバスステートに移行し、CSEL(CSEL端子、CSEL信号)がLレベルか否かを判断する(ステップS31、S32、S33)。即ち自身がマスタ側に設定されているか、スレーブ側に設定されているかを判断する。 On the other hand, as shown in FIG. 17, when a hard reset is performed, the device side shifts to a release bus state and determines whether or not CSEL (CSEL terminal, CSEL signal) is at L level (steps S31, S32, S33). ). That is, it is determined whether it is set on the master side or the slave side.
そしてCSELがLレベルに設定され、自身がマスタ側に設定されていると判断した場合には、XDASPウェイトステートに移行した後、サンプルXDSAPステートに移行する(ステップS34、S35)。このサンプルXDSAPステートでは、自身の初期化及び自己診断処理を行うと共に、スレーブ側からのスレーブ検知信号XDASPをサンプルしてモニタする。 If it is determined that the CSEL is set to the L level and that the CSEL is set to the master side, the process shifts to the XDASP wait state and then shifts to the sample XDSAP state (steps S34 and S35). In this sample XDSAP state, it performs initialization and self-diagnosis processing of itself, and samples and monitors the slave detection signal XDASP from the slave side.
そして信号XDASPがLレベル(アクティブ)であると判断した場合には、スレーブの存在が検知されたと判断して、サンプルXPDIAGステートに移行する(ステップS36、S37)。このサンプルXPDIAGステートでは、スレーブ側からの自己診断信号XPDIAG(スレーブの自己診断結果の通知信号)をサンプルしてモニタする。 If it is determined that the signal XDASP is at the L level (active), it is determined that the presence of the slave is detected, and the state shifts to the sample XPDIAG state (steps S36 and S37). In the sample XPDIAG state, a self-diagnosis signal XPDIAG (slave self-diagnosis result notification signal) from the slave is sampled and monitored.
そして信号XPDIAGがLレベル(アクティブ)であると判断した場合には、スレーブ側の自己診断がパスしたと判断し、タスクファイル・レジスタのエラーレジスタのビット7を0に設定する(ステップS38、S39)。一方、信号XPDIAGがHレベル(非アクティブ)であると判断した場合には、スレーブ側の自己診断がフェイルしたと判断し、エラーレジスタのビット7を1に設定する(ステップS40)。なおステップS36で、信号XDASPがHレベルであると判断された場合には、スレーブが非存在であると判断すると共に、エラーレジスタのビット7を0に設定する(ステップS41)。そしてセットステータスステートに移行し(ステップS42)、自己診断処理を完了すると共に、タスクファイル・レジスタのステータスレジスタのBUSYビットを0にクリアする。そしてデバイスアイドル状態に移行する(ステップS43)。
If it is determined that the signal XPDIAG is at L level (active), it is determined that the self-diagnosis on the slave side has passed, and
一方、ステップS33でCSELがHレベルに設定され、自身がスレーブ側に設定されていると判断した場合には、セットXDASPステートに移行する(ステップS44)。このセットXDASPステートでは、スレーブ検知信号XDASPをLレベル(アクティブ)にすると共に、自身の初期化及び自己診断処理を行う。このようにスレーブ側がスレーブ検知信号XDASPをLレベルにすることで、ステップS36に示すようにマスタ側はスレーブの存在を検知できる。 On the other hand, if it is determined in step S33 that CSEL is set to the H level and the slave is set on the slave side, the process proceeds to the set XDASP state (step S44). In this set XDASP state, the slave detection signal XDASP is set to L level (active), and its own initialization and self-diagnosis processing are performed. As described above, when the slave side sets the slave detection signal XDASP to the L level, the master side can detect the presence of the slave as shown in step S36.
次に、セットステータスステートに移行する(ステップS45)。そして自己診断信号XPDIAGをLレベル(アクティブ)又はHレベル(非アクティブ)にすると共に、タスクファイル・レジスタのステータスレジスタのBUSYビットを0にクリアし、デバイスアイドル状態に移行する(ステップS46)。このようにスレーブ側が信号XPDIAGをLレベルにすることで、ステップS39に示すようにマスタ側はスレーブ側の自己診断がパスしたと判断できる。またスレーブ側が信号XPDIAGをHレベルにすることで、ステップS40に示すようにマスタ側はスレーブ側の自己診断がフェイルしたと判断できる。 Next, the process proceeds to the set status state (step S45). Then, the self-diagnosis signal XPDIAG is set to L level (active) or H level (inactive), the BUSY bit of the status register of the task file register is cleared to 0, and the device idle state is entered (step S46). Thus, by setting the signal XPDIAG to the L level on the slave side, the master side can determine that the self-diagnosis on the slave side has passed as shown in step S39. Further, by setting the signal XPDIAG to the H level on the slave side, the master side can determine that the self-diagnosis on the slave side has failed as shown in step S40.
そして本実施形態では、初期化シーケンス管理部34は、CSEL端子がLレベルに設定され、自身がマスタ側に設定されたと判断した場合には、図17のステップS34〜S43に示すように、スレーブ検知処理と自己診断処理を行う。即ち、信号XDASPに基づいてスレーブが検知されたか否かを判断すると共に、マスタ側の自己診断処理や信号XPDIAGに基づくスレーブ側の自己診断結果の確認処理を行う。
In this embodiment, when the initialization
また初期化シーケンス管理部34は、CSEL端子がHレベルに設定され、自身がスレーブ側に設定されたと判断した場合には、図17のステップS44〜S46に示すように、スレーブ検知信号XDASP、自己診断信号XPDIAGの制御を行う。即ち、スレーブ検知信号XDASPをLレベルにして、スレーブの存在をマスタ側に通知する。また自己診断信号XPDIAGをLレベルにしたり、Hレベルにして、スレーブ側の自己診断結果をホスト側に通知する。
When the initialization
以上のような初期化シーケンス処理を初期化シーケンス管理部34に代行させることで、マスタとしてのみ取り扱われるSATAデバイスに、マスタ、スレーブの区別の概念を導入できると共に、PATAの規格にしたがった適正な初期化シーケンス処理を実現できる。
By substituting the initialization sequence processing as described above to the initialization
6.3 DEVビットの設定
前述したようにPATAでは、データDD[15:0]やアドレスDA[2:0]のバスは、マスタとスレーブで共用される。従って、マスタ及びスレーブの両方が、データDD[15:0]のバスからのコマンド、パラメータをタスクファイル・レジスタを介して受け取ることになる。そして、マスタへ宛てたものであるか、スレーブへ宛てたものであるかは、デバイス/ヘッドレジスタのDEVビットにより判断する。具体的にはDEVビットが0である場合にはマスタに宛てたものであると判断し、DEVビットが1である場合にはスレーブに宛てたものであると判断する。
6.3 Setting of DEV Bit As described above, in PATA, the bus of data DD [15: 0] and address DA [2: 0] is shared by the master and the slave. Therefore, both the master and the slave receive commands and parameters from the bus of the data DD [15: 0] via the task file register. Then, it is determined by the DEV bit of the device / head register whether the address is for the master or the slave. Specifically, when the DEV bit is 0, it is determined that the address is for the master, and when the DEV bit is 1, it is determined that the address is for the slave.
一方、SATAデバイスは、常にマスタとして取り扱われる。従ってSATAデバイスは、DEVビットが0に設定されたコマンド、パラメータだけを、自身に宛てたものとして受け取ることになる。 On the other hand, the SATA device is always handled as a master. Therefore, the SATA device receives only commands and parameters with the DEV bit set to 0 as being addressed to itself.
ところが、図15(B)に示すように、CSEL端子をHレベルにしてスレーブ設定にした場合には、ホスト2はSATAデバイス4をスレーブと見なしている。従って、SATAデバイス4に対してコマンドやパラメータを送る場合には、DEVビットをスレーブ設定である1に設定する。従って、自身がマスタであると認識しているSATAデバイス4は、これらのコマンドやパラメータを受け取れなくなってしまう。そこで本実施形態では、以下のようなDEVビット設定手法を採用している。
However, as shown in FIG. 15B, when the CSEL terminal is set to the H level and the slave is set, the
例えば図18(A)では、CSEL端子(CSEL信号)がLレベルに設定され、データ転送制御装置がマスタ側に設定されている。そしてホスト2がマスタへのATAコマンドを発行している。この場合には、シーケンスコントローラ30は、TFR12のレジスタ値(コマンド、パラメータ)をそのままSFR52に転送する。するとSATAI/F50は、SFR52のレジスタ値に基づいて、レジスタFIS(Host to Device)等を生成して、SATAデバイス4に送信する。
For example, in FIG. 18A, the CSEL terminal (CSEL signal) is set to L level, and the data transfer control device is set to the master side. The
このとき、TFR12のデバイス/ヘッドレジスタのDEVビット=0(マスタ設定)も、TFR12からSFR52にそのまま転送されて、SATAデバイス4に送信される。そしてSATAデバイス4は、自身をマスタとして認識しているため、ホスト2からのコマンドやパラメータを、問題なく受け取ることができる。
At this time, the DEV bit = 0 (master setting) of the device / head register of the
また図18(B)では、データ転送制御装置がマスタ側に設定されているときに、ホスト2からのATAコマンドに対応するFIS(例えばレジスタFIS、PIOセットアップFIS、DMAアクティベートFIS等)を、SATAI/F50がSATAデバイス4から受信している。この場合には、シーケンスコントローラ30は、SFR52のレジスタ値をTFR12にそのまま転送する。そしてホスト2は、SATAデバイス4からのステータス等を受け取る。
In FIG. 18B, when the data transfer control device is set on the master side, the FIS (for example, register FIS, PIO setup FIS, DMA activate FIS, etc.) corresponding to the ATA command from the
このとき、SFR52のデバイス/ヘッドレジスタのDEVビット=0(マスタ設定)も、SFR52からTFR12にそのまま転送される。従って、PATAI/F10は、マスタ側であるSATAデバイス4からのステータス等を、PATAのDD[15:0]のバスに適正に出力できるようになる。
At this time, the DEV bit = 0 (master setting) of the device / head register of the
一方、図19(A)では、CSEL端子がHレベルに設定され、データ転送制御装置がスレーブ側に設定されている。そしてホスト2がスレーブへのATAコマンドを発行している。この場合には、シーケンスコントローラ30は、デバイス/ヘッドレジスタのDEVビットを1(スレーブ設定)から0(マスタ設定)に書き換えて、TFR12のレジスタ値をSFR52に転送する。するとSATAI/F50は、SFR52のレジスタ値に基づいて、レジスタFIS(H to D)等を生成して、SATAデバイス4に送信する。
On the other hand, in FIG. 19A, the CSEL terminal is set to H level, and the data transfer control device is set to the slave side. The
このとき、SATAデバイス4は、自身をマスタとして認識しているが、本実施形態ではDEVビットを1(スレーブ設定)から0(マスタ設定)に書き換えているため、ホスト2からのコマンドやパラメータを問題なく受け取ることができる。
At this time, the
また図19(B)では、データ転送制御装置がスレーブ側に設定されているときに、ホスト2からのATAコマンドに対応するFISを、SATAI/F50がSATAデバイス4から受信している。この場合には、シーケンスコントローラ30は、SFR52のデバイス/ヘッドレジスタのDEVビットを0(マスタ設定)から1(スレーブ設定)に書き換えて、SFR52のレジスタ値をTFR12に転送する。そしてホスト2は、SATAデバイス4からのステータス等を受け取る。
In FIG. 19B, when the data transfer control device is set to the slave side, the SATA I /
このとき、ホスト2は、SATAデバイス4をスレーブとして認識しているが、本実施形態ではDEVビットを0(マスタ設定)から1(スレーブ設定)に書き換えているため、SATAデバイス4からのステータス等を問題なく受け取ることができる。
At this time, the
以上のように本実施形態では、CSEL端子の状態に応じた適正な値に、デバイス/ヘッドレジスタのDEVビットを書き換えている。従って、CSEL端子によりデータ転送制御装置をスレーブ側に設定した場合にも、ホスト2と、自身をマスタと認識しているSATAデバイス4との間で、コマンド、パラメータやステータスの適正な転送処理を実現できる。
As described above, in this embodiment, the DEV bit of the device / head register is rewritten to an appropriate value according to the state of the CSEL terminal. Therefore, even when the data transfer control device is set to the slave side by the CSEL terminal, appropriate transfer processing of commands, parameters, and status is performed between the
次に本実施形態のDEVビットの設定手法について図20、図21のフローチャートを用いて更に詳細に説明する。 Next, the DEV bit setting method of the present embodiment will be described in more detail with reference to the flowcharts of FIGS.
図20では、ホスト2がマスタへのATAコマンドを発行している(ステップS51)。そしてCSEL端子がLレベルか否かを判断し(ステップS52)、Lレベルである場合には、図18(A)で説明したようにTFR12のレジスタ値をそのままSFR52に転送する(ステップS53)。そしてSATAデバイス4へのコマンドの転送及び実行が行われる(ステップS54)。
In FIG. 20, the
次に、SATAデバイス4からステータス返送のためのFIS(レジスタFIS等)を受信すると(ステップS55)、図18(B)で説明したようにSFR52のレジスタ値をそのままTFR12に転送する(ステップS56)。
Next, when an FIS (register FIS or the like) for status return is received from the SATA device 4 (step S55), the register value of the
一方、ステップS52でCSEL端子がHレベルであると判断された場合には、ホスト2により発行されたATAコマンドは非実行になる(ステップS57)。即ち、ホスト2が発行したATAコマンドはマスタへ宛てたものであり、CSEL端子はスレーブ側に設定されているため、スレーブ側であるデータ転送制御装置は、このATAコマンドの実行処理を行わない。
On the other hand, if it is determined in step S52 that the CSEL terminal is at the H level, the ATA command issued by the
図21では、ホスト2がスレーブへのATAコマンドを発行している(ステップS61)。そしてCSEL端子がLレベルか否かを判断し(ステップS62)、LレベルではなくHレベルである場合には、図19(A)で説明したようにTFR12のデバイス/ヘッドレジスタのDEVビットを0(マスタ設定)に書き換えて、TFR12のレジスタ値をSFR52に転送する(ステップS63)。そしてSATAデバイス4へのコマンドの転送及び実行が行われる(ステップS64)。
In FIG. 21, the
次に、SATAデバイス4からステータス返送のためのFIS(レジスタFIS等)を受信すると(ステップS65)、図19(B)で説明したようにSFR52のデバイス/ヘッドレジスタのDEVビットを1(スレーブ設定)に書き換えて、SFR52のレジスタ値をTFR12に転送する(ステップS66)。
Next, when an FIS (register FIS or the like) for status return is received from the SATA device 4 (step S65), the DEV bit of the device / head register of the
一方、ステップS62でCSEL端子がLレベルであると判断された場合には、ホスト2により発行されたATAコマンドは非実行になる(ステップS67)。即ち、ホスト2が発行したATAコマンドはスレーブへ宛てたものであり、CSEL端子はマスタ側に設定されているため、マスタ側であるデータ転送制御装置は、このATAコマンドの実行処理を行わない。
On the other hand, if it is determined in step S62 that the CSEL terminal is at the L level, the ATA command issued by the
7.受信FISの種類による転送シーケンス制御
本実施形態のようにブリッジ機能を有するデータ転送制御装置では、ホスト2が発行したATAコマンドに応じた転送シーケンス制御を行う必要がある。そして転送シーケンス制御の内容をデータ転送制御装置が知るためには、ATAコマンドをデコードする必要があり、そのために、コマンドデコーダやパラメータテーブルが必要になる。即ちホスト2が発行したコマンドをデコードし、転送方向(リード、ライト)や転送種別(PIO(Programmed I/O)、DMA)を判別し、内部転送シーケンスを決定する。
7). Transfer sequence control according to the type of reception FIS In a data transfer control device having a bridge function as in this embodiment, it is necessary to perform transfer sequence control according to an ATA command issued by the
しかしながら、このようなコマンドデコーダを設けると、データ転送制御装置のロジック回路の大規模化やメモリ容量の増加に繋がる。またATAコマンドのデコードを行うためには、デコードのためのコマンドテーブルを持たなければならないが、データ転送制御装置の開発終了後に、規格において新規コマンドの追加が発生した場合には、データ転送制御装置の回路修正を行わない限り、新規コマンドをサポートできなくなる。例えばATAPIでは、ブルーレイディスクなどの新しい規格の光ディスクドライブが追加されると、パラメータテーブルの変更が必要になる。従って、開発が終了している既存のデータ転送制御装置を使用できず、パラメータテーブル(テーブルメモリ)を変更するための回路修正が必要になり、余分な開発期間や開発コストがかかってしまう。更にベンダーにユニークな特殊コマンドに対しても、対応することが難しい。 However, providing such a command decoder leads to an increase in the scale of the logic circuit of the data transfer control device and an increase in memory capacity. In addition, in order to decode an ATA command, it must have a command table for decoding. If a new command is added in the standard after development of the data transfer control device is completed, the data transfer control device Unless the circuit is corrected, new commands cannot be supported. For example, in ATAPI, when a new standard optical disc drive such as a Blu-ray disc is added, the parameter table must be changed. Therefore, it is not possible to use an existing data transfer control device for which development has been completed, and it is necessary to modify a circuit for changing the parameter table (table memory), resulting in an extra development period and development cost. Furthermore, it is difficult to deal with special commands unique to vendors.
この場合にデータ転送制御装置にCPU(処理部)を内蔵させ、パラメータテーブルの変更をファームウェア等の書き換えにより実現すれば、新規コマンドが増えたり、コマンドの内容が変更された場合にも、これに対応できる。 In this case, if the CPU (processing unit) is built in the data transfer control device and the parameter table is changed by rewriting the firmware or the like, even if new commands increase or the contents of the commands are changed, Yes.
しかしながら、データ転送制御装置にCPUを内蔵させると、CPU上で動作するファームウェアの開発や、CPUの動作確認のためのデバッグツールの開発などが必要になってしまい、開発期間の長期化や高コスト化を招く。 However, if the CPU is built in the data transfer control device, it will be necessary to develop firmware that runs on the CPU, and to develop a debugging tool for checking the operation of the CPU. Invite
このような問題を解決するための図22(A)〜図23(C)に示す手法では、ホストが発行したコマンドをデコードすることなくデバイスに転送し、デバイスから返送されてきたFISの情報に基づいて、発行されたコマンドについての転送シーケンスを制御する。即ちATAコマンドのデコードを、データ転送制御装置が行うのではなく、SATAデバイスに行わせる。そしてデータ転送制御装置は、ATAコマンドをデコードせずに(一部をデコードしてもよい)、SATAデバイスにそのまま転送し、SATAデバイスの反応を観察することで、自身の転送シーケンスを決定して実行する。 In the method shown in FIGS. 22A to 23C for solving such a problem, the command issued by the host is transferred to the device without decoding, and the FIS information returned from the device is used. Based on this, the transfer sequence for the issued command is controlled. That is, the ATA command is not decoded by the data transfer control device, but is made to be performed by the SATA device. Then, the data transfer control device transfers the ATA command to the SATA device without decoding the ATA command (or may decode a part thereof), and determines its own transfer sequence by observing the reaction of the SATA device. Execute.
具体的には図22(A)に示すようにホスト2がPATAバスを介してATAコマンド(転送コマンド)を発行すると、PATAI/F10がこのコマンドを受ける。そしてSATAI/F50は、発行されたATAコマンドを含むレジスタFIS(Host to Device)を作成して、SATAバスを介してデバイス4に送信する。
Specifically, as shown in FIG. 22A, when the
デバイス4側のSATAI/F(図示せず)は、レジスタFISを受信すると、デコード処理を行い、レジスタFIS(ATAコマンド)に対応するFISを送信し、このFISをSATAI/F50が受信する。
When the SATA I / F (not shown) on the
シーケンスコントローラ30(転送シーケンサ、ブリッジシーケンサ)は、レジスタFISに対応するFISをSATAI/F50がデバイス4から受信すると、ホスト2から発行されたATAコマンドの転送シーケンス制御として、受信したFISの種類に応じた転送シーケンス制御を行う。
When the SATA I /
より具体的には図22(B)ではホスト2はPIOリードのATAコマンドを発行している。この場合にはデバイス4は、転送方向がリード方向であるPIOセットアップFISを送信する。即ちPIOのデータ転送の直前にデバイス4がホスト2に転送するFISであるPIOセットアップFISを、デバイス4が送信し、SATAI/F50が受信する。このPIOセットアップFISは、データ転送の初期ステータス(Status)及びステータス終了値(E_Status)を有する。
More specifically, in FIG. 22B, the
このように受信FISがPIOセットアップFISであり、PIOセットアップFISにより指定される転送方向がリード方向である場合には、シーケンスコントローラ30は、PIOリードの転送シーケンス制御を行う。即ちシーケンスコントローラ30は、PIOリードの転送シーケンスのための制御信号(転送方向設定信号、転送開始信号、転送停止信号等)をSATAI/F50、データバッファ70、PATAI/F10に出力する。これにより、デバイス4から読み出されたデータが、SATAI/F50、データバッファ70、PATAI/F10を介してホスト2に転送される。
As described above, when the reception FIS is the PIO setup FIS and the transfer direction designated by the PIO setup FIS is the read direction, the
図22(C)では、ホスト2はPIOライトのATAコマンドを発行している。この場合にはデバイス4は、転送方向がライト方向であるPIOセットアップFISを送信し、SATAI/F50が受信する。
In FIG. 22C, the
このように受信FISがPIOセットアップFISであり、PIOセットアップFISにより指定される転送方向がライト方向である場合には、シーケンスコントローラ30は、PIOライトの転送シーケンス制御を行う。即ちシーケンスコントローラ30は、PIOライトの転送シーケンスのための制御信号をPATAI/F10、データバッファ70、SATAI/F50に出力する。これにより、ホスト2からのデータが、PATAI/F10、データバッファ70、SATAI/F50を介してデバイス4に転送される。
As described above, when the reception FIS is the PIO setup FIS and the transfer direction designated by the PIO setup FIS is the write direction, the
図23(A)では、ホスト2はDMAリードのATAコマンドを発行している。この場合にはデバイス4はデータFISを送信する。即ちデバイス4はデータ転送のためのFISであるデータFISを送信し、SATAI/F50が受信する。
In FIG. 23A, the
このように受信FISがデータFISである場合には、シーケンスコントローラ30は、DMAリードの転送シーケンス制御を行う。これにより、デバイス4から読み出されたデータが、SATAI/F50、データバッファ70、PATAI/F10を介してホスト2にDMA転送される。
Thus, when the reception FIS is the data FIS, the
図23(B)では、ホスト2はDMAライトのATAコマンドを発行している。この場合にはデバイス4はDMAアクティベートFISを送信する。即ちDMAの実行準備が出来ていることをホスト2に知らせるためのDMAアクティベートFISを、デバイス4が送信し、SATAI/F50が受信する。
In FIG. 23B, the
このように受信FISがDMAアクティベートFISである場合には、シーケンスコントローラ30は、DMAライトの転送シーケンス制御を行う。これにより、ホスト2からのデータが、PATAI/F10、データバッファ70、SATAI/F50を介してデバイス4にDMA転送される。
As described above, when the reception FIS is the DMA activate FIS, the
図23(C)では、ホスト2はノーデータコマンドのATAコマンドを発行している。この場合にはデバイス4はレジスタFIS(Device to Host)を送信し、SATAI/F50が受信する。このように、ATAコマンドに対応する受信FISが、デバイス4からホスト2へのレジスタFISである場合には、シーケンスコントローラ30は、ホスト2から発行されたATAコマンドはノーデータコマンドであると判断する。そしてレジスタFISのレジスタ値を、SATAI/F50のシャドウ・タスクファイル・レジスタからPATAI/F10のタスクファイル・レジスタに反映させる。
In FIG. 23C, the
以上のように、図22(A)〜図23(C)の手法によれば、ホスト2が発行したATAコマンドをデコードしなくても、デバイス4からの受信FIS情報に基づいて、発行されたATAコマンドの種別を判断して、そのATAコマンドに対応する転送シーケンス制御を実現できる。従って、コマンドデコーダの回路を節約でき、データ転送制御装置の小規模化を図れる。また、規格において新規コマンドの追加が発生しても、データ転送制御装置の回路修正を行うことなく、これに対応できる。またデータ転送制御装置にCPUを内蔵させなくても済むため、CPU上で動作するファームウェアの開発やデバッグツールの開発が不要になり、開発期間を短縮化でき、開発コストを低減できる。なおデータ転送制御装置にATAコマンドの一部をデコードする回路を設けたり、CPU(処理部)を内蔵させる変形実施も可能である。
As described above, according to the method shown in FIGS. 22A to 23C, the ATA command issued by the
以上のような図22(A)〜図23(C)の手法を採用すれば、コマンドデコード回路を節約できるが、ホスト2がアイデンティファイ・デバイス・コマンドを発行した場合には、図9〜図14(B)で説明したように、通常のPIO転送とは異なる転送シーケンス制御が必要になる。例えば図9で説明したように、アイデンティファイ・デバイス情報であるリードデータを、データバッファ70から読み出して書き換え処理を行って書き戻す転送シーケンス制御や、図13〜図14(B)で説明したようなIORDY信号に関する特別な転送シーケンス制御が必要になる。
If the method of FIGS. 22A to 23C as described above is adopted, the command decoding circuit can be saved. However, when the
そこで本実施形態では、図22(A)〜図23(C)に示すような、受信FISの種類に応じた転送シーケンス制御を行う他に、ホスト2から発行されたATAコマンドが前記アイデンティファイ・デバイス・コマンドであった場合には、アイデンティファイ・デバイス情報が設定されたデータFISを受信したときに、図9〜図14(B)で説明したようなアイデンティファイ・デバイス・コマンドに対応する転送シーケンス制御を行う。このようにすれば、PATAとSATAのバスブリッジ機能を実現しながらホストとSATAデバイスとの間の転送の整合性についても適正に維持できるようになる。
Therefore, in this embodiment, in addition to performing transfer sequence control according to the type of reception FIS as shown in FIGS. 22A to 23C, an ATA command issued from the
なお図24にPIOリードの転送シーケンス図を示す。ホスト2によりPIOリードのコマンドが発行されると、図24のA1に示すようにTFR12のステータスレジスタがD0hに設定される。即ちPATAI/F10によりBUSYビットが1にセットされ、デバイス4がビジー状態であることがホスト2に知らされる。そしてシーケンスコントローラ30によりTFR12のレジスタ値がSFR52に転送(コピー)される。するとA2に示すように、SATAI/F50は、SFR52のレジスタ値に基づいてPIOリードコマンドを含むレジスタFIS(Host to Device)を作成し、SATAバスを介してデバイス4に送信する。
FIG. 24 is a PIO read transfer sequence diagram. When the PIO read command is issued by the
このレジスタFISを受信したデバイス4は、A3に示すようにPIOセットアップFISを送信する。この場合に図8(C)のPIOセットアップFISのステータス(Status)には58hが設定され、エンドステータス(E_Status)にはD0hが設定される。ここでD0hではBUSYビットが1にセットされ、58hではDRQビットが1にセットされる。また50hではBUSYビット及びDRQビットが共に0にクリア(解除)される。またエンドステータスは例えばSATAI/F50の一時保存レジスタに保存される。
The
シーケンスコントローラ30は、デバイス4からPIOセットアップFISを受信し、その方向パラメータD(図8(C)参照)がデバイスからホストへの方向である場合には、ホスト2が発行したコマンドはPIOリードであると判断する。そしてSFR52からTFR12にレジスタ値を転送し、A4に示すようにTFR12のステータスレジスタを58hに設定して、DRQビットを1にセットする。これによりホスト2に対する割り込みINTRQが発生する。なおINTRQの代わりにホスト2によるポーリングを採用してもよい。
When the
そしてデバイス4からデータFISを受信し、ホスト2がデータをリードすると、A5に示すように、PIOセットアップFISのエンドステータスであるD0hがTFR12のステータスレジスタに設定され、BUSYビットが1にセットされる。即ちSATAI/F50の一時保存レジスタに保存されたエンドステータス(D0h)が、TFR12のステータスレジスタに転送されて書き込まれる。これにより、デバイス4がビジー状態であることがホスト2に知らされる。
When the data FIS is received from the
以上のようにして各セクタのPIOリードが繰り返される。そしてA6に示すように最後のセクタのPIOセットアップFISではエンドステータスが50h又は51hになっている。従ってA7に示すようにこのエンドステータス50h又は51hがTFR12のステータスレジスタに設定され、DRQビットがクリアされる。これにより、全てのデータ転送が完了したことがホスト2に知らされる。
As described above, the PIO read of each sector is repeated. As shown in A6, the end status is 50h or 51h in the PIO setup FIS of the last sector. Therefore, as shown at A7, the end status 50h or 51h is set in the status register of the
8.SATAI/Fの構成
図25にSATAI/F50の構成例を示す。なおSATAI/F50の構成は図25に限定されず、その構成要素の一部を削除したり、他の構成要素を追加するなどの種々の変形実施が可能である。例えば物理層回路200を設けない構成としてもよい。
8). SATA I / F Configuration FIG. 25 shows a configuration example of the SATA I /
SATAでは、データは32ビット(4バイト)単位で処理される。この32ビットのデータが、リンクコントローラ150により8b/10bでエンコードされて40ビットのデータになり、物理層回路200に送られる。物理層回路200は、この40ビットのデータをシリアル化してSATAのケーブルに送信する。受信も逆の手順で、シリアルデータが物理層回路200で40ビットのデータに変換され、リンクコントローラ150で32ビットのデータに変換され、トランスポートコントローラ110に送られる。
In SATA, data is processed in units of 32 bits (4 bytes). The 32-bit data is encoded at 8b / 10b by the
トランスポートコントローラ110はトランスポート層の制御を行うものである。具体的にはトランスポートコントローラ110は、上位層(アプリケーション層)からFISの送信要求が来た時に、以下の処理を行う。
The
まずトランスポートコントローラ110は、FISタイプの要件に基づいてFISの内容を収集する。また送信する情報をFISのタイプ毎に定義フォーマットに配置する。次にリンクコントローラ150に対して送信要求を通知する。これによりリンクコントローラ150はX_RDYの送信処理を行う。そして相手ノードからのR_RDYを受信し、リンクコントローラ150から受信のアクノリッジが来ると、トランスポートコントローラ110はFISをリンクコントローラ150に転送する。そして送信FIFO120のフロー管理を行い、必要なフロー制御をリンクコントローラ150に通知する。その後、リンクコントローラ150から送信結果を受信すると、必要に応じて上位層に送信結果を通知する。
First, the
トランスポートコントローラ110は、リンクコントローラ150からFISを受信した時には、以下の処理を行う。
When the
トランスポートコントローラ110は、リンクコントローラ150からFISを受信すると、受信したFISのタイプを判別する。そしてFISのタイプに応じた適切なレジスタやFIFOにデータを転送する。そして受信FIFO122のフロー管理を行い、必要なフロー制御をリンクコントローラ150に通知する。その後、リンクコントローラ150及び上位層(アプリケーション層)に受信結果を通知する。
When the
リンクコントローラ150はリンク層の制御を行うものである。具体的にはリンクコントローラ150は、送信時には以下の処理を行う。
The
まずリンクコントローラ150はトランスポートコントローラ110からのデータ(FIS)を受け取る。そしてFISのCRCを生成し、FISの最後尾に付加する。次にデータのスクランブルを行い、その後、8b/10bのエンコードを行う。そしてSATA通信のプロトコルにしたがったプリミティブ、FISの送信を行う。そして送信結果をトランスポートコントローラ110に通知する。
First, the
リンクコントローラ150は受信時には以下の処理を行う。即ちリンクコントローラ150は物理層回路200から、8b/10bエンコードキャラクタを受信する。そして8b/10bエンコードキャラクタをデコードし、デコードしたプリミティブを処理部等に通知する。次にデコードしたFISのデスクランブル処理を行い、CRCをチェックする。そしてトランスポートコントローラ110にデータを渡す。またデコード結果やCRCのチェック結果をトランスポートコントローラ110に通知する。
The
物理層回路200は物理層を実現するアナログフロントエンド回路である。この物理層回路200は、シリアルデータ(シリアルストリーム)の送受信や、シリアルデータからパラレルデータへの変換や、パラレルデータからシリアルデータへの変換を行う。また8b/10bのK28.5キャラクタの検出や、OOB(Out Of Band)信号の検出と送信を行う。またデバイスステータス(デバイスの有無、転送状態、パワー状態)の提供や、通信制御用のインターフェース(転送レート制御、ループバック)の提供を行う。またオプションでパワーマネージメントも行う。
The
物理層回路(PHY)200はトランスミッタ(ドライバ)210、レシーバ220、OOB検出回路230などを含む。
The physical layer circuit (PHY) 200 includes a transmitter (driver) 210, a
トランスミッタ210は、差動信号線(差動信号線ペア)TX+/−を介してシリアルデータ(パケット)の送信を行い、レシーバ220は、差動信号線(差動信号線ペア)RX+/−を介してシリアルデータ(パケット)の受信を行う。TX+/−、RX+/−のSATAバス(広義にはシリアルバス)では、振幅電圧+/−250mVのNRZ差動信号によるシリアルストリーム転送が行われる。
The
OOB検出回路230はOOB信号の検出処理を行う。このOOB信号は、SATAインターフェースのリセット/初期化、通信の確立や、スピード・ネゴシエーションをつかさどる信号である。
The
リンクコントローラ150は、リンクステート制御回路160、フレーム生成回路190、フレームデコード回路192を含む。
The
リンクステート制御回路160は、リンクコントローラ150のステート制御を行う。例えばリセットステート、アイドルステート、送信ステート、受信ステート等のステート間の遷移処理等を行う。
The link
フレーム生成回路190は、トランスポートコントローラ110からの送信データ(FIS)や、リンクステート制御回路160からの送信制御信号などに基づいてフレームの生成処理を行う。具体的には、トランスポートコントローラ110からのFISのCRCを演算したり、スクランブル処理を行ったり、8b/10bエンコード処理を行ったり、プリミティブを生成して付加する処理などを行う。
The
フレームデコード回路192は、受信したフレームの解析(分解)処理を行い、受信解析信号(パワーダウンリクエスト信号等)をリンクステート制御回路160に出力する。具体的には、FISに付加されたプリミティブを解析したり、8b/10bのデコード処理を行ったり、デスクランブル処理を行ったり、CRCを演算してチェックする処理などを行う。
The
トランスポートコントローラ110は、割りこみコントローラ118、DMA制御回路119、送信FIFO120、受信FIFO122、FIS生成回路130、FISデコード回路132、トランスポートステート制御回路140を含む。
The
割り込みコントローラ118は、デバイス4からの受信FIS情報などを知らせるための割り込み信号を生成する。DMA制御回路119は、FISに含まれる送信データや受信データ(コンテンツ・データ)のDMA転送を制御する。送信FIFO120は、DMA制御回路119からの送信データのバッファとなるFIFOである。受信FIFO122は、リンクコントローラ150からの受信データのバッファとなるFIFOである。FIS生成回路130はFISの生成を行う回路であり、FISデコード回路132はFISの解析を行う回路である。トランスポートステート制御回路140は、トランスポートコントローラ110のステート制御を行う。
The interrupt
9.シーケンスコントローラ
図26にシーケンスコントローラ30の構成例を示す。シーケンスコントローラ30はレジスタ更新部32、初期化シーケンス管理部34、パラメータ書き換え部36、DMAモード設定記憶部38、転送制御部40を含む。なおシーケンスコントローラ30の構成は図26に限定されず、その構成要素の一部を削除したり、他の構成要素を追加するなどの種々の変形実施が可能である。
9. Sequence Controller FIG. 26 shows a configuration example of the
レジスタ更新部32はTFR12(タスクファイル・レジスタ)、SFR52(シャドウ・タスクファイル・レジスタ)のレジスタ値の更新処理を行う。具体的にはTFR12のレジスタ値をSFR52に転送してSFR52のレジスタ値を更新したり、SFR52のレジスタ値をTFR12に転送してTFR12のレジスタ値を更新する。
The
例えばTFR12にホスト2によりATAコマンドが書き込まれると、PATAI/F10はコマンドライト検出信号をアクティブにする。そしてコマンドライト検出信号がアクティブになると、レジスタ更新部32はTFR12のレジスタ値をSFR52に転送する処理を行う。
For example, when an ATA command is written to the
またSATAI/F50は、デバイス4から受信したFISをデコードし、デコード結果に基づいて、FISの種類を知らせるための割り込み信号(広義には受信FIS情報)を生成して出力する。レジスタ更新部32は、この割り込み信号に基づいて受信FISの種類を判別して、SFR52からTFR12へのレジスタ値の転送処理などを行って、レジスタ値の更新処理を行う。
The SATA I /
初期化シーケンス管理部34は、HRST(ハードリセット)、SRST(ソフトリセット)に伴う初期化シーケンスを管理する。具体的には、マスター、スレーブなどの設定をモニタして、PATAの初期化シーケンスを管理する。
The initialization
パラメータ書き換え部36は、ホスト2がデバイス4に対してアイデンティファイ・デバイス・コマンドを発行し、デバイス4からデバイス情報のパラメータを受信した場合に、パラメータの書き換え処理を行う。即ち転送速度などのパラメータを自身が対応可能なパラメータに書き換える。
The
DMAモード設定記憶部38は、ホスト2がセットフューチャー・コマンドを発行した場合に、セットフューチャー・コマンドを解析して、DMA転送のモード設定を記憶する。
When the
転送制御部40はデータ転送制御装置の転送シーケンスを制御するものであり、モニタ部42、制御信号生成部44を含む。モニタ部42は、PATAI/F10からのコマンドライト検出信号や、SATAI/F50からの割り込み信号(受信FIS情報)などの信号をモニタする。そして制御信号生成部44は、モニタ結果に基づいて、転送方向設定信号、転送開始信号、転送停止信号などの制御信号を生成し、PATI/F10、データバッファ70、SATAI/F50に出力して、転送シーケンス制御を実行する。なおデータバッファ70に対しては転送開始信号、転送停止信号は出力せず、転送方向設定信号を出力する。
The
10.電子機器
図27に本実施形態の電子機器の構成例を示す。この電子機器は、本実施形態で説明したデータ転送制御装置310とホスト302とデバイス304を含む。ホスト302とデータ転送制御装置310はPATAバスを介して接続され、データ転送制御装置310とデバイス304はSATAバスを介して接続される。なお本実施形態の電子機器の構成は図27に限定されず、その構成要素の一部を省略したり、他の構成要素を付加する変形実施が可能である。
10. Electronic Device FIG. 27 shows a configuration example of the electronic device of this embodiment. This electronic apparatus includes the data
同図においてデバイス304は、HDD(ハードディスクドライブ)等のストレージデバイスや、光ディスクドライブ(CD、DVD)等である。
In the figure, a
ホスト302は、処理部330(CPU)、ROM340、RAM350、表示部360、操作部370を含むことができる。処理部330(CPU)はデータ転送制御装置310や電子機器の全体制御を行う。なおデータ転送制御装置310を制御する処理部と、電子機器を制御する処理部とを別々に設けてもよい。ROM340は制御プログラムや各種データを記憶する。RAM350は処理部330やデータ転送制御装置310のワーク領域やデータ格納領域として機能する。表示部360は種々の情報をユーザに表示する。操作部370はユーザが電子機器を操作するためのものである。
The
本実施形態の電子機器によれば、ホスト302がSATAI/Fを有していない場合にも、データ転送制御装置310を介してSATAのデバイス304をホスト302に接続して、あたかもPATAのデバイスのように扱うことが可能になる。
According to the electronic apparatus of the present embodiment, even when the
なお、本実施形態を適用できる電子機器としては、カーナビゲーションシステム、車載用オーディオ機器、HDDレコーダ、ビデオカメラ、携帯型音楽プレーヤ、携帯型映像プレーヤ、ゲーム装置、又は携帯型ゲーム装置等の種々のものが考えられる。 Note that various electronic devices such as a car navigation system, an in-vehicle audio device, an HDD recorder, a video camera, a portable music player, a portable video player, a game device, or a portable game device can be applied to the electronic device. Things can be considered.
なお、上記のように本実施形態について詳細に説明したが、本発明の新規事項および効果から実体的に逸脱しない多くの変形が可能であることは当業者には容易に理解できるであろう。従って、このような変形例はすべて本発明の範囲に含まれるものとする。例えば、明細書又は図面において、少なくとも一度、より広義または同義な異なる用語と共に記載された用語は、明細書又は図面のいかなる箇所においても、その異なる用語に置き換えることができる。またデータ転送制御装置、電子機器の構成、動作も本実施形態で説明したものに限定に限定されず、種々の変形実施が可能である。また本実施形態では、SATAへの本発明の適用例について説明したが、本発明は、SATAと同様の思想に基づく規格や、SATA(SATA I、SATA II、SAS)を発展させた規格等にも適用できる。 Although the present embodiment has been described in detail as described above, it will be easily understood by those skilled in the art that many modifications can be made without departing from the novel matters and effects of the present invention. Accordingly, all such modifications are intended to be included in the scope of the present invention. For example, a term described at least once together with a different term having a broader meaning or the same meaning in the specification or the drawings can be replaced with the different term in any part of the specification or the drawings. Further, the configuration and operation of the data transfer control device and the electronic device are not limited to those described in the present embodiment, and various modifications can be made. In this embodiment, the application example of the present invention to SATA has been described. However, the present invention is based on a standard based on the same idea as SATA, a standard developed from SATA (SATA I, SATA II, SAS), or the like. Is also applicable.
2 ホスト、4 デバイス、10 PATAI/F、
12 タスクファイル・レジスタ(TFR)、14 転送コントローラ、
30 シーケンスコントローラ、32 レジスタ更新部、
34 初期化シーケンス管理部、36 パラメータ書き換え部、
38 DMA転送設定記憶部、40 転送制御部、
42 モニタ部、44 制御信号生成部、50 SATAI/F、
52 シャドウ・タスクファイル・レジスタ(SFR)、70 データバッファ、
72 メモリコントローラ、74 FIFOメモリ、
110 トランスポートコントローラ、118 割りこみコントローラ、
120 送信FIFO、122 受信FIFO、130 FIS生成回路、
132 FISデコード回路、150 リンクコントローラ、
160 リンクステート制御回路、190 フレーム生成回路、
192 フレームデコード回路、200 物理層回路、210 トランスミッタ、
220 レシーバ、230 OOB検出回路
2 hosts, 4 devices, 10 PATA I / F,
12 Task file register (TFR), 14 Transfer controller,
30 sequence controller, 32 register update unit,
34 initialization sequence management unit, 36 parameter rewriting unit,
38 DMA transfer setting storage unit, 40 transfer control unit,
42 monitor unit, 44 control signal generation unit, 50 SATA I / F,
52 shadow task file register (SFR), 70 data buffer,
72 memory controller, 74 FIFO memory,
110 Transport controller, 118 Interrupt controller,
120 transmission FIFO, 122 reception FIFO, 130 FIS generation circuit,
132 FIS decoding circuit, 150 link controller,
160 link state control circuit, 190 frame generation circuit,
192 frame decoding circuit, 200 physical layer circuit, 210 transmitter,
220 receiver, 230 OOB detection circuit
Claims (14)
パラレルATAバスに接続され、ホストとの間のインターフェースを行うパラレルATAインターフェースと、
シリアルATAバスに接続され、シリアルATAのデバイスとの間のインターフェースを行うシリアルATAインターフェースと、
転送シーケンス制御を行うシーケンスコントローラを含み、
前記パラレルATAインターフェースは、タスクファイル・レジスタを有し、
前記シリアルATAインターフェースは、
前記ホストによりアイデンティファイ・デバイス・コマンドが発行された場合に、前記アイデンティファイ・デバイス・コマンドに対応するレジスタFISを前記シリアルATAの前記デバイスに送信し、
前記シーケンスコントローラは、
前記アイデンティファイ・デバイス・コマンドの返値であるアイデンティファイ・デバイス情報が設定されたデータFISを、前記シリアルATAインターフェースが受信した場合に、前記アイデンティファイ・デバイス情報の書き換え処理を行うことを特徴とするデータ転送制御装置。 A data transfer control device having a parallel ATA and serial ATA bus bridge function,
A parallel ATA interface connected to the parallel ATA bus for interfacing with the host;
A serial ATA interface connected to the serial ATA bus for interfacing with serial ATA devices;
Includes a sequence controller that performs transfer sequence control,
The parallel ATA interface has a task file register,
The serial ATA interface is
When an identified device command is issued by the host, a register FIS corresponding to the identified device command is transmitted to the device of the serial ATA.
The sequence controller is
When the serial ATA interface receives data FIS in which the identified device information, which is a return value of the identified device command, is set, the rewrite processing of the identified device information is performed. A data transfer control device.
前記ホスト、前記デバイス間で転送されるデータのバッファリングを行うデータバッファを含み、
前記シーケンスコントローラは、
前記データバッファに、前記アイデンティファイ・デバイス情報が書き込まれた後、書き込まれた前記アイデンティファイ・デバイス情報を読み出し、読み出された前記アイデンティファイ・デバイス情報の書き換え処理を行って、前記データバッファに書き戻すことを特徴とするデータ転送制御装置。 In claim 1,
A data buffer for buffering data transferred between the host and the device;
The sequence controller is
After the identified device information is written to the data buffer, the written device information is read, and the read device information is rewritten, A data transfer control device characterized by writing back to a data buffer.
前記シーケンスコントローラは、
前記デバイスからシリアルATA側でのPIOリード転送のPIOセットアップFISを受信した後、PIOリード転送のデータFISを受信した場合に、前記アイデンティファイ・デバイス情報として、1セクタ分のリードデータが前記データバッファに書き込まれるまでウェイトし、1セクタ分の前記リードデータが前記データバッファに書き込まれた後に、前記リードデータである前記アイデンティファイ・デバイス情報の書き換え処理を行い、その後に前記タスクファイル・レジスタのステータスレジスタのビジービットをクリアすると共にデータリクエストビットをセットすることを特徴とするデータ転送制御装置。 In claim 2,
The sequence controller is
When the PIO read transfer data FIS is received after receiving the PIO setup transfer FIS for the PIO read transfer on the serial ATA side from the device, the read data for one sector is the data as the identified device information. Wait until it is written to the buffer, and after the read data for one sector is written to the data buffer, rewrite processing of the identified device information as the read data is performed, and then the task file register A data transfer control device characterized by clearing a busy bit of the status register and setting a data request bit.
前記シーケンスコントローラは、
前記タスクファイル・レジスタの前記ステータスレジスタのビットを設定した後に、前記パラレルATAインターフェースに対してパラレルATA側でのPIOリード転送の開始を指示することを特徴とするデータ転送制御装置。 In claim 3,
The sequence controller is
A data transfer control device, wherein after setting a bit of the status register of the task file register, the parallel ATA interface is instructed to start PIO read transfer on the parallel ATA side.
前記パラレルATAインターフェースは、
前記リードデータがバッファリングされるパラレルATA用データバッファを有し、前記タスクファイル・レジスタの前記ステータスレジスタのビットが設定された場合に非アクティブになり、書き換え後の前記アイデンティファイ・デバイス情報であるリードデータが前記パラレルATA用データバッファに蓄積された場合にアクティブになるIORDY信号を生成することを特徴とするデータ転送制御装置。 In claim 3 or 4,
The parallel ATA interface is
It has a parallel ATA data buffer in which the read data is buffered, and becomes inactive when a bit of the status register of the task file register is set. A data transfer control device for generating an IORDY signal that becomes active when certain read data is accumulated in the parallel ATA data buffer.
前記シーケンスコントローラは、
前記書き換え処理として、前記アイデンティファイ・デバイス情報のIORDYパラメータの書き替え処理を行うこと特徴とするデータ転送制御装置。 In any one of Claims 1 thru | or 5,
The sequence controller is
A data transfer control device, wherein as the rewriting process, a rewriting process of an IORDY parameter of the identified device information is performed.
前記シーケンスコントローラは、
前記書き換え処理として、前記アイデンティファイ・デバイス情報の転送能力パラメータを、データ転送制御装置の転送能力に応じたパラメータに書き替える処理を行うこと特徴とするデータ転送制御装置。 In any one of Claims 1 thru | or 6.
The sequence controller is
A data transfer control device, wherein as the rewriting processing, a processing is performed to rewrite the transfer capability parameter of the identified device information to a parameter corresponding to the transfer capability of the data transfer control device.
初期化シーケンス管理機能を有しない前記シリアルATAの前記デバイスに代わって初期化シーケンス管理を代行する初期化シーケンス管理部を含み、
前記初期化シーケンス管理部は、
マスタ・スレーブ設定端子によりデータ転送制御装置がマスタ側に設定された場合には、ハードリセット後にスレーブ検知処理と自己診断処理を行い、前記マスタ・スレーブ設定端子によりデータ転送制御装置がスレーブ側に設定された場合には、ハードリセット後にスレーブ検知信号、自己診断信号の制御を行うことを特徴とするデータ転送制御装置。 In any one of Claims 1 thru | or 7,
An initialization sequence management unit that performs initialization sequence management on behalf of the device of the serial ATA that does not have an initialization sequence management function;
The initialization sequence management unit
When the data transfer control device is set on the master side using the master / slave setting terminal, slave detection processing and self-diagnosis processing are performed after a hard reset, and the data transfer control device is set on the slave side using the master / slave setting terminal. If so, a data transfer control device that controls the slave detection signal and the self-diagnosis signal after a hard reset.
前記シーケンスコントローラは、
前記書き換え処理として、スレーブ検知結果、自己診断結果を前記ホストに通知するための書き替え処理を行うこと特徴とするデータ転送制御装置。 In claim 8,
The sequence controller is
A data transfer control device characterized by performing a rewrite process for notifying the host of a slave detection result and a self-diagnosis result as the rewrite process.
前記パラレルATAインターフェースは、タスクファイル・レジスタを有し、
前記シリアルATAインターフェースは、
前記タスクファイル・レジスタとの間でレジスタ値が転送されるシャドウ・タスクファイル・レジスタを含み、
前記シーケンスコントローラは、
データ転送制御装置がマスタ側に設定されているときに、前記ホストがマスタへのATAコマンドを発行した場合には、前記タスクファイル・レジスタのレジスタ値をそのまま前記シャドウ・タスクファイル・レジスタに転送し、
データ転送制御装置がスレーブ側に設定されているときに、前記ホストがスレーブへのATAコマンドを発行した場合には、前記タスクファイル・レジスタのデバイス/ヘッドレジスタのDEVビットをマスタ設定に書き換えて前記タスクファイル・レジスタのレジスタ値を前記シャドウ・タスクファイル・レジスタに転送することを特徴とするデータ転送制御装置。 In claim 8 or 9,
The parallel ATA interface has a task file register,
The serial ATA interface is
A shadow task file register in which register values are transferred to and from the task file register;
The sequence controller is
If the host issues an ATA command to the master when the data transfer control device is set to the master side, the register value of the task file register is transferred to the shadow task file register as it is. ,
When the host issues an ATA command to the slave when the data transfer control device is set to the slave side, the DEV bit of the device / head register of the task file register is rewritten to the master setting and the A data transfer control device for transferring a register value of a task file register to the shadow task file register.
前記シーケンスコントローラは、
データ転送制御装置がマスタ側に設定されているときに、前記ホストからのATAコマンドに対応するFISを前記シリアルATAインターフェースが前記デバイスから受信した場合には、前記シャドウ・タスクファイル・レジスタのレジスタ値を前記タスクファイル・レジスタにそのままに転送し、
データ転送制御装置がスレーブ側に設定されているときに、前記ホストからのATAコマンドに対応するFISを前記シリアルATAインターフェースが前記デバイスから受信した場合には、前記シャドウ・タスクファイル・レジスタのデバイス/ヘッドレジスタのDEVビットをスレーブ設定に書き換えて前記シャドウ・タスクファイル・レジスタのレジスタ値を前記タスクファイル・レジスタに転送することを特徴とするデータ転送制御装置。 In claim 10,
The sequence controller is
When the data transfer control device is set to the master side and the FIS corresponding to the ATA command from the host is received from the device by the serial ATA interface, the register value of the shadow task file register Is transferred to the task file register as it is,
If the serial ATA interface receives an FIS corresponding to an ATA command from the host from the device when the data transfer control device is set to the slave side, the device / A data transfer control device comprising: rewriting a DEV bit of a head register to a slave setting and transferring a register value of the shadow task file register to the task file register.
前記シーケンスコントローラは、
前記書き換え処理として、前記アイデンティファイ・デバイス情報のチェックサムパラメータを無効設定に書き替える処理を行うこと特徴とするデータ転送制御装置。 In any one of Claims 1 thru | or 11,
The sequence controller is
The data transfer control device according to claim 1, wherein the rewriting process is a process of rewriting a checksum parameter of the identified device information to an invalid setting.
前記シリアルATAインターフェースは、
前記パラレルATAバスを介して前記ホストがATAコマンドを発行した場合に、発行された前記ATAコマンドを含むレジスタFISを前記シリアルATAバスを介して前記デバイスに送信し、
前記シーケンスコントローラは、
前記レジスタFISに対応するFISを前記シリアルATAインターフェースが前記デバイスから受信した場合に、前記ホストから発行された前記ATAコマンドの転送シーケンス制御として、受信したFISの種類に応じた転送シーケンス制御を行うと共に、
前記ホストから発行された前記ATAコマンドが前記アイデンティファイ・デバイス・コマンドであった場合には、前記アイデンティファイ・デバイス情報が設定されたデータFISを受信したときに、前記アイデンティファイ・デバイス・コマンドに対応する転送シーケンス制御を行うことを特徴とするデータ転送制御装置。 In any one of Claims 1 to 12,
The serial ATA interface is
When the host issues an ATA command via the parallel ATA bus, a register FIS including the issued ATA command is transmitted to the device via the serial ATA bus;
The sequence controller is
When the FIS corresponding to the register FIS is received from the device by the serial ATA interface, as the transfer sequence control of the ATA command issued from the host, transfer sequence control corresponding to the type of received FIS is performed. ,
When the ATA command issued from the host is the identified device command, when the data FIS in which the identified device information is set is received, the identified device A data transfer control device that performs transfer sequence control corresponding to a command.
前記データ転送制御装置に接続される前記ホストと、
前記データ転送制御装置に接続される前記デバイスと、
を含むことを特徴とする電子機器。 A data transfer control device according to any one of claims 1 to 13,
The host connected to the data transfer control device;
The device connected to the data transfer control device;
An electronic device comprising:
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2007202055A JP2009037479A (en) | 2007-08-02 | 2007-08-02 | Data transfer control device and electronic device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2007202055A JP2009037479A (en) | 2007-08-02 | 2007-08-02 | Data transfer control device and electronic device |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2009037479A true JP2009037479A (en) | 2009-02-19 |
Family
ID=40439313
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2007202055A Pending JP2009037479A (en) | 2007-08-02 | 2007-08-02 | Data transfer control device and electronic device |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2009037479A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113868159A (en) * | 2020-06-30 | 2021-12-31 | 中车株洲电力机车研究所有限公司 | IO module, in-module master control device and in-module interface device identification method |
CN114721984A (en) * | 2022-03-30 | 2022-07-08 | 湖南长城银河科技有限公司 | SATA interface data transmission method and system for low-delay application |
-
2007
- 2007-08-02 JP JP2007202055A patent/JP2009037479A/en active Pending
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113868159A (en) * | 2020-06-30 | 2021-12-31 | 中车株洲电力机车研究所有限公司 | IO module, in-module master control device and in-module interface device identification method |
CN114721984A (en) * | 2022-03-30 | 2022-07-08 | 湖南长城银河科技有限公司 | SATA interface data transmission method and system for low-delay application |
CN114721984B (en) * | 2022-03-30 | 2024-03-26 | 湖南长城银河科技有限公司 | SATA interface data transmission method and system for low-delay application |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US7739419B2 (en) | Data transfer control device and electronic instrument | |
TWI452469B (en) | Pcie mass storage device, system having the same, and method for operating the same | |
US7069350B2 (en) | Data transfer control system, electronic instrument, and data transfer control method | |
KR101035225B1 (en) | Controller apparatus and method for improved data transfer | |
US7225288B2 (en) | Extended host controller test mode support for use with full-speed USB devices | |
JP2008090375A (en) | Interrupt control system and storage control system using the same | |
JP4434218B2 (en) | Data transfer control device and electronic device | |
US6148384A (en) | Decoupled serial memory access with passkey protected memory areas | |
US10896119B1 (en) | Common input/output interface for application and debug circuitry | |
JP3636160B2 (en) | Data transfer control device, electronic device, and data transfer control method | |
JP2008242701A (en) | Data transfer controller and electronic device | |
JP4404023B2 (en) | Data transfer control device and electronic device | |
JP2009037479A (en) | Data transfer control device and electronic device | |
JP2009048444A (en) | Control method of usb device, controller and electronic equipment | |
JP3714420B2 (en) | DATA TRANSFER CONTROL DEVICE, ELECTRONIC DEVICE, PROGRAM, AND ELECTRONIC DEVICE MANUFACTURING METHOD | |
JP2009037474A (en) | Data transfer control device and electronic device | |
JP2005520248A (en) | USB host controller | |
KR101109600B1 (en) | Method for transmitting data using direct memory access control and apparatus therefor | |
JP2008204048A (en) | Data transfer control device and electronic device | |
JP2008293154A (en) | Data transfer control device and electronic device | |
JP2008204049A (en) | Data transfer control device and electronic device | |
JP2009037475A (en) | Data transfer control device and electronic device | |
JP2009032011A (en) | Data transfer control device and electronic device | |
JP2008204050A (en) | Data transfer control device and electronic device | |
JP2009026165A (en) | Controller, electronic apparatus, and method for controlling electronic apparatus |