Linux PCMCIA HOWTO <!-- <author>David Hinds, <tt><htmlurl url="mailto:dhinds@pcmcia.sourceforge.org" name="dhinds@pcmcia.sourceforge.org"></tt>. --> <author>David Hinds, <tt><htmlurl url="mailto:dhinds@pcmcia.sourceforge.org" name="dhinds@pcmcia.sourceforge.org"></tt> <date>v2.46, 1 December 1999 <trans>こじまみつひろ と JF プロジェクト <tdate>v2.46j, 18 December 1999 <abstract> <!-- This document describes how to install and use PCMCIA Card Services for Linux, and answers some frequently asked questions. The latest version of this document can always be found at <url url="ftp://sourceforge.org/pcmcia/doc">. An HTML version is at <url url="http://pcmcia.sourceforge.org">. --> この文書は Linux に PCMCIA カードサービスをインストールして使うための 方法についてまとめたものです。また、しばしば尋ねられる質問(FAQ)にも 答えています。この文書の最新版は <url url="ftp://sourceforge.org/pcmcia/doc"> にあります。 HTML 版は <url url="ftp://hyper.stanford.edu/pub/pcmcia/doc"> です。 </abstract> <toc> <!-- <sect>General information and hardware requirements --> <sect>概略と必要なハードウェア <!-- <sect1>Introduction --> <sect1>イントロダクション <p> <!-- Card Services for Linux is a complete <idx>PCMCIA</idx> or ``<idx>PC Card</idx>'' support package. It includes a set of loadable kernel modules that implement a version of the Card Services applications program interface, a set of client drivers for specific cards, and a card manager daemon that can respond to card insertion and removal events, loading and unloading drivers on demand. It supports ``hot swapping'' of most card types, so cards can be safely inserted and ejected at any time. --> Linux 用の PCMCIA カードサービスは、<idx>PCMCIA</idx> あるいは 「<idx>PC カード</idx>」をサポートするためのソフトウェア一式です。この パッケージには、あるバージョンのカードサービス API を実装した カーネルモジュール、それぞれのカードごとのクライアントドライバ、カード の着脱を監視し、必要に応じてドライバをロードしたり外したりする カードマネージャーデーモンが含まれています。ほとんどの種類のカードの 「活線挿抜」にも対応しているので、いつでも安全にカードを着脱することが 可能です。 <!-- This software is continually under development. It probably contains bugs, and should be used with caution. I'll do my best to fix problems that are reported to me, but if you don't tell me, I may never know. If you use this code, I hope you will send me your experiences, good or bad! --> このソフトウェアはまだ開発中のものです。多分バグがあるでしょうし、注意 して使う必要があります。報告していただいたバグは可能な限り修正するつも りですが、報告がないと私はそのバグに気づかないかもしれません。もしこの プログラムを使ってもらえるならば、良いことでも悪いことでもいいですから 経験談を送っていただけますよう希望します。 <!-- If you have any suggestions for how this document could be improved, please let me know (<tt><htmlurl url="mailto:dhinds@pcmcia.sourceforge.org" name="dhinds@pcmcia.sourceforge.org"></tt>). --> この文書についての提案や改善点についても是非教えてください (<tt><htmlurl url="mailto:dhinds@pcmcia.sourceforge.org" name="dhinds@pcmcia.sourceforge.org"></tt> まで)。 [訳注: 翻訳に関することは JF プロジェクト (<tt><JF@linux.or.jp></tt>)までお願いします] <!-- <sect1>Copyright notice and disclaimer --> <sect1>著作権表示と免責事項 <p> Copyright (c) 1998 David A. Hinds This document may be reproduced or distributed in any form without my prior permission. Modified versions of this document, including translations into other languages, may be freely distributed, provided that they are clearly identified as such, and this copyright is included intact. This document may be included in commercial distributions without my prior consent. While it is not required, I would like to be informed of such usage. If you intend to incorporate this document in a published work, please contact me to make sure you have the latest available version. This document is provided ``AS IS'', with no express or implied warranties. Use the information in this document at your own risk. この文書をコピーしたり再配布するのに私の事前の許可は必要ありません。他 の言語への翻訳を含むこの文書の修正版も、それが修正版であることが明確に 示されており、この著作権条項がそのまま含まれている限り、自由に再配布可 能です。 この文書は私の事前の許可なく商業的なパッケージに含めることも可能ですが、 そのような使用に際しては連絡していただくことを希望します。出版物に含め る場合は最新版であることを確認するために是非私まで連絡してください。 この文書は「そのまま(as is)」の形で提供され、一切の保証はありません。 この文書に記載されている情報を利用される際は自らの責任でお願いします。 <!-- <sect1>What is the latest version, and where can I get it? --> <sect1>最新のバージョンはいくつですか? どこで手に入りますか? <p> <!-- The current major release of Card Services is version 3.1, and minor updates or bug fixes are numbered 3.1.1, 3.1.2, and so on. --> PCMCIA カードサービスの最新のメジャーリリースはバージョンは 3.1 で、 ちょっとした変更やバグの修正に応じて 3.1.1, 3.1.2 のようなバージョン 番号が振られています。 <!-- Source code for the latest version is available from <tt/sourceforge.org/ in the <tt>/pcmcia</tt> directory, as <tt/pcmcia-cs-3.1.?.tar.gz/. There will usually be several versions here. I generally only keep the latest minor release for a given major release. New major releases may contain relatively untested code, so I also keep the latest version of the previous major release as a relatively stable fallback; the current fallback is 3.0.14. It is up to you to decide which version is more appropriate, but the <tt/CHANGES/ file will summarize the most important differences. --> 最新バージョンのソースコードは <tt/sourceforge.org/ の <tt>/pcmcia</tt> ディレクトリに <tt/pcmcia-cs-3.1.?.tar.gz/ という 名前で置いてあります。普通は複数のバージョンが同一のディレクトリに あります。普通はメジャーバージョン別に、最新版のマイナーバージョンだけ が置かれています。 新しいメジャーバージョンにはテストが不十分なコードが入っているので、 比較的安心して使える予備として、以前のバージョンの最終版も残すようにし ています。現在の予備のバージョンは 3.0.14 です。どのバージョンを利用す るか判断するのは読者の皆さんですが、重要な違いは <tt>CHANGES</tt> ファイルにまとめておいたので参考にしてください。 <!-- <tt/sourceforge.org/ is mirrored at <tt/sunsite.unc.edu/ (and all sunsite mirror sites) in <tt>/pub/Linux/kernel/pcmcia</tt>. --> <tt/sourceforge.org/ は <tt/sunsite.unc.edu/ (そして sunsite の ミラーサイト全て)の <tt>/pub/Linux/kernel/pcmcia</tt> にミラーされてい ます。 <!-- If you do not feel up to compiling the drivers from scratch, pre-compiled drivers are included with current releases of most of the major Linux distributions, including Slackware, Debian, Red Hat, Caldera, SuSE, and Yggdrasil, among others. --> PCMCIA ドライバを最初からコンパイルしなくても、最近の主要 Linux ディストリビューションのほとんどにはコンパイル済みのドライバが入ってい ます。このようなディストリビューションには、Slackware, Debian, RedHat, Caldera, SuSE, Yggdrasil などがあります。 [訳注: 国産ディストリビューションの大部分も含まれます] <!-- <sect1>What systems are supported? --> <sect1>サポートしているシステムは? <p> <!-- This package should run on almost Intel-based Linux-capable laptop. It also runs on Alpha-based platforms (i.e., the DEC Multia). Work is being done to make the package fully dual-endian, so that it will also support PowerPC-based platforms (i.e., Apple Powerbooks). Most common socket controllers are supported. Card docks for desktop systems should work as long as they use a supported controller, and are plugged directly into the ISA or PCI bus, as opposed to SCSI-to-PCMCIA or IDE-to-PCMCIA adapters. The following controllers are recognized by the supplied socket drivers: --> このパッケージは Linux が動作する Intel ベースの PC のほとんどで動作す るはずです。Alpha ベースのプラットフォーム(つまり DEC Multia)でも動作 します。どちらのエンディアンでも完全に動くようにするための作業を現在行っ ており、これによって PowerPC ベースのプラットフォーム(つまり Apple Powerbook)でも動作するようになるでしょう。一般的な ソケットコントローラのほとんどをサポートしています。 サポートされているコントローラを使っており、SCSI-PCMCIA アダプタや IDE-PCMCIA アダプタを使わずにコントローラを直接 ISA バスや PCI バスに 挿している限り、デスクトップ機用のカードドックでも動作するはずです。 以下に挙げるコントローラは、パッケージ付属のソケットドライバが認識する ものです: <itemize> <item>Cirrus Logic PD6710, PD6720, PD6722, PD6729, PD6730, PD6732, PD6832 <item>Intel i82365sl B, C, and DF steps, 82092AA <item>O2Micro OZ6729, OZ6730, OZ6832, OZ6833, OZ6836, OZ6860, OZ6812 <item>Omega Micro 82C365G, 82C092G <item>Ricoh RF5C296, RF5C396, RL5C465, RL5C466, RL5C475, RL5C476, RL5C478 <item>SMC 34C90 <item>Texas Instruments PCI1130, PCI1131, PCI1210, PCI1220, PCI1221, PCI1225, PCI1250A, PCI1251A, PCI1251B, PCI1450 <!-- <item>Toshiba ToPIC95, ToPIC97 (experimental, incomplete) --> <item>東芝 ToPIC95, ToPIC97 (試験的に対応。不完全です) <item>Vadem VG465, VG468, VG469 <item>VLSI Technologies 82C146, VCF94365 <item>VIA VT83C469 <item>Databook DB86082, DB86082A, DB86084, DB86084A, DB86072, DB86082B </itemize> <!-- Other controllers that are register compatible with the Intel i82365sl will generally work, as well. --> 一般的には、i82365sl とレジスタ互換である他のコントローラも動作します。 <!-- Support for 32-bit CardBus cards is still somewhat experimental. Drivers prior to version 3.0 only support 16-bit cards in CardBus sockets. Due to the rapid pace of technological change for laptop hardware, new controllers appear frequently, and there may be delays between when a new model appears on the market, and when driver support becomes available. --> 32 ビット CardBus への対応は、まだいくらか試験的なものです。 バージョン 3.0 より前のドライバは、CardBus ソケット内の 16 ビット カードしかサポートしていません。ラップトップ機の技術の変化のペースが早 いため、新しいコントローラが頻繁に登場しますし、新しく市場に出たモデル にドライバが対応するのが遅れることがあります。 <!-- Toshiba has made available some documentation for their ToPIC95 and ToPIC97 chipsets, however the information they have provided has not really been adequate. Despite conflicting reports to the contrary, Toshiba has not made any effective effort to remedy this situation. There are serious bugs in Linux support for the ToPIC chipsets, that cannot be resolved until better documentation or help from Toshiba becomes available. I do not recommend use of Toshiba laptops at this time. For use of 16-bit cards, I recommend setting the bridge mode to ``PCIC'' in the BIOS setup; for CardBus cards, you are on your own. --> 東芝は ToPIC95, ToPIC97 チップセットに関するドキュメントをいくつか公開 しましたが、提供された情報は十分ではありません。 相反する矛盾した報告が出ているにもかかわらず、東芝はこの状況を解決する 有効な取り組みをしていません。 Linx の ToPIC チップセットのサポートには重大なバグがありますが、これは 東芝からもっとまともな文書が出るか、東芝からの援助が得られない限りは 解決しないでしょう。現時点では、東芝のラップトップ機を使わないことをお 勧めします。16 ビットカードの場合は、BIOS の設定で ``PCIC'' への ブリッジモードを設定することをお勧めします。CardBus カードの場合には、 自力で何とかしてください。 <!-- The Motorola 6AHC05GA controller used in some Hyundai laptops is not supported. The custom host controller in the HP Omnibook 600 is also unsupported. --> Hyundai(現代)製のラップトップ機のいくつかが採用している Motorola の 6AHC05GA コントローラはサポートしていません。HP Omnibook 600 で使われ ている専用の PCMCIA コンローラもサポートしていません。 <!-- <sect1>What cards are supported? --> <sect1>サポートしているカードは? <p> <!-- The current release includes drivers for a variety of ethernet cards, a driver for modem and serial port cards, several SCSI adapter drivers, a driver for ATA/IDE drive cards, and memory card drivers that should support most SRAM cards and some flash cards. The <tt/SUPPORTED.CARDS/ file included with each release of Card Services lists all cards that are known to work in at least one actual system. --> 最新版には、さまざまなイーサネットカード用のドライバ、モデムカードや シリアルポートカード用のドライバ、いくつかの SCSI アダプタ用のドライバ、 ATA/IDE ドライブカード、ほとんど のSRAM カードといくつかの Flash カード で使えるドライバが入っています。各リリースの PCMCIA カードサービスに付 属の <tt/SUPPORTED.CARDS/ ファイルには、少なくとも一つの実働システムで の実績があるカードが全て記載されています。 <!-- The likelihood that a card not on the supported list will work depends on the type of card. Essentially all modems should work with the supplied driver. Some network cards may work if they are OEM versions of supported cards. Other types of IO cards (frame buffers, sound cards, etc) will not work until someone writes the appropriate drivers. --> リストにないカードが動くかどうかはカードの種類に依存します。ほとんどの モデムカードはこのドライバで動くはずです。ネットワークカードは、サポー トされているカードの OEM 版なら動くかもしれません。その他のタイプの I/O カード(フレームバッファ、サウンドカード等)は誰かが専用のドライバ を書かない限り動かないでしょう。 <!-- <sect1>When will my favorite (unsupported) card become supported? --> <sect1>いつになったら私のお気に入りの(未サポート)カードがサポートされるんでしょう? <p> <!-- Unfortunately, they usually don't pay me to write device drivers, so if you would like to have a driver for your favorite card, you are probably going to have to do at least some of the work. Ideally, I'd like to work towards a model like the Linux kernel, where I would be responsible mainly for the ``core'' driver code and other authors would contribute and maintain client drivers for specific cards. The <tt/SUPPORTED.CARDS/ file mentions some cards for which driver work is currently in progress. I will try to help where I can, but be warned that debugging kernel device drivers by email is not particularly effective. --> 残念ながら、私がデバイスドライバを書いても一文の得にもなりません。 ですから、もしあなたの使いたいカード用のドライバが欲しければ、多分あな た自身が何かしらの作業を行う必要があるでしょう。 理想を言えば、私は Linux カーネルのようなモデルで作業をしたいと思って います。つまり、私が主に「コア(中心的な)」ドライバのコードを担当し、 他の作者の方々が特定カード向けのクライアントドライバを提供・管理するの です。<tt/SUPPORTED.CARDS/ では、現在開発が進行中のカードについても触 れています。私もできるかぎりのお手伝いはするつもりですが、カーネルの デバイスドライバのデバッグを電子メールで行っても、あまり効率は上がらな いことを言っておきます。 <!-- Manufacturers interested in helping provide Linux support for their products can contact me about consulting arrangements. --> 自社製品の Linux 対応への支援を考えているメーカーがあれば、相談の取り まとめをしますので私に連絡を取ってください。 <!-- <sect1>Mailing lists and other information sources --> <sect1>メーリングリストとその他の情報源 <p> <!-- I used to maintain a database and mailing list of Linux PCMCIA users. More recently, I've turned my web page for Linux PCMCIA information into a ``HyperNews'' site, with a set of message lists for Linux PCMCIA issues. There are lists for installation and configuration issues, for different types of cards, and for programming and debugging issues. The Linux PCMCIA information page is at <url url="http://pcmcia.sourceforge.org">. Users can request email notification of new responses to particular questions, or notification for all new messages in a given category. I hope that this will become a useful repository of information, for questions that go beyond the scope of the HOWTO. --> 私は Linux PCMCIA ユーザのためのデータベースとメーリングリストを運営し ています。私はごく最近、 Linux の PCMCIA 情報用の WWW ページを 「HyperNews」サイトに移しました。ここには Linux の PCMCIA に関する話題 を扱うメッセージリストをいくつか用意しています。メッセージリストには、 インストールと設定の話題を扱うもの、色々な種類のカードに関するもの、 プログラミングとデバッグの話題を扱うものがあります。Linux の PCMCIA 情 報のページは <url url="http://pcmcia.sourceforge.org"> にあります。ユーザは特定の質問に対する新しい返答があると電子メールで 通知を受けることができますし、特定の分野で新しいメッセージが投稿された 場合にも通知を受けることができます。私はこの HOWTO の範囲を超えるよう な質問に対して、このページが便利な情報収集の場になることを期待しています。 <!-- There is a Linux mailing list devoted to laptop issues, the ``linux-laptop'' list. For more information, send a message containing the word ``help'' to <tt/majordomo@vger.rutgers.edu/. To subscribe, send a message containing ``subscribe linux-laptop'' to the same address. This mailing list might be a good forum for discussion of Linux PCMCIA issues. --> ラップトップ機の話題を扱う Linux 向けメーリングリストがあります。 ``linux-laptop'' メーリングリストです。詳しい情報については、 本文に ``help'' とだけ書いたメールを <tt/majordomo@vger.rutgers.edu/ 宛に送ってください。このメーリングリストを購読するには、同じアドレスに ``subscribe linux-laptop'' と書いたメールを送ります。この メーリングリストは Linux の PCMCIA に関する話題を議論するための良い 場所だと思います。 <!-- The Linux Laptop Home Page at <url url="http://www.cs.utexas.edu/users/kharker/linux-laptop"> has links to many sites that have information about configuring specific types of laptops for Linux. There is also a searchable database of system configuration information. --> 「Linux Laptop Home Page( <url url="http://www.cs.utexas.edu/users/kharker/linux-laptop">)」には、 個別のラップトップ機を Linux で設定するための情報が書かれたページへの リンクがたくさんあります。システム設定情報を検索できるデータベースもあ ります。 <!-- <sect1>Why don't you distribute binaries? --> <sect1>なぜ PCMCIA のバイナリを配布しないの? <p> <!-- For me, distributing binaries would be a significant hassle. It is complicated because some features can only be selected at compile time, and because the modules are somewhat dependent on having the ``right'' kernel configuration. So, I would probably need to distribute precompiled modules along with matching kernels. Beyond this, the greatest need for precompiled modules is when installing Linux on a clean system. This typically requires setting up drivers so they can be used in the installation process for a particular Linux distribution. Each Linux distribution has its own ideosyncracies, and it is not feasible for me to provide boot and root disks for even just the common combinations of drivers and distributions. --> 私にとって、PCMCIA のバイナリを配布するのはとても大変だからです。 この作業は面倒なのです。というのも、コンパイル時にしか設定できない機能 もありますし、PCMCIA のモジュール類は「正しい」カーネルの設定に依存し ています。そのため、もしコンパイル済みのモジュールを配布しようとすれば、 対応するカーネルを添付するはめになるでしょう。この他にコンパイル済みの PCMCIA モジュールが必要とされる場合として、新しいマシンに Linux を インストールする時があります。この場合は普通、特定の Linux ディストリ ビューションのインストール処理に合わせてドライバを設定する必要がありま す。それぞれの Linux ディストリビューションには独自のインストール法が あり、一般的なドライバとディストリビューションを組みあわせた boot/root ディスクを用意することは私には不可能です。 <!-- PCMCIA is now a part of many of the major Linux distributions, including Red Hat, Caldera, Slackware, Yggdrasil, Craftworks, and Nascent Technology. --> PCMCIA は RedHat, Caldera, Slackware, Yggdrasil, Craftworks, Nascent Technology といった Linux の主要ディストリビューションに含まれるように なりました。 <!-- <sect1>Why is the package so darned big? --> <sect1> なぜ PCMCIA パッケージはこんなに大きいの? <p> <!-- Well, first of all, it isn't actually that large. All the driver modules together take up about 500K of disk space. The utility programs add up to about 70K, and the scripts in <tt>/etc/pcmcia</tt> are about 50K. The core driver modules take up about 55K of system memory. The <tt/cardmgr/ daemon will generally be swapped out except when cards are inserted or removed. The total package size is comparable to DOS/Windows Card Services implementations. --> 最初に弁解しておきますが、実際のところそんなに大きいわけではないですよ。 全てのドライバモジュールを合わせてもディスクを 500k ほど食うだけです。 各種のユーティリティ類がもう 70k 、<tt>/etc/pcmcia</tt> が 50 k ほどで す。動いている時は PCMCIA モジュールの core の部分がシステムメモリを 55k ほど取ります。<tt/cardmgr/ デーモンは通常、カードが抜き挿しされた 時以外はスワップアウトされているはずです。パッケージ全体の規模としては DOS のカードサービスとそれほど変わりません。 <!-- Compared to DOS ``point enablers'', this may still seem like a lot of overhead, especially for people that don't plan on using many of the features of PCMCIA, such as power management or hot swapping. Point enablers can be tiny because they generally support only one or a small set of cards, and also generally support a restricted set of host controllers. If someone were to write a genuinely ``generic'' modem enabler, it would end up incorporating much of the functionality of Card Services, to handle cards from different vendors and the full range of host controller variants. --> PCMCIA の特徴的な機能、すなわち省電力や活線挿抜を必要としない人々から 見ると、DOS の ``point enabler'' に比べて、まだかなりのオーバーヘッド があるように思えるかもしれません。``point enabler'' は確かに小さいプ ログラムですが、ごく限られたカードしかサポートしていませんし、使える PCMCIA コントローラも限られています。試しに本当に「汎用」なモデムの イネーブラを書いてみれば、多くのベンダーからリリースされているカードを サポートし、PCMCIA コントローラの違いにも対応するためには、結局 カードサービスの機能のほとんどをサポートしなければならないことが分かる でしょう。 <!-- <sect>Compilation and installation<label id="compile"> --> <sect>コンパイルとインストール<label id="compile"> <!-- <sect1>Prerequisites and kernel setup --> <sect1>必要なファイルとカーネルの設定 <p> <!-- Before starting, you should think about whether you really need to compile the PCMCIA package yourself. All common Linux distributions come with pre-compiled driver packages. Generally, you only need to install the drivers from scratch if you need a new feature of the current drivers, or if you've updated and/or reconfigured your kernel in a way that is incompatible with the drivers included with your Linux distribution. While compiling the package is not technically difficult, it does require some general Linux familiarity. --> コンパイルをする前に、本当に自分自身で PCMCIA パッケージをコンパイル しなければならないのかどうかを考えてみてください。一般的な Linux ディストリビューションの全てには、コンパイル済みのドライバパッケージが 付属しています。一般的に、最初からドライバをインストールする必要がある のは、最新ドライバの新機能が必要な場合か、カーネルの更新や再設定を行っ て Linux ディストリビューション付属のドライバとの互換性がなくなった場 合だけです。パッケージのコンパイルは技術的には難しくありませんが、 Linux 全般に慣れている必要があります。 <!-- The following things should be installed on your system before you begin: --> 作業を始める前には以下のツールがインストールされていなければなりません: <itemize> <item> <!-- A 2.0.*, 2.1.*, or 2.2.* series kernel source tree. --> 2.0.*, 2.1.*, 2.2.* のいずれかの系列のカーネルのソースツリー <item> <!-- An appropriate set of module utilities. --> 適切なモジュールユーティリティ群 <item> <!-- (Optional) the ``XForms'' X11 user interface toolkit. --> (なくても構いません) ``XForms'' と呼ばれる X11 用のインタフェース ツールキット </itemize> <!-- You need to have a complete linux source tree for your kernel, not just an up-to-date kernel image. The driver modules contain some references to kernel source files. While you may want to build a new kernel to remove unnecessary drivers, installing PCMCIA does not require you to do so. --> 最新のカーネルイメージだけでなく、カーネルのソースツリー全体が必要です。 PCMCIA のプログラムの中には、カーネルのソースを参照している部分がある からです。不要なドライバを除いた新しいカーネルをコンパイルしたくなるか もしれませんが、PCMCIA カードサービスをインストールするためにカーネル を再構築する必要はありません。 <!-- Current ``stable'' kernel sources and patches are available from <url url="ftp://sunsite.unc.edu/pub/Linux/kernel/v2.0">, or from <url url="ftp://tsx-11.mit.edu/pub/linux/sources/system/v2.0">. Development kernels can be found in the corresponding <tt/v2.1/ subdirectories. Current module utilities can be found in the same locations. --> 最新の「安定版」のカーネルのソースとパッチは、 <url url="ftp://sunsite.unc.edu/pub/Linux/kernel/v2.0"> や <url url="ftp://tsx-11.mit.edu/pub/linux/sources/system/v2.0"> から入手できます。 開発版のカーネルは同じ場所の <tt/v2.1/ ディレクトリにあります。 最新のモジュールユーティリティも同じ場所にあります。 [訳注: 翻訳の時点では安定版カーネルの最新は 2.2.x、開発版の最新は 2.3.x です] <!-- In the Linux kernel source tree, the <tt>Documentation/Changes</tt> file describes the versions of all sorts of other system components that are required for that kernel release. You may want to check through this and verify that your system is up to date, especially if you have updated your kernel. If you are using a development kernel, be sure that you are using the right combination of shared libraries and module tools. --> Linux カーネルのソースツリーに入っている <tt>Documentation/Changes</tt>ファイルには、そのバージョンのカーネルで 必要となる全ての種類のシステムコンポーネントのバージョンが書かれていま す。このファイルを調べて、システムを最新の状態にするとよいでしょう。 特にカーネルを更新した場合にはそうすべきです。開発版のカーネルを使って いる場合には、共有ライブラリとモジュールユーティリティの組合せが正しい かどうかを確認してください。 <!-- When configuring your kernel, if you plan on using a PCMCIA ethernet card, you should turn on networking support but turn off the normal Linux network card drivers, including the ``pocket and portable adapters''. The PCMCIA network card drivers are all implemented as loadable modules. Any drivers compiled into your kernel will only waste space. --> カーネルを設定する際、PCMCIA のイーサネットカードを使うつもりなら、 ``networking support'' を <tt/[Y]/ にして、``pocket and portable adapters'' を含む一般の Linux 用のネットワークカード用のドラ イバは全て使わないように設定します。PCMCIA ネットワークカード用のドラ イバは必要なときにロードされるモジュールとして提供されていますので、カー ネルにドライバを組みこむのはメモリの無駄でしかありません。 <!-- If you want to use SLIP, PPP, or PLIP, you do need to either configure your kernel with these enabled, or use the loadable module versions of these drivers. There is an unfortunate deficiency in the kernel config process in 1.2.X kernels, in that it is not possible to set configuration options (like SLIP compression) for a loadable module, so it is probably better to just link SLIP into the kernel if you need it. --> SLIP や PPP, PLIP を使う場合には、カーネルの設定時にこれらを使うように 指定するか、これらのドライバのローダブルモジュール版を使う必要があります。 残念ながらカーネル 1.2.X では設定の手順に問題があり、ローダブル モジュール用の細かな設定(例えば SLIP の圧縮の有無)ができません。そのた め、SLIP が必要ならば(モジュールとして使うのではなく)カーネルに組み込 む方がいいでしょう。 <!-- In order to use a PCMCIA token ring adapter, your kernel should be configured with ``Token Ring driver support'' (<tt/CONFIG_TR/) enabled, though you should leave <tt/CONFIG_IBMTR/ off. --> PCMCIA トークンリングアダプタを使う場合、<tt>``Token Ring driver support''(CONFIG_TR)</tt> を設定しますが、<tt>CONFIG_IBMTR</tt> は使わないようにします。 <!-- If you want to use a PCMCIA IDE adapter, your kernel should be configured with <tt/CONFIG_BLK_DEV_IDE_PCMCIA/ enabled, for 2.0.* through 2.1.7 kernels. Older kernels do not support removeable IDE devices; newer kernels do not require a special configuration setting. --> PCMCIA IDE アダプタを使いたい場合、カーネル 2.0.* から 2.1.7 では、 <tt/CONFIG_BLK_DEV_IDE_PCMCIA/ を有効にしなければなりません。 古いカーネルはリムーバブル IDE デバイスをサポートしていません。新しい カーネルでは、特別な設定は必要ありません。 <!-- If you will be using a PCMCIA SCSI adapter, then enable <tt/CONFIG_SCSI/ when configuring your kernel. Also, enable any top level drivers (SCSI disk, tape, cdrom, generic) that you expect to use. All low-level drivers for particular host adapters should be disabled, as they will just take up space. --> もし PCMCIA SCSI アダプタを使うなら、カーネルの設定時に <tt/CONFIG_SCSI/ を設定します。使うメディアごとの SCSI ドライバ(ディス ク、テープ、CD-ROM、 汎用ドライバ)も設定します。特定のホストアダプタ用 のハードウェアレベルのドライバは使わないように設定します。それらを組み こんでもメモリの無駄です。 <!-- If you want to modularize a driver that is needed for a PCMCIA device, you must modify <tt>/etc/pcmcia/config</tt> to specify what modules need to be loaded for what card types. For example, if the serial driver is modularized, then the serial device definition should be: --> PCMCIA デバイスが必要とするドライバをモジュール化する場合、 <tt>/etc/pcmcia/config</tt> を修正して、カードの種類に合ったモジュール をロードするように設定します。例えば、シリアルドライバがモジュール化さ れている場合、<tt>/etc/pcmcia/config</tt>のシリアルデバイスの設定を <tscreen><verb> device "serial_cs" class "serial" module "misc/serial", "serial_cs" </verb></tscreen> のようにします。 <!-- This package includes an X-based card status utility called <tt/cardinfo/. This utility is based on a freely distributed user interface toolkit called the XForms Library. This library is available as a separate package with most Linux distributions. If you would like to build <tt/cardinfo/, you should install XForms and all the normal X header files and libraries before configuring the PCMCIA package. --> このパッケージには <tt/cardinfo/ という X 上でカードの状態を表示するた めのユーティリティプログラムが入っています。<tt/cardinfo/ を使うために は、XForms Library という自由に配布できるユーザインタフェース用 ツールキットが必要です。ほとんどの Linux ディストリビューションでは、 このライブラリは PCMCIA と別のパッケージとして使うことができます。 <tt/cardinfo/ をコンパイルしたければ、PCMCIA パッケージの設定を行う前 に XForms と X11 のヘッダファイルとライブラリをインストールする必要が あります。 <!-- <sect1>Installation --> <sect1>インストール <p> <!-- Here is a synopsis of the installation process: --> 以下が簡単なインストールの手順です: <itemize> <item> <!-- Unpack pcmcia-cs-3.1.?.tar.gz in /usr/src. --> <tt>/usr/src</tt> で <tt/pcmcia-cs-3.1.?.tgz/ ファイルを展開する <item> <!-- Run ``<tt/make config/'' in the new <tt/pcmcia-cs-3.1.?/ directory. --> <tt/pcmcia-cs-3.1.?/ ディレクトリで ``<tt/make config/'' を実行する <item> <!-- Run ``<tt/make all/'', then ``<tt/make install/''. --> ``<tt/make all/'', ``<tt/make install/'' を順に実行する。 <item> <!-- Customize the startup script and the option files in <tt>/etc/pcmcia</tt> for your site, if needed. --> 必要ならば、<tt>/etc/pcmcia</tt> ディレクトリにあるオプション指定用 ファイルを環境に合わせて設定する。 </itemize> <!-- If you plan to install any contributed client drivers not included in the core PCMCIA distribution, unpack each of them in the top-level directory of the PCMCIA source tree. Then follow the normal build instructions. The extra drivers will be compiled and installed automatically. --> 基本の PCMCIA 配布物に含まれていない、他の方が作成した クライアントドライバをインストールするつもりであれば、これらを PCMCIA ソースツリーのトップディレクトリで展開してください。その後は通 常のインストール手順に従います。追加のドライバは、自動的にコンパイル・ インストールされます。 <!-- Running ``<tt/make config/'' prompts for a few configuration options, and checks out your system to verify that it satisfies all prerequisites for installing PCMCIA support. In most cases, you'll be able to just accept all the default configuration options. Be sure to carefully check the output of this command in case there are problems. The following options are available: --> ``<tt/make config/'' とすると、プログラムがいくつか設定のためのオプショ ンを尋ね、PCMCIA カードサービスをインストールする環境が整っているかど うかをチェックします。多くの場合、デフォルトの設定オプションのままで大 丈夫なはずですが、もし何か問題が起これば、このコマンドの出力を注意深く チェックしてみてください。 以下のオプションが使えます: <descrip> <!-- <tag/Alternate target install directory?/ If you are compiling the package for installation on another machine, specify an alternate target directory when prompted. This should be an absolute path. All files will be installed relative to this directory. You will then be able to <tt/tar/ this directory tree and copy to your target machine, and unpack relative to its root directory to install everything in the proper places. --> <tag/Alternate target install directory?(インストール先のディレクトリを変更するか?)/ 別のマシンにインストールするためのパッケージ用にコンパイルする場合、 「alternate target directory(別のインストール先)」を指定してく ださい。このディレクトリ名は絶対パスで指定する必要があります。PCMCIA 用のツール類は全てこのディレクトリに元にした相対的なディレクトリに インストールされますので、そのディレクトリ以下を <tt/tar/ でまとめて、 目的とするマシンにコピーし、適切な場所に展開してください。 <!-- <tag/Build 'trusting' versions of card utilities?/ Some of the support utilities (<tt/cardctl/ and <tt/cardinfo/) can be compiled either in ``safe'' or ``trusting'' forms. The ``safe'' forms prevent non-root users from modifying card configurations. The ``trusting'' forms permit ordinary users to issue commands to suspend and resume cards, reset cards, and change the current configuration scheme. The default is to build the safe forms. --> <tag/Build 'trusting' versions of card utilities?(「信頼する」形式のカードユーティリティを作るか?)/ サポート用ユーティリティの一部(<tt/cardctl/ と <tt/cardinfo/)は、 「安全な(safe)」形式または「信頼する(trusting)」形式のどちらかで コンパイルすることができます。「安全な」形式では、root 以外のユーザが カードの設定を変更することは禁止されます。「信頼する」形式では、カード のサスペンドとリジューム、カードのリセット、現在の設定スキームの変更を 行うコマンドを一般ユーザが発行することを許可されます。 デフォルトでは「安全」な形式を作ります。 <!-- <tag/Include 32-bit (CardBus) card support?/ This option must be selected if you wish to use 32-bit CardBus cards. It is not required for CardBus bridge support, if you only plan to use 16-bit PC Cards. --> <tag/Include 32-bit (CardBus) card support?(32 ビット(CardBus) をサポートするか?)/ 32 ビットの CardBus カードを使いたければ、このオプションを選択しなけれ ばなりません。 16 ビットの PC カードしか使う予定がなければ、CardBus ブリッジのサポート は必要ありません。 <!-- <tag/Include PnP BIOS resource checking?/ This builds additional code into the PCMCIA core module to communicate with a system's PnP BIOS to obtain resource information for built-in ``motherboard'' devices (serial and parallel ports, sound, etc), to help avoid resource conflicts. If enabled, some extra resource files will be created under <tt>/proc/bus/pccard</tt>, and the <tt/lspnp/ and <tt/setpnp/ tools can be used to view and manipulate PnP BIOS devices. However, this setting causes problems on some laptops and is not turned on by default. --> <tag/Include PnP BIOS resource checking?(PnP BIOS によるリソースのチェックを行うか?)/ このオプションを選ぶと、追加のコードが PCMCIA のコアモジュール内に入り ます。このコードはシステムの PnP BIOS と通信して組み込みの 「マザーボード」デバイス(シリアルポート、パラレルポート、サウンド等)の リソース情報を取得し、リソースの衝突を避ける役に立ちます。 このオプションを有効にすると、いくつかの追加のリソースファイルが <tt>/proc/bus/pccard</tt> の下に作られ、 <tt/lspnp/ ツールと <tt/setpnp/ ツールを使って PnP BIOS デバイスの参照 と操作を行えます。しかし、この設定は一部のラップトップ機で問題を起こす ので、デフォルトでは有効になっていません。 <!-- <tag/How to set kernel-specific options?/ There are a few kernel configuration options that affect the PCMCIA tools. The configuration script can deduce these from the running kernel (the default and most common case). Alternatively, if you are compiling for installation on another machine, it can read the configuration from a kernel source tree, or each option can be set interactively. --> <tag/How to set kernel-specific options?(カーネル固有のオプションの設定方法は?)/ PCMCIA の各種ツールに影響を与えるカーネルの設定オプションもいくつかありま す。たいていの場合、設定用のスクリプトはこれらのオプションを稼働中のカー ネルから推定します(デフォルト動作であり、最も一般的なケースです)。 別のマシン用にコンパイルする場合などにはこれを行わ ないで、カーネルのソースコードから設定オプションを読み込むこともできま すし、それぞれのオプションを対話的に設定することも可能です。 </descrip> <!-- The <tt/Configure/ script can also be executed non-interactively, for automatic builds or to quickly reconfigure after a kernel update. Some additional less-frequently-used options can be only be set from the command line. Running ``<tt/Configure -/-help/'' lists all available options. --> <tt/Configure/ スクリプトは、自動的に構築するためやカーネルの更新後に 素早く再設定するために非対話的に実行することもできます。 あまり使われないオプションのいくつかは、コマンドラインでしか指定できま せん。利用可能な全てのオプションを見るには、``<tt/Configure --help/'' を実行してください。 <!-- Running ``<tt/make all/'' followed by ``<tt/make install/'' will build and then install the kernel modules and utility programs. Kernel modules are installed under <tt>/lib/modules/<version>/pcmcia</tt>. The <tt/cardmgr/ and <tt/cardctl/ programs are installed in <tt>/sbin</tt>. If <tt/cardinfo/ is built, it is installed in <tt>/usr/bin/X11</tt>. --> ``<tt/make all/'' して ``<tt/make install/'' すると、プログラムをコン パイルし、カーネル用モジュールとユーティリティプログラムを適切な場所に インストールされます。カーネル用のモジュールは <tt>/lib/modules/<version>/pcmcia</tt> ディレクトリにインストー ルされます。 [訳注: version の部分には、使っているカーネルのバージョン番号 (2.0.36, 2.2.8 等)が入ります] プログラム <tt/cardmgr/ と <tt/cardctl/ は <tt>/sbin</tt> に、インストー ルされます。<tt/cardinfo/ を作っていれば、これは <tt>/usr/X11R6/bin</tt> にインストールされます。 <!-- Configuration files will be installed in the <tt>/etc/pcmcia</tt> directory. If you are installing over an older version, your old config scripts will be backed up before being replaced. The saved scripts will be given an <tt/*.O/ extension. --> 設定用のファイルは <tt>/etc/pcmcia</tt> ディレクトリにインストールされ ます。もし古いバージョンに上書きしてインストールすると、古い設定ファイ ルはバックアップ後に置き換えられます。保存されたスクリプトには <tt/*.O/ という拡張子が付けられます。 <!-- If you don't know what kind of host controller your system uses, you can use the <tt/probe/ utility in the <tt>cardmgr/</tt> subdirectory to determine this. There are two major types: the Databook TCIC-2 type and the Intel i82365SL-compatible type. --> もしどのような PCMCIA コントローラチップが使われているかわからなければ、 <tt>cardmgr/</tt> サブディレクトリにある <tt/probe/ コマンドで調べるこ とができます。コントローラには大きく分けて Databook TCIC-2 と Intel i82365SL 互換チップの 2 つの種類があります。 <!-- In a few cases, the <tt/probe/ command will be unable to determine your controller type automatically. If you have a Halikan NBD 486 system, it has a TCIC-2 controller at an unusual location: you'll need to edit <tt/rc.pcmcia/ to load the <tt/tcic/ module, and also set the <tt/PCIC_OPTS/ parameter to ``<tt/tcic_base=0x02c0/''. --> たまに <tt>probe</tt> コマンドで自動的にコントローラを設定できない ことがあります。Halikan NBD 486 システムでは TCIC-2 コントローラが変わった アドレスにあります。したがって、<tt/rc.pcmcia/ を編集して <tt/tici/ モジュールをロードするようにし、<tt>PCIC_OPTS </tt>の パラメータに<tt>``tcic_base=0x02c0''</tt>を指定する必要があります。 <!-- On some systems using Cirrus controllers, including the NEC Versa M, the BIOS puts the controller in a special suspended state at system startup time. On these systems, the <tt/probe/ command will fail to find any known host controller. If this happens, edit <tt/rc.pcmcia/ and set <tt/PCIC/ to <tt/i82365/, and <tt/PCIC_OPTS/ to ``<tt/wakeup=1/''. --> Cirrus 製のコントローラを使っている一部のシステム(NEC Versa M 等)では、 システムの起動時に BIOS がコントローラに特殊なサスペンド状態を設定しま す。このようなシステムでは、<tt/probe/ コマンドは対応していても ホストコントローラの検出に失敗します。この場合には、<tt/rc.pcmcia/ を 編集して、<tt/PCIC/ に <tt/i82365/ を設定し、<tt/PCIC_OPTS/ に ``<tt/wakeup=1/'' を設定してください。 <!-- <sect1>Startup options<label id="startup"> --> <sect1>起動オプション<label id="startup"> <p> <!-- The PCMCIA startup script recognizes several groups of startup options, set via environment variables. Multiple options should be separated by spaces and enclosed in quotes. Placement of startup options depends on the Linux distribution used. They may be placed directly in the startup script, or they may be kept in a separate option file. See the <ref id="distributions" name="Notes about specific Linux distributions"> for specifics. The following variables can be set: --> PCMCIA の起動スクリプトは、何種類かのグループの起動オプションを認識し ます。これは環境変数を使って設定します。オプションが複数個になる場合は、 空白で区切り、全体をクォートしなければなりません。起動オプションを書く 場所はディストリビューションによって違います。直接起動スクリプトに書い ても構いませんし、独立したオプション用ファイルに書いてもいいでしょう。 ディストリビューション固有の事情については、 <ref id="distributions" name="個別ディストリビューションに関する注意"> の節をご覧ください。 <descrip> <tag><tt/PCMCIA/</tag> <!-- This variable specifies whether PCMCIA support should be started up, or not. If it is set to anything other than ``yes'', then the startup script will be disabled. --> この変数は、PCMCIA サポートを起動するかどうかを指定します。``yes'' 以 外が設定されると、起動スクリプトは無効になります。 <tag><tt/PCIC/</tag> <!-- This identifies the PC Card Interface Controller driver module. There are two options: ``tcic'' or ``i82365''. Virtually all current controllers are in the ``i82365'' group. This is the only mandatory option setting. --> このオプションは PC カードコントローラドライバモジュールを指定します。 選択肢は 2 つ(``tcic'' または ``i82365'')です。事実上、現在利用可能な ドライバは全て ``i82365'' に属しています。これは唯一必須なオプション 設定です。 <tag><tt/PCIC_OPTS/</tag> <!-- This specifies options for the PCIC module. Some host controllers have optional features that may or may not be implemented in a particular system. In some cases, it is impossible for the socket driver to detect if these features are implemented. See the corresponding man page for a complete description of the available options. --> このオプションは、PCIC モジュール用のオプションを指定します。 ホストコントローラによっては、実際のシステムでは実装されていることもさ れていないこともあるオプション機能があります。場合によっては、この機能 が実装されているかどうかをソケットドライバが検出できないことがあります。 指定できるオプションの詳しい説明については、該当するオンラインマニュアル をご覧ください。 <tag><tt/CORE_OPTS/</tag> <!-- This specifies options for the <tt/pcmcia_core/ module, which implements the core PC Card driver services. See ``<tt/man pcmcia_core/'' for more information. --> このオプションは、<tt/pcmcia_core/ モジュール用のオプションを指定しま す。このモジュールは、PC カードドライバサービスの中心部分を実装したも のです。詳しくは ``<tt/man pcmcia_core/'' を見てください。 <tag><tt/CARDMGR_OPTS/</tag> <!-- This specifies options to be passed to the <tt/cardmgr/ daemon. See ``<tt/man cardmgr/'' for more information. --> このオプションは、<tt/cardmgr/ デーモンに渡すオプションを指定します。 詳しくは ``<tt/man cardmgr/'' をご覧ください。 <tag><tt/SCHEME/</tag> <!-- If set, then the PC Card configuration scheme will be initialized to this at driver startup time. See the <ref id="config" name="Overview of the PCMCIA configuration scripts"> for a discussion of schemes. --> このオプションが設定されていると、その内容がドライバの起動時の PC カードの設定スキームとして初期化されます。スキームについての説明は、 <ref id="config" name="PCMCIA 設定スクリプトの概要">の節をご覧ください。 </descrip> <!-- The low level socket drivers, <tt/tcic/ and <tt/i82365/, have various bus timing parameters that may need to be adjusted for certain systems with unusual bus clocking. Symptoms of timing problems can include card recognition problems, lock-ups under heavy loads, high error rates, or poor device performance. Only certain host bridges have adjustable timing parameters: check the corresponding man page to see what options are available for your controller. Here is a brief summary: --> ハードウェアレベルのソケットドライバ(<tt/tcic/ と <tt/i82365/)はバスタ イミングを制御するためのパラメータを多数持っており、バスクロックが通常 とは異なるシステムではそれらを調整する必要があるかもしれません。バスタ イミングに起因する問題としては、カードが認識されない、負荷が高いとハン グアップする、エラーがよく起きる、デバイスの性能が出ない等があります。 タイミング調整のパラメータを持っているのは特定のホストブリッジだけです。 お使いのコントローラに対して指定できるオプションについては該当するオン ラインマニュアルを見てもらうこととして、ここでは概要だけを説明します: <itemize> <item> <!-- Cirrus controllers have numerous configurable timing parameters. The most important seems to be the <tt/cmd_time/ flag, which determines the length of PCMCIA bus cycles. Fast 486 systems (i.e., DX4-100) seem to often benefit from increasing this from 6 (the default) to 12 or 16. --> Cirrus 製のコントローラーにはタイミングを設定するためのパラメーターが 多数用意されています。そのうち、最も重要なものは <tt/cmd_time/ フラグ でしょう。このフラグは PCMCIA のバスサイクル長を設定します。 高速な 486 システム(つまり DX4-100)では、この値を 6 (デフォルト値)から 12 または 16 に増やすと効果があるようです。 <item> <!-- The Cirrus PD6729 PCI controller has the <tt/fast_pci/ flag, which should be set if the PCI bus speed is greater than 25 MHz. --> Cirrus PD6729 PCI コントローラーには <tt/fast_pci/ というフラグがあり ます。もし PCI バスのスピードが 25MHz 以上の場合、このフラグをセットす る必要があります。 <item> <!-- For Vadem VG-468 controllers and Databook TCIC-2 controllers, the <tt/async_clock/ flag changes the relative clocking of PCMCIA bus and host bus cycles. Setting this flag adds extra wait states to some operations. However, I have yet to hear of a laptop that needs this. --> Vadem VG-468 コントローラと Databook TCIC-2 コントローラーには <tt/async_clock/ フラグがあり、PCMCIA のバスクロックとホストの バスクロックの相対的なタイミングを変更します。このフラグをセットすれば、 いくつかの操作ついて余分のウェイトサイクルが入るようになります。 ただし私は、このフラグが必要なラップトップ機を聞いたことはまだありませ ん。 <item> <!-- The <tt/pcmcia_core/ module has the <tt/cis_speed/ parameter for changing the memory speed used for accessing a card's Card Information Structure (CIS). On some systems with fast bus clocks, increasing this parameter (i.e., slowing down card accesses) may be beneficial for card recognition problems. --> <tt/pcmcia_core/ モジュールには <tt/cis_speed/ というパラメータがあり、 PCMCIA カードのカード情報領域(CIS:Card Information Structure)にアクセス する速度を変化させます。バスクロックの速いシステムではこのパラメータを 大きくする(すなわち、カードへのアクセス速度を遅くする)とカード認識の問 題が解決するかもしれません。 <item> <!-- This is not a timing issue, but if you have more than one ISA-to-PCMCIA controller in your system or extra sockets in a docking station, the <tt/i82365/ module should be loaded with the <tt/extra_sockets/ parameter set to 1. This should not be necessary for detection of PCI-to-PCMCIA or PCI-to-CardBus bridges. --> これはタイミングの問題ではありませんが、システムに複数の ISA-PCMCIA コントローラがある場合や、ドッキングステーションに追加の ソケットがある場合には、i82365 モジュールは <tt>extra_sockets</tt> パラメータを 1 にしてロードしなければなりません。この設定は、 PCI-PCMCIA や PCI-CardBus ブリッジの検出では必要ないはずです。 </itemize> <!-- Here are some timing settings for specific systems: --> 個別システムでのタイミングの設定例をいくつか紹介します: <itemize> <!-- <item>On the ARM Pentium-90 or Midwest Micro Soundbook Plus, use ``<tt/freq_bypass=1 cmd_time=8/''. --> <item> ARM Pentium-90 や Midwest Micro Soundbook Plus では <tt>``freq_bypass=1 cmd_time=8''</tt> と設定します。 <!-- <item>On a Midwest Micro Soundbook Elite, use ``<tt/cmd_time=12/''. --> <item> Midwest Micro Soundbook Elite では <tt>``cmd_time=12''</tt> を 指定します。 <!-- <item>On a Gateway Liberty, try ``<tt/cmd_time=16/''. --> <item>Gateway Liberty では <tt>``cmd_time=16''</tt> を試してください。 <!-- <item>On a Samsung SENS 810, use ``<tt/fast_pci=1/''. --> <item>Samsung SENS 810 では ``<tt/fast_pci=1/'' を指定します。 </itemize> <!-- <sect1>System resource settings --> <sect1>システムリソースの設定 <p> <!-- Card Services should automatically avoid allocating IO ports and interrupts already in use by other standard devices. It will also attempt to detect conflicts with unknown devices, but this is not completely reliable. In some cases, you may need to explicitly exclude resources for a device in <tt>/etc/pcmcia/config.opts</tt>. --> カードサービス・システムは他の標準的なデバイスが既に使っている I/O ポートや IRQ は自動的に回避しようとします。非標準的なデバイスとぶ つかっていることを検知しても自動的に別のリソースを使おうとしますが、こ の機能はまだ完璧ではありません。場合によっては、使わないリソースを <tt>/etc/pcmcia/config.opts</tt> で明示的に指定する必要があるかもしれ ません。 <!-- Here are some resource settings for specific laptop types. View this list with suspicion: it may give useful hints for solving problems, but it is inevitably out of date and certainly contains mistakes. Corrections and additions are welcome. --> 以下は、特定のラップトップ機で必要なリソースの設定です。このリストを信 用しすぎないでください。このリストは問題解決のためのヒントになるかもし れませんが、どうしても内容は古くなってしまいますし、きっと間違いもある でしょう。訂正・追加は歓迎です。 <itemize> <item> <!-- On the AMS SoundPro, exclude irq 10. --> AMS Soundpro の場合、irq 10 を使わないように設定します。 <item> <!-- On some AMS TravelPro 5300 models, use memory 0xc8000-0xcffff. --> AMS TravelPro 5300 の一部のモデルでは、0xc8000-0xcffff のメモリ領域を 使うように設定します。 <item> <!-- On the BMX 486DX2-66, exclude irq 5, irq 9. --> BMX 486DX2-66 の場合、irq 5 と 9 を使わないように設定します。 <item> <!-- On the Chicony NB5, use memory 0xda000-0xdffff. --> Chicony NB5 では 0xda000-0xdffff のメモリ領域を使うように設定します。 <item> <!-- On the Compaq Presario 1020, exclude port 0x2f8-0x2ff, irq 3, irq 5. --> Compaq Presario 1020 では 0x2f8-0x2ff のポートと irq 3, 5 を使わないよ うに設定します。 <item> <!-- On the HP Omnibook 4000C, exclude port 0x300-0x30f. --> HP Omnibook 4000C では 0x300-0x30f のポートを使わないように設定します。 <item> <!-- On the IBM ThinkPad 380, and maybe the 385 and 600 series, exclude port 0x230-0x233, and irq 5. --> IBM ThinkPad 380 および、たぶん 385, 600 シリーズでは 0x230-0x233 のポートと irq 5 を使わないように設定します。 <item> <!-- On IBM ThinkPad 600 and 770 models with internal modems, exclude port 0x2f8-0x2ff. --> 内蔵モデム付きの IBM ThinkPad 600 と 770 では、ポート 0x2f8-0x2ff を使 わないように設定します。 <item> <!-- On the IBM ThinkPad 600E and 770Z, change the high memory window to 0x60000000-0x60ffffff. --> IBM ThinkPad 600E と 770Z では、ハイメモリウィンドウを 0x60000000-0x60ffffff に変更します。 <item> <!-- On the Micron Millenia Transport, exclude irq 5, irq 9. --> Micron Millenia Transport では irq 5, 9 を使わないように設定します。 <item> <!-- On the NEC Versa M, exclude irq 9, port 0x2e0-2ff. --> NEC Versa M では irq 9 と 0x2e0-2ff のポートを使わないようにします。 <item> <!-- On the NEC Versa P/75, exclude irq 5, irq 9. --> NEC Versa P/75 では irq 5 と irq 9 を使わないようにします。 <item> <!-- On the NEC Versa S, exclude irq 9, irq 12. --> NEC Versa S では irq 9 と 12 を使わないようにします。 <item> <!-- On the NEC Versa 6000 series, exclude port 0x2f8-0x33f, irq 9, irq 10. --> NEC Versa 6000 シリーズでは、0x2f8-0x33f のポートと irq 9, 10 を使わな いようにします。 <item> <!-- On the ProStar 9200, Altima Virage, and Acquiline Hurricane DX4-100, exclude irq 5, port 0x330-0x35f. Maybe use memory 0xd8000-0xdffff. --> ProStar 9200, Altima Virage, Acquiline Hurricane DX4-100 では irq 5と I/O ポートの 0x330-0x35f を使わないように設定します。メモリは多分、 0xd8000-0xdffff を使うように指定する必要があるでしょう。 <item> <!-- On the Siemens Nixdorf SIMATIC PG 720C, use memory 0xc0000-0xcffff, port 0x300-0x3bf. --> Siemens Nixdorf SIMATIC PG 720C では、メモリ 0xc0000-0xcffff, ポート 0x300-0x3bf を使うように設定します。 <item> <!-- On the TI TravelMate 5000, use memory 0xd4000-0xdffff. --> TI TravelMate 5000 では 0xd4000-0xdffff の領域を使うようにします。 <item> <!-- On the Toshiba T4900 CT, exclude irq 5, port 0x2e0-0x2e8, port 0x330-0x338. --> 東芝 T4900 CT では irq 5 と I/O ポート 0x2e0-0x2e8, 0x330-0x338 を 使用しないように設定します。 <item> <!-- On the Toshiba Tecra 8000, exclude irq 3, irq 5, irq 9. --> 東芝 Tecra 8000 では、irq 3, irq 5, irq 9 を使わないように設定します。 <item> <!-- On the Twinhead 5100, HP 4000, Sharp PC-8700 and PC-8900, exclude irq 9 (sound), irq 12. --> Twinhead 5100, HP 4000, Sharp PC-8700, PC-8900 では irq 9(サウンド 用)と irq 12 を使わないように設定します。 <item> <!-- On an MPC 800 Series, exclude irq 5, port 0x300-0x30f for the CD-ROM. --> MPC 800 シリーズでは CD-ROM 用に irq 5 と 0x300-0x30f を使わないように 設定します。 </itemize> [訳注: VAIO PCG-C1R に関する情報が JF 文書の <htmlurl url="http://www.linux.or.jp/JF/JFdocs/VAIO-C1R.html" name="VAIO PCG-C1R で Linux">にあります] <!-- <sect1>Notes about specific Linux distributions<label id="distributions"> --> <sect1>個別ディストリビューションに関する注意<label id="distributions"> <p> <!-- This section is incomplete. Corrections and additions are welcome. --> この節は未完成です。訂正・追加をよろしくお願いします。 <sect2>Debian <p> <!-- Debian uses a System V boot script arrangement. The PCMCIA startup script is installed as <tt>/etc/init.d/pcmcia</tt>, and startup options are specified in <tt>/etc/pcmcia.conf</tt>. Debian's syslog configuration will place kernel messages in <tt>/var/log/messages</tt> and <tt/cardmgr/ messages in <tt>/var/log/daemon.log</tt>. --> Debian では、システムの起動スクリプトの配置は System V 風になっていま す。PCMCIA の起動スクリプトは <tt>/etc/init.d/pcmcia</tt> にインストー ルされ、起動オプションは <tt>/etc/pcmcia.conf</tt> で指定されます。 Debian における syslog の設定では、カーネルからのメッセージは <tt>/var/log/messages</tt> に書き込まれ、<tt/cardmgr/ からのメッセージ は <tt>/var/log/daemon.log</tt> に書き込まれます。 <!-- Debian distributes the PCMCIA system in two packages: the ``<tt/pcmcia-cs/'' package contains <tt/cardmgr/ and other tools, man pages, and configuration scripts; and the ``<tt/pcmcia-modules/'' package contains the kernel driver modules. --> Debian は、PCMCIA システムを 2 つのパッケージで配布しています。すなわ ち、<tt/cardmgr/ やオンラインマニュアル、設定スクリプトを含む ``<tt/pcmcia-cs/'' パッケージと、カーネルドライバモジュールを含む ``<tt/pcmcia-modules/'' パッケージです。 <!-- <sect2>Red Hat, Caldera, Mandrake --> <sect2>RedHat, Caldera, Mandrake <p> [訳注: 日本語 RedHat Linux, LASER5 Linux, Vine Linux を含みます] <p> <!-- These distributions use a System V boot script organization. The PCMCIA startup script is installed as <tt>/etc/rc.d/init.d/pcmcia</tt>, and boot options are kept in <tt>/etc/sysconfig/pcmcia</tt>. Beware that installing the Red Hat package may install a default boot option file that has PCMCIA disabled. To enable PCMCIA, the ``<tt/PCMCIA/'' variable should be set to ``<tt/yes/''. Red Hat's default <tt/syslogd/ configuration will record all interesting messages in <tt>/var/log/messages</tt>. --> これらのディストリビューションの起動スクリプトの配置は System V 形式で す。PCMCIA の起動スクリプトは <tt>/etc/rc.d/init.d/pcmcia</tt> にイン ストールされ、起動オプションは <tt>/etc/sysconfig/pcmcia</tt> に書かれ ます。RedHat のデフォルトのインストールでは、PCMCIA を無効にした状態の 起動オプションファイルがインストールされるので注意してください。 PCMCIA を有効にするには、環境変数 ``<tt/PCMCIA/'' に ``<tt/yes/'' を設 定します。RedHat のデフォルトの <tt/syslogd/ の設定では、関連メッセージは全 て <tt>/var/log/messages</tt> に記録されます。 <!-- Red Hat's PCMCIA package contains a replacement for the network setup script, <tt>/etc/pcmcia/network</tt>, which meshes with the Red Hat <tt/linuxconf/ configuration system. This is convenient for the case where just one network adapter is used, with one set of network parameters, but does not have the full flexibility of the regular PCMCIA network script. Compiling and installing a clean PCMCIA source distribution will overwrite the network script, breaking the link to the Red Hat tools. If you prefer the Red Hat tools, either use only Red Hat RPM's, or create <tt>/etc/pcmcia/network.opts</tt> with the following contents: --> RedHat の PCMCIA パッケージには、ネットワーク設定スクリプト (<tt>/etc/pcmcia/network</tt>)を置き換えるファイルが入っています。その ため、RedHat の <tt/linuxconf/ 設定システムとうまく組み合わせて使えます。 これは 1 つだけのネットワークアダプタを 1 組のネットワーク設定で 使っている時には便利ですが、通常の PCMCIA ネットワークスクリプトのよう な柔軟性はありません。PCMCIA の素のソース配布物からコンパイルとインストー ルを行うと、RedHat のツール群へのリンクが壊れてしまいます。 RedHat のスクリプトを使いたければ、RedHat の RPM だけを使うか、以下の 内容の <tt>/etc/pcmcia/network.opts</tt> を作るようにしてください: <tscreen><verb> if [ -f /etc/sysconfig/network-scripts/ifcfg-eth0 ] ; then start_fn () { /sbin/ifup $1 } stop_fn () { /sbin/ifdown $1 } fi </verb></tscreen> <!-- If you do use <tt/linuxconf/ (or <tt/netconf/) to configure your network interface, leave the ``kernel module'', ``I/O port'', and ``irq'' parameters blank. Setting these parameters may interfere with proper operation of the PCMCIA subsystem. --> <tt/linuxconf/ (または <tt/netconf/)を使ってネットワークインタフェース を設定する場合は、``kernel module'', ``I/O port'', `irq'' パラメータは 空のままにしてください。これらのパラメータを設定すると、PCMCIA サブシステム の適切な動作の邪魔になるかもしれません。 <!-- At boot time, when the Red Hat network subsystem starts up, it may say ``Delaying eth0 initialization'' and ``[FAILED]''. This is actually not a failure: it means that this network interface will not be initialized until after the PCMCIA network device is configured. --> マシンの起動時にネットワークサブシステムが立ち上がる際に ``Delaying eth0 initialization'' と ``[FAILED]'' と出力されるかもしれ ません。これは実際には問題ありません: これは、PCMCIA のネットワーク デバイスが設定されるまではネットワークインタフェースが初期化されないと いう意味です。 <!-- Red Hat bundles their slightly modified PCMCIA source distribution in their kernel SRPM, rather than as a separate source package. --> RedHat では、多少修正が入った PCMCIA のソース配布物がカーネルの SRPM に付いています。単独のソースパッケージでは配布されていません。 <sect2>Slackware <p> [訳注: Plamo Linux を含みます] <p> <!-- Slackware uses a BSD boot script arrangement. The PCMCIA startup script is installed as <tt>/etc/rc.d/rc.pcmcia</tt>, and boot options are specified in <tt>rc.pcmcia</tt> itself. The PCMCIA startup script is invoked from <tt>/etc/rc.d/rc.S</tt>. --> Slackware の起動スクリプト配置は BSD 風です。PCMCIA 起動スクリプトは <tt>/etc/rc.d/rc.pcmcia</tt> にインストールされ、起動オプションは <tt>rc.pcmcia</tt> で直接指定されます。PCMCIA 起動スクリプトは <tt>/etc/rc.d/rc.S</tt> から呼び出されます。 <sect2>SuSE <p> <!-- SuSE uses a System V init script arrangement, with init scripts stored under <tt>/sbin/init.d</tt>. The PCMCIA startup script is installed as <tt>/sbin/init.d/pcmcia</tt>, and startup options are kept in <tt>/etc/rc.config</tt>. The SuSE startup script is somewhat limited and does not allow PCMCIA startup variables to be overridden from the <tt/lilo/ boot prompt. --> SuSE の起動スクリプトは System V 形式です。起動スクリプトは <tt>/sbin/init.d</tt> に置かれます。PCMCIA の起動スクリプトは <tt>/sbin/init.d/pcmcia</tt> にインストールされ、起動オプションは <tt>/etc/rc.config</tt> に書かれます。SuSE の起動スクリプトには 多少の制限があり、<tt/lilo/ の起動プロンプトから PCMCIA の起動変数を 上書きすることができません。 <!-- <sect>Resolving installation and configuration problems --> <sect>インストールと設定における問題の解決 <p> <!-- This section describes some of the most common failure modes for the PCMCIA subsystem. Try to match your symptoms against the examples. This section only describes general failures that are not specific to a particular client driver or type of card. --> この章では、PCMCIA サブシステムで起こしやすい問題をいくつか説明します。 現われた症状を例と比べてみてください。この章では、特定の クライアントドライバやカードに固有でない一般的な問題だけを説明します。 <!-- Before trying to diagnose a problem, you have to know where your system log is kept (see <ref id="distributions" name="Notes about specific Linux distributions">). You should also be familiar with basic diagnostic tools like <tt/dmesg/ and <tt/lsmod/. Also, be aware that most driver components (including all the kernel modules) have their own individual man pages. --> 問題を分析する前には、システムログが記録される場所を知っておいてくださ い(<ref id="distributions" name="個別ディストリビューションに関する注意"> を参照)。また、<tt/dmesg/ や <tt/lsmod/ のような、基本的な診断ツールに も慣れておいてください。それから、ほとんどのドライバコンポーネント (カーネルモジュール全てを含みます)には専用のオンラインマニュアルが付い ていることも忘れないでください。 <!-- Try to define your problem as narrowly as possible. If you have several cards, try each card in isolation, and in different combinations. Try cold Linux boots, versus warm boots from Windows. Compare booting with cards inserted, versus inserting cards after boot. If you normally use your laptop docked, try it undocked. And sometimes, two sockets will behave differently. --> 問題をできるだけ絞り込みましょう。複数のカードを使っている場合は、 それぞれを単独で使ってみたり、色々な組合せを試してみましょう。 Linux をコールドブートした結果と Windows からウォームブートした結果を 比べてみましょう。カードを挿入したまま起動した結果と起動後にカードを 挿入した結果を比べてみましょう。通常はラップトップ機をドックに接続して いるのであれば、ドックから切り離してみましょう。また、2 つのソケットの 動作が異なる場合もあります。 <!-- It is nearly impossible to debug driver problems encountered when attempting to install Linux via a PCMCIA device. Even if you can identify the problem based on its symptoms, installation disks are difficult to modify, especially without access to a running Linux system. Customization of installation disks is completely dependent on the choice of Linux distribution, and is beyond the scope of this document. In general, the best course of action is to install Linux using some other means, obtain the latest drivers, and then debug the problem if it persists. --> Linux を PCMCIA 経由でインストールしている時に遭遇したドライバの問題を デバッグするのはほとんど不可能です。症状に基づいて問題を特定しても、イ ンストール用ディスクを修正するのは困難でしょう(特に、動作している Linux システムがない場合)。インストール用ディスクの修正方法は選んだディ ストリビューションによって全く違い、これは本文書で扱う範囲を超えていま す。一般的にはこういう場合の最善の策は、別の手段で Linux をインストー ルすること、最新のドライバを入手すること、それでどうしようもなければ問 題をデバッグすることです。 <!-- <sect1>Base PCMCIA kernel modules do not load --> <sect1>ベースとなる PCMCIA カーネルモジュールがロードされません <p> <!-- Symptoms: --> 症状: <itemize> <!-- <item>Kernel version mismatch errors are reported when the PCMCIA startup script runs. --> <item>PCMCIA の起動スクリプトの実行中に、カーネルバージョンの不整合に 関するエラーが出る。 <!-- <item>After startup, <tt/lsmod/ does not show any PCMCIA modules. --> <item>起動後に <tt/lsmod/ を実行しても PCMCIA モジュールが表示されない。 <!-- <item><tt/cardmgr/ reports ``<tt>no pcmcia driver in /proc/devices</tt>'' in the system log. --> <item><tt/cardmgr/ がシステムログに ``<tt>no pcmcia driver in /proc/devices</tt>'' と報告を出す。 </itemize> <!-- Kernel modules contain version information that is checked against the current kernel when a module is loaded. The type of checking depends on the setting of the <tt/CONFIG_MODVERSIONS/ kernel option. If this is false, then the kernel version number is compiled into each module, and <tt/insmod/ checks this for a match with the running kernel. If <tt/CONFIG_MODVERSIONS/ is true, then each symbol exported by the kernel is given a sort of checksum. These codes are all compared against the corresponding codes compiled into a module. The intent was for this to make modules less version-dependent, because the checksums would only change if a kernel interface changed, and would generally stay the same across minor kernel updates. In practice, the checksums have turned out to be even more restrictive, because many kernel interfaces depend on compile-time kernel option settings. Also, the checksums turned out to be an excessively pessimistic judge of compatibility. --> カーネルモジュールにはバージョン情報が書き込まれており、これは モジュールのロード時に現在動作中のカーネルのバージョンと比べられます。 このチェックの種類は、カーネルのオプションである <tt/CONFIG_MODVERSIONS/ の設定によって変わります。これが <tt/No/ ならば、カーネルのバージョン番号 はコンパイル時に各モジュールに書き込まれ、<tt/insmod/ はこの値が実行中 のカーネルと一致するかをチェックします。<tt/CONFIG_MODVERSIONS/ が <tt/Yes/ ならば、カーネルがエクスポートしたそれぞれのシンボルには、あ る種のチェックサムが与えられます。これらのコードは全て、モジュールに 組み込まれている該当コードと比較されます。この目的は、モジュールをでき るだけバージョンに依存しないようにすることです。というのも、チェックサム が変わるのはカーネルのインタフェースが変わる時だけであり、一般的には カーネルのマイナーバージョンが上がっても変わらないからです。実際には、 チェックサムの制限は厳しいことが分かっています。なぜなら、多くのカーネル インタフェースはコンパイル時のカーネルのオプション設定に依存するからです。 また、チェックサムによる互換性の判定は非常に厳しいことが分かっています。 <!-- The practical upshot of this is that kernel modules are closely tied to both the kernel version, and the setting of many kernel configuration options. Generally, a set of modules compiled for one 2.0.31 kernel will not load against some other 2.0.31 kernel unless special care is taken to ensure that the two were built with similar configurations. This makes distribution of precompiled kernel modules a tricky business. --> 実際の結論としては、カーネルモジュールはカーネルのバージョンと多くの カーネル設定オプションの設定値の両方に密接に関係しています。一般的には、 バージョン 2.0.31 のカーネル用に設定したモジュール群は、同じような設定 になるように注意して構築していなければ、バージョン 2.0.31 の別のカーネ ルではロードできないことがあります。そのため、コンパイル済みのカーネル モジュールを配布するのは非常にやりにくい作業です。 <!-- You have several options: --> 選択肢はいくつかあります: <itemize> <!-- <item>If you obtained precompiled drivers as part of a Linux distribution, verify that you are using an unmodified kernel as supplied with that distribution. If you intend to use precompiled modules, you generally must stick with the corresponding kernel. --> <item>コンパイル済みのドライバを Linux ディストリビューションの一部と して入手した場合には、そのディストリビューションに付属している、変更さ れていないカーネルを使っていることを確かめてください。コンパイル済みの モジュールを使うつもりであれば普通、これに対応するカーネルを使い続けな ければなりません。 <!-- <item>If you have reconfigured or upgraded your kernel, you will probably need to compile and install the PCMCIA package from scratch. This is easily done if you already have the kernel source tree installed. See <ref id="compile" name="Compilation and installation"> for detailed instructions. --> <item>カーネルの再設定やバージョンアップを行っている場合には、PCMCIA パッケージのコンパイルとインストールを最初から行わなければならないでしょ う。カーネルのソースがインストールしてあれば、この作業は簡単です。詳し い手順については、<ref id="compile" name="コンパイルとインストール"> の 章を見てください。 <!-- <item>In some cases, incompatibilities in other system components can prevent correct loading of kernel modules. If you have upgraded your own kernel, pay attention to the ``minimal requirements'' for module utilities and binutils listed in the <tt>Documentation/Changes</tt> file in the kernel source code tree. --> <item>場合によっては、他のシステムコンポーネントと互換性がないために、 カーネルモジュールを正しくロードできないことがあります。カーネルの バージョンアップをしている場合には、カーネルのソースコードに入っている <tt>Documentation/Changes</tt> ファイルに書かれている、 モジュールユーティリティと binutils の「最低条件」を確かめてください。 </itemize> <!-- <sect1>Some client driver modules do not load --> <sect1>ロードできないクライアントドライバモジュールがあります <p> <!-- Symptoms: --> 症状: <itemize> <!-- <item>The base modules (<tt/pcmcia_core/, <tt/ds/, <tt/i82365/) load correctly. --> <item>基本モジュール (<tt/pcmcia_core/, <tt/ds/, <tt/i82365/) は正しく ロードされている。 <!-- <item>Inserting a card gives a high beep + low beep pattern. --> <item>カードを挿した時に高いビープ音 + 低いビープ音が鳴る。 <!-- <item><tt/cardmgr/ reports version mismatch errors in the system log. --> <item><tt/cardmgr/ がシステムログにバージョン不整合のエラーを残す。 </itemize> <!-- Some of the driver modules require kernel services that may or may not be present, depending on kernel configuration. For instance, the SCSI card drivers require that the kernel be configured with SCSI support, and the network drivers require a networking kernel. If a kernel lacks a necessary feature, <tt/insmod/ may report undefined symbols and refuse to load a particular module. Note that <tt/insmod/ error messages do not distinguish between version mismatch errors and missing symbol errors. --> 一部のドライバモジュールはカーネルのサービスを必要としますが、これはカー ネルの設定によりあったりなかったりします。例えば、SCSI カードドライバ はカーネルが SCSI をサポートする設定になっていることを必要とし、 ネットワークドライバはネットワーク対応のカーネルを必要とします。 もしカーネルが必要な機能を持っていなければ、<tt/insmod/ は 「undefined symbols」というエラーを出し、そのモジュールのロードを拒否 します。<tt/insmod/ のエラーでは、バージョン不整合のエラーと シンボル不足のエラーが区別できないことに注意してください。 <!-- Specifically: --> もっと正確に書くと以下のようになります: <itemize> <!-- <item>The serial client driver <tt/serial_cs/ requires the kernel serial driver to be enabled with <tt/CONFIG_SERIAL/. This driver may be built as a module. --> <item>シリアル用のクライアントドライバである <tt/serial_cs/ を使うには、 <tt/CONFIG_SERIAL/ によってカーネルのシリアルドライバを有効する必要が あります。このドライバはモジュールとして作られます。 <!-- <item>Support for multiport serial cards or multifunction cards that include serial or modem devices requires <tt/CONFIG_SERIAL_SHARE_IRQ/ to be enabled. --> <item>マルチポートシリアルカードや、シリアルデバイスやモデムデバイスを 含むマルチファンクションカードをサポートするには、 <tt/CONFIG_SERIAL_SHARE_IRQ/ を有効にする必要があります。 <!-- <item>The SCSI client drivers require that <tt/CONFIG_SCSI/ be enabled, along with the appropriate top level driver options (<tt/CONFIG_BLK_DEV_SD/, <tt/CONFIG_BLK_DEV_SR/, etc for 2.1 kernels). These may be built as modules. --> <item>SCSI 用のクライアントドライバを使うには、<tt/CONFIG_SCSI/ を有効 にする必要があります。また、適切なトップレベルドライバオプションを設定 する必要があります(バージョン 2.1 のカーネルでは <tt/CONFIG_BLK_DEV_SD/, <tt/CONFIG_BLK_DEV_SR/ 等)。これらはモジュール として構築されます。 <!-- <item>The network client drivers require that <tt/CONFIG_INET/ is enabled. Kernel networking support cannot be compiled as a module. --> <item>ネットワーク用のクライアントドライバを使うには、<tt/CONFIG_INET/ を有効にする必要があります。カーネルのネットワークサポートは、モジュール として組み込むことはできません。 <!-- <item>The token-ring client requires that the kernel be compiled with <tt/CONFIG_TR/ enabled. --> <item>トークンリング用のクライアントドライバを使うには、<tt/CONFIG_TR/ を有効にする必要があります。 </itemize> <!-- There are two ways to proceed: --> 解決方法は 2 通りあります: <itemize> <!-- <item>Rebuild your kernel with the necessary features enabled. --> <item>必要な機能を有効にしてカーネルを再構築します。 <!-- <item>If the features have been compiled as modules, then modify <tt>/etc/pcmcia/config</tt> to preload these modules. --> <item>この機能がモジュールとしてコンパイルされていれば、 <tt>/etc/pcmcia/config</tt> を修正して、必要なモジュールを予めロードし ておくようにします。 </itemize> <!-- The <tt>/etc/pcmcia/config</tt> file can specify that additional modules need to be loaded for a particular client. For example, for the serial driver, one would use: --> <tt>/etc/pcmcia/config</tt> では、特定のクライアント用にロードする必要 がある追加のモジュールを指定することができます。例えばシリアルドライバ を指定する時には以下のように設定します: <tscreen><verb> device "serial_cs" class "serial" module "misc/serial", "serial_cs" </verb></tscreen> <!-- Module paths are specified relative to the top-level module directory for the current kernel version; if no relative path is given, then the path defaults to the <tt/pcmcia/ subdirectory. --> 複数のパスを、現在のカーネルのバージョンに対応するモジュールの トップレベルディレクトリからの相対パスで指定します。相対パスが全く与え られなければ、パスのデフォルト値は <tt/pcmcia/ サブディレクトリになり ます。 <!-- <sect1>Interrupt scan failures<label id="irqscan"> --> <sect1>割り込みのスキャンに失敗します<label id="irqscan"> <p> <!-- Symptoms: --> 症状: <itemize> <!-- <item>The system locks up when the PCMCIA drivers are loaded, even with no cards present. --> <item>PCMCIA ドライバがロードされると、カードが挿さっていなくても システムが固まってしまう。 <!-- <item>The system log shows a successful host controller probe just before the lock-up, but does not show interrupt probe results. --> <item>システムログには、システムが固まる直前にちゃんとホストコントロー ラが検出したことが記録されているが、割り込みの検出の結果は記録されてい ない。 </itemize> <!-- After identifying the host controller type, the socket driver probes for free interrupts. The probe involves programming the controller for each apparently free interrupt, then generating a ``soft'' interrupt, to see if the interrupt can be detected correctly. In some cases, probing a particular interrupt can interfere with another system device. --> ホストコントローラの種類を識別した後、ソケットドライバは空いている 割り込みを探査します。この探査では、空いているように見える割り込みそれ ぞれに対するコントローラのプログラミングが行われ、その後には「ソフト」 な割り込みの生成が行われます。これは割り込みが正しく検出されたかどうか を調べるために行われます。場合によっては、特定の割り込みを探査すると他 のシステムデバイスとの衝突が起こることがあります。 <!-- The reason for the probe is to identify interrupts which appear to be free (i.e., are not reserved by any other Linux device driver), yet are either not physically wired to the host controller, or are connected to another device that does not have a driver. --> 探査を行う理由は、空いている(つまり、Linux の他のデバイスドライバに 予約されていない)と思われる割り込みで、まだホストコントローラに物理的 に接続されていないか、またはドライバを持っていない他のデバイスに接続さ れているものを識別することです。 <!-- In the system log, a successful probe might look like: --> 探査が成功すると、システムログには以下のような記録が残ります: <tscreen><verb> Intel PCIC probe: TI 1130 CardBus at mem 0x10211000, 2 sockets ... ISA irqs (scanned) = 5,7,9,10 status change on irq 10 </verb></tscreen> <!-- There are two ways to proceed: --> 先に進む方法は 2 つあります: <itemize> <!-- <item>The interrupt probe can be restricted to a list of interrupts using the <tt/irq_list/ parameter for the socket drivers. For example, ``<tt/irq_list=5,9,10/'' would limit the scan to three interrupts. All PCMCIA devices will be restricted to using these interrupts (assuming they pass the probe). You may need to use trial and error to find out which interrupts can be safely probed. --> <item>割り込みの探査は、ソケットドライバに対する <tt/irq_list/ パラメータを使った割り込みのリストによって制限されます。例えば ``<tt/irq_list=5,9,10/'' を指定すると、探査は 3 つの割り込みに対してし か行われません。全ての PCMCIA デバイスは、これらの割り込みを使うように 制限されます(探査はうまくいくものとします)。安全に検出できる割り込みを 見つけるには、試行錯誤が必要かもしれません。 <!-- <item>The interrupt probe can be disabled entirely by loading the socket driver with the ``do_scan=0'' option. In this case, a default interrupt list will be used, which avoids interrupts already allocated for other devices. --> <item>``do_scan=0'' オプションを付けてソケットドライバをロードすると、 割り込みの探査は全く行われなくなります。この場合、デフォルトの割り込み リストが使われるので、既に他のデバイスに割り当てられた割り込みを避ける ことができます。 </itemize> <!-- In either case, the probe options can be specified using the <tt/PCIC_OPTS/ definition in the PCMCIA startup script, for example: --> いずれの場合も、探査用のオプションの指定には PCMCIA 起動スクリプト内の <tt/PCIC_OPTS/ の定義を用います。設定例を以下に示します: <tscreen><verb> PCIC_OPTS="irq_list=5,9,10" </verb></tscreen> <!-- It should be noted that <tt>/proc/interrupts</tt> is completely useless when it comes to diagnosing interrupt probe problems. The probe is sensible enough to never attempt to use an interrupt that is already in use by another Linux driver. So, the PCMCIA drivers are already using all the information in <tt>/proc/interrupts</tt>. Depending on system design, an inactive device can still occupy an interrupt and cause trouble if it is probed for PCMCIA. --> 割り込み探査で問題が起こった時には、<tt>/proc/interrupts</tt> を調べて も全く役に立たないことは肝に命じておいてください。この探査は、Linux の 他のドライバが既に使っている割り込みを使わないようにする程度には賢いの です。ですから、PCMCIA のドライバは既に <tt>/proc/interrupts</tt> の全 ての情報を使っています。システムの設計によっては、動作中でないデバイスで も割り込みを占有し、PCMCIA が探査を行った時に問題を起こすことがありま す。 <!-- <sect1>IO port scan failures<label id="ioscan"> --> <sect1>I/O ポートのスキャンに失敗します<label id="ioscan"> <p> <!-- Symptoms: --> 症状: <itemize> <!-- <item>The system locks up when <tt/cardmgr/ is first started, even with no cards present. --> <item>カードが挿さっていなくても、<tt/cardmgr/ を最初に起動した時に システムが固まってしまう。 <!-- <item>The system log shows a successful host controller probe, including interrupt probe results, but does not show IO probe results. --> <item>システムログには、割り込み探査の結果も含めてホストコントローラの 探査が成功したと記録されるが、I/O 探査の結果は記録されない。 <!-- <item>In some cases, the IO probe will succeed, but report large numbers of random exclusions. --> <item>I/O 探査は正常終了するが、でたらめなアドレスがたくさん除外される という症状が出ることもある。 </itemize> <!-- When <tt/cardmgr/ processes IO port ranges listed in <tt>/etc/pcmcia/config.opts</tt>, the kernel probes these ranges to detect latent devices that occupy IO space but are not associated with a Linux driver. The probe is read-only, but in rare cases, reading from a device may interfere with an important system function, resulting in a lock-up. --> <tt>/etc/pcmcia/config.opts</tt> に挙げられている I/O ポート領域を <tt/cardmgr/ が処理する時、カーネルはこれらの範囲を探査し、I/O 空間を 占有しているけれど Linux のドライバには割り当てられていない隠れた デバイスを検出します。探査では読み取りしか行われませんが、デバイスから の読み出しが重要なシステム関数と衝突し、その結果システムが固まることが 稀に起こります。 <!-- Your system user's guide may include a map of system devices, showing their IO and memory ranges. These can be explicitly excluded in <tt/config.opts/. --> お使いのシステムのユーザガイドを見れば、システムデバイスの割り当て表が 載っており、I/O 領域とメモリ領域の範囲がわかるかもしれません。そうする と、<tt/config.opts/ でこれらの領域を明示的に除外することができます。 <!-- Alternatively, if the probe is unreliable on your system, it can be disabled by setting <tt/CORE_OPTS/ to ``<tt/probe_io=0/''. In this case, you should be very careful to specify only genuinely available ranges of ports in <tt/config.opts/, instead of using the default settings. --> 別の方法として、システムの探査が信頼できない場合には、<tt/CORE_OPTS/ の設定を``<tt/probe_io=0/'' とすることで探査を無効にすることができます。 この場合にはデフォルトの設定を使わないで、ちゃんと使えるポートの範囲だ けを注意深く <tt/config.opts/ に設定しなければなりません。 <!-- <sect1>Memory probe failures --> <sect1>メモリの検出に失敗します <p> <!-- Symptoms: --> 症状: <itemize> <!-- <item>The core drivers load correctly when no cards are present, with no errors in the system log. --> <item>カードが挿さっていない時にはコアドライバが正常にロードされ、 システムログにもエラーが残らない。 <!-- <item>The system freezes and/or reboots as soon as any card is inserted, before any beeps are heard. --> <item>カードを挿すと、ビープ音がすることなく、即座にシステムが固まった りリブートする。 </itemize> <!-- Or alternately: --> 以下のような症状が出る場合もあります: <itemize> <!-- <item>All card insertions generate a high beep followed by a low beep. --> <item>どんなカードを挿しても必ず「高いビープ音 + 低いビープ音」が鳴る。 <!-- <item>All cards are identified as ``anonymous memory cards''. --> <item>どんなカードも ``anonymous memory cards(未知のメモリカード)'' と 認識される。 <!-- <item>The system log reports that various memory ranges have been excluded. --> <item>あちこちのメモリ領域が除外されていることがシステムログに記録され る。 </itemize> <!-- The core modules perform a memory scan at the time of first 16-bit card insertion. This scan can potentially interfere with other memory mapped devices. Also, pre-3.0.0 driver packages perform a more aggressive scan than more recent drivers. The memory window is defined in <tt>/etc/pcmcia/config.opts</tt>. The default window is large, so it may help to restrict the scan to a narrower range. Reasonable ranges to try include 0xd0000-0xdffff, 0xc0000-0xcffff, 0xc8000-0xcffff, or 0xd8000-0xdffff. --> コアモジュールは、16 ビットカードが初めて挿入された時にメモリ走査を実 行します。この操作はメモリにマップされている他のデバイスと衝突する可能 性があります。またバージョン3.0.0 以前のパッケージでは、最近のドライバ よりもきわどい走査を行っていました。メモリウィンドウは <tt>/etc/pcmcia/config.opts</tt> で定義されています。デフォルトの ウィンドウは大きいので、走査をもっと狭い範囲に制限すればよいでしょう。 試すのにちょうどよい範囲は 0xd0000-0xdffff, 0xc0000-0xcffff, 0xc8000-0xcffff, 0xd8000-0xdffff あたりです。 <!-- If you have DOS or Windows PCMCIA drivers, you may be able to deduce what memory region those drivers use. Note that DOS memory addresses are often specified in ``segment'' form, which leaves off the final hex digit (so an absolute address of 0xd0000 might be given as 0xd000). Be sure to add the extra digit back when making changes to <tt>config.opts</tt>. --> DOS または Windows の PCMCIA ドライバがあれば、これらのドライバが使っ ているメモリ領域を調べてもいいでしょう。DOS のメモリアドレスは多くの場 合、「セグメント」の形で指定されており、最終的な 16 進アドレスとは離れ ている点に注意してください(絶対アドレス 0xd0000 が 0xd000 と与えられた りします)。<tt>config.opts</tt> を変更する時には、追加の桁を必ず足し戻 してください。 <!-- In unusual cases, a memory probe failure can indicate a timing register setup problem with the host controller. See the <ref id="startup" name="Startup options"> section for information about dealing with common timing problems. --> 普通でない場合として、メモリ探査の失敗が、ホストコントローラに関するタ イミングレジスタの設定の問題である可能性があります。一般的なタイミング の問題の扱いについては、<ref id="startup" name="起動オプション">の節を ご覧ください。 <itemize> <item><tt>cs: warning: no high memory space available!</tt> </itemize> <!-- CardBus bridges can allocate memory windows outside of the 640KB-1MB ``memory hole'' in the ISA bus architecture. It is generally a good idea to configure CardBus bridges to use high memory windows, because these are unlikely to conflict with other devices. Also, CardBus cards may require large memory windows, which may be difficult or impossible to fit into low memory. Card Services will preferentially allocate windows in high memory for CardBus bridges, if both low and high memory windows are defined in <tt>config.opts</tt>. The default <tt/config.opts/ now includes a high memory window of 0xa0000000-0xa0ffffff. If you have a CardBus bridge and have upgraded from an older PCMCIA driver release, add this memory window if it is not already defined. --> CardBus ブリッジは、ISA バスのアーキテクチャにおける 640KB-1MB の 「メモリの隙間」の外にメモリウィンドウを割り当てることができます。 高位のメモリ領域を使うように CardBus ブリッジを設定するのは、一般的に は良い考えです。なぜなら他のデバイスと衝突しにくいからです。また、 CardBus のカードは大きなメモリウィンドウを必要としますが、これを低位の メモリ領域に取るのは困難であったり不可能だったりします。カードサービス が CardBus ブリッジに対してはウィンドウを割り当てる際には、 <tt>config.opts</tt> に高位のメモリと低位のメモリが両方定義されていれ ば、カードサービスは優先的に高位のメモリを使います。現在のデフォルトの <tt/config.opts/ には高位アドレスのウィンドウ 0xa0000000-0xa0ffffff が 含まれています。読者の皆さんが CardBus ブリッジを持っており、かつ古い PCMCIA ドライバからのバージョンアップを行った場合は、このアドレスがま だ定義されていないのであれば、これを追加しましょう。 <!-- In some cases, the default high memory window is not usable. On some IBM Thinkpad models, a window of 0x60000000-0x60ffffff will work in place of the default window. --> 場合によっては、デフォルトの高位メモリウィンドウが使えないことがありま す。IBM ThinkPad の一部のモデルでは、デフォルトのウィンドウの代わりに 0x60000000-0x60ffffff のウィンドウが使えます。 <!-- <sect1>Failure to detect card insertions and removals --> <sect1>カードの抜き挿しを検出できません <p> <!-- Symptoms: --> 症状: <itemize> <!-- <item>Cards are detected and configured properly if present at boot time. --> <item>起動時にカードが挿してあれば、カードの検出と設定がうまく行われる。 <!-- <item>The drivers do not respond to insertion and removal events, either by recording events in the system log, or by beeping. --> <item>カードの挿入と抜き取りを行ってもドライバが反応しない。 すなわち、システムログにも記録が残らないし、ビープ音もしない。 </itemize> <!-- In most cases, the socket driver (<tt/i82365/ or <tt/tcic/) will automatically probe and select an appropriate interrupt to signal card status changes. The automatic interrupt probe doesn't work on some Intel-compatible controllers, including Cirrus chips and the chips used in some IBM ThinkPads. If a device is inactive at probe time, its interrupt may also appear to be available. In these cases, the socket driver may pick an interrupt that is used by another device. --> 大抵の場合、ソケットドライバ(<tt/i82365/ または <tt/tcic/)は適切な 割り込みの探査と選択を行い、カードの状態変化を知らせます。割り込みの 自動的探査は Intel 互換の一部のカードではうまく動作しません。このよう なカードとしては Cirrus 製のチップがありますが、これが IBM の ThinkPad の一部で使われています。探査の時、あるデバイスが動作していなければ、そ の割り込みは使えるように見えるかもしれません。このような場合には、 ソケットドライバは他のデバイスが使っている割り込みを選ぶかもしれません。 <!-- With the <tt/i82365/ and <tt/tcic/ drivers, the <tt/irq_list/ option can be used to limit the interrupts that will be tested. This list limits the set of interrupts that can be used by PCMCIA cards as well as for monitoring card status changes. The <tt/cs_irq/ option can also be used to explicitly set the interrupt to be used for monitoring card status changes. --> <tt/i82365/ ドライバと <tt/tcic/ ドライバでは、<tt/irq_list/ オプショ ンを使って調べる割り込みを制限することができます。このリストは PCMCIA カードが使える割り込みの組合せと、カードの状態変化を監視する割り込みの 組合せを制限します。<tt/cs_irq/ オプションを使って、カードの状態変化の 監視に使う割り込みを明示的に設定することもできます。 <!-- If you can't find an interrupt number that works, there is also a polled status mode: both <tt/i82365/ and <tt/tcic/ will accept a <tt/poll_interval=100/ option, to poll for card status changes once per second. This option should also be used if your system has a shortage of interrupts available for use by PCMCIA cards. Especially for systems with more than one host controller, there is little point in dedicating interrupts for monitoring card status changes. --> 使える割り込みを見つからなければ、呼び出しモード(polled status mode)を 使うこともできます。<tt/i82365/ と <tt/tcic/ のどちらでも <tt/poll_interval=100/ といったオプションを設定することができます。こ の設定を行うと、カードの状態は 1 秒間に 1 回 行われる呼び出しで調べら れます。このオプションは、PCMCIA カードで使える割り込みが足りない場合 にも使うべきです。特に、複数のホストコントローラを持つシステムの場合に は、カードの状態の監視に専用の割り込みを割り当ててもいいことはありませ ん。 <!-- All these options should be set in the <tt/PCIC_OPTS=/ line in either <tt>/etc/rc.d/rc.pcmcia</tt> or <tt>/etc/sysconfig/pcmcia</tt>, depending on your site setup. --> これらのオプションは全て、<tt>/etc/rc.d/rc.pcmcia</tt> または <tt>/etc/sysconfig/pcmcia</tt> ファイル内の <tt/PCIC_OPTS=/ 行で設定す ることになっているはずです。どちらのファイルを使うかはサイトの設定によっ て異なります。 <!-- <sect1>System resource starvation --> <sect1>システムリソースの不足 <p> <!-- Symptoms: --> 症状: <itemize> <!-- <item>When a card is inserted, it is identified correctly but cannot be configured (high/low beep pattern). --> <item>カードを挿入すると、正しく認識されるが設定ができない( 高いビープ音 + 低いビープ音が鳴ります)。 <!-- <item>One of the following messages will appear in the system log: --> <item>以下のメッセージのいずれかがシステムログに出力される: <tscreen><verb> RequestIO: Resource in use RequestIRQ: Resource in use RequestWindow: Resource in use GetNextTuple: No more items could not allocate nn IO ports for CardBus socket n could not allocate nnK memory for CardBus socket n could not allocate interrupt for CardBus socket n </verb></tscreen> </itemize> <!-- Interrupt starvation often indicates a problem with the interrupt probe (see <ref id="irqscan" name="Interrupt scan failures">). In some cases, the probe will seem to work, but only report one or two available interrupts. Check your system log to see if the scan results look sensible. Disabling the probe and selecting interrupts manually should help. --> 割り込みが不足する場合、割り込み探査に問題があることが多くあります( <ref id="irqscan" name="割り込みのスキャンに失敗します">の項を参照して ください)。場合によっては、探査はうまく行われているように見えるけれど、 利用できる割り込みが 1 つあるいは 2 つしか報告されないこともあります。 システムログを調べて、探査の結果がそれらしいかどうかを見てください。 探査を行わず、割り込みを手動で選んでも問題が解決することがあります。 <!-- If the interrupt probe is not working properly, the socket driver may allocate an interrupt for monitoring card insertions, even when interrupts are too scarce for this to be a good idea. In that case, you can switch the controller to polled mode by setting <tt/PCIC_OPTS/ to ``<tt/poll_interval=100/'. Or, if you have a CardBus controller, try ``<tt/pci_csc=1/'', which selects a PCI interrupt (if available) for card status changes. --> 割り込みの検出がうまく動作していない場合は、割り込みが全く足りなくて カード挿入の監視用に割り込みを割り当てることが好ましくないのに、 ソケットドライバがカード挿入の監視用の割り込みを割り当てているのかもし れません。このような場合には、<tt/PCIC_OPTS/ に ``<tt/poll_interval=100/' を設定してコントローラの設定を呼び出しモード に切り替えるといいでしょう。あるいは、CardBus コントローラの場合には、 ``<tt/pci_csc=1/'' を試してください。これはカードの状態変化の監視に (利用可能ならば) PCI 割り込み を使うための設定です。 <!-- IO port starvation is fairly uncommon, but sometimes happens with cards that require large, contiguous, aligned regions of IO port space, or that only recognize a few specific IO port positions. The default IO port ranges in <tt>/etc/pcmcia/config.opts</tt> are normally sufficient, but may be extended. In rare cases, starvation may indicate that the IO port probe failed (see <ref id="ioscan" name="IO port scan failures">). --> I/O ポートが不足することは普通はありませんが、必要とする I/O ポート空間が巨大かつ連続で、整列されてなければならないカードを使う 場合や、特定小数の位置の I/O ポートしか認識しないカードを使う場合には、 不足することもあります。普通は <tt>/etc/pcmcia/config.opts</tt> に設定 されているデフォルトの I/O ポート範囲で十分ですが、これを広げることも できます。稀にしか起きませんが、I/O ポートの不足が I/O ポートの探査の失敗によって起こることがあります( <ref id="ioscan" name="I/O ポートのスキャンに失敗します">を参照)。 <!-- Memory starvation is also uncommon with the default memory window settings in <tt/config.opts/. CardBus cards may require larger memory regions than typical 16-bit cards. Since CardBus memory windows can be mapped anywhere in the host's PCI address space (rather than just in the 640K-1MB ``hole'' in PC systems), it is helpful to specify large memory windows in high memory, such as 0xa0000000-0xa0ffffff. --> メモリの不足も、<tt/config.opts/ で設定されているデフォルトの メモリウィンドウ設定を使っていれば普通は起こりません。CardBus カードは、 典型的な 16 ビットカードよりも大きなメモリ領域を必要とすることがありま す。CardBus のメモリウィンドウは(PC システムが持つ 640KB-1MB の領域の 単なる「隙間」でなく)ホストの PCI アドレス空間のどこにでもマップするこ とができるので、高位メモリ領域(0xa0000000-0xa0ffffff など)に大きな メモリウィンドウを取ると問題が解決することがあります。 <!-- <sect1>Resource conflict only with two cards inserted <sect1>Resource conflict between two cards --> <sect1>2 枚のカードを挿入した時だけリソースが衝突します <p> <!-- Symptoms: --> 症状: <itemize> <!-- <item>Two cards each work fine when used separately. --> <item>2 枚のカードを別々に使うとうまく動作する。 <!-- <item>When both cards are inserted, only one works. --> <item>両方のカードを同時に挿入すると、片方しか動作しない。 </itemize> <!-- This usually indicates a resource conflict with a system device that Linux does not know about. PCMCIA devices are dynamically configured, so, for example, interrupts are allocated as needed, rather than specifically assigned to particular cards or sockets. Given a list of resources that appear to be available, cards are assigned resources in the order they are configured. In this case, the card configured last is being assigned a resource that in fact is not free. --> これは普通、Linux が認識していないシステムデバイスとリソースが衝突して いる時の症状です。PCMCIA デバイスは動的に設定されるので、例えば、 割り込みは特定のカードやソケットに明確に割り当てられるのではなく、必要 に応じた割り当てが行われます。利用可能と思われるリソースのリストを与え ると、カードには設定された順にリソースが割り当てられます。この場合、最 後に設定されたカードには、実際には空いていないリソースが割り当てられて います。 <!-- Check the system log to see what resources are used by the non-working card. Exclude these in <tt>/etc/pcmcia/config.opts</tt>, and restart the <tt/cardmgr/ daemon to reload the resource database. --> システムログを調べて、動作していないカードが使っているリソースを探しま しょう。<tt>/etc/pcmcia/config.opts</tt> を編集してこのようなリソース を除外する設定にし、<tt/cardmgr/ デーモンを再起動して リソースデータベースを再読み込みさせてください。 <!-- <sect1>Device configuration does not complete --> <sect1>デバイスの設定が終わりません <p> <!-- Symptoms: --> 症状: <itemize> <!-- <item>When a card is inserted, exactly one high beep is heard. --> <item>カードを挿入すると、高いビープ音が 1 回だけ鳴る。 <!-- <item>Subsequent card insertions and removals may be ignored. --> <item>それ以降はカードの抜き挿しを行っても無視される。 </itemize> <!-- This indicates that the card was identified successfully, however, <tt/cardmgr/ has been unable to complete the configuration process for some reason. The most likely reason is that a step in the card setup script has blocked. A good example would be the network script blocking if a network card is inserted with no actual network hookup present. --> この症状が示すのは、カードはうまく認識されているものの、何らかの理由で <tt/cardmgr/ が設定処理を終えられないということです。もっともありがち な原因は、カード設定スクリプトのどこかの処理がブロックされていることで す。わかりやすい例としては、物理的にネットワークに繋がっていないのにネッ トワークカードを挿し込むとネットワーク設定スクリプトがブロックされるこ とが挙げられます。 <!-- To pinpoint the problem, you can manually run a setup script to see where it is blocking. The scripts are in the <tt>/etc/pcmcia</tt> directory. They take two parameters: a device name, and an action. The <tt/cardmgr/ daemon records the configuration commands in the system log. For example, if the system log shows that the command ``./network start eth0'' was the last command executed by <tt/cardmgr/, the following command would trace the script: --> 原因を特定するためには、手動で設定スクリプトを実行し、どこでブロックさ れるかを調べるとよいでしょう。スクリプトは <tt>/etc/pcmcia</tt> ディレ クトリにあります。スクリプトに与える引き数は、デバイス名と動作の 2 つ です。<tt/cardmgr/ デーモンは設定コマンドをシステムログに記録します。 例えば、``./network start eth0'' というコマンドが <tt/cardmgr/ が実行 した最後のプログラムであるという記録がシステムログに残っていれば、以下 のコマンドを実行するとスクリプトの動作をトレースすることができます: <tscreen><verb> sh -x /etc/pcmcia/network start eth0 </verb></tscreen> <!-- <sect>Usage and features --> <sect>使い方と機能 <!-- <sect1>Tools for configuring and monitoring PCMCIA devices --> <sect1>PCMCIA デバイスの設定と監視のためのツール <p> <!-- If the modules are all loaded correctly, the output of the <tt/lsmod/ command should look like the following, when no cards are inserted: --> モジュールが全て正しくロードされれば、カードが全く挿入されていない時の <tt/lsmod/ コマンドの出力は以下のようになります: <tscreen><verb> Module Size Used by ds 5640 2 i82365 15452 2 pcmcia_core 30012 3 [ds i82365] </verb></tscreen> <!-- The system log should also include output from the socket driver describing the host controller(s) found and the number of sockets detected. --> システムログには、ソケットドライバが検出したホストコントローラとソケッ トの数も記録されるはずです。 <!-- <sect2>The cardmgr configuration daemon --> <sect2>設定用デーモン `cardmgr' <p> <!-- The <tt><cdx>cardmgr</cdx></tt> daemon is responsible for monitoring PCMCIA sockets, loading client drivers when needed, and running user-level scripts in response to card insertions and removals. It records its actions in the system log, but also uses beeps to signal card status changes. The tones of the beeps indicate success or failure of particular configuration steps. Two high beeps indicate that a card was identified and configured successfully. A high beep followed by a low beep indicates that a card was identified, but could not be configured for some reason. One low beep indicates that a card could not be identified. --> <tt><cdx>cardmgr</cdx></tt> の仕事は、PCMCIA ソケットの監視を行い、 必要に応じてクライアントドライバをロードし、ユーザレベルで動作する スクリプトをカードの抜き挿しに応じて実行することです。<tt/cardmgr/ は 自分自身の動作をシステムログに記録しますが、ビープ音を使ってもカードの 状態変更を知らせます。ビープ音の音色は、特定の設定段階における成功また は失敗を示します。高いビープ音が二度鳴った時は、カードは正しく認識・設 定されたことが示されています。高いビープ音の後に低いビープ音が鳴った時 は、カードは認識はされたものの何らかの原因により設定できなかったことが 示されています。低いビープ音が一度だけ鳴った時は、カードが認識できなかっ たことが示されています。 <!-- The <tt/cardmgr/ daemon configures cards based on a database of known card types kept in <tt><cdx>/etc/pcmcia/config</cdx></tt>. This file describes the various client drivers, then describes how to identify various cards, and which driver(s) belong with which cards. The format of this file is described in the <tt/pcmcia(5)/ man page. --> <tt/cardmgr/ デーモンは、<tt><cdx>/etc/pcmcia/config</cdx></tt> に置か れている既知のタイプのカードのデータベースに基づいてカードを設定します。 このファイルは各種のクライアントドライバについて書かれています。それか ら、各種カードの識別方法と、どのカードにどのドライバを使うかが書かれて います。このファイルの書式の説明は、オンラインマニュアルの <tt/pcmcia(5)/ にあります。 <!-- <sect2>The socket status file, stab --> <sect2>ソケットの状態ファイルとスタブ <p> <!-- <tt/Cardmgr/ records device information for each socket in <tt><cdx>/var/state/pcmcia/stab</cdx></tt> or <tt><cdx>/var/lib/pcmcia/stab</cdx></tt>, depending on filesystem layout. Here is a sample <tt>stab</tt> listing: --> <tt/cardmgr/ は各ソケットについてのデバイス情報を <tt><cdx>/var/state/pcmcia/stab</cdx></tt> または <tt><cdx>/var/lib/pcmcia/stab</cdx></tt> に記録します(どちらが使われる かはファイルシステムの配置によります)。以下に <tt>stab</tt> の例を示します: <tscreen><verb> Socket 0: Adaptec APA-1460 SlimSCSI 0 scsi aha152x_cs 0 sda 8 0 0 scsi aha152x_cs 1 scd0 11 0 Socket 1: Serial or Modem Card 1 serial serial_cs 0 ttyS1 5 65 </verb></tscreen> <!-- For the lines describing devices, the first field is the socket, the second is the device class, the third is the driver name, the fourth is used to number multiple devices associated with the same driver, the fifth is the device name, and the final two fields are the major and minor device numbers for this device (if applicable). See the <tt/stab/ man page for more info. --> デバイスの状態を示している行の最初の欄がソケット番号、2 つ目が デバイスクラス、3 つ目がドライバ名、4 つ目がそのドライバが関係している デバイスの数、5 つ目はデバイス名、最後の 2 つはそのデバイスの メジャーデバイス番号とマイナーデバイス番号です(使用できる場合)。 詳しい情報については <tt/stab/ のオンラインマニュアルを見てください。 <!-- <sect2>The cardctl and cardinfo utilities --> <sect2>cardctl, cardinfo ユーティリティ <p> <!-- The <tt><cdx>cardctl</cdx></tt> command can be used to check the status of a socket, or to see how it is configured. It can also be used to alter the configuration status of a card. Here is an example of the output of the ``<tt/cardctl config/'' command: --> <tt><cdx>cardctl</cdx></tt> コマンドを使うと、ソケットの状態をチェック することや、ソケットがどのように設定されているかを調べることができます。 このコマンドを使って、カードの設定状態を変更することもできます。 ``<tt/cardctl config/'' コマンドの出力例を以下に示します: <tscreen><verb> Socket 0: not configured Socket 1: Vcc = 5.0, Vpp1 = 0.0, Vpp2 = 0.0 Card type is memory and I/O IRQ 3 is dynamic shared, level mode, enabled Speaker output is enabled Function 0: Config register base = 0x0800 Option = 0x63, status = 0x08 I/O window 1: 0x0280 to 0x02bf, auto sized I/O window 2: 0x02f8 to 0x02ff, 8 bit </verb></tscreen> <!-- Or ``<tt/cardctl ident/'', to get card identification information: --> ``<tt/cardctl ident/''を実行することにより、カードの識別情報を得ること もできます: <tscreen><verb> Socket 0: no product info available Socket 1: product info: "LINKSYS", "PCMLM336", "A", "0040052D6400" manfid: 0x0143, 0xc0ab function: 0 (multifunction) </verb></tscreen> <!-- The ``<tt/cardctl suspend/'' and ``<tt/cardctl resume/'' commands can be used to shut down a card without unloading its associated drivers. The ``<tt/cardctl reset/'' command attempts to reset and reconfigure a card. ``<tt/cardctl insert/'' and ``<tt/cardctl eject/'' mimic the actions performed when a card is physically inserted or ejected, including loading or unloading drivers, and configuring or shutting down devices. --> ``<tt/cardctl suspend/'' コマンドと ``<tt/cardctl resume/'' コマンドを 使うと、対応するドライバを取り外すことなくカードを停止させることができ ます。``<tt/cardctl reset/'' コマンドはカードのリセットと再設定を行お うとします。``<tt/cardctl insert/'' コマンドと ``<tt/cardctl eject/'' コマンドは、カードを物理的に抜き挿しした時に実行する動作を疑似的に行い ます。この動作にはドライバのロードとアンロード、デバイスの設定と停止が 含まれます。 <!-- If you are running X, the <tt><cdx>cardinfo</cdx></tt> utility produces a graphical display showing the current status of all PCMCIA sockets, similar in content to ``<tt/cardctl config/''. It also provides a graphical interface to most other <tt/cardctl/ functions. --> X を実行していれば、<tt><cdx>cardinfo</cdx></tt> を使って全ての PCMCIA ソケットの現在の状態をグラフィカルに表示することができます。この内容は ``<tt/cardctl config/'' に似ています。<tt>cardinfo</tt> を使うと、 <tt/cardctl/ の他の機能のほとんどをグラフィカルに操作することもできま す。 <!-- <sect2>Inserting and ejecting cards --> <sect2>カードの抜き挿し <p> <!-- In theory, you can insert and remove PCMCIA cards at any time. However, it is a good idea not to eject a card that is currently being used by an application program. Kernels older than 1.1.77 would often lock up when serial/modem cards were ejected, but this should be fixed now. --> 理論的には、PCMCIA カードはいつでも抜き挿しすることができます。 しかし、アプリケーションが使っている最中にカードを抜くのはよくありませ ん。1.1.77 より古いバージョンのカーネルは、シリアル/モデムカードを抜く と固まることがありましたが、この問題は既に修正されています。 <!-- Some card types cannot be safely hot ejected. Specifically, ATA/IDE and SCSI interface cards are not hot-swap-safe. This is unlikely to be fixed, because a complete solution would require significant changes to the Linux block device model. Also, it is generally not safe to hot eject CardBus cards of any type. This is likely to improve gradually as hot swap bugs in the CardBus drivers are found and fixed. For these card types (IDE, SCSI, CardBus), it is recommended that you always use ``<tt/cardctl eject/'' before ejecting. --> 一部のカードは安全にイジェクトできません。特に ATA/IDE インタフェースカードと SCSI インタフェースカードは安全にホット スワップできません。この問題を完全に解決するには Linux のブロックデバ イスのモデルの大幅な変更が必要なので、この問題はおそらく修正されないで しょう。また、CardBus カードはどんな種類のものであれ安全にホットイジェクト できません。こちらの次第に改善していくでしょう。CardBus ドライバ中の ホットスワップに関するバグの発見と修正が現在行われつつあるからです。 これらの種類のカードを使う場合は、カードをイジェクトする前に 必ず ``<tt/cardctl eject/'' を実行することをお勧めします。 <!-- <sect2>Card Services and Advanced Power Management --> <sect2>カードサービスと APM(Advanced Power Management) <p> <!-- Card Services can be compiled with support for <idx>APM</idx> (<idx>Advanced Power Management</idx>) if you've configured your kernel with APM support. The APM kernel driver is maintained by Stephen Rothwell (Stephen.Rothwell@canb.auug.org.au). The <tt/apmd/ daemon is maintained by Avery Pennarun (apenwarr@worldvisions.ca), with more information available at <url url="http://www.worldvisions.ca/~apenwarr/apmd/">. The PCMCIA modules will automatically be configured for APM if a compatible version is detected on your system. --> <idx>APM</idx> (<idx>Advanced Power Management</idx>) に対応するように カーネルを設定してあれば、カードサービスに APM 対応を組み込むことがで きます。APM のカーネルドライバを管理しているのは Stephen Rothwell さん (Stephen.Rothwell@canb.auug.org.au) です。 <tt/apmd/ デーモンを管理しているのは Avery Pennarun さん (apenwarr@worldvisions.ca) であり、詳しい情報は <url url="http://www.worldvisions.ca/~apenwarr/apmd/"> で入手できます。 システム上で互換バージョンの APM が検出されれば、PCMCIA モジュールは 自動的に APM 用に設定されます。 <!-- Whether or not APM is configured, you can use ``<tt/cardctl suspend/'' before suspending your laptop, and ``<tt/cardctl resume/'' after resuming, to cleanly shut down and restart your PCMCIA cards. This will not work with a modem that is in use, because the serial driver isn't able to save and restore the modem operating parameters. --> APM が設定されているかどうかに関わらず、ラップトップ機をサスペンドする 前に ``<tt/cardctl suspend/'' を使い、レジュームの後に ``<tt/cardctl resume/'' を使って、PCMCIA カードの停止と再起動を安全に 行うことができます。この操作は使用中のモデムに対しては行えません。なぜ なら、シリアルドライバはモデムの動作パラメータの保存と復元を行うことが できないからです。 <!-- APM seems to be unstable on some systems. If you experience trouble with APM and PCMCIA on your system, try to narrow down the problem to one package or the other before reporting a bug. --> システムによっては APM が不安定なことがあるようです。APM と PCMCIA を 組み合わせると問題が起きる場合には、バグ報告を行う前にどちらのパッケー ジに問題があるかを絞りこんでください。 <!-- Some drivers, notably the PCMCIA SCSI drivers, cannot recover from a suspend/resume cycle. When using a PCMCIA SCSI card, always use ``<tt/cardctl eject/'' prior to suspending the system. --> 一部のドライバ(特に PCMCIA の SCSI ドライバ)は、サスペンドすると レジュームを行うことができません。PCMCIA の SCSI カードを使う場合には、 システムをサスペンドする前には必ず ``<tt/cardctl eject/'' を実行してく ださい。 <!-- <sect2>Shutting down the PCMCIA system --> <sect2>PCMCIA システムの終了 <p> <!-- To unload the entire PCMCIA package, invoke <tt/rc.pcmcia/ with: --> PCMCIA パッケージ全体をアンロードするには、<tt/rc.pcmcia/ スクリプトを 以下のように実行します: <tscreen><verb> /etc/rc.d/rc.pcmcia stop </verb></tscreen> <!-- This script will take several seconds to run, to give all client drivers time to shut down gracefully. If a device is currently in use, the shutdown will be incomplete, and some kernel modules may not be unloaded. To avoid this, use ``<tt/cardctl eject/'' to shut down all sockets before invoking <tt/rc.pcmcia/. The exit status of the <tt/cardctl/ command will indicate if any sockets could not be shut down. --> このスクリプトの実行には数秒かかります。これは、全てのクライアントドラ イバが正常に停止するのを待つためです。あるデバイスが使用中の場合、停止 が完全には行われず、カーネルモジュールがアンロードされないことがありま す。これを避けるには、<tt/rc.pcmcia/ スクリプトを実行する前に ``<tt/cardctl eject/'' を実行して全てのソケットを停止させてください。 <tt/cardctl/ コマンドの終了ステータスは、停止できなかったソケットがあ るかどうかを示します。 <!-- <sect1>Overview of the PCMCIA configuration scripts<label id="config"> --> <sect1>PCMCIA 設定スクリプトの概要<label id="config"> <p> <!-- Each PCMCIA device has an associated ``class'' that describes how it should be configured and managed. Classes are associated with device drivers in <tt>/etc/pcmcia/config</tt>. There are currently five IO device classes (network, SCSI, cdrom, fixed disk, and serial) and two memory device classes (memory and FTL). For each class, there are two scripts in <tt><cdx>/etc/pcmcia</cdx></tt>: a main configuration script (i.e., <tt>/etc/pcmcia/scsi</tt> for SCSI devices), and an options script (i.e., <tt>/etc/pcmcia/scsi.opts</tt>). The main script for a device will be invoked to configure that device when a card is inserted, and to shut down the device when the card is removed. For cards with several associated devices, the script will be invoked for each device. --> PCMCIA デバイスはどのように設定され機能するかについていくつかの 「クラス」に分類できます。クラスは <tt>/etc/pcmcia/config</tt> の デバイスドライバと対応しています。現時点では I/O デバイスに 5 つの クラス(network, SCSI, cdrom, fixed disk, serial)があり、メモリデバイス には 2 つのクラス(memory, FTL)があります。それぞれのクラスごとに 2 つ のスクリプトが <tt>/etc/pcmcia/config</tt> に用意されています: 一つが 設定用のメインスクリプト(例えば SCSI デバイス用なら <tt>/etc/pcmcia/scsi</tt>)で、もう一つは設定オプションを指定する スクリプト(<tt>/etc/pcmcia/scsi.opts</tt>)です。デバイスを設定する メインスクリプトは、カードが挿入された時にデバイスを設定するために起動 され、カードが抜かれた時にはデバイスを停止させるために起動されます。 複数のデバイスに対応しているカードが挿入された場合、このスクリプトは デバイスごとに起動されます。 <!-- The config scripts start by extracting some information about a device from the <tt>stab</tt> file. Each script constructs a ``device address'', that uniquely describes the device it has been asked to configure, in the <tt/ADDRESS/ shell variable. This is passed to the <tt/*.opts/ script, which should return information about how a device at this address should be configured. For some devices, the device address is just the socket number. For others, it includes extra information that may be useful in deciding how to configure the device. For example, network devices pass their hardware ethernet address as part of the device address, so the <tt/network.opts/ script could use this to select from several different configurations. --> 設定用のスクリプトは、デバイスについての情報のいくつかを <tt>stab</tt> ファイルから取り出します。各スクリプトは 「デバイスアドレス」を構築し、これを <tt>ADDRESS</tt> というシェル変数に設定し ます。この「デバイスアドレス」は、呼び出されたスクリプトの設定対象であ るデバイスを一意に記述するものです。この「デバイスアドレス」は <tt>*.opts</tt> スクリプトに渡され、<tt>*.opts</tt>スクリプトは、この アドレスにあるデバイスをどのように設定すべきかの情報を返します。 いくつかのデバイスではデバイスアドレスは単なるソケット番号ですが、その 他のデバイスでは設定の仕方を決めるのに役立つ情報が含まれていることもあ ります。例えば、ネットワーク用のデバイスはハードウェアイーサネット アドレスをデバイスアドレスの一部として <tt>network.opts</tt> スクリプトに 渡すので、ハードウェアアドレスによって異なる設定を行うことも可能です。 <!-- The first part of all device addresses is the current PCMCIA ``scheme''. This parameter is used to support multiple sets of device configurations based on a single external user-specified variable. One use of schemes would be to have a ``home'' scheme, and a ``work'' scheme, which would include different sets of network configuration parameters. The current scheme is selected using the ``<tt/cardctl scheme/'' command. The default if no scheme is set is ``default''. --> デバイスアドレスの最初の部分は、PCMCIA の現在の「スキーム(scheme)」を 示します。このパラメータを使って、一つの外部ユーザー変数によって複数 のデバイス設定を切り替えることが可能です。スキームの使い方の一つは、 ``home'' スキームと ``work'' スキームの 2 種を用意して、それぞれに異な るネットワークパラメータを設定することです。現在使っているスキームは ``<tt/cardctl/ スキーム'' コマンドで変更できます。特にスキームを設定し ない場合は、``default'' スキームが使われます。 <!-- As a general rule, when configuring Linux for a laptop, PCMCIA devices should only be configured from the PCMCIA device scripts. Do not try to configure a PCMCIA device the same way you would configure a permanently attached device. However, some Linux distributions provide PCMCIA packages that are hooked into those distributions' own device configuration tools. In that case, some of the following sections may not apply; ideally, this will be documented by the distribution maintainers. --> 一般論として、ラップトップ機の Linux の場合、PCMCIA デバイスは PCMCIA デバイス用のスクリプトでのみ設定すべきで、常設のデバイスと同じように [訳注: /etc/rc.d/rc.inet* などで] 設定してはいけません。しかし Linux ディストリビューションによっては、 ディストリビューション独自のデバイス設定ツールで PCMCIA パッケージの 設定を行うようになっています。このような場合には、これ以降の章の内容が 当てはまらないことがあります。理想を言えば、そういった部分の解説文書は ディストリビューションの管理者が用意すべきでしょう。 <!-- <sect1>PCMCIA network adapters --> <sect1>PCMCIA ネットワークアダプタ <p> <!-- Linux ethernet-type network interfaces normally have names like <tt/eth0/, <tt/eth1/, and so on. Token-ring adapters are handled similarly, however they are named <tt/tr0/, <tt/tr1/, and so on. The <tt/ifconfig/ command is used to view or modify the state of a network interface. A peculiarity of Linux is that network interfaces do not have corresponding device files under <tt>/dev</tt>, so do not be surprised when you do not find them. --> Linux ではイーサネットタイプのネットワークインタフェースは <tt/eth0/, <tt/eth1/ といった名前になっています。トークンリングのアダプタも同様で すが、インターフェイス名は <tt>tr0</tt>, <tt>tr1</tt> となります。 ネットワークインタフェースの状態のチェックや変更を行うには <tt/ifconfig/ コマンドを使います。Linux の特徴として、ネットワーク インタフェースが対応するデバイスは <tt>/dev</tt> の下には無いので、 デバイスファイルが無くても驚かないでください。 <!-- When an ethernet card is detected, it will be assigned the first free interface name, which will normally be <tt/eth0/. <tt/Cardmgr/ will run the <tt>/etc/pcmcia/network</tt> script to configure the interface, which normally reads network settings from <tt>/etc/pcmcia/network.opts</tt>. The <tt/network/ and <tt/network.opts/ scripts will be executed only when your ethernet card is actually present. If your system has an automatic network configuration facility, it may or may not be PCMCIA-aware. Consult the documentation of your Linux distribution and the <ref id="distributions" name="Notes about specific Linux distributions"> to determine if PCMCIA network devices should be configured with the automatic tools, or by editing <tt/network.opts/. --> PCMCIA イーサネットカードが検出されると、空いている最初のインターフェー ス名が割り当てられます。これは多分 <tt/eth0/ でしょう。 <tt/cardmgr/ が自動的に <tt>/etc/pcmcia/network</tt> スクリプトを実行 してインターフェースに関する設定を行いますが、ネットワークに関する設定は <tt>/etc/pcmcia/network</tt> から読み込まれます。<tt/network/ スクリプト と <tt/network.opts/ スクリプトが実行されるのは、イーサネットカードが 実際に存在する時だけです。ネットワークの自動設定機能をシステムが備えて いる場合、これが PCMCIA 対応であることもそうでないこともあります。 お使いの Linux ディストリビューションの文書や <ref id="distributions" name="個別ディストリビューションに関する注意"> の節を見て、PCMCIA のネットワークデバイスの設定は自動化されたツールが 行うのか、それとも <tt/network.opts/ を手で編集して行うのかを調べてく ださい。 <!-- The device address passed to <tt/network.opts/ consists of four comma-separated fields: the scheme, the socket number, the device instance, and the card's hardware ethernet address. The device instance is used to number devices for cards that have several network interfaces, so it will usually be 0. If you have several network cards used for different purposes, one option would be to configure the cards based on socket position, as in: --> <tt>network.opts</tt> に渡されるデバイスアドレスは、コンマで区切られた 4 つのフィールドから成っています。4 つのフィールドは、スキーム、 ソケット番号、デバイスインスタンス、カードのハードウェアアドレスです。 デバイスインスタンスは複数のネットワークインタフェースを持つような カードの(付加的な)デバイス番号なので、通常は 0 になります。もし異なる 目的に使う複数のネットワークカードを持っているなら、ソケット番号によっ て設定オプションを変えることが可能で、その場合の <tt>network.opts</tt> は以下のようになります: <tscreen><verb> case "$ADDRESS" in *,0,*,*) # definitions for network card in socket 0 ;; *,1,*,*) # definitions for network card in socket 1 ;; esac </verb></tscreen> <!-- Alternatively, they could be configured using their hardware addresses, as in: --> あるいは、それぞれのカードのハードウェアアドレスを使って以下のように 設定することもできます: <tscreen><verb> case "$ADDRESS" in *,*,*,00:80:C8:76:00:B1) # definitions for a D-Link card ;; *,*,*,08:00:5A:44:80:01) # definitions for an IBM card esac </verb></tscreen> <!-- <sect2>Network device parameters --> <sect2>ネットワークデバイスのパラメータ <p> <!-- The following parameters can be defined in <tt/network.opts/: --> <tt/network.opts/ では以下のパラメータを定義することができます: <descrip> <tag><tt/IF_PORT/</tag> <!-- Specifies the ethernet transceiver type, for certain 16-bit cards that do not autodetect. See ``<tt/man ifport/'' for more information. --> イーサネットのトランシーバの種類を自動検出できない特定の 16 ビット カードに対して、これを指定します。詳しくは ``<tt/man ifport/'' を見て <tag><tt/PUMP/</tag> <!-- A boolean (y/n) value: indicates if the host's IP address and routing information should be obtained using either BOOTP or DHCP, using Red Hat's <tt/pump/ daemon. --> 値には y か n を指定します。このパラメータは、RedHat の <tt/pump/ デーモンを用いて、ホストの IP アドレスと経路情報を BOOTP か DHCP を 使って取得するかどうかを指定します。 <tag><tt/BOOTP/</tag> <!-- A boolean (y/n) value: indicates if the host's IP address and routing information should be obtained using the BOOTP protocol, with <tt/bootpc/. --> 値には y か n を指定します。このパラメータは、<tt/bootpc/ を使って、 ホストの IP アドレスと経路情報を BOOTP プロトコルを使って取得するかど うかを示します。 <tag><tt/DHCP/</tag> <!-- A boolean (y/n) value: indicates if the host's IP address and routing information should be obtained from a DHCP server. The network script first looks for <tt/dhcpcd/, then <tt/dhclient/. --> 値には y か n を指定します。このパラメータは、ホストの IP アドレスと 経路情報を DHCP サーバから取得するかどうかを示します。ネットワーク スクリプトは最初に <tt/dhcpcd/ を探し、その次に <tt/dhclient/ を探しま す。 <tag><tt/IPADDR/</tag> <!-- The IP address for this interface. --> このインタフェースに対する IP アドレス。 <tag><tt/NETMASK/, <tt/BROADCAST/, <tt/NETWORK/</tag> <!-- Basic network parameters: see the networking HOWTO for more information. --> ネットワークの基本的なパラメータです。詳しくはネットワーク関連の HOWTO 文書をご覧ください。 <tag><tt/GATEWAY/</tag> <!-- The IP address of a gateway for this host's subnet. Packets with destinations outside this subnet will be routed to this gateway. --> このホストが所属するサブネットのゲートウェイの IP アドレスです。 終点アドレスがこのサブネットの外部になっているパケットは、この ゲートウェイに送られます。 <tag><tt/DOMAIN/</tag> <!-- The local network domain name for this host, to be used in creating <tt>/etc/resolv.conf</tt>. --> このホストのローカルのネットワークドメイン名です。これは <tt>/etc/resolv.conf</tt> を生成する際に使います。 <tag><tt/SEARCH/</tag> <!-- A search list for host name lookup, to be added to <tt>/etc/resolv.conf</tt>. <tt/DOMAIN/ and <tt/SEARCH/ are mutually exclusive: see ``<tt/man resolver/'' for more information. --> ホスト名参照の検索リストであり、<tt>/etc/resolv.conf</tt> に追加されま す。<tt/DOMAIN/ と <tt/SEARCH/ は互いに排他的です。詳しくは ``<tt/man resolver/'' をご覧ください。 <tag><tt/DNS_1/, <tt/DNS_2/, <tt/DNS_3/</tag> <!-- Host names or IP addresses for nameservers for this interface, to be added to <tt>/etc/resolv.conf</tt> --> このインタフェースが使うネームサーバのホスト名または IP アドレス。これ は <tt>/etc/resolv.conf</tt> に追加されます。 <tag><tt/MOUNTS/</tag> <!-- A space-separated list of NFS mount points to be mounted for this interface. --> このインタフェースがマウントに使う NFS マウントポイントを空白で 区切って並べたリストです。 <tag><tt/IPX_FRAME/, <tt/IPX_NETNUM/</tag> <!-- For IPX networks: the frame type and network number, passed to the <tt/ipx_interface/ command. --> IPX ネットワーク用のパラメータです。フレームタイプとネットワーク番号を 表し、<tt/ipx_interface/ コマンドに渡されます。 </descrip> <!-- For example: --> 指定例を以下に示します: <tscreen><verb> case "$ADDRESS" in *,*,*,*) IF_PORT="10base2" BOOTP="n" IPADDR="10.0.0.1" NETMASK="255.255.255.0" NETWORK="10.0.0.0" BROADCAST="10.0.0.255" GATEWAY="10.0.0.1" DOMAIN="domain.org" DNS_1="dns1.domain.org" ;; esac </verb></tscreen> <!-- To automatically mount and unmount NFS filesystems, first add all these filesystems to <tt>/etc/fstab</tt>, but include <tt>noauto</tt> in the mount options. In <tt>network.opts</tt>, list the filesystem mount points in the <tt>MOUNTS</tt> variable. It is especially important to use either <tt/cardctl/ or <tt/cardinfo/ to shut down a network card when NFS mounts are active. It is not possible to cleanly unmount NFS filesystems if a network card is simply ejected without warning. --> NFS ファイルシステムのマウントやアンマウントを自動的に行うには、まず マウントするファイルシステムを全て <tt>/etc/fstab</tt> に記述します。 ただし、マウント用オプションとして <tt>noauto</tt> を指定してください。 <tt>network.opts</tt> では、ファイルシステムのマウントポイントを <tt>MOUNTS</tt> 変数に列挙します。NFS マウントを行っている最中は、 ネットワークを停止させるのに <tt/cardctl/ コマンドや <tt/cardinfo/ コマンドを使うことが特に重要です。ネットワークカードが予告無しに抜かれ ると、NFS ファイルシステムが正常にアンマウントできないからです。 <!-- In addition to the usual network configuration parameters, the <tt/network.opts/ script can specify extra actions to be taken after an interface is configured, or before an interface is shut down. If <tt/network.opts/ defines a shell function called <tt/start_fn/, it will be invoked by the network script after the interface is configured, and the interface name will be passed to the function as its first (and only) argument. Similarly, if it is defined, <tt/stop_fn/ will be invoked before shutting down an interface. --> 通常のネットワーク設定オプションに加えて、<tt/network.opts/ では インタフェースの設定が終わった直後やインタフェースを停止する直前に行う 追加の動作を指定することができます。<tt/network.opts/ で <tt/start_fn/ というシェル関数が定義されていれば、ネットワークスクリプトはインタフェース を設定した直後にこの関数を呼び出します。この際には、インタフェース名が 最初の(そして唯一の)引き数として関数に渡されます。同様に、<tt/stop_fn/ というシェル関数が定義されていれば、このシェル関数はインタフェースが停 止する直前に呼び出されます。 <!-- The transceiver type for some cards can be selected using the <tt/IF_PORT/ setting. This can either be a numeric value, or a keyword identifying the transceiver type. All the network drivers default to either autodetect the interface if possible, or 10baseT otherwise. The <tt/ifport/ command can be used to check or set the current transceiver type. For example: --> 一部のカードでは、トランシーバの種類を <tt/IF_PORT/ の設定で選べます。 これは数値で選ぶか、トランシーバの種類を表す キーワードで選びます。全てのネットワークドライバのデフォルト動作は、 可能ならばインタフェースは自動検出し、検出ができなければ 10BaseT を 使うというものです。<tt/ifport/ コマンドを使うと、トランシーバの種類 の現在値の確認や設定ができます。実行例を以下に示します: <tscreen><verb> # ifport eth0 10base2 # # ifport eth0 eth0 2 (10base2) </verb></tscreen> <!-- The current (3.0.10 or later) 3c589 driver should quickly autodetect transceiver changes at any time. Earlier releases of the 3c589 driver had a somewhat slow and flaky transceiver autodetection algorithm. For these releases, the appropriate network cable should be connected to the card when the card is configured, or you can force autodetection with: --> 現在(3.0.10 以降)の 3c589 用ドライバは、トランシーバの変化をいつでも即 座に自動検出するはずです。以前のバージョンの 3c589 用のドライバは、 トランシーバの自動検出アルゴリズムがいくぶん遅く、問題点もありました。 このようなバージョンでは、カードが設定されてから適切なネットワークケー ブルをカードに繋ぐか、以下のようなコマンドを実行して強制的に自動検出を 実行させなければなりません: <tscreen><verb> ifconfig eth0 down up </verb></tscreen> <!-- <sect2>Comments about specific cards --> <sect2>個別のカードに関するコメント <p> <itemize> <item> <!-- With IBM CCAE and Socket EA cards, the transceiver type (10base2, 10baseT, AUI) needs to be set when the network device is configured. Make sure that the transceiver type reported in the system log matches your connection. --> IBM CCAE と Socket EA カードではネットワークデバイスの設定の際に トランシーバの種類(10base2, 10baseT, AUI)を指定する必要があります。 システムのログファイルを調べて、設定されているトランシーバの種類が、 物理的に接続しているものと一致していることを確認してください。 <item> <!-- The Farallon EtherWave is actually based on the 3Com 3c589, with a special transceiver. Though the EtherWave uses 10baseT-style connections, its transceiver requires that the 3c589 be configured in 10base2 mode. --> Farallon EtherWave は実は 3Com 3c589 を基にしていますが、独自の トランシーバを使っています。EtherWave は 10baseT タイプのコネクタを使っ ていますが、トランシーバは 3c589 が 10base2 モードに設定されていないと 正しく動作しません。 <item> <!-- If you have trouble with an IBM CCAE, NE4100, Thomas Conrad, or Kingston adapter, try increasing the memory access time with the <tt/mem_speed=#/ option to the <tt/pcnet_cs/ module. An example of how to do this is given in the standard <tt/config.opts/ file. Try speeds of up to 1000 (in nanoseconds). --> IBM CCAE, NE4100, Thomas Conrad, Kingston といったカードでトラブルが生 じる場合は、<tt>pcnet_cs</tt> モジュールの <tt>mem_speed=#</tt> オプションを使ってメモリへアクセスする時間を増やしてみてください。 指定例は標準の <tt>config.opts</tt> ファイルにあります。 <tt>mem_speed=1000</tt>(ナノセコンド単位)まで上げてみてください。 <item> <!-- For the New Media Ethernet adapter, on some systems, it may be necessary to increase the IO port access time with the <tt/io_speed=#/ option when the <tt/pcmcia_core/ module is loaded. Edit <tt/CORE_OPTS/ in the startup script to set this option. --> New Media Ethernet アダプタなどの場合、I/O ポートにアクセスする時間 を <tt>io_speed=#</tt> オプションで指定する必要があるかもしれませ ん。このオプションは <tt>pcmcia_core</tt> モジュールをロードする際に指 定します。起動スクリプト中の <tt>CORE_OPTS</tt> を編集して、この オプションを指定してください。 <item> <!-- The multicast support in the New Media Ethernet driver is incomplete. The latest driver will function with multicast kernels, but will ignore multicast packets. Promiscuous mode should work properly. --> New Media Ethernet ドライバのマルチキャスト対応は不完全です。 最新のドライバはマルチキャスト対応のカーネルで動作しますが、 マルチキャストのパケットは無視します。無差別モードは正しく動作するはず です。 <item> <!-- The driver used by the IBM and 3Com token ring adapters seems to behave very badly if the cards are not connected to a ring when they get initialized. Always connect these cards to the net before they are powered up. If <tt/ifconfig/ reports the hardware address as all 0's, this is likely to be due to a memory window configuration problem. --> IBM と 3Com のトークンリングアダプタが使うドライバは、初期化の際に カードがリングに接続されていなければ、非常におかしな動作をします。これ らのカードは、必ず電源を入れる前にネットワークに接続しましょう。 <tt/ifconfig/ が報告するハードウェアアドレスが全て 0 ならば、たぶん メモリウィンドウの設定に問題があります。 <item> <!-- Some Linksys, D-Link, and IC-Card 10baseT/10base2 cards have a unique way of selecting the transceiver type that isn't handled by the Linux drivers. One workaround is to boot DOS and use the vendor-supplied utility to select the transceiver, then warm boot Linux. Alternatively, a Linux utility to perform this function is available at <url url="ftp://sourceforge.org/pcmcia/extras/dlport.c">. --> Linksys, D-Link, IC-Card 製の 10baseT/10base2 カードは、Linux 用ドライバ では扱えない独特の方法でトランシーバの種類を検出します。回避方法の 1 つは、DOS を起動して、ベンダーが提供しているユーティリティを使って トランシーバの種類を選択し、その後で Linux をウォームブートすることで す。別の方法として、この機能を実行する Linux 用のユーティリティを <url url="ftp://sourceforge.org/pcmcia/extras/dlport.c"> で入手 できます。 <item> <!-- For WaveLAN wireless network adapters, Jean Tourrilhes (<tt/jt@hpl.hp.com/) has put together a wireless HOWTO at <url url="http://www.hpl.hp.com/personal/Jean_Tourrilhes/Linux/">. --> WaveLAN 無線ネットワークアダプタ向けに、Jean Tourrilhes さん (<tt/jt@hpl.hp.com/)が wireless HOWTO を書いています。これは <url url="http://www.hpl.hp.com/personal/Jean_Tourrilhes/Linux/"> にあ ります。 </itemize> <!-- <sect2>Diagnosing problems with network adapters --> <sect2>ネットワークアダプタにまつわる問題の診断 <p> <itemize> <item> <!-- Is your card recognized as an ethernet card? Check the system log and make sure that <tt/cardmgr/ identifies the card correctly and starts up one of the network drivers. If it doesn't, your card might still be usable if it is compatible with a supported card. This will be most easily done if the card claims to be ``NE2000 compatible''. --> あなたのカードはイーサネットカードとして認識されていますか? ログファイル をチェックして、<tt>cardmgr</tt> がカードを正しく認識し、ネットワーク ドライバを起動しているか確認してください。もしだめならば、サポートされ ているカードと「互換」と称していてもあなたのカードはまだ使えないのでしょ う。これは、カードが「NE2000 互換」と称している時によく起きるようです。 <item> <!-- Is the card configured properly? If you are using a supported card, and it was recognized by <tt/cardmgr/, but still doesn't work, there might be an interrupt or port conflict with another device. Find out what resources the card is using (from the system log), and try excluding these in <tt>/etc/pcmcia/config.opts</tt> to force the card to use something different. --> カードは正しく設定されていますか? もしサポートされているカードを使い、 <tt/cardmgr/ に正しく認識されてるのにうまく動かないという場合は、他の デバイスと IRQ やポートが衝突しているのかもしれません。カードが使って いるリソースをチェックして(ログファイルを調べて)、カードが別の IRQ や ポートを使うように <tt>/etc/pcmcia/config.opts </tt> を設定し、問題と なる IRQ やポートを使わないようにします。 <item> <!-- If your card seems to be configured properly, but sometimes locks up, particularly under high load, you may need to try changing your socket driver timing parameters. See the <ref id="startup" name="Startup options"> section for more information. --> カードは正しく設定されているが(特に負荷が高い時に)固まってしまうことが 時々起こる場合、ソケットドライバのタイミングを制御するパラメータを変え る必要があるかもしれません。詳細については <ref id="startup" name="起動オプション">の節を見てください。 <item> <!-- If you get ``network unreachable'' messages when you try to access the network, then the routing information specified in <tt>/etc/pcmcia/network.opts</tt> is incorrect. This message is an absolutely foolproof indication of a routing error. On the other hand, mis-configured cards will usually fail silently. --> ネットワークにアクセスしようとすると ``network unreachable'' という メッセージが表示される場合は、<tt>/etc/pcmcia/network.opts</tt> で指定 している経路情報に間違いがあります。このメッセージはどう考えても 経路情報エラーを示しているとしか考えられません。これに対して、カードの 設定ミスの場合は普通、うまく動作できなくてもエラーを表示しません。 <item> <!-- If you are trying to use DHCP to configure your network interface, try testing things with a static IP address instead, to rule out a DHCP configuration problem. --> DHCP を使ってネットワークインタフェースを設定しようとしている場合は、 DHCP ではなく固定の IP アドレスを使ったテストを行い、DHCP の設定による 問題を除外します。 <item> <!-- To diagnose problems in <tt>/etc/pcmcia/network.opts</tt>, start by trying to ping other systems on the same subnet using their IP addresses. Then try to ping your gateway, and then machines on other subnets. Ping machines by name only after trying these simpler tests. --> <tt>/etc/pcmcia/network.opts</tt> の問題を見つけるためには、まず 同じサブネット上にある他のマシンに ping を打ってみましょう。マシンの指 定には IP アドレスを使います。次にゲートウェイに ping を打ち、それから 他のサブネット上にあるマシンに ping を打ちます。ホスト名を使って ping を打つのは、以上の簡単なテストが終わってからです。 <item> <!-- Make sure your problem is really a PCMCIA one. It may help to see see if the card works under DOS with the vendor's drivers. Double check your modifications to the <tt>/etc/pcmcia/network.opts</tt> script. Make sure your drop cable, ``T'' jack, terminator, etc are working. --> 問題が本当に PCMCIA に起因することを確認してください。DOS 上で、ベンダー 製のドライバなら動くかどうかを確認するのもいいでしょう。 <tt>/etc/pcmcia/network.opts</tt> スクリプトを変更した部分があれば、そ こを繰り返しチェックしてください。ケーブルや ``T'' 型ジャック、 ターミネータ等が正しく動作しているか確認してください。 </itemize> <!-- <sect1>PCMCIA serial and modem devices --> <sect1>PCMCIA のシリアルデバイスとモデムデバイス <p> <!-- Linux serial devices are accessed via the <tt>/dev/ttyS*</tt> and <tt>/dev/cua*</tt> special device files. In pre-2.2 kernels, the <tt/ttyS*/ devices were for incoming connections, such as directly connected terminals, and the <tt/cua*/ devices were for outgoing connections, such as modems. Use of <tt/cua*/ devices is deprecated in current kernels, and <tt/ttyS*/ can be used for all applications. The configuration of a serial device can be examined and modified with the <tt/setserial/ command. --> Linux のシリアルデバイスは、<tt>/dev/ttyS*</tt> と <tt>/dev/cua*</tt> という特殊なデバイスファイルを経由してアクセスします。バージョン 2.2 より前のカーネルでは、<tt>ttyS*</tt> デバイスは端末などを直接接続する ための入力用デバイスであり、<tt>cua*</tt> デバイスはモデム等で利用する ための出力用デバイスでした。現在のカーネルでは <tt/cua*/ デバイスを使 わないことが推奨されており、全てのアプリケーションで <tt/ttyS*/ を使い ます。シリアルデバイスの設定は、<tt>setserial</tt>コマンドを使って確認、 変更できます。 <!-- When a serial or modem card is detected, it will be assigned to the first available serial device slot. This will usually be <tt>/dev/ttyS1</tt> (<tt/cua1/) or <tt>/dev/ttyS2</tt> (<tt/cua2/), depending on the number of built-in serial ports. The <tt/ttyS*/ device is the one reported in <tt>stab</tt>. The default serial device option script, <tt>/etc/pcmcia/serial.opts</tt>, will link the device file to <tt>/dev/modem</tt> as a convenience. For pre-2.2 kernels, the link is made to the <tt/cua*/ device. --> シリアルカードあるいはモデムカードの挿入が検出されると、最初の空いてい るシリアルデバイスに自動的に割り当てられます。通常、これはシステムに最 初から付いているシリアルポートの数によって <tt>/dev/cua1</tt> (<tt>/dev/ttyS1</tt>)か <tt>/dev/cua2</tt>(<tt>/dev/ttyS2</tt>)のどち らかになります。<tt>/dev/ttyS*</tt> デバイスは <tt>stab</tt> に記録されます。デバイスを使いやすくするために、シリアルデバイス設定用 のデフォルトのスクリプト(<tt>/etc/pcmcia/serial.opts</tt>)は、 <tt>/dev/modem</tt> から適切なデバイスファイルにシンボリックリンクを張 ります。バージョン 2.2 より前のカーネルでは、このリンクは <tt/cua*/ デバイスに張られます。 <!-- Do not try to use <tt>/etc/rc.d/rc.serial</tt> to configure a PCMCIA modem. This script should only be used to configure non-removable devices. Modify <tt>/etc/pcmcia/serial.opts</tt> if you want to do anything special to set up your modem. Also, do not try to change the IO port and interrupt settings of a serial device using <tt/setserial/. This would tell the serial driver to look for the device in a different place, but would not change how the card's hardware is actually configured. The serial configuration script allows you to specify other <tt/setserial/ options, as well as whether a line should be added to <tt>/etc/inittab</tt> for this port. --> PCMCIA モデムカードを設定するのに <tt>/etc/rc.d/rc.serial</tt> を使っ てはいけません。このスクリプトは抜き挿しをしないシリアルデバイスを設定 するためのものです。モデムにの設定を行う場合には、 <tt>/etc/rc.d/rc.serial</tt> ではなく <tt>/etc/pcmcia/serial.opt</tt> で設定してください。また、シリアルデバイスの I/O ポートと割り込みの変 更を行うのに <tt/setserial/ を使ってはいけません。このコマンドは別の アドレスにあるデバイスをシリアルドライバに探させるもので、カードの ハードウェアに実際に設定されている情報を変えることはできないからです。 シリアル設定用のスクリプトを使うと、<tt/setserial/ の別のオプションを 指定することができますし、このポート用に <tt>/etc/inittab</tt> に行を 追加するかどうかを指定することもできます。 <!-- The device address passed to <tt/serial.opts/ has three comma-separated fields: the first is the scheme, the second is the socket number, and the third is the device instance. The device instance may take several values for cards that support multiple serial ports, but for single-port cards, it will always be 0. If you commonly use more than one modem, you may want to specify different settings based on socket position, as in: --> <tt>serial.opts</tt> に渡されるデバイスアドレスは、コンマで区切られた 3 つのフィールドから構成されています。一つ目のフィールドはスキーム、二 つ目がソケット番号、三つ目がデバイスインスタンスです。複数のシリアルポート をサポートしているカードではデバイスインスタンスが複数の値を持つ ことがありますが、ポートが一つしかないカードの場合には、 デバイスインスタンスの値は必ず 0 です。普段から複数の PCMCIA モデムカード を使っているなら、挿入するソケットによって設定を変えることが可能です。 その場合の設定は以下のようにします: <tscreen><verb> case "$ADDRESS" in *,0,*) # Options for modem in socket 0 LINK=/dev/modem0 ;; *,1,*) # Options for modem in socket 1 LINK=/dev/modem1 ;; esac </verb></tscreen> <!-- If a PCMCIA modem is already configured when Linux boots, it may be incorrectly identified as an ordinary built-in serial port. This is harmless, however, when the PCMCIA drivers take control of the modem, it will be assigned a different device slot. It is best to either parse <tt>stab</tt> or use <tt>/dev/modem</tt>, rather than expecting a PCMCIA modem to always have the same device assignment. --> 起動時に既に PCMCIA モデムカードが設定されていると、ハードウェアに最初 から付いているシリアルポートと誤認される可能性があります。実害はありま せんが、PCMCIA ドライバがモデムを制御する場合、デバイスが異なるスロット に割り当てられる可能性があります。よって、アプリケーション側では PCMCIA モデムが常に同じデバイス(<tt>/dev/cua*</tt>)に割り当てられると 仮定せず、<tt>stab</tt> を解析するかシンボリックリンク <tt>/dev/modem</tt> を使うのがいいでしょう。 <!-- If you configure your kernel to load the basic Linux serial port driver as a module, you must edit <tt>/etc/pcmcia/config</tt> to indicate that this module must be loaded. Edit the serial device entry to read: --> 基本のシリアルポートドライバをモジュールとしてロードするようにカーネル の設定を行っている場合、<tt>/etc/pcmcia/config</tt> を修正してシリアル ポートドライバを予めロードするようにします。 <tt>/etc/pcmcia/config</tt>のシリアルデバイスの項目を以下のように修正 してください: <tscreen><verb> device "serial_cs" class "serial" module "misc/serial", "serial_cs" </verb></tscreen> <!-- <sect2>Serial device parameters --> <sect2>シリアルデバイスのパラメータ <p> <!-- The following parameters can be defined in <tt/serial.opts/: --> 以下のパラメータを <tt/serial.opts/ で定義することができます: <descrip> <tag><tt/LINK/</tag> <!-- Specifies a path for a symbolic link to be created to the ``dialout'' or <tt>/dev/cua*</tt> device. Specifies a path for a symbolic link to be created to the ``callout'' device (e.g., <tt>/dev/cua*</tt> for pre-2.2, or <tt>/dev/ttyS*</tt> for 2.2 kernels). --> 「コールアウト用」デバイスに対して張られるシンボリックリンクのパスを指 定します(例: 2.2 より前のカーネルでは <tt>/dev/cua*</tt>, 2.2 では <tt>/dev/ttyS*</tt> です)。 <tag><tt/SERIAL_OPTS/</tag> <!-- Specifies options to be passed to the <tt/setserial/ command. --> <tt/setserial/ コマンドに渡すオプションを指定します。 <tag><tt/INITTAB/</tag> <!-- If specified, this will be used to construct an <tt/inittab/ entry for the device. --> このパラメータを指定すると、その値を使って、対象となるデバイスの <tt/inittab/ 用のエントリが作られます。 </descrip> <!-- For example: --> 指定例を以下に示します: <tscreen><verb> case "$ADDRESS" in *,*,*,*) LINK="/dev/modem" SERIAL_OPTS="" INITTAB="/sbin/getty" </verb></tscreen> <!-- <sect2>Comments about specific cards --> <sect2>特定のカードについてのコメント <p> <itemize> <!-- <item>The Uniden Data 2000 Wireless CDPD card has some special dialing strings for initiating SLIP and PPP mode. For SLIP, use ``ATDT2''; for PPP, "ATDT0". --> <item>Uniden Data 2000 Wireless CDPD カードには、SLIP モードや PPP モー ドで通信を始めるための特殊なダイアル文字列があります。SLIP の場合には ``ATDT2'' を、PPP の場合には ``ATDT0'' を使います。 </itemize> <!-- <sect2>Diagnosing problems with serial devices --> <sect2>シリアルデバイスにまつわる問題の診断 <p> <itemize> <item> <!-- Is your card recognized as a modem? Check the system log and make sure that <tt/cardmgr/ identifies the card correctly and starts up the <tt/serial_cs/ driver. If it doesn't, you may need to add a new entry to your <tt>/etc/pcmcia/config</tt> file so that it will be identified properly. See the <ref id="new-card" name="Configuring unrecognized cards"> section for details. --> あなたのカードはモデムとして認識されていますか? <tt>/usr/adm/messages</tt> をチェックして <tt>cardmgr</tt> がカードを 正しく識別し、<tt>serial_cs</tt> ドライバを起動していることを確認して ください。もし正しく識別されていない場合、<tt>/etc/pcmcia/config</tt> ファイルに新しいエントリを加えて、正しく識別できるようにする必要がある かもしれません。詳しくは <ref id="new-card" name="識別されないカードの設定">の節を見てください。 <item> <!-- Is the modem configured successfully by serial_cs? Again, check the system log and look for messages from the serial_cs driver. If you see ``register_serial() failed'', you may have an I/O port conflict with another device. Another tip-off of a conflict is if the device is reported to be an 8250; most modern modems should be identified as 16550A UART's. If you think you're seeing a port conflict, edit <tt>/etc/pcmcia/config.opts</tt> and exclude the port range that was allocated for the modem. --> serial_cs ドライバがモデムを正しく設定していますか? もう一度 <tt>/usr/adm/messages</tt> をチェックして、serial_cs ドライバの出力を 調べてください。もし ``register_serial() failed'' というメッセージが 出力されていれば、他のデバイスと I/O ポートが衝突している可能性があり ます。デバイスが 8250 であると識別されることも I/O ポートが衝突してい る徴候の一つです。というのも、最近の PCMCIA モデムは 16550A UART と識 別されるはずだからです。I/O ポートが他のデバイスと衝突している場合は、 <tt>/etc/pcmcia/config.opts</tt>を修正して、モデム用に割り当てられてい るポートを使わないようにしてみてください。 <item> <!-- Is there an interrupt conflict? If the system log looks good, but the modem just doesn't seem to work, try using <tt/setserial/ to change the irq to 0, and see if the modem works. This causes the serial driver to use a slower polled mode instead of using interrupts. If this seems to fix the problem, it is likely that some other device in your system is using the interrupt selected by serial_cs. You should add a line to <tt>/etc/pcmcia/config.opts</tt> to exclude this interrupt. --> IRQ は衝突していませんか? もしログファイルは正しいようだがモデムはうま く動かないという場合、<tt>setserial</tt> コマンドを使って irq を 0 に して動くかどうか確認してみてください。irq を 0 に設定すれば、シリアル ドライバは割り込みのかわりに、より遅い「呼び出しモード(polled mode)」 を使うようになります。もしこれでうまく行くようなら、serial_cs の選んだ IRQ を何か別のデバイスが使っている可能性があります。この割り込みを使 わないように <tt>/etc/pcmcia/config.opts</tt> を設定してください。 <item> <!-- If the modem seems to work only very, very slowly, this is an almost certain indicator of an interrupt conflict. --> モデムからの反応が異様に遅いというのも IRQ が衝突している徴候のひとつ です。 <item> <!-- Make sure your problem is really a PCMCIA one. It may help to see if the card works under DOS with the vendor's drivers. Also, don't test the card with something complex like SLIP or PPP until you are sure you can make simple connections. If simple things work but SLIP does not, your problem is most likely with SLIP, not with PCMCIA. --> <item> 問題が本当に PCMCIA に由来するものか確認してください。ベンダー製の ドライバを使って DOS で動くか調べるのもいいでしょう。また、単純な接続 ができるようになるまでは、 SLIP や PPP のような複雑な設定は試さないで ください。もし単純な接続はうまくいくが SLIP は駄目という場合の原因は大 抵 SLIP にあり、PCMCIA にはありません。 <!-- If you get kernel messages indicating that the serial_cs module cannot be loaded, it means that your kernel does not have serial device support. If you have compiled the serial driver as a module, you must modify <tt>/etc/pcmcia/config</tt> to indicate that the <tt>serial</tt> module should be loaded before <tt>serial_cs</tt>. --> serial_cs モジュールがロードできないことを示すカーネルメッセージが残っ ていれば、カーネルにシリアルデバイスのサポートが組み込まれていないとい うことです。シリアルドライバをモジュールとして作っていれば、 <tt>/etc/pcmcia/config</tt> を修正して、<tt>serial_cs</tt> の前に <tt>serial</tt> モジュールをロードするように設定しなければなりません。 </itemize> <!-- <sect1>PCMCIA parallel port devices --> <sect1>PCMCIA パラレルポートデバイス <p> <!-- The Linux parallel port driver is layered so that several high-level device types can share use of the same low level port driver. Printer devices are accessed via the <tt>/dev/lp*</tt> special device files. The configuration of a printer device can be examined and modified with the <tt/tunelp/ command. --> Linux のパラレルポートドライバはレイヤ化されているので、 いくつかのタイプの高レベルデバイスは、ポート用の低レベルドライバについ ては同じものを共有できます。プリンタデバイスは特殊デバイスファイル <tt>/dev/lp*</tt> 経由でアクセスできます。プリンタデバイスの設定は、 <tt/tunelp/ コマンドで試験と修正ができます。 <!-- The <tt/parport_cs/ module depends on the <tt/parport/ and <tt/parport_pc/ drivers, which may be either compiled into the kernel or compiled as modules. The layered driver structure means that any top-level parallel drivers (such as the plip driver, the printer driver, etc) must be compiled as modules. These drivers only recognize parallel port devices at module startup time, so they need to be loaded after any PC Card parallel devices are configured. --> <tt/parport_cs/ モジュールは <tt/parport/ ドライバと <tt/parport_pc/ ドライバに依存しています。これらはカーネルに組み込んでも、モジュールと して作成しても構いません。ドライバの構成がレイヤ化されているというこ とは、トップレベルのパラレルドライバ(PLIP ドライバやプリンタドライバ等) は全てモジュールとしてコンパイルしなければならないということです。 これらのドライバはモジュールの起動時しかパラレルポートを認識しないので、 PC カード用パラレルデバイスの設定を終えた後にモジュールをロードしなけ ればなりません。 <!-- The device address passed to <tt/parport.opts/ has three comma-separated fields: the first is the scheme, the second is the socket number, and the third is the device instance. The device instance may take several values for cards that support multiple parallel ports, but for single-port cards, it will always be 0. If you commonly use more than one such card, you may want to specify different settings based on socket position, as in: --> <tt/parport.opts/ に渡されるデバイスアドレスは、コンマで区切られた 3 つのフィールドから構成されています。一つ目のフィールドはスキーム、 二つ目はソケット番号、三つ目はデバイスインスタンスです。 複数のパラレルポートに対応しているカードの場合はデバイスインスタンスが 複数の値を持つことがありますが、ポートが一つしかないカードの場合は デバイスインスタンスの値は必ず 0 になります。普段から複数の PCMCIA パラレルポートカードを使っているなら、挿入するソケットの位置によって設 定を変えることが可能です。その場合の設定は以下のようにします: <tscreen><verb> case "$ADDRESS" in *,0,*) # Options for card in socket 0 LINK=/dev/printer0 ;; *,1,*) # Options for card in socket 1 LINK=/dev/printer1 ;; esac </verb></tscreen> <!-- If you configure your kernel to load the basic Linux parallel port driver as a module, you must edit <tt>/etc/pcmcia/config</tt> to indicate that the appropriate modules must be loaded. Edit the parallel device entry to read: --> Linux の基本のパラレルポートドライバをモジュールとしてロードするように カーネルを設定しているならば、<tt>/etc/pcmcia/config</tt> を編集して、 適切なモジュールが必ずロードされるようにしなければなりません。読み込ま れるパラレルデバイスの項目を編集してください: <tscreen><verb> device "parport_cs" class "parport" module "misc/parport", "misc/parport_pc", "parport_cs" </verb></tscreen> <!-- <sect2>Parallel device parameters --> <sect2>パラレルデバイスのパラメータ <p> <!-- The following parameters can be defined in <tt/parport.opts/: --> 以下のパラメータを <tt/parport.opts/ で定義できます: <descrip> <tag><tt/LINK/</tag> <!-- Specifies a path for a symbolic link to be created to the printer port. --> プリンタポートに対して張られるシンボリックリンクのパスを指定します。 <tag><tt/LP_OPTS/</tag> <!-- Specifies options to be passed to the <tt/tunelp/ command. --> <tt/tunelp/ コマンドに渡すオプションを指定します。 </descrip> <!-- For example: --> 例を以下に示します: <tscreen><verb> case "$ADDRESS" in *,*,*,*) LINK="/dev/printer" LP_OPTS="" </verb></tscreen> <!-- <sect2>Diagnosing problems with parallel port devices --> <sect2>パラレルポートデバイスで起こる問題の診断 <p> <itemize> <item> <!-- Is there an interrupt conflict? If the system log looks good, but the port just doesn't seem to work, try using <tt/tunelp/ to change the irq to 0, and see if things improve. This switches the driver to polling mode. If this seems to fix the problem, it is likely that some other device in your system is using the interrupt selected by parport_cs. You should add a line to <tt>/etc/pcmcia/config.opts</tt> to exclude this interrupt. --> 割り込みは衝突していませんか? システムログに問題がないけれどポートが動 作しているようには見えない場合は、<tt/tunelp/ を使って IRQ を 0 に変更 し、これで状況が改善するかどうかを見てください。この操作はドライバを ポーリングモードに変えます。これで問題が解決するようであれば、 parport_cs が選んだ割り込みをシステム上の他の何らかのデバイスが使って いると思われます。<tt>/etc/pcmcia/config.opts</tt> に設定を追加して、 この割り込みを除外してください。 <item> <!-- If you get kernel messages indicating that the <tt/parport_cs/ module cannot be loaded, it means that your kernel does not have parallel device support. If you have compiled the parallel driver as a module, you may need to modify <tt>/etc/pcmcia/config</tt> to indicate that the <tt>parport</tt> and <tt/parport_pc/ modules should be loaded before <tt>parport_cs</tt>. --> <tt/parport_cs/ モジュールがロードできないことを示すカーネルメッセージ が出ている場合は、カーネルがパラレルデバイスをサポートしていないという ことです。パラレルドライバをモジュールとして作ったのであれば、 <tt>/etc/pcmcia/config</tt> を編集して、<tt>parport</tt> モジュールと <tt/parport_pc/ モジュールを <tt>parport_cs</tt> モジュールの前にロー ドするように設定する必要があるでしょう。 </itemize> <!-- <sect1>PCMCIA SCSI adapters --> <sect1>PCMCIA SCSI アダプタ <p> <!-- All the currently supported PCMCIA SCSI cards are work-alikes of one of the following ISA bus cards: the Qlogic, the Adaptec AHA-152X, or the Future Domain TMC-16x0. The PCMCIA drivers are built by linking some PCMCIA-specific code (in <tt/qlogic_cs.c/, <tt/aha152x_cs.c/, or <tt/fdomain_cs.c/) with the normal Linux SCSI driver, pulled from the Linux kernel source tree. The Adaptec APA1480 CardBus driver is based on the kernel aic7xxx PCI driver. Due to limitations in the Linux SCSI driver model, only one removable card per driver is supported. --> 現時点までにサポートされている PCMCIA SCSI カードは、 Qlogic, Adaptec AHA-152X, Future Domain TMC-16x0 といった ISA バス用のカードと機能的に 同等な PCMCIA カードです。これらのカード用の PCMCIA ドライバモジュール は PCMCIA 独自のコード(<tt>qlogic_cs.c</tt>, <tt/aha152x_cs.c/, <tt>fdomain_cs.c</tt>)とLinux カーネルのソースコードから引っ張ってきた 通常の SCSI ドライバをリンクして作成されています。 Adaptec APA1480 CardBus ドライバは、カーネルの aic7xxx PCI ドライバを ベースにしています。 Linux の SCSI ドライバの設計に由来する制限のため、取り外しができる カードはドライバごとに 1 つずつしかサポートできません。 <!-- When a new SCSI host adapter is detected, the SCSI drivers will probe for devices. Check the system log to make sure your devices are detected properly. New SCSI devices will be assigned to the first available SCSI device files. The first SCSI disk will be <tt>/dev/sda</tt>, the first SCSI tape will be <tt>/dev/st0</tt>, and the first CD-ROM will be <tt>/dev/scd0</tt>. --> 新しく SCSI カードが挿されたことを検出すると、SCSI ドライバはその カードに接続されているデバイスを調べます。システムログをチェックして、 挿したデバイスが正しく検出されているかどうかを確認してください。検出さ れた SCSI デバイスは、空いている最初の SCSI デバイスファイルに自動的に 割り当てられます。すなわち最初に見つかった SCSI ディスクは <tt>/dev/sda</tt> に、最初の SCSI テープは <tt>/dev/st0</tt> に、 最初 の CD-ROM は <tt>/dev/scd0</tt> になります。 <!-- A list of SCSI devices connected to this host adapter will be shown in <tt>stab</tt>, and the SCSI configuration script, <tt>/etc/pcmcia/scsi</tt>, will be called once for each attached device, to either configure or shut down that device. The default script does not take any actions to configure SCSI devices, but will properly unmount filesystems on SCSI devices when a card is removed. --> このホストアダプタに接続されている SCSI デバイスのリストは <tt>stab</tt> に記録されます。また SCSI 設定スクリプト (<tt>/etc/pcmcia/scsi</tt>)が割り当てられたデバイスをごとに一度呼び出 され、そのデバイスの設定や停止を行います。デフォルトのスクリプトは、 SCSI デバイスの設定は全く行わず、カードが抜かれた時に SCSI デバイス上 のファイルシステムを正しくアンマウトする処理だけを行います。 <!-- The device addresses passed to <tt/scsi.opts/ are complicated, because of the variety of things that can be attached to a SCSI adapter. Addresses consist of either six or seven comma-separated fields: the current scheme, the device type, the socket number, the SCSI channel, ID, and logical unit number, and optionally, the partition number. The device type will be ``sd'' for disks, ``st'' for tapes, ``sr'' for CD-ROM devices, and ``sg'' for generic SCSI devices. For most setups, the SCSI channel and logical unit number will be 0. For disk devices with several partitions, <tt/scsi.opts/ will first be called for the whole device, with a five-field address. The script should set the <tt/PARTS/ variable to a list of partitions. Then, <tt/scsi.opts/ will be called for each partition, with the longer seven-field addresses. --> SCSI アダプタには色々な機器が接続できるため、<tt>scsi.opts</tt> に渡す デバイスアドレスはかなり複雑です。フィールドはコンマで区切られた 6 個 あるいは 7 個のフィールドからできています:それぞれのフィールドは、 スキーム、デバイスタイプ、ソケット番号、SCSI チャンネル、ID、 論理ユニット番号、(これは省略可能ですが)パーティション番号です。 デバイスの種類は ``sd'' がディスク、``st'' がテープ、``sr'' が CD-ROM で ``sg'' がジェネリック SCSI デバイスです。ほとんどの設定では SCSI チャンネルと論理ユニット番号は 0 です。複数のパーティションを持つ ディスクデバイスについては、まず <tt>scsi.opts</tt> スクリプトが、5 つ のフィールドを持つデバイスアドレスを使ってデバイス全体に対して呼ばれま す。<tt>scsi.opts</tt> スクリプトはパーティションのリストを <tt>PARTS</tt> 変数に返します。次に <tt>scsi.opts</tt> スクリプトがそ れぞれのパーティションについて、7 個全てのフィールドを持つアドレスを使っ て呼び出されます。 <!-- If your kernel does not have a top-level driver (disk, tape, etc) for a particular SCSI device, then the device will not be configured by the PCMCIA drivers. As a side effect, the device's name in <tt>stab</tt> will be something like ``sd#nnnn'' where ``nnnn'' is a four-digit hex number. This happens when <tt/cardmgr/ is unable to translate a SCSI device ID into a corresponding Linux device name. --> お使いのカーネルに、それぞれの SCSI デバイスに対応したディスクやテープ を利用するためのトップレベルドライバが組みこまれていない場合、PCMCIA ドライバからそれらのデバイスを設定することはできません。その副作用とし て、<tt>stab</tt> に残されるデバイス名は &dquot;<tt>sd#nnnn</tt>&dquot; のような形になります。ここで &dquot;<tt>nnnn</tt>&dquot;は 4 桁の 16 進数です。この現象は、 <tt>cardmgr</tt> が SCSI デバイス ID を Linux の対応するデバイス名に 変換できなかった際に起きます。 <!-- It is possible to modularize the top-level SCSI drivers so that they are loaded on demand. To do so, you need to edit <tt>/etc/pcmcia/config</tt> to tell <tt/cardmgr/ which extra modules need to be loaded when your adapter is configured. For example: --> トップレベルの SCSI ドライバ(SCSI ディスク用ドライバ、SCSI テープ用 ドライバなど)をモジュール化して、必要な時にロードすることも可能です。 そのためには、<tt>/etc/pcmcia/config</tt> を修正して、アダプタを設定す る時にロードする必要がある追加のモジュールを <tt/cardmgr/ に教えてやる 必要があります。設定例を以下に示します: <tscreen><verb> device "aha152x_cs" class "scsi" module "scsi/scsi_mod", "scsi/sd_mod", "aha152x_cs" </verb></tscreen> <!-- would say to load the core SCSI module and the top-level disk driver module before loading the regular PCMCIA driver module. The PCMCIA Configure script will not automatically detect modularized SCSI modules, so you will need use the manual configure option to enable SCSI support. --> このようにすると、核となる SCSI モジュールとトップレベル SCSI ディスク ドライバ用のモジュールが、通常の PCMCIA ドライバモジュールより先に ロードされます。PCMCIA 設定スクリプトはモジュール化された SCSI ドライバ を自動検出しないので、SCSI のサポートを有効にするためには手動で設定を 行う必要があります。 <!-- Always turn on SCSI devices before powering up your laptop, or before inserting the adapter card, so that the SCSI bus is properly terminated when the adapter is configured. Also be very careful about ejecting a SCSI adapter. Be sure that all associated SCSI devices are unmounted and closed before ejecting the card. The best way to ensure this is to use either <tt/cardctl/ or <tt/cardinfo/ to request card removal before physically ejecting the card. For now, all SCSI devices should be powered up before plugging in a SCSI adapter, and should stay connected until after you unplug the adapter and/or power down your laptop. --> ラップトップ機の電源を入れる前、あるいはアダプタカードを挿入する前には、 接続する全ての SCSI デバイスの電源を入れておき、アダプタが設定される 時にはきちんと SCSI バスがターミネート(終端)されているようにしましょう。 また、SCSI アダプタを抜く時には細心の注意を払いましょう。これを最も確 実に行う方法は、カードを物理的に抜く前に <tt>cardctl</tt> か <tt>cardinfo</tt> を使ってカードを抜き出しの要求を出すことです。現状で は、接続する全ての SCSI デバイスの電源を SCSI アダプタの挿入前に入れな ければいけませんし、アダプタカードを抜くかラップトップ機の電源を落とす までは SCSI デバイスの電源を切ってはいけません。 <!-- There is a potential complication when using these cards that does not arise with ordinary ISA bus adapters. The SCSI bus carries a ``termination power'' signal that is necessary for proper operation of ordinary passive SCSI terminators. PCMCIA SCSI adapters do not supply termination power, so if it is required, an external device must supply it. Some external SCSI devices may be configured to supply termination power. Others, such as the Zip Drive and the Syquest EZ-Drive, use active terminators that do not depend on it. In some cases, it may be necessary to use a special terminator block such as the APS SCSI Sentry 2, which has an external power supply. When configuring your SCSI device chain, be aware of whether or not any of your devices require or can provide termination power. --> PCMCIA SCSI カードを使う場合、通常の ISA バスに接続するタイプのアダプタ では起こらない問題が生じることもあります。たいてい、パッシブ型の SCSI ターミネータを正しく作動させるためには、 SCSI バスにターミネータ用の 電力が必要です、PCMCIA タイプの SCSI アダプタはターミネータ用の電力を 供給しないので、もしこの電力が必要ならば、接続されている外部デバイスが 電力を供給しなければなりません。SCSI デバイスの中にはターミネータ用の 電力を供給するように設定できるものもありますし、Zip ドライブや Syquest 社の EX-Drive のようにアクティブ型のターミネータを使っているため、 ターミネータ用の電力には依存しないものもあります。時には、APS SCSI Sentry 2 のように外部から電流を供給するタイプの特別なターミネータ を使う必要があるかもしれません。SCSI デバイスをいくつも繋げて接続する 場合には、ターミネータ用の電力を必要とするデバイスや、電力を供給できる デバイスがあるかどうかに注意してください。 <!-- <sect2>SCSI device parameters --> <sect2>SCSI デバイスのパラメータ <p> <!-- The following parameters can be defined in <tt/scsi.opts/: --> 以下のパラメータを <tt/scsi.opts/ で定義することができます: <descrip> <tag><tt/DO_FSTAB/</tag> <!-- A boolean (y/n) setting: specifies if an entry should be added to <tt>/etc/fstab</tt> for this device. --> 値には y か n を指定します。このデバイスのために <tt>/etc/fstab</tt> の設定を追加するかどうかを指定します。 <tag><tt/DO_FSCK/</tag> <!-- A boolean (y/n) setting: specifies if the filesystem should be checked before being mounted, with ``<tt/fsck -Ta/''. --> 値には y か n を指定します。マウントを行う前に ``<tt/fsck -Ta/'' コマンドを使ってファイルシステムの検査を行うかどうかを指定します。 <tag><tt/DO_MOUNT/</tag> <!-- A boolean (y/n) setting: specifies if this device should be automatically mounted at card insertion time. --> 値には y か n を指定します。カードを挿した時に自動的にマウントを行うか どうかを指定します。 <tag><tt/FSTYPE/, <tt/OPTS/, <tt/MOUNTPT/</tag> <!-- The filesystem type, mount options, and mount point to be used for the fstab entry and/or mounting the device. --> fstab 用のエントリやデバイスのマウント時に使うファイルシステムの種類、 マウント時のオプション、マウントポイントを指定します。 </descrip> <!-- For example, here is a script for configuring a disk device at SCSI ID 3, with two partitions, and a CD-ROM at SCSI ID 6: --> 例として、SCSI ID が 3 でパーティションを 2 つ持つディスクと SCSI ID が 6 である CD-ROM を設定するためのスクリプトを以下に示します: <tscreen><verb> case "$ADDRESS" in *,sd,*,0,3,0) # This device has two partitions... PARTS="1 2" ;; *,sd,*,0,3,0,1) # Options for partition 1: # update /etc/fstab, and mount an ext2 fs on /usr1 DO_FSTAB="y" ; DO_FSCK="y" ; DO_MOUNT="y" FSTYPE="ext2" OPTS="" MOUNTPT="/usr1" ;; *,sd,*,0,3,0,2) # Options for partition 2: # update /etc/fstab, and mount an MS-DOS fs on /usr2 DO_FSTAB="y" ; DO_FSCK="y" ; DO_MOUNT="y" FSTYPE="msdos" OPTS="" MOUNTPT="/usr2" ;; *,sr,*,0,6,0) # Options for CD-ROM at SCSI ID 6 PARTS="" DO_FSTAB="y" ; DO_FSCK="n" ; DO_MOUNT="y" FSTYPE="iso9660" OPTS="ro" MOUNTPT="/cdrom" ;; esac </verb></tscreen> <!-- <sect2>Comments about specific cards --> <sect2>個別カードに関するコメント <p> <itemize> <item> <!-- The Adaptec APA-1480 CardBus card needs a large IO port window (256 contiguous ports aligned on a 256-port boundary). It may be necessary to expand the IO port regions in <tt>/etc/pcmcia/config.opts</tt> to guarantee that such a large window can be found. --> Adaptec APA-1480 CardBus カードは巨大な I/O ポートウィンドウ(256 個の ポート境界上に配置された 256 個の連続したポート)を必要とします。このよ うに巨大なウィンドウを検出するためには、 <tt>/etc/pcmcia/config.opts</tt> で I/O ポート領域を広げる必要があるか もしれません。 <item> <!-- The Adaptec APA-460 SlimSCSI adapter is not supported. This card was originally sold under the Trantor name, and when Adaptec merged with Trantor, they continued to sell the Trantor card with an Adaptec label. The APA-460 is not compatible with any existing Linux driver. --> Adaptec APA-460 SlimSCSI アダプタはサポートされていません。このカード は元々 Trantor 社から発売されていたものですが、Adaptec 社が Trantor 社 を合併してからは Adaptec のラベルを付けて売っています。APA-460 はどの Linux 用のドライバとも互換性がありません。 <item> <!-- I have had one report of a bad interaction between the New Media Bus Toaster and a UMAX Astra 1200s scanner. Due to the complexity of the SCSI protocol, when diagnosing problems with SCSI devices, it is worth considering that incompatible combinations like this may exist and may not be documented. --> New Media Bus Toaster と UMAX Astra 1200s スキャナについては、通信がう まくできないという報告を受けたことがあります。SCSI プロトコルは複雑な ので、SCSI デバイスにまつわる問題を調べる際には、このように互換性のな い組合せが存在し、しかも文書化されていないかもしれないことを考慮する必 要があります。 </itemize> <!-- <sect2>Diagnosing problems with SCSI adapters --> <sect2>SCSI アダプタにまつわる問題の診断 <p> <itemize> <item> <!-- With the <tt/aha152x_cs/ driver (used by Adaptec, New Media, and a few others), it seems that SCSI disconnect/reconnect support is a frequent source of trouble with tape drives. To disable this ``feature,'' add the following to <tt>/etc/pcmcia/config.opts</tt>: --> <tt/aha152x_cs/ ドライバ(Adaptec, New Media などで使用)の場合、 SCSI 切断/再接続のサポートがテープドライブにおいてよくトラブルの原因に なるようです。この「機能」を無効にするには、 <tt>/etc/pcmcia/config.opts</tt> に以下の行を追加します: <tscreen><verb> module "aha152x_cs" opts "reconnect=0" </verb></tscreen> <item> <!-- Also with the <tt/aha152x_cs/ driver, certain devices seem to require a longer startup delay, controlled via the <tt/reset_delay/ module parameter. The Yamaha 4416S CDR drive is one such device. The result is the device is identified successfully, then hangs the system. In such cases, try: --> また <tt/aha152x_cs/ ドライバの場合、特定のデバイスで起動時の待ち時間 を長くする必要があるようです。これはモジュールのパラメータ <tt/reset_delay/ で制御できます。Yamaha の 4416S CD-R ドライブは、この ようなドライブの一例です。待ち時間を長く取らないと、デバイスの認識はう まく行きますが、その後にシステムがハングしてしまいます。このような場合 には以下の設定を試してください: <tscreen><verb> module "aha152x_cs" opts "reset_delay=500" </verb></tscreen> <item> <!-- Another potential source of SCSI device probe problems is probing of multiple LUN's. If you see successful detection of a device, followed by SCSI bus timeouts when LUN 1 for that device is probed, then disable the kernel's <tt/CONFIG_SCSI_MULTI_LUN/ option. --> SCSI デバイスの探査で起きる可能性がある別の問題としては、複数 LUN の 探査があります。あるデバイスがうまく検出されたけれど、その後で そのデバイスの LUN 1 を検出する時にSCSI バスがタイムアウトする場合には、 カーネルの <tt/CONFIG_SCSI_MULTI_LUN/ を無効にしてください。 <item> <!-- If you have compiled SCSI support as modules (<tt>CONFIG_SCSI</tt> is ``m''), you must modify <tt>/etc/pcmcia/config</tt> to load the SCSI modules before the appropriate <tt>*_cs</tt> driver is loaded. --> SCSI サポートをモジュールとして組み込んだ(<tt>CONFIG_SCSI</tt> を ``m'' に設定した)場合には、使用する <tt>*_cs</tt> ドライバがロードされ る前に SCSI モジュールがロードされるように <tt>/etc/pcmcia/config</tt> を修正しなければなりません。 <item> <!-- If you get ``aborting command due to timeout'' messages when the SCSI bus is probed, you almost certainly have an interrupt conflict. --> SCSI バスを探査した時に ``aborting command due to timeout'' という メッセージが表示される場合は、ほぼ確実に割り込みの衝突が起こっています。 <item> <!-- If the host driver reports ``no SCSI devices found'', verify that your kernel was compiled with the appropriate top-level SCSI drivers for your devices (i.e., disk, tape, CD-ROM, and/or generic). If a top-level driver is missing, devices of that type will be ignored. --> ホストドライバが ``no SCSI devices found'' というメッセージを出力する 場合には、使っているデバイス(つまりディスク、テープ、CD-ROM, ジェネリッ クデバイス)用の適切なトップレベル SCSI ドライバがカーネルに組み込まれ ていることを確かめてください。トップレベルドライバが無ければ、その種類 のデバイスは無視されます。 </itemize> <!-- <sect1>PCMCIA memory cards --> <sect1>PCMCIA メモリカード <p> <!-- The <tt/memory_cs/ driver handles all types of memory cards, as well as providing direct access to the PCMCIA memory address space for cards that have other functions. When loaded, it creates a combination of character and block devices. See the man page for the module for a complete description of the device naming scheme. Block devices are used for disk-like access (creating and mounting filesystems, etc). The character devices are for "raw" unbuffered reads and writes at arbitrary locations. --> <tt/memory_cs/ ドライバは全ての種類のメモリカードを扱うことができます。 別の機能を持つカードの PCMCIA メモリのアドレス空間に直接アクセスすることも できます。このドライバをロードする時には、キャラクタデバイスと ブロックデバイスの組が生成されます。デバイスの命名規則の詳しい説明につ いては、モジュールのオンラインマニュアルを見てください。ブロックデバイス はディスクのようなアクセス(ファイルシステムの作成やマウント等)を行うた めに使います。キャラクタデバイスは、任意の位置においてバッファ無しの読 み書きを行う "raw" デバイスとして用います。 <!-- The device address passed to <tt/memory.opts/ consists of two fields: the scheme, and the socket number. The options are applied to the first common memory partition on the corresponding memory card. --> <tt/memory.opts/ に渡すデバイスアドレスには 2 つのフィールドがあります。 すなわちスキームとソケット番号です。オプションは、対応するメモリカード の最初の共通メモリパーティションに適用されます。 <!-- Some older memory cards, and most simple static RAM cards, lack a ``Card Information Structure'' (CIS), which is the scheme PCMCIA cards use to identify themselves. Normally, <tt/cardmgr/ will assume that any card that lacks a CIS is a simple memory card, and load the <tt/memory_cs/ driver. Thus, a common side effect of a general card identification problem is that other types of cards may be misdetected as memory cards. --> 一部の古いメモリカードや、ほとんどの単純な静的 RAM カードには CIS(Card Information Structure, カード情報領域)がありません。CIS は PCMCIA が自分自身を識別するために使います。<tt/cardmgr/ は普通、CIS が 無いカードは全て単純なメモリカードとみなし、<tt/memory_cs/ ドライバを ロードします。したがって、一般にカードの識別の問題が起こった時には、 他の種類のカードが間違ってメモリカードと認識されるという副作用がありま す。 <!-- The <tt/memory_cs/ driver uses a heuristic to guess the capacity of these cards. The heuristic does not work for write protected cards, and may make mistakes in some other cases as well. If a card is misdetected, its size should then be explicitly specified when using commands such as <tt/dd/ or <tt/mkfs/. --> <tt/memory_cs/ は経験的手法を使ってカードの機能を推定します。経験的手 法は書き込み禁止のカードでは動作しませんし、他にも間違った推定を行って しまうことがあります。カードが間違って認識された場合には、<tt/dd/ や <tt/mkfs/ といったコマンドを使う時には、メモリの大きさを明示的に指定し てください。 <!-- <sect2>Memory device parameters --> <sect2>メモリデバイスのパラメータ <p> <!-- The following parameters can be specified in <tt/memory.opts/: --> 以下のパラメータは <tt/memory.opts/ で指定することができます: <descrip> <tag><tt/DO_FSTAB/</tag> <!-- A boolean (y/n) setting: specifies if an entry should be added to <tt>/etc/fstab</tt> for this device. --> 値には y か n を指定します。このデバイス用に <tt>/etc/fstab</tt> の 設定を追加するかどうかを指定します。 <tag><tt/DO_FSCK/</tag> <!-- A boolean (y/n) setting: specifies if the filesystem should be checked before being mounted, with ``<tt/fsck -Ta/''. --> 値には y か n を指定します。マウントを行う前に ``<tt/fsck -Ta/'' コマンドを使ってファイルシステムの検査を行うかどうかを指定します。 <tag><tt/DO_MOUNT/</tag> <!-- A boolean (y/n) setting: specifies if this device should be automatically mounted at card insertion time. --> 値には y か n を指定します。カードを挿した時に自動的にマウントを行うか どうかを指定します。 <tag><tt/FSTYPE/, <tt/OPTS/, <tt/MOUNTPT/</tag> <!-- The filesystem type, mount options, and mount point to be used for the fstab entry and/or mounting the device. --> fstab 用のエントリやデバイスのマウント時に使うファイルシステムの種類、 マウント時のオプション、マウントポイントを指定します。 </descrip> <!-- Here is an example of a script that will automatically mount memory cards based on which socket they are inserted into: --> ソケットに挿入されたメモリカードのマウントを自動的に行うためのスクリプ トの例を示します: <tscreen><verb> case "$ADDRESS" in *,0,0) # Mount filesystem, but don't update /etc/fstab DO_FSTAB="n" ; DO_FSCK="y" ; DO_MOUNT="y" FSTYPE="ext2" ; OPTS="" MOUNTPT="/mem0" ;; *,1,0) # Mount filesystem, but don't update /etc/fstab DO_FSTAB="n" ; DO_FSCK="y" ; DO_MOUNT="y" FSTYPE="ext2" ; OPTS="" MOUNTPT="/mem1" ;; esac </verb></tscreen> <!-- <sect2>Using linear flash memory cards --> <sect2>リニアフラッシュメモリカードの使い方 <p> <!-- The following information applies only to so-called ``linear flash'' memory cards. Many flash cards, including all SmartMedia and CompactFlash cards, actually include circuitry to emulate an IDE disk device. Those cards are thus handled as IDE devices, not memory cards. --> 以下の情報はいわゆる「リニアフラッシュ」メモリカードにしか当てはまりま せん。SmartMedia や CompactFlash を含む多くのフラッシュカードは、実際 は IDE ディスクデバイスをエミュレートする回路を持っています。したがっ て、こういったカードはメモリデバイスではなく IDE デバイスとして扱われ ます。 <!-- There are two major formats for flash memory cards: the <idx>FTL</idx> or ``<idx>flash translation layer</idx>'' style, and the Microsoft <idx>Flash File System</idx>. The FTL format is generally more flexible because it allows any ordinary high-level filesystem (ext2, ms-dos, etc) to be used on a flash card as if it were an ordinary disk device. The FFS is a completely different filesystem type. Linux cannot currently handle cards formated with FFS. --> フラッシュメモリカードには有力なフォーマットが二つあります: <idx>FTL</idx> つまり ``<idx>flash translation layer</idx>'' 形式と Microsoft <idx>Flash File System</idx> 形式です。一般的には、FTL 形式 の方が柔軟性に優れています。というのも、FTL 形式のフラッシュカード上に は、通常のディスクデバイスと同様に任意の一般的な高レベルファイルシステム (ext2, MS-DOS 等)を作れるからです。FFS は全く独自のファイルシステムで す。現時点では、Linux は FFS でフォーマットされたカードを扱えません。 <!-- To use a flash memory card as an ordinary disk-like block device, first create an FTL partition on the device with the <tt><cdx>ftl_format</cdx></tt> command. This layer hides the device-specific details of flash memory programming and make the card look like a simple block device. For example: --> フラッシュメモリカードを普通のディスクのようなブロックデバイスとして使 うには、まず <tt><cdx>ftl_format</cdx></tt> コマンドを使ってデバイス上 に FTL パーティションを作成します。このレイヤはフラッシュメモリ のプログラミングにおけるデバイス固有の細かい部分を隠し、カードが単なる ブロックデバイスに見えるようにします。以下にコマンドの例を示します: <tscreen><verb> ftl_format -i /dev/mem0c0c </verb></tscreen> <!-- Note that this command accesses the card through the ``raw'' memory card interface. Once formatted, the card can be accessed as an ordinary block device via the <tt/ftl_cs/ driver. For example: --> このメモリは ``raw'' メモリカードインタフェース経由でカードにアクセス します。一度フォーマットすると、このカードは <tt/ftl_cs/ ドライバ経由 で通常のブロックデバイスとしてアクセスすることができます。操作例を以下 に示します: <tscreen><verb> mke2fs /dev/ftl0c0 mount -t ext2 /dev/ftl0c0 /mnt </verb></tscreen> <!-- Device naming for FTL devices is tricky. Minor device numbers have three parts: the card number, the region number on that card, and optionally, the partition within that region. A region can either be treated as a single block device with no partition table (like a floppy), or it can be partitioned like a hard disk device. The ``ftl0c0'' device is card 0, common memory region 0, the entire region. The ``ftl0c0p1'' through ``ftl0c0p4'' devices are primary partitions 1 through 4 if the region has been partitioned. --> FTL デバイスの命名規則はちょっと変わっています。マイナーデバイス番号が 3 つの部分に分かれています。すなわちカード番号、そのカード上での領域番号、 (省略可能な)領域内でのパーティション番号です。 ある領域はパーティションテーブルを持たない単独のブロックデバイスとして 扱うこともできますし(フロッピーと同様です)、ハードディスクデバイスのよ うにパーティションを切ることもできます。``ftl0c0'' デバイスはカード 0, 共通メモリ領域 0, 全領域を使うという意味です。 領域がパーティション分割されていれば、``ftl0c0p1'' から ``ftl0c0p4'' が基本パーティションの 1 番から 4 番を表します。 <!-- Configuration options for FTL partitions can be given in <tt/ftl.opts/, which is similar in structure to <tt/memory.opts/. The device address passed to <tt/ftl.opts/ consists of three or four fields: the scheme, the socket number, the region number, and optionally, the partition number. Most flash cards have just one flash memory region, so the region number will generally always be zero. --> FTL パーティションの設定オプションは <tt/ftl.opts/ で指定できます。 このファイルの構成は <tt/memory.opts/ に似ています。 <tt/ftl.opts/ に渡すデバイスアドレスは、3 個または 4 個のフィールドか ら構成されます。すなわちスキーム、ソケット番号、領域番号、(省略可能な) パーティション番号です。ほとんどのフラッシュカードはフラッシュメモリ領域 を 1 つしか持っていません。したがって領域番号は常に 0 となります。 <!-- Intel Series 100 flash cards use the first 128K flash block to store the cards' configuration information. To prevent accidental erasure of this information, <tt/ftl_format/ will automatically detect this and skip the first block when creating an FTL partition. --> Intel Series 100 フラッシュカードは、最初の 128K のフラッシュブロック を使ってカードの設定情報を格納しています。この情報を誤って消してしまう のを防ぐため、<tt/ftl_format/ は自動的にこれを検出し、FTL パーティション の作成時には最初のブロックをスキップします。 <!-- <sect1>PCMCIA ATA/IDE card drives --> <sect1>PCMCIA ATA/IDE カードドライブ <p> <!-- ATA/IDE drive support is based on the regular kernel IDE driver. This includes SmartMedia and CompactFlash devices: these flash memory cards are set up so that they emulate an IDE interface. The PCMCIA-specific part of the driver is <tt/ide_cs/. Be sure to use <tt/cardctl/ or <tt/cardinfo/ to shut down an ATA/IDE card before ejecting it, as the driver has not been made ``hot-swap-proof''. --> ATA/IDE ドライブのサポートは、カーネルの通常の IDE ドライバを基にして います。SmartMedia デバイスと CompactFlash デバイスもサポート対象に含 まれています: こういったフラッシュメモリカードは、IDE インタフェースを エミュレートするように設定されています。 このドライバの PCMCIA 固有の部分が <tt/ide_cs/ です。 ATA/IDE カードを抜く前には、<tt/cardctl/ や <tt/cardinfo/ を使ってカード を停止させてください。というのも、このドライバはホットスワップに対応し ていないからです。 <!-- The device addresses passed to <tt/ide.opts/ consist of either three or four fields: the current scheme, the socket number, the drive's serial number, and an optional partition number. The <tt/ide_info/ command can be used to obtain an IDE device's serial number. As with SCSI devices, <tt/ide.opts/ is first called for the entire device. If <tt/ide.opts/ returns a list of partitions in the <tt/PARTS/ variable, the script will then be called for each partition. --> <tt/ide.opts/ に渡すデバイスアドレスは 3 個または 4 個のフィールドから 構成されます。すなわち現在のスキーム、ソケット番号、デバイスのシリアル番号、 (省略可能な)パーティション番号です。<tt/ide_info/ コマンドを使うと、 IDE デバイスのシリアル番号を得ることができます。SCSI デバイスと同様に、 <tt/ide.opts/ はまずデバイス全体に対して呼び出されます。 <tt/ide.opts/ がパーティションのリストを <tt/PARTS/ 変数に返した場合は、 次にこのスクリプトがそれぞれのパーティションに対して呼び出されます。 <!-- <sect2>ATA/IDE fixed-disk device parameters --> <sect2>ATA/IDE 固定ディスクデバイスのパラメータ <p> <!-- The following parameters can be specified in <tt/ide.opts/: --> 以下のパラメータを <tt/ide.opts/ で指定することができます: <descrip> <tag><tt/DO_FSTAB/</tag> <!-- A boolean (y/n) setting: specifies if an entry should be added to <tt>/etc/fstab</tt> for this device. --> 値には y か n を指定します。このデバイス用に <tt>/etc/fstab</tt> の 設定を追加するかどうかを指定します。 <tag><tt/DO_FSCK/</tag> <!-- A boolean (y/n) setting: specifies if the filesystem should be checked before being mounted, with ``<tt/fsck -Ta/''. --> 値には y か n を指定します。マウントを行う前に ``<tt/fsck -Ta/'' コマンドを使ってファイルシステムの検査を行うかどうかを指定します。 <tag><tt/DO_MOUNT/</tag> <!-- A boolean (y/n) setting: specifies if this device should be automatically mounted at card insertion time. --> 値には y か n を指定します。カードを挿した時に自動的にマウントを行うか どうかを指定します。 <tag><tt/FSTYPE/, <tt/OPTS/, <tt/MOUNTPT/</tag> <!-- The filesystem type, mount options, and mount point to be used for the fstab entry and/or mounting the device. --> fstab 用のエントリやデバイスのマウント時に使うファイルシステムの種類、 マウント時のオプション、マウントポイントを指定します。 </descrip> <!-- Here is an example <tt/ide.opts/ file to mount the first partition of any ATA/IDE card on <tt>/mnt</tt>. --> 任意の ATA/IDE カードの最初のパーティションを <tt>/mnt</tt> にマウント するための <tt/ide.opts/ ファイルの例を示します: <tscreen><verb> case "$ADDRESS" in *,*,*,1) DO_FSTAB="y" ; DO_FSCK="y" ; DO_MOUNT="y" FSTYPE="msdos" OPTS="" MOUNTPT="/mnt" ;; *,*,*) PARTS="1" ;; esac </verb></tscreen> <!-- <sect2>Diagnosing problems with ATA/IDE adapters --> <sect2>ATA/IDE アダプタにまつわる問題の診断 <p> <itemize> <item> <!-- An IO port conflict may cause the IDE driver to misdetect the drive geometry and report ``<tt/INVALID GEOMETRY: 0 PHYSICAL HEADS?/''. To fix, try excluding the selected IO port range in <tt>/etc/pcmcia/config.opts</tt>. --> I/O ポートが衝突していると、IDE ドライバがドライブのジオメトリを誤検出 し、``<tt/INVALID GEOMETRY: 0 PHYSICAL HEADS?/'' と報告するかもしれま せん。これを修正するには、<tt>/etc/pcmcia/config.opts</tt> を編集して、 衝突する範囲の I/O ポートを使わないようにしましょう。 <item> <!-- Some IDE drives violate the PCMCIA specification by requiring a longer time to spin up than the maximum allowed card setup time. Starting with release 3.0.6, the ide_cs driver will automatically retry the device probe to give these drives time to spin up. With older drivers, you may need to load the <tt/pcmcia_core/ module with: --> 一部の IDE カードはディスクの回転が始まるのに時間がかかるため、PCMCIA の仕様でカードの設定のために許されている最大時間を超えてしまうことがあ ります。バージョン 3.0.6 以降では、ide_cs ドライバは自動的にデバイス 検出のリトライを行い、このようなディスクドライブが動き出すための時間を 与えます。古いドライバを使っている場合には、<tt/pcmcia_core/ モジュール を以下のようにしてロードする必要があるかもしれません。 <tscreen><verb> CORE_OPTS="unreset_delay=400" </verb></tscreen> <item> <!-- To use an ATA/IDE CD-ROM device, your kernel must be compiled with <tt/CONFIG_BLK_DEV_IDECD/ enabled. This will normally be the case for standard kernels, however it is something to be aware of if you compile a custom kernel. --> ATA/IDE CD-ROM デバイスを使うためには、カーネルは <tt/CONFIG_BLK_DEV_IDECD/ オプションを有効にして構築しなければなりませ ん。標準のカーネルではこのオプションは有効になっていますが、独自の カーネルを作っている場合には注意が必要です。 <item> <!-- A common error when using IDE drives is try to mount the wrong device file. Generally, you want to mount a partition of the device, not the entire device (i.e., <tt>/dev/hde1</tt>, not <tt>/dev/hde</tt>). --> IDE ドライブの使用時によく起こるエラーは、誤ったデバイスファイルをマウ ントしようとすることです。普通は、デバイス全体ではなくデバイス中の パーティションひとつをマウントします(つまり <tt>/dev/hde</tt> ではなく <tt>/dev/hde1</tt>)。 </itemize> <!-- <sect1>Multifunction cards --> <sect1>マルチファンクションカード <p> <!-- A single interrupt can be shared by several drivers, such as the serial driver and an ethernet driver: in fact, the PCMCIA specification requires all card functions to share the same interrupt. Normally, all card functions are available without having to swap drivers. Any remotely recent Linux kernel (i.e., 1.3.72 or later) supports this kind of interrupt sharing. --> 一つの割り込みを複数のドライバ(例えばシリアルドライバとイーサネット ドライバ)で共有することができます。実際、PCMCIA の仕様では、カードの機 能全てが同じ割り込みを共有することを要求しています。普通は、カードの機 能は全てドライバを切り替えることなく利用できます。 ある程度最近の Linux カーネル(つまり 1.3.72 以降)は、こういった種類の 割り込みの共有をサポートしています。 <!-- Simultaneous use of two card functions is ``tricky'' and various hardware vendors have implemented interrupt sharing in their own incompatible (and sometimes proprietary) ways. The drivers for some cards (Ositech Jack of Diamonds, 3Com 3c562 and related cards, Linksys cards) properly support simultaneous access, but others (older Megahertz cards in particular) do not. If you have trouble using a card with both functions active, try using each function in isolation. That may require explicitly doing an ``<tt/ifconfig down/'' to shut down a network interface and use a modem on the same card. --> カードの機能を 2 つ同時に使うには「細工」が必要で、色々なハードウェア ベンダーがそれぞれ互換性の無い(場合によっては独自の)方法を使って割り込み の共有を実装しています。一部のカード(Ositech Jack of Diamonds, 3Com 3c562 とその関連カード、Linksys 製カード)用のドライバは同時アクセ スをうまくサポートしていますが、サポートできていないカード(特に古い Megahertz 製カード)もあります。両方の機能を有効にしてカードを使うと問 題が起こる場合は、それぞれの機能を切り離して試してください。これを行う には、明示的に ``<tt/ifconfig down/'' を実行してネットワークインタフェース を停止させ、それから同じカードのモデム機能を使う必要があるかもしれませ ん。 <!-- <sect>Advanced topics --> <sect>高度な話題 <p> <!-- <sect1>Resource allocation for PCMCIA devices --> <sect1>PCMCIA デバイスへのリソース割り当て <p> <!-- In theory, it should not really matter which interrupt is allocated to which device, as long as two devices are not configured to use the same interrupt. In <tt>/etc/pcmcia/config.opts</tt> you'll find a place for excluding interrupts that are used by non-PCMCIA devices. --> 理論的には、2 つのデバイスが同じ IRQ を使わない限り、どの IRQ がどの デバイスに割りあてられても問題にはならないはずです。 <tt>/etc/pcmcia/config</tt> ファイルには、PCMCIA 以外のデバイスが 利用する IRQ を PCMCIA では使わないように設定する部分があります。 <!-- Similarly, there is no way to directly specify the I/O addresses for a card to use. The <tt>/etc/pcmcia/config.opts</tt> file allows you to specify ranges of ports available for use by any card, or to exclude ranges that conflict with other devices. --> 同様に、あるカードが使う I/O アドレスを直接指定する方法はありません。 <tt>/etc/pcmcia/config.opts</tt> ファイルを使うと、どのカードでも使え る I/O ポートの範囲を指定することや、他のデバイスと衝突する範囲の I/O ポートを使わないように指定することができます。 <!-- After modifying <tt>/etc/pcmcia/config.opts</tt>, you can reinitialize <tt/cardmgr/ with ``<tt/kill -HUP/''. --> <tt>/etc/pcmcia/config.opts</tt> を修正したら、``<tt/kill -HUP/'' を使っ て <tt/cardmgr/ の初期化をやり直してください。 <!-- The interrupt used to monitor card status changes is chosen by the low-level socket driver module (<tt/i82365/ or <tt/tcic/) before <tt/cardmgr/ parses <tt>/etc/pcmcia/config</tt>, so it is not affected by changes to this file. To set this interrupt, use the <tt/cs_irq=/ option when the socket driver is loaded, by setting the <tt/PCIC_OPTS/ variable in <tt>/etc/rc.d/rc.pcmcia</tt>. --> カード状態の変更を監視するための割り込みは、<tt/cardmgr/ が <tt>/etc/pcmcia/config</tt> を読み込む前に低レベルのソケットドライバ モジュール(<tt/i82365/ や <tt/tcic/)が決めます。したがって、このファイル を変更しても影響はありません。この割り込みを設定するには、 ソケットドライバをロードする時に <tt/cs_irq=/ オプションで設定してくだ さい。この設定は <tt>/etc/rc.d/rc.pcmcia</tt> で <tt/PCIC_OPTS/ 変数を 設定することによって行います。 <!-- All the client card drivers have a parameter called <tt/irq_list/ for specifying which interrupts they may try to allocate. These driver options should be set in your <tt>/etc/pcmcia/config</tt> file. For example: --> 全てのクライアントカードドライバには、割り当てを試みる割り込みを指定す るための <tt/irq_list/ というパラメータがあります。このようなドライバ オプションは <tt>/etc/pcmcia/config</tt> ファイルで設定します。指定例 を以下に示します: <tscreen><verb> device "serial_cs" module "serial_cs" opts "irq_list=8,12" ... </verb></tscreen> <!-- would specify that the serial driver should only use irq 8 or irq 12. Regardless of <tt/irq_list/ settings, Card Services will never allocate an interrupt that is already in use by another device, or an interrupt that is excluded in the config file. --> この指定により、シリアルドライバは irq 8 か irq 12 しか使わなくなりま す。<tt/irq_list/ の設定に関係なく、カードサービスシステムは他のデバイス が既に使っている割り込みや設定ファイルで除外されている割り込みは決して 割り当てません。 <!-- <sect1>How can I have separate device setups for home and work? --> <sect1>家と会社で別々の設定を使い分けることができますか? <p> <!-- This is fairly easy using ``scheme'' support. Use two configuration schemes, called ``home'' and ``work''. Here is an example of a <tt/network.opts/ script with scheme-specific settings: --> PCMCIA の「スキーム」を使えば簡単です。例えば ``home'' と ``work'' と いう 2 つのスキームの設定を考えてみましょう。スキームを反映した <tt>network.opts</tt> スクリプトの例を以下に示します: <tscreen><verb> case "$ADDRESS" in work,*,*,*) # definitions for network card in work scheme ... ;; home,*,*,*|default,*,*,*) # definitions for network card in home scheme ... ;; esac </verb></tscreen> <!-- The first part of a device address is always the configuration scheme. In this example, the second ``case'' clause will select for both the ``home'' and ``default'' schemes. So, if the scheme is unset for any reason, it will default to the ``home'' setup. --> PCMCIA デバイスアドレスの最初の部分は常にスキームの設定に対応していま す。この例では 2 つめの ``case'' の部分が ``home'' と ``default'' のス キームになっており、スキームが設定されていない場合は ``home'' の設定で 起動されることになります。 <!-- Now, to select between the two sets of settings, run either: --> 2 つの設定を切りかえるには、 <tscreen><verb> cardctl scheme home </verb></tscreen> <!-- or --> あるいは <tscreen><verb> cardctl scheme work </verb></tscreen> を実行します。 <!-- The <tt/cardctl/ command does the equivalent of shutting down all your cards and restarting them. The command can be safely executed whether or not the PCMCIA system is loaded, but the command may fail if you are using other PCMCIA devices at the time (even if their configurations are not explicitly dependant on the scheme setting). --> <tt/cardctl/ は、全てのカードの停止と再起動に相当する操作を行います。 このコマンドは PCMCIA システムがロードされているかどうかに関わらず安全 に実行することができますが、その時にちょうど別の PCMCIA デバイスを使っ ていれば、コマンドは失敗するかもしれません(たとえ、設定がそのスキーム 設定に明示的に依存していなくても)。 <!-- To find out the current scheme setting, run: --> 現在のスキームの設定を知るには以下のコマンドを実行します: <tscreen><verb> cardctl scheme </verb></tscreen> <!-- By default, the scheme setting is persistent across boots. This can have undesirable effects if networking is initialized for the wrong environment. Optionally, you can set the initial scheme value with the <tt/SCHEME/ startup option (see <ref id="startup" name="Startup options"> for details). It is also possible to set the scheme from the <tt/lilo/ boot prompt. Since <tt/lilo/ passes unrecognized options to <tt/init/ as environment variables, a value for <tt/SCHEME/ (or any other PCMCIA startup option) at the boot prompt will be propagated into the PCMCIA startup script. --> デフォルトでは、スキーム設定は再起動しても変化しません。そのため、 間違った環境向けにネットワークが初期化されてしまうと、好ましくない結果 になるかもしれません。このような場合には、起動オプションの <tt/SCHEME/ を使ってスキームの初期値を設定することができます(詳しくは <ref id="startup" name="起動オプション"> を参照)。<tt/lilo/ の起動 プロンプトを使ってスキームを設定することもできます。<tt/lilo/ は認識で きないオプションを環境変数として <tt/init/ に渡すので、起動プロンプト で <tt/SCHEME/(あるいは別の PCMCIA 起動オプション)を設定すると、その値 が PCMCIA 起動スクリプトに伝えられます。 <!-- To save even more keystrokes, schemes can be specified in <tt/lilo/'s configuration file. For instance, you could have: --> キー操作を減らすには、スキームを <tt/lilo/ の設定ファイルで指定すると よいでしょう。例えば以下のように設定します: <tscreen><verb> root = /dev/hda1 read-only image = /boot/vmlinuz label = home append = "SCHEME=home" image = /boot/vmlinuz label = work append = "SCHEME=work" </verb></tscreen> <!-- Typing ``home'' or ``work'' at the boot prompt would then boot into the appropriate scheme. --> 起動プロンプトで ``home'' あるいは ``work'' と入力すれば、適切な スキームでシステムが起動します。 <!-- <sect1>Booting from a PCMCIA device --> <sect1>PCMCIA デバイスからの起動 <p> <!-- Having the root filesystem on a PCMCIA device is tricky because the Linux PCMCIA system is not designed to be linked into the kernel. Its core components, the loadable kernel modules and the user mode cardmgr daemon, depend on an already running system. The kernel's ``<idx>initrd</idx>'' facility works around this requirement by allowing Linux to boot using a temporary ram disk as a minimal root image, load drivers, and then re-mount a different root filesystem. The temporary root can configure PCMCIA devices and then re-mount a PCMCIA device as root. --> ルートファイルシステムを PCMCIA デバイス上に置くには細工が必要です。と いうのも、Linux の PCMCIA システムはカーネルにリンクするようには設計さ れていないからです。中心部分となるローダブルカーネルモジュールと、 ユーザモードで動作する cardmgr デーモンは、既に動作しているシステムを 前提にしているのです。この要件はカーネルの ``<idx>initrd</idx>'' を使っ て回避することができます。この機能は一時的な RAM ディスクを小さな ルートファイルシステムとして用いて起動し、ドライバをロードし、その後で 別のルートファイルシステムを改めてマウントするというものです。一時的な ルートファイルシステム上で PCMCIA のデバイスを設定し、それから PCMCIA デバイスをルートファイルシステムとしてマウントし直すことができます。 <!-- The initrd image absolutely must reside on a bootable device: this generally cannot be put on a PCMCIA device. This is a BIOS limitation, not a kernel limitation. It is useful here to distinguish between ``boot-able'' devices (i.e., devices that can be booted), and ``root-able'' devices (i.e., devices that can be mounted as root). ``Boot-able'' devices are determined by the BIOS, and are generally limited to internal floppy and hard disk drives. ``Root-able'' devices are any block devices that the kernel supports once it has been loaded. The initrd facility makes more devices ``root-able'', not ``boot-able''. --> initrd イメージは絶対に起動デバイス以外に置かなければなりません。した がって、これを PCMCIA デバイスに置くことはできません。これは BIOS によ る制限であり、カーネルの制限ではありません。ここでは「起動可能」デバイス (つまり起動できるデバイス)と「ルート利用可能」デバイス(つまり ルートファイルシステムとしてマウントできるデバイス)を区別すると便利で しょう。「起動可能」デバイスは BIOS が決めますが、一般的には内蔵フロッピー とハードディスクに制限されています。「ルート利用可能」デバイスは、 カーネルがロードされた後に対応している全てのブロックデバイスです。 initrd 機能は、より多くのデバイスを「ルート利用可能」にします。 「起動可能」にはしません。 <!-- Some Linux distributions will allow installation to a device connected to a PCMCIA SCSI adapter, as an unintended side-effect of their support for installs from PCMCIA SCSI CD-ROM devices. However, at present, no Linux installation tools support configuring an appropriate ``initrd'' to boot Linux with a PCMCIA root filesystem. Setting up a system with a PCMCIA root thus requires that you use another Linux system to create the ``initrd'' image. If another Linux system is not available, another option would be to temporarily install a minimal Linux setup on a non-PCMCIA drive, create an initrd image, and then reinstall to the PCMCIA target. --> Linux ディストリビューションには、インストール時に PCMCIA SCSI アダプタ を使えるものもあります。これは、PCMCIA SCSI CD-ROM デバイスからの インストールに対応した結果としての意図しない副作用です。しかし現状では、 ``initrd'' を適切に設定して PCMCIA デバイス上のルートファイルシステム を使って起動するインストール用ツールはありません。したがって、PCMCIA デバイス上にルートファイルシステムを置くシステムを設定するには、別の Linux マシンを使って ``initrd'' イメージを作らなければなりません。別の Linux マシンが無ければ、最小構成の Linux を PCMCIA でないデバイス上に 一時的に構築し、そこで initrd イメージを作成し、それからインストール先 の PCMCIA に改めてインストールすることもできます。 <!-- The Linux Bootdisk-HOWTO has some general information about setting up boot disks but nothing specific to initrd. The main initrd document is included with recent kernel source code distributions, in <tt>linux/Documentation/initrd.txt</tt>. Before beginning, you should read this document. A familiarity with <tt/lilo/ is also helpful. Using initrd also requires that you have a kernel compiled with <tt/CONFIG_BLK_DEV_RAM/ and <tt/CONFIG_BLK_DEV_INITRD/ enabled. --> Linux Bootdisk-HOWTO には起動ディスクの設定に関する一般的な情報が書か れていますが、initrd 固有の情報は載っていません。initrd に関する最も 重要な文書は、最近のカーネルソースに含まれている <tt>linux/Documentation/initrd.txt</tt> です。作業を始める前に、この 文書を必ず読んでください。<tt/lilo/ にも慣れておくといいでしょう。 initrd を使うためには、カーネルの <tt/CONFIG_BLK_DEV_RAM/ オプションと <tt/CONFIG_BLK_DEV_INITRD/ オプションが有効でなければなりません。 <!-- This is an advanced configuration technique, and requires a high level of familiarity with Linux and the PCMCIA system. Be sure to read all the relevant documentation before starting. The following cookbook instructions should work, but deviations from the examples will quickly put you in uncharted and ``unsupported'' territory, and you will be on your own. --> これは高度な設定技術であり、Linux と PCMCIA に関する高度な技術が必要で す。作業の前には必ず関連文書を全て読んでください。以下の説明の手順でう まく行くはずですが、例から離れるとすぐに案内がない「サポート無し」の領 域に入るので、自分で何とかしなくてはならなくなります。 <!-- This method absolutely requires that you use a PCMCIA driver release of 2.9.5 or later. Older PCMCIA packages or individual components will not work in the initrd context. Do not mix components from different releases. --> この方法を使うにはバージョン 2.9.5 以降の PCMCIA ドライバが必ず必要で す。古い PCMCIA パッケージやパッケージ内の個別の要素は、initrd におい てはうまく動作しません。異なるバージョンの内容を混ぜてはいけません。 <!-- <sect2>The pcinitrd helper script --> <sect2>補助スクリプト ``pcinitrd'' <p> <!-- The <tt/pcinitrd/ script creates a basic initrd image for booting with a PCMCIA root partition. The image includes a minimal directory heirarchy, a handful of device files, a few binaries, shared libraries, and a set of PCMCIA driver modules. When invoking <tt/pcinitrd/, you specify the driver modules that you want to be included in the image. The core PCMCIA components, <tt/pcmcia_core/ and <tt/ds/, are automatically included. --> <tt/pcinitrd/ スクリプトは、PCMCIA デバイス上のルートパーティションで 起動するための基本的な initrd イメージを作ります。このイメージには必要 最低限のディレクトリ階層とわずかのデバイスファイル、少しの実行ファイル と共有ライブラリ、PCMCIA ドライバモジュール群しか入っていません。 <tt/pcinitrd/ を実行する時には、イメージに入れたいドライバモジュールを 指定します。PCMCIA システムの中心部分である <tt/pcmcia_core/ と <tt/ds/ は自動的に入ります。 <!-- As an example, say that your laptop uses an i82365-compatible host controller, and you want to boot Linux with the root filesystem on a hard drive attached to an Adaptec SlimSCSI adapter. You could create an appropriate initrd image with: --> 例として、i82365 互換のホストコントローラを使っているラップトップ機が あり、Adaptec SlimSCSI アダプタに接続されているハードディスク上に ルートファイルシステムを置いて Linux を起動したいと考えているものとし ます。この場合の initrd イメージは以下のようにして作成します: <tscreen><verb> pcinitrd -v initrd pcmcia/i82365.o pcmcia/aha152x_cs.o </verb></tscreen> <!-- To customize the initrd startup sequence, you could mount the image using the ``loopback'' device with a command like: --> initrd の起動シーケンスのカスタマイズは、 <tscreen><verb> mount -o loop -t ext2 initrd /mnt </verb></tscreen> といったコマンドで「ループバックデバイス」を利用してイメージをマウント して、 <!-- and then edit the <tt/linuxrc/ script. The configuration files will be installed under <tt>/etc</tt> in the image, and can also be customized. See the man page for <tt/pcinitrd/ for more information. --> <tt/linuxrc/ スクリプトを編集することで行えます。設定ファイルはイメージ の <tt>/etc</tt> ディレクトリにインストールされ、これもカスタマイズで きます。詳しくは <tt/pcinitrd/ のオンラインマニュアルを見てください。 <!-- <sect2>Creating an initrd boot floppy --> <sect2>initrd 起動ディスクの作成 <p> <!-- After creating an image with <tt/pcinitrd/, you can create a boot floppy by copying the kernel, the compressed initrd image, and a few support files for <tt/lilo/ to a clean floppy. In the following example, we assume that the desired PCMCIA root device is <tt>/dev/sda1</tt>: --> <tt/pcinitrd/ を使ってイメージを作った後は、起動ディスクを作成します。 これはカーネルと圧縮した initrd イメージ、<tt/lilo/ 用のファイル数個を 新品のフロッピーにコピーすることによって行います。以下の例では、使う予 定の PCMCIA ルートデバイスは <tt>/dev/sda1</tt> であるものとします: <tscreen><verb> mke2fs /dev/fd0 mount /dev/fd0 /mnt mkdir /mnt/etc /mnt/boot /mnt/dev cp -a /dev/fd0 /dev/sda1 /mnt/dev cp [kernel-image] /mnt/vmlinuz cp /boot/boot.b /mnt/boot/boot.b gzip < [initrd-image] > /mnt/initrd </verb></tscreen> <!-- Create <tt>/mnt/etc/lilo.conf</tt> with the contents: --> 以下の内容を持つ <tt>/mnt/etc/lilo.conf</tt> を作成します: <tscreen><verb> boot=/dev/fd0 compact image=/vmlinuz label=linux initrd=/initrd read-only root=/dev/sda1 </verb></tscreen> <!-- Finally, invoke lilo with: --> 最後に <tt/lilo/ を以下のように実行します: <tscreen><verb> lilo -r /mnt </verb></tscreen> <!-- When <tt/lilo/ is invoked with <tt/-r/, it performs all actions relative to the specified alternate root directory. The reason for creating the device files under <tt>/mnt/dev</tt> was that <tt/lilo/ will not be able to use the files in <tt>/dev</tt> when it is running in this alternate-root mode. --> <tt/-r/ オプションを付けて <tt/lilo/ を実行すると、<tt/lilo/ は指定さ れた代替ルートディレクトリからの相対位置に基づいて全ての動作を行います。 <tt>/mnt/dev</tt> ディレクトリにデバイスファイルを作成した理由は、 <tt/lilo/ はこの代替ルートモードで動作している時には、<tt>/dev</tt> ディレクトリにあるファイルを使うことができないからです。 <!-- <sect2>Installing an initrd image on a non-Linux drive --> <sect2>Linux 用でないドライブ上にある initrd イメージのインストール <p> <!-- One common use of the initrd facility would be on systems where the internal hard drive is dedicated to another operating system. The Linux kernel and initrd image can be placed in a non-Linux partition, and <tt/lilo/ or <tt/LOADLIN/ can be set up to boot Linux from these images. --> initrd 機能を使う理由としてよくあるのは、内蔵ハードディスクが他の OS 専用になっているシステムを使う場合でしょう。Linux のカーネルと initrd イメージを Linux 用でないパーティションに置き、 <tt/lilo/ や <tt/LOADLIN/ を使ってこれらのイメージから Linux を起動す る設定にすることができます。 <!-- Assuming that you have a kernel has been configured for the appropriate root device, and an initrd image created on another system, the easiest way to get started is to boot Linux using <tt/LOADLIN/, as: --> 適切なルートデバイス用のカーネルの設定が既にできており、他の OS 上に initrd イメージが作られているものとすると、手っ取り早い方法は <tt/LOADLIN/ を使って Linux を起動することです。これは以下のように行い ます: <tscreen><verb> LOADLIN <kernel> initrd=<initrd-image> </verb></tscreen> <!-- Once you can boot Linux on your target machine, you could then install <tt/lilo/ to allow booting Linux directly. For example, say that <tt>/dev/hda1</tt> is the non-Linux target partition and <tt>/mnt</tt> can be used as a mount point. First, create a subdirectory on the target for the Linux files: --> 対象のマシンで一度 Linux が起動できれば、<tt/lilo/ をインストールして 直接 Linux を起動するようにできるでしょう。例えば <tt>/dev/hda1</tt> が Linux 用のファイルシステムでない対象パーティションであり、 <tt>/mnt</tt> がマウントポイントとして使えるものとします。まずは Linux 関連ファイル用のサブディレクトリを作成します: <tscreen><verb> mount /dev/hda1 /mnt mkdir /mnt/linux cp [kernel-image] /mnt/linux/vmlinuz cp [initrd-image] /mnt/linux/initrd </verb></tscreen> <!-- In this example, say that <tt>/dev/sda1</tt> is the desired Linux root partition, a SCSI hard drive mounted via a PCMCIA SCSI adapter. To install <tt/lilo/, create a <tt/lilo.conf/ file with the contents: --> この例では <tt>/dev/sda1</tt> が希望する Linux のルートパーティション であり、SCSI ハードディスクは PCMCIA の SCSI アダプタ経由でマウントさ れるものとします。<tt/lilo/ をインストールするには、以下のような内容の <tt/lilo.conf/ を作ります: <tscreen><verb> boot=/dev/hda map=/mnt/linux/map compact image=/mnt/linux/vmlinuz label=linux root=/dev/sda1 initrd=/mnt/linux/initrd read-only other=/dev/hda1 table=/dev/hda label=windows </verb></tscreen> <!-- The <tt/boot=/ line says to install the boot loader in the master boot record of the specified device. The <tt/root=/ line identifies the desired root filesystem to be used after loading the initrd image, and may be unnecessary if the kernel image is already configured this way. The <tt/other=/ section is used to describe the other operating system installed on <tt>/dev/hda1</tt>. --> <tt/boot=/ 行は、指定されたデバイスの MBR(Master Boot Record)に ブートローダをインストールすることを指示します。<tt/root=/ は、 initrd イメージをロードした後に使うルートファイルシステムを指定します。 この指定は、カーネルイメージが既にこのように設定されている場合には必要 ありません。<tt/other=/ は、<tt>/dev/hda1</tt> にインストールされてい る他の OS を記述するために使います。 <!-- To install <tt/lilo/ in this case, use: --> この場合に <tt/lilo/ をインストールするには、以下のコマンドを使います: <tscreen><verb> lilo -C lilo.conf </verb></tscreen> <!-- Note that in this case, the <tt/lilo.conf/ file uses absolute paths that include <tt>/mnt</tt>. I did this in the example because the target filesystem may not support the creation of Linux device files for the <tt/boot=/ and <tt/root=/ options. --> 今回は、<tt/lilo.conf/ では <tt>/mnt</tt> 等の絶対パスを使っている点に 注意してください。私が例でこれを使ったのは、 対象のファイルシステムでは <tt/boot=/ オプションと <tt/root=/ オプション に対して、Linux のデバイスファイルが作れないかもしれないからです。 <!-- <sect>Dealing with unsupported cards --> <sect>サポートされていないカードの扱い <p> <!-- <sect1>Configuring unrecognized cards<label id="new-card"> --> <sect1>識別されないカードの設定<label id="new-card"> <p> <!-- Assuming that your card is supported by an existing driver, all that needs to be done is to add an entry to <tt>/etc/pcmcia/config</tt> to tell <tt/cardmgr/ how to identify the card, and which driver(s) need to be linked up to this card. Check the man page for <tt/pcmcia/ for more information about the config file format. If you insert an unknown card, <tt/cardmgr/ will normally record some identification information in the system log that can be used to construct the config entry. This information can also be displayed with the ``<tt/cardctl ident/'' command. --> 既存のドライバがお使いのカードをサポートしているとすると、必要なことは <tt>/etc/pcmcia/config</tt> にエントリを追加して、<tt/cardmgr/ に認識 の仕方とこのカードにはどのドライバをリンクする必要があるのかを教えてや ることだけです。設定ファイルのフォーマットの詳細については <tt/pcmcia/ のオンラインマニュアルをご覧ください。知らないカードが挿入 されると、<tt/cardmgr/ は通常、設定エントリの作成に利用できるような何 らかの認証情報をシステムログに記録します。この情報は ``<tt/cardctl ident/'' コマンドでも表示することができます。 <!-- Here is an example of how cardmgr will report an unsupported card in <tt>/usr/adm/messages</tt>. --> 以下の例は、cardmgr がサポートしていないカードについて <tt>/usr/adm/messages</tt> に残した記録です。 <tscreen><verb> cardmgr[460]: unsupported card in socket 1 cardmgr[460]: product info: "MEGAHERTZ", "XJ2288", "V.34 PCMCIA MODEM" cardmgr[460]: manfid: 0x0101, 0x1234 function: 2 (serial) </verb></tscreen> <!-- The corresponding entry in <tt>/etc/pcmcia/config</tt> would be: --> <tt>/etc/pcmcia/config</tt> の該当エントリは以下のようになっていると思 います: <tscreen><verb> card "Megahertz XJ2288 V.34 Fax Modem" version "MEGAHERTZ", "XJ2288", "V.34 PCMCIA MODEM" bind "serial_cs" </verb></tscreen> <!-- or using the more compact product ID codes: --> プロダクト ID コードがもっと短くて以下のようになっているかもしれません: <tscreen><verb> card "Megahertz XJ2288 V.34 Fax Modem" manfid 0x0101, 0x1234 bind "serial_cs" </verb></tscreen> <!-- You can use ``*'' to match strings that don't need to match exactly, like version numbers. When making new config entries, be careful to copy the strings exactly, preserving case and blank spaces. Also be sure that the config entry has the same number of strings as are reported in the log file. --> バージョン番号のように、正確にマッチする必要がない文字列については ``*'' を使ったマッチングを行うことができます。新しい設定エントリを作成 する時には、大文字・小文字の区別や空白文字などを含めて文字列を正確に コピーしてください。また、設定エントリの文字列の数は必ず、ログファイル に記録される文字列の数と同じになるようにしてください。 <!-- Beware that you can specify just about any driver for a card, but if you're just shooting in the dark, there is not much reason to expect this to be productive. You may get lucky and find that your card is supported by an existing driver. However, the most likely outcome is that the driver won't work, and may have unfortunate side effects like locking up your system. Unlike most ordinary device drivers, which probe for an appropriate card, the probe for a PCMCIA device is done by <tt/cardmgr/, and the driver itself may not do much validation before attempting to communicate with the device. --> あるカードに対してどんなドライバでも指定することはできますが、それが 闇雲に突っ込んでいるだけであれば、あまり意味があるとは言えません。 お使いのカードを既存のドライバがサポートしていることに運良く気づくかも しれません。しかし、もっとも起こりそうな結果はドライバが動作しないこと で、その際にはシステムが固まってしまうといった不運なおまけも伴うかもし れません。適切なカードの探査を行う通常のドライバの大部分とは異なり、 PCMCIA デバイスの探査は <tt/cardmgr/ が行い、ドライバ自体はデバイスと 通信する前にそのデバイスが正しいかどうかの確認をあまり行わないことがあ ります。 <!-- After editing <tt>/etc/pcmcia/config</tt>, you can signal <tt/cardmgr/ to reload the file with: --> <tt>/etc/pcmcia/config</tt> ファイルを編集したら、以下のコマンドを使っ て <tt/cardmgr/ にファイルを読み込み直させることができます: <tscreen><verb> kill -HUP `cat /var/run/cardmgr.pid` </verb></tscreen> <!-- If you do set up an entry for a new card, please send me a copy so that I can include it in the standard config file. --> 新しいカードのエントリを設定したら、私がこれを標準の設定ファイルに取り 込めるように、そのコピーを私まで送ってください。 <!-- <sect1>Adding support for an NE2000-compatible ethernet card --> <sect1>NE2000 互換イーサネットカードへの対応 <p> <!-- Before you begin: this procedure will only work for simple ethernet cards. Multifunction cards (i.e., ethernet/modem combo cards) have an extra layer of complexity regarding how the two functions are integrated, and generally cannot be supported without obtaining some configuration information from the card vendor. Using the following procedure for a multifunction card will not be productive. --> 始める前に: この手続きが使えるのは、単純なイーサネットカードの場合だけ です。マルチファンクションカード(つまりイーサネットとモデムのコンボカード) には 2 つの機能をまとめるための複雑な追加のレイヤがあるため、一般的には カードのベンダーが用意した何らかの設定情報を使う以外には対応する方法が ありません。以下の手続きをマルチファンクションカードで試しても意味がな いでしょう。 <!-- First, see if the card is already recognized by <tt/cardmgr/. Some cards not listed in <tt/SUPPORTED.CARDS/ are actually OEM versions of cards that are supported. If you find a card like this, let me know so I can add it to the list. --> まず、対象のカードが既に <tt/cardmgr/ に認識されていることを確かめます。 <tt/SUPPORTED.CARDS/ に書かれていないカードでも、実際には対応されてい るカードの OEM 品ということがあります。このようなカードを見つけたら、 私までお知らせください。<tt/SUPPORTED.CARDS/ のリストに追加します。 <!-- If your card is not recognized, follow the instructions in the <ref id="new-card" name="Configuring unrecognized cards"> section to create a config entry for your card, and bind the card to the <tt/pcnet_cs/ driver. Restart <tt/cardmgr/ to use the updated config file. --> カードが認識されていなければ、 <ref id="new-card" name="識別されないカードの設定">の節の手順に従って そのカード用の設定エントリを作り、<tt/pcnet_cs/ ドライバに割り当ててく ださい。それから <tt/cardmgr/ を再起動し、修正した設定ファイルを使うよ うにします。 <!-- If the <tt/pcnet_cs/ driver says that it is unable to determine your card's hardware ethernet address, then edit your new config entry to bind the card to the memory card driver, <tt/memory_cs/. Restart <tt/cardmgr/ to use the new updated config file. You will need to know your card's hardware ethernet address. This address is a series of six two-digit hex numbers, often printed on the card itself. If it is not printed on the card, you may be able to use a DOS driver to display the address. In any case, once you know it, run: --> <tt/pcnet_cs/ ドライバが、お使いのカードのハードウェアイーサネット アドレスを調べられないというメッセージを出力した場合には、新しい 設定エントリを修正して、そのカードをメモリカードのドライバ (<tt/memory_cs/)に割り当ててください。そして <tt/cardmgr/ を再起動して 書き換えた設定ファイルを読み込ませます。ここで知っている必要があるのは、 お使いのカードのハードウェアイーサネットアドレスだけです。このアドレス は 2 桁の 16 進数を 6 つ並べたもので、多くの場合、カード自身に記載され ています。カードに記載されていなければ、DOS 用のドライバを使ってアドレス を表示させるとよいでしょう。何とかしてこのアドレスを調べたら、次のコマ ンドを実行してください: <tscreen><verb> dd if=/dev/mem0a count=20 | od -Ax -t x1 </verb></tscreen> <!-- and search the output for your address. Only the even bytes are defined, so ignore the odd bytes in the dump. Record the hex offset of the first byte of the address. Now, edit <tt>clients/pcnet_cs.c</tt> and find the <tt/hw_info/ structure. You'll need to create a new entry for your card. The first field is the memory offset. The next three fields are the first three bytes of the hardware address. The final field contains some flags for specific card features; to start, try setting it to 0. --> そして、このダンプ出力の中からアドレスに相当する部分を探します。意味が あるのは偶数バイトだけなので、ダンプ中の奇数バイトは無視してください。 このアドレスの最初のバイトへのオフセットを 16 進値で記録してください。 さて、ここで <tt>clients/pcnet_cs.c</tt> ファイルを編集し、 <tt/hw_info/ 構造体を探します。この構造体を使って、対象となるカード用 の新しいエントリを作る必要があります。最初のフィールドがメモリの オフセット値です。次の 3 つのフィールドは、ハードウェアアドレスの最初 の 3 バイトです。最後のフィールドは、カード特有の機能を表す何らかのフ ラグです。このフラグの値はまずは 0 にしておきます。 <!-- After editing <tt/pcnet_cs.c/, compile and install the new module. Edit <tt>/etc/pcmcia/config</tt> again, and change the card binding from <tt/memory_cs/ to <tt/pcnet_cs/. Follow the instructions for reloading the config file, and you should be all set. Please send me copies of your new <tt/hw_info/ and config entries. --> <tt/pcnet_cs.c/ の編集が終わったら、新しいモジュールのコンパイルと インストールを行います。そして再び <tt>/etc/pcmcia/config</tt> を編集 し、カードの割り当てを <tt/memory_cs/ から <tt/pcnet_cs/ に変更します。 最後に設定ファイルの再読み込みを手順通りに行えば、全ての設定が行われる はずです。新しく作成した <tt/hw_info/ と設定エントリは私まで送ってくだ さい。 <!-- If you can't find your card's hardware address in the hex dump, as a method of last resort, it is possible to ``hard-wire'' the address when the <tt/pcnet_cs/ module is initialized. Edit <tt>/etc/pcmcia/config.opts</tt> and add a <tt/hw_addr=/ option, like so: --> カードのハードウェアダンプが 16 進ダンプ出力の中に無かった場合は、最後 の手段として、<tt/pcnet_cs/ モジュールが初期化される時に「直に書く」方法 もあります。<tt>/etc/pcmcia/config.opts</tt> を編集して、<tt/hw_addr=/ を以下のように追加してください: <tscreen><verb> module "pcnet_cs" opts "hw_addr=0x00,0x80,0xc8,0x01,0x02,0x03" </verb></tscreen> <!-- Substitute your own card's hardware address in the appropriate spot, of course. Beware that if you've gotten this far, it is very unlikely that your card is genuinely NE2000 compatible. In fact, I'm not sure if there are <em/any/ cards that are not handled by one of the first two methods. --> 当然ながら、あなた自身が使っているカードのハードウェアアドレスを適切な 位置に書いてください。これでも駄目だったら、そのカードが本当に NE2000 互換ということはまずありません。実際、最初の 2 つの方法で扱えないカー ドを私は<em/全く/知りません。 <!-- <sect1>PCMCIA floppy interface cards --> <sect1>PCMCIA フロッピーインタフェースカード <p> <!-- The PCMCIA floppy interface used in the Compaq Aero and a few other laptops is not yet supported by this package. The snag in supporting the Aero floppy is that the Aero seems to use a customized PCMCIA controller to support DMA to the floppy. Without knowing exactly how this is done, there isn't any way to implement support under Linux. --> Compaq Aero を含めたいくつかのラップトップ機で使われている PCMCIA フロッピーインタフェースは、現在の PCMCIA カードサービスではまだ サポートされていません。Aero のフロッピーへの対応の障害になっているの は、Aero ではフロッピーでも DMA を使えるように改造された独自の PCMCIA コントローラが使われていることです。DMA の制御がどのように行われている のかが正確に分からないと、Linux でも対応させようがありません。 <!-- If the floppy adapter card is present when an Aero is booted, the Aero BIOS will configure the card, and Linux will identify it as a normal floppy drive. When the Linux PCMCIA drivers are loaded, they will notice that the card is already configured and attached to a Linux driver, and this socket will be left alone. So, the drive can be used if it is present at boot time, but the card is not hot swappable. --> Aero の場合、起動時にフロッピーアダプタカードが接続されていれば Aero の BIOS がカードを設定し、Linux からは通常のフロッピードライブとして 利用できます。PCMCIA ドライバがロードされた時、そのカードは既に設定済み であり、Linux のフロッピードライバと接続されていることが分かるはずです。 したがって、カードが挿さっているソケットは使われずに放っておかれます。 すなわち、起動時に FD カードが挿入されていればフロッピーデバイスは使用 可能ですが、そのカードは抜き挿しできないことに注意してください。 <!-- <sect>Debugging tips and programming information --> <sect>デバッグのヒントとプログラム情報 <!-- <sect1>Submitting useful bug reports --> <sect1>有益なバグレポートの送り方 <p> <!-- The best way to submit bug reports is to use the HyperNews message lists on the Linux PCMCIA information site. That way, other people can see current problems (and fixes or workarounds, if available). Here are some things that should be included in all bug reports: --> 最も好ましいバグレポートの送り方は、Linux PCMCIA 情報サイトにある HyperNews のメッセージリストを使うことです。この方法なら、現状の問題 (そして、もしあれば修正方法や回避方法)が他の人にも見えるからです。 バグレポートに必須の項目を以下に示します: <itemize> <!-- <item>Your system brand and model. --> <item>お使いのマシンの品名とモデル <!-- <item>What PCMCIA card(s) you are using. --> <item>お使いの PCMCIA カード <!-- <item>Your Linux kernel version (i.e., ``<tt/uname -rv/''), and PCMCIA driver version (i.e., ``<tt/cardctl -V/''). --> <item>Linux のカーネルのバージョン(``<tt/uname -rv/'' の実行結果)と PCMCIA のドライバのバージョン(``<tt/cardctl -V/'' の実行結果) <!-- <item>Any changes you have made to the startup files in <tt>/etc/pcmcia</tt>, or to the PCMCIA startup script. --> <item><tt>/etc/pcmcia</tt> にある起動ファイルや PCMCIA 起動スクリプト に加えて変更全て <!-- <item>All PCMCIA-related messages in your system log file. That includes startup messages, and messages generated when your cards are configured. --> <item>システムのログファイルに記録された PCMCIA に関わる内容全て。 これは起動メッセージとカードの設定時に出力されたメッセージを含みます。 </itemize> <!-- All the PCMCIA modules and the <tt/cardmgr/ daemon send status messages to the system log. This will usually be something like <tt>/var/log/messages</tt> or <tt>/usr/adm/messages</tt>. This file should be the first place to look when tracking down a problem. When submitting a bug report, always include the relevant contents of this file. If you are having trouble finding your system messages, check <tt>/etc/syslog.conf</tt> to see how different classes of messages are handled. --> PCMCIA モジュールと <tt/cardmgr/ デーモンはステータスメッセージを システムログに送ります。システムログは普通、 <tt>/var/log/messages</tt> や <tt>/usr/adm/messages</tt> といった名前 だと思います。問題を調べるときには、このファイルを最初に見るべきです。 バグレポートを送る時にも、このファイルの内容は必ず入れてください。 システムのメッセージが見つからない場合には、<tt>/etc/syslog.conf</tt> を見て、他のクラスのメッセージの出力先を調べてください。 <!-- Before submitting a bug report, please check to make sure that you are using an up-to-date copy of the driver package. While it is somewhat gratifying to read bug reports for things I've already fixed, it isn't a particularly constructive use of my time. --> バグレポートを送る前には、最新のドライバを使っていることを必ず確認して ください。既に直したバグのバグレポートを読むのは嬉しくないことでもない のですが、これはあまり有効な時間の使い方ではありませんから。 <!-- If you do not have web access, bug reports can be sent to me at <tt><htmlurl url="mailto:dhinds@pcmcia.sourceforge.org" name="dhinds@pcmcia.sourceforge.org"></tt>. However, I prefer that bug reports be posted to my web site, so that they can be seen by others. --> WWW にアクセスできなければ、直接私宛( <tt><htmlurl url="mailto:dhinds@pcmcia.sourceforge.org" name="dhinds@pcmcia.sourceforge.org"></tt>) にメールで送ってくださっても構いません。ただし、できればバグレポートは 他の人にも見せられるように、WWW サイトの方に送って欲しいと思っています。 <!-- <sect1>Interpreting kernel trap reports --> <sect1>カーネルのトラップ通知の解釈 <p> <!-- If your problem involves a kernel fault, the register dump from the fault is only useful if you can translate the fault address, EIP, to something meaningful. Recent versions of <tt/klogd/ attempt to translate fault addresses based on the current kernel symbol map, but this may not work if the fault is in a module, or if the problem is severe enough that <tt/klogd/ cannot finish writing the fault information to the system log. --> もしカーネル自身がフォールトする(エラーを起す)場合、あなたが問題となる アドレス、EIP 等から何か意味を読み取れるとしても、レジスタのダンプ情報 しか役に立たないでしょう。最近のバージョンの <tt/klogd/ はフォールトが 起きたアドレスを、現在のカーネルのシンボルマップに基づいて変換しますが、 フォールトがモジュール内で起こった場合や問題が深刻で <tt/klogd/ がフォー ルトの情報をシステムログに書き込めない場合にはこの方法は使えません。 <!-- If a fault is in the main kernel, the fault address can be looked up in the <tt/System.map/ file. This may be installed in <tt>/System.map</tt> or <tt>/boot/System.map</tt>. If a fault is in a module, the <tt/nm/ command gives the same information, however, the fault address has to be adjusted based on the module's load address. Let's say that you have the following kernel fault: --> フォールトがカーネル本体で起こっている場合、フォールトが起きたアドレス は <tt/System.map/ ファイルに残ります。このファイルは <tt>/System.map</tt> か <tt>/boot/System.map</tt> にあると思います。 フォールトがモジュールで起こっている場合には、<tt/nm/ コマンドを使えば 同じ情報が得られますが、フォールトが起きたアドレスはモジュールがロード されたアドレスが基準になっています。例えば、カーネルが以下のような フォールトを起こしたとします: <tscreen><verb> Unable to handle kernel NULL pointer dereference current->tss.cr3 = 014c9000, %cr3 = 014c9000 *pde = 00000000 Oops: 0002 CPU: 0 EIP: 0010:[<c2026081>] EFLAGS: 00010282 </verb></tscreen> <!-- The fault address is 0xc2026081. Looking at <tt/System.map/, we see that this is past the end of the kernel, i.e., is in a kernel module. To determine which module, check the output of ``<tt/ksyms -m | sort/'': --> フォールトが起きたアドレスは 0xc2026081 です。<tt/System.map/ を見ると、 このアドレスはカーネルの最後のアドレスを越えているが分かるでしょう。つ まり、フォールトはカーネルモジュールで起きているのです。どのモジュール でフォールトが起きたのかを調べるために、``<tt/ksyms -m | sort/'' の 出力を調べましょう: <tscreen><verb> Address Symbol Defined by c200d000 (35k) [pcmcia_core] c200d10c register_ss_entry [pcmcia_core] c200d230 unregister_ss_entry [pcmcia_core] ... c2026000 (9k) [3c574_cs] c202a000 (4k) [serial_cs] </verb></tscreen> <!-- So, 0xc2026081 is in the <tt/3c574_cs/ module, and is at an offset of 0x0081 from the start of the module. We cannot look up this offset in <tt/3c574_cs.o/ yet: when the kernel loads a module, it inserts a header at the module load address, so the real start of the module is offset from the address shown in <tt/ksyms/. The size of the header varies with kernel version: to find out the size for your kernel, check a module that exports symbols (like <tt/pcmcia_core/ above), and compare a symbol address with <tt/nm/ output for that symbol. In this example, <tt/register_ss_entry/ is loaded at an offset of 0xc200d10c - 0xc200d000 = 0x010c, while ``<tt/nm pcmcia_core.o/'' shows the offset as 0x00c0, so the header size is 0x010c - 0x00c0 = 0x004c bytes. --> したがって 0xc2026081 は <tt/3c574_cs/ モジュールの内部で、モジュール の先頭からのオフセットが 0x0081 です。<tt/3c574_cs.o/ 内部のこのオフセット 位置を参照する方法は今のところありません。カーネルがモジュールをロード した時、カーネルはモジュールをロードしたアドレスの先頭にヘッダを入れる ので、実際にモジュールが始まる位置は <tt/ksyms/ が示すアドレスから オフセットを取った位置となります。ヘッダの大きさはカーネルのバージョン ごとに異なります。お使いのカーネルでのヘッダの大きさを調べるには、 シンボルをエクスポートしているモジュール(前述の <tt/pcmcia_core/ 等)を 調べ、シンボルいずれかのアドレスをそのシンボルに対する <tt/nm/ コマンド の出力と比較します。この例では、<tt/register_ss_entry/ は 0xc200d10c - 0xc200d000 = 0x010c というオフセット位置にロードされてい ます。ここで ``<tt/nm pcmcia_core.o/'' は 0x00c0 というオフセットを示 していますから、ヘッダの大きさは 0x010c - 0x00c0 = 0x004c ということに なります。 <!-- Back to <tt/3c574_cs/, our fault offset is 0x0081, and subtracting the 0x004c header, the real module offset is 0x0035. Now looking at ``<tt/nm 3c574_cs.o | sort/'', we see: --> <tt/3c574_cs/ の話に戻ると、フォールトが起きたオフセット位置は 0x0081 なので、これからヘッダの大きさである 0x004c を引くと、モジュールの実際 の位置は 0x0035 となります。ここで ``<tt/nm 3c574_cs.o | sort/'' を 実行すると以下のような出力となります: <tscreen><verb> 0000002c d if_names 0000002c t tc574_attach 00000040 d mii_preamble_required 00000041 d dev_info </verb></tscreen> <!-- So, the fault is located in <tt/tc574_attach()/. --> したがって、フォールトが起きた位置は <tt/tc574_attach()/ です。 <!-- In this example, the fault did not cause a total system lockup, so <tt/ksyms/ could be executed after the fault happened. In other cases, you may have to infer the module load addresses indirectly. The same sequence of events will normally load modules in the same order and at the same addresses. If a fault happens when a certain card is inserted, get the <tt/ksyms/ output before inserting the card, or with a different card inserted. You can also manually load the card's driver modules with <tt/insmod/ and run <tt/ksyms/ before inserting the card. --> この例では、フォールトでシステム全体が固まることはないので、フォールト が起きた後に <tt/ksyms/ を実行することもできます。場合によっては、 モジュールがロードされた位置を間接的に推測するしかないこともあります。 同じ順序で操作すれば、普通はモジュールも同じ順序で同じ位置にロードされ ます。特定のカードを挿入した時にフォールトが起こる場合は、そのカードを 挿す直前か、代わりに別のカードを挿した時の <tt/ksyms/ コマンドの出力を 調べましょう。カードを挿す前に手動で <tt/insmod/ でカードのドライバ モジュールをロードし、<tt/ksyms/ コマンドを実行するという方法もありま す。 <!-- For more background, see ``<tt/man insmod/'', ``<tt/man ksyms/'', and ``<tt/man klogd/''. In the kernel source tree, <tt>Documentation/oops-tracing.txt</tt> is also relevant. Here are a few more kernel debugging hints: --> 背景を詳しく知りたければ ``<tt/man insmod/'', ``<tt/man ksyms/'', ``<tt/man klogd/'' を見てください。カーネルのソースコードに入っている <tt>Documentation/oops-tracing.txt</tt> も関連があります。カーネルの デバッグ関連のヒントをいくつか紹介します: <itemize> <!-- <item>Depending on the fault, it may also be useful to translate addresses in the ``Call Trace'', using the same procedure as for the main fault address. --> <item>フォールトの種類によっては、「呼び出しトレース」のアドレスに変換 するのも役立ちます。変換の手順は、普通のフォールトアドレスの場合と同じ です。 <!-- <item>To diagnose a silent lock-up, try to provoke the problem with X disabled, since kernel messages sent to the text console will not be visible under X. --> <item>何もメッセージを出さずにシステムが固まってしまう場合には、X を使 わない状態で問題を再現してみてください。というのも、テキストコンソール に送られるカーネルメッセージは X 上では読めないからです。 <!-- <item>If you kill <tt/klogd/, most kernel messages will be echoed directly on the text console, which may be helpful if the problem prevents <tt/klogd/ from writing to the system log. --> <item><tt/klogd/ を殺してあると、ほとんどのカーネルメッセージは直接 テキストコンソールに表示されます。この方法は、<tt/klogd/ からシステム ログに書き込みができなくなってしまう問題が起きた時に役立ちます。 <!-- <item>To cause all kernel messages to be sent to the console, for 2.1 kernels, if <tt>/proc/sys/kernel/printk</tt> exists, do: --> <item>カーネルのバージョンが 2.1 で、かつ <tt>/proc/sys/kernel/printk</tt> が存在するならば、以下の操作で全ての カーネルメッセージをコンソールに送ることができます: <tscreen><verb> echo 8 > /proc/sys/kernel/printk </verb></tscreen> <!-- <item>The key combination <RightAlt><ScrLk> prints a register dump on the text console. This may work even if the system is otherwise completely unresponsive, and the EIP address can be interpreted as for a kernel fault. --> <item><右Alt><ScrLk> というキーの組合せで、レジスタの ダンプをコンソールに出力することができます。これはシステムが完全に反応 しない状態でも動作するかもしれません。また、EIP アドレスはカーネルフォー ルト用のアドレスに変換されます。 <!-- <item>For 2.1 kernels configured with <tt/CONFIG_MAGIC_SYSRQ/ enabled, various emergency functions are available via special <Alt><SysRq> key combinations, documented in <tt>Documentation/sysrq.txt</tt> in the kernel source tree. --> <item>バージョン 2.1 のカーネルでは[訳注: 2.2 も同様です]、 <tt/CONFIG_MAGIC_SYSRQ/ を有効に してあると、特別な <Alt><SysRq> というキーの組合せで様々な 緊急用機能を使うことができます。この機能については、カーネルのソースツリー に入っている <tt>Documentation/sysrq.txt</tt> をご覧ください。 </itemize> <!-- <sect1>Low level PCMCIA debugging aids<label id="pcdebug"> --> <sect1>PCMCIA の低レベルのデバッグを行うための情報<label id="pcdebug"> <p> <!-- The PCMCIA modules contain a lot of conditionally-compiled debugging code. Most of this code is under control of the <tt/PCMCIA_DEBUG/ preprocessor define. If this is undefined, debugging code will not be compiled. If set to 0, the code is compiled but inactive. Larger numbers specify increasing levels of verbosity. Each module built with <tt/PCMCIA_DEBUG/ defined will have an integer parameter, <tt/pc_debug/, that controls the verbosity of its output. This can be adjusted when the module is loaded, so output can be controlled on a per-module basis without recompiling. --> PCMCIA モジュールにはコンパイル時のオプションで決まるデバッグ用コード がたくさん含まれています。 これらのコードの大部分はプリプロセッサの <tt>PCMCIA_DEBUG</tt> という定義で制御されています。もし <tt>PCMCIA_DEBUG</tt> が未定義ならば、デバッグ用のコードはコンパイルさ れません。もし 0 に定義されていれば、コードはコンパイルされるものの、 利用されません。この数字を大きくすればデバッグメッセージはより細かくな ります。<tt>PCMCIA_DEBUG</tt> を定義してコンパイルした各モジュールには 整数を値に持つ <tt>pc_debug</tt> という変数が設定され、この変数でデバッグ 出力の詳しさを制御できます。この変数はモジュールがロードされる際に設定 できるので、再コンパイルを行わなくてもモジュール別にデバッグ出力を制御 することができます。 <!-- Your default configuration for <tt/syslogd/ may discard kernel debugging messages. To ensure that they are recorded, edit <tt>/etc/syslog.conf</tt> to ensure that ``<tt/kern.debug/'' messages are recorded somewhere. See ``<tt/man syslog.conf/'' for details. --> <tt/syslogd/ のデフォルトの設定は、カーネルのデバッグメッセージを無視 するようになっているかもしれません。これを確実に記録するためには、 <tt>/etc/syslog.conf</tt> を編集して、``<tt/kern.debug/'' クラスの メッセージがどこかに記録されるようにします。詳しくは ``<tt/man syslog.conf/'' をご覧ください。 <!-- There are a few debugging tools in the <tt>debug_tools/</tt> subdirectory of the PCMCIA distribution. The <tt/dump_tcic/ and <tt/dump_i365/ utilities generate complete register dumps of the PCMCIA controllers, and decode a lot of the register information. They are most useful if you have access to a datasheet for the corresponding controller chip. The <tt/dump_cis/ utility (<tt/dump_tuples/ in pre-3.0.2 distributions) lists the contents of a card's CIS (Card Information Structure), and decodes some of the important bits. And the <tt/dump_cisreg/ utility displays a card's local configuration registers. --> PCMCIA パッケージの <tt>debug_tools/</tt> ディレクトリには、デバッグ用 のツールがいくつか入っています。<tt>dump_tcic</tt> と <tt>dump_i365</tt> コマンドは PCMCIA コントローラのレジスタを全て ダンプし、多くのレジスタ情報をデコードします。これらのコントローラ チップのデータシートを参照できるなら、この情報は非常に有効でしょう。 <tt>dump_cis</tt>(バージョン 3.0.2 以前は <tt>dump_tuples</tt>)コマンド は、カードの CIS(Card Information Structure)を出力し、いくつかの重要な ビットをデコードします。<tt>dump_cisreg</tt> コマンドはカードのローカル な設定レジスタを出力します。 <!-- The <tt/memory_cs/ memory card driver is also sometimes useful for debugging problems with 16-bit PC Cards. It can be bound to any card, and does not interfere with other drivers. It can be used to directly access any card's attribute memory or common memory. Similarly for CardBus cards, the <tt/memory_cb/ driver can be bound to any 32-bit card, to give direct access to that card's address spaces. See the man pages for more information. --> メモリカードドライバである <tt>pcmem_cs</tt> も 16 ビット PC カードの デバッグに役立つことがあります。このドライバはどんな PCMCIA カードに対 しても利用でき、他のドライバと干渉することもありません。このドライバを 使えば、どんなカードの属性メモリや共通メモリにも直接アクセスできます。 CardBus カードの場合も同様で、<tt/memory_cb/ ドライバはどんな 32 ビッ トカードに対しても使うことができ、カードのアドレス空間にも直接アクセス することができます。詳しくはオンラインマニュアルを参照してください。 <sect1>/proc/bus/pccard <p> <!-- Starting with 2.1.103 kernels, the PCMCIA package will create a tree of status information under <tt><cdx>/proc/bus/pccard</cdx></tt>. Much of the information can only be interpreted using the data sheets for the PCMCIA host controller. Its contents may depend on how the drivers were configured, but may include all or some of the following: --> バージョン 2.1.103 以降のカーネルでは、PCMCIA パッケージはステータス情報 のツリーを <tt><cdx>/proc/bus/pccard</cdx></tt> ディレクトリ以下に作り ます。この情報の多くは、PCMCIA ホストコントローラのデータシートを使わ ないと意味が分かりません。この内容はドライバの設定によりますが、以下の 情報の全てあるいは一部を含んでいると思います: <descrip> <tag><tt>/proc/bus/pccard/{irq,ioport,memory}</tt></tag> <!-- If present, these files contain resource allocation information to supplement the normal kernel resource tables. Recent versions of the PCMCIA system may obtain additional resource information from the Plug and Play BIOS if configured to do so. --> これらのファイルがある場合には、カーネルの通常のリソーステーブルを補う ためのリソースの割り当て情報が書かれています。最近のバージョンの PCMCIA システムは、(設定がしてあれば)追加のリソース情報をプラグ&プ レイ BIOS からできます。 <tag><tt>/proc/bus/pccard/drivers</tt></tag> <!-- In recent releases, this lists all currently loaded PCMCIA client drivers. Unlike <tt>/proc/modules</tt>, it also lists drivers that may be statically linked into the kernel. --> 最近のリリースでは、このファイルには現在ロードされている PCMCIA クライ アントドライバが列挙されています。<tt>/proc/modules</tt> と異なり、こ のファイルはカーネル内に静的にリンクされているかもしれないドライバも列 挙します。 <tag><tt>/proc/bus/pccard/*/info</tt></tag> <!-- For each socket, describes that socket's host controller and its capabilities. --> それぞれのソケットについて、ソケットのホストコントローラとその機能を示 します。 <tag><tt>/proc/bus/pccard/*/exca</tt></tag> <!-- This contains a dump of a controller's ``ExCA'' Intel i82365sl-compatible register set. --> このファイルには、コントローラの ``ExCA'' Intel i82365sl 互換レジスタ セットのダンプが含まれています。 <tag><tt>/proc/bus/pccard/*/{pci,cardbus}</tt></tag> <!-- For CardBus bridges, a dump of the bridge's PCI configuration space, and a dump of the bridge's CardBus configuration registers. --> CardBus ブリッジについての、ブリッジの PCI 設定空間のダンプと、 ブリッジの CardBus 設定レジスタのダンプが含まれています。 </descrip> <!-- <sect1>Writing Card Services drivers for new cards --> <sect1>出たばかりのカード向けに PCMCIA カードサービスのドライバを書くには <p> <!-- The Linux PCMCIA Programmer's Guide is the best documentation for the client driver interface. The latest version is always available from <tt/sourceforge.org/ in <tt>/pcmcia/doc</tt>, or on the web at <url url="http://pcmcia.sourceforge.org">. --> ``Linux PCMCIA Programmer's Guide'' がクライアントドライバインタフェース に関する最善の文書です。最新版は <tt/sourceforge.org/ の <tt>/pub/pcmcia/doc</tt> ディレクトリにあります。WWW 上では <url url="http://pcmcia.sourceforge.org"> から入手できます。 <!-- For devices that are close relatives of normal ISA devices, you will probably be able to use parts of existing Linux drivers. In some cases, the biggest stumbling block will be modifying an existing driver so that it can handle adding and removing devices after boot time. Of the current drivers, the memory card driver is the only ``self-contained'' driver that does not depend on other parts of the Linux kernel to do most of the dirty work. --> 使いたいデバイスが普通の ISA デバイスによく似ていれば、既存の Linux 用 のドライバの一部を流用することもできるでしょう。場合によっては、既存の ドライバを修正してブート後にもデバイスを追加したり外したりできるように するのがもっとも苦労するところです。今あるドライバの中では、メモリカード 用のドライバが、あらゆる種類の汚れ仕事をするのにカーネルの他の部分を利 用しない、唯一の「自己完結した」ドライバです。 <!-- In many cases, the largest barrier to supporting a new card type is obtaining technical information from the manufacturer. It may be difficult to figure out who to ask, or to explain exactly what information is needed. However, with a few exceptions, it is very difficult if not impossible to implement a driver for a card without technical information from the manufacturer. --> 多くの場合、新しい種類のカードをサポートする際の最大の障害は、メーカー から技術情報を入手することです。誰に頼めばよいかも分かりにくいですし、 どんな情報が必要かを正確に説明するのも困難です。しかし、一部の例外を除 くと、メーカーからの技術情報無しでドライバを書くのは不可能とは行かない までも非常に困難です。 <!-- I have written a dummy driver with lots of comments that explains a lot of how a driver communicates with Card Services; you will find this in the PCMCIA source distribution in <tt>clients/dummy_cs.c</tt>. --> ドライバがカードサービスシステムとどのように通信するかを説明するために、 多数のコメントを入れたダミーのドライバを用意しています。PCMCIA パッケージ のソースコードに入っている <tt>clients/dummy_cs.c</tt> がそれです。 <!-- <sect1>Guidelines for PCMCIA client driver authors --> <sect1>PCMCIA クライアントドライバを書く人のための手引き <p> <!-- I have decided that it is not really feasible for me to distribute all PCMCIA client drivers as part of the PCMCIA package. Each new driver makes the main package incrementally harder to maintain, and including a driver inevitably transfers some of the maintenance work from the driver author to me. Instead, I will decide on a case by case basis whether or not to include contributed drivers, based on user demand as well as maintainability. For drivers not included in the core package, I suggest that driver authors adopt the following scheme for packaging their drivers for distribution. --> 私は、全ての PCMCIA クライアントドライバを PCMCIA パッケージの一部とし て配布するのは本当は適切でないと考えています。新しいドライバが加わるた びに本家のパッケージも段々メンテナンスしにくくなりますし、ドライバを取 り込むとメンテナンス作業の一部がドライバの作者から私へ移ってくるのも明 らかです。そこで全てのドライバを取り込む代わりに、寄付されたドライバは ケースバイケースの判断で取り込むかどうかを決めています。判断はユーザの 要望やメンテナンス性に基づいて行っています。本家のパッケージに取り込ま なかったドライバについては、私はドライバの作者に以下の方法で配布用のド ライバパッケージを作るようにお願いしています。 <!-- Driver files should be arranged in the same directory scheme used in the PCMCIA source distribution, so that the driver can be unpacked on top of a complete PCMCIA source tree. A driver should include source files (in <tt>./modules/</tt>), a man page (in <tt>./man/</tt>), and configuration files (in <tt>./etc/</tt>). The top level directory should also include a README file. --> ドライバファイルは、PCMCIA のソース配布物で使われているのと同じディレクトリ 配置にしなければなりません。これはドライバを PCMCIA ソースツリーのトップ ディレクトリで展開できるようにするためです。ドライバには ソースファイル(<tt>./modules/</tt> ディレクトリ内)、 オンラインマニュアル(<tt>./man/</tt> ディレクトリ内)、 設定ファイル(<tt>./etc/</tt>)が含まれていなければなりません。トップレベル ディレクトリには README ファイルもなければなりません。 <!-- The top-level directory should include a makefile, set up so that ``<tt/make -f .../ all'' and ``<tt/make -f ... install/'' compile the driver and install all appropriate files. If this makefile is given an extension of <tt/.mk/, then it will automatically be invoked by the top-level <tt/Makefile/ for the <tt/all/ and <tt/install/ targets. Here is an example of how such a makefile could be constructed: --> トップレベルディレクトリには makefile が必要で、これは ``<tt/make -f .../ all'' でドライバをコンパイルでき、 ``<tt/make -f ... install/'' で必要なファイルを全てインストールできる ように設定されていなければなりません。この makefile に <tt/.mk/ という 拡張子が付いていれば、このファイルはトップレベルの <tt/Makefile/ から ターゲット <tt/all/ と <tt/install/ について自動的に呼び出されます。 このような makefile の作り方の例を以下に示します: <tscreen><verb> # Sample Makefile for contributed client driver FILES = sample_cs.mk README.sample_cs \ modules/sample_cs.c modules/sample_cs.h \ etc/sample etc/sample.opts man/sample_cs.4 all: $(MAKE) -C modules MODULES=sample_cs.o install: $(MAKE) -C modules install-modules MODULES=sample_cs.o $(MAKE) -C etc install-clients CLIENTS=sample $(MAKE) -C man install-man4 MAN4=sample_cs.4 dist: tar czvf sample_cs.tar.gz $(FILES) </verb></tscreen> <!-- This makefile uses install targets defined in 2.9.10 and later versions of the PCMCIA package. This makefile also includes a ``dist'' target for the convenience of the driver author. You would probably want to add a version number to the final package filename (for example, <tt/sample_cs-1.5.tar.gz/). A complete distribution could look like: --> この makefile では、バージョン 2.9.10 以降の PCMCIA パッケージで定義さ れているインストールターゲットを使っています。この makefile には、 ドライバ作者の利便のための ``dist'' ターゲットも入っています。最終的な パッケージのファイル名にはバージョン番号も入れるとよいでしょう( <tt/sample_cs-1.5.tar.gz/ 等)。完成品の配布ファイルの内容は以下のよう になります: <tscreen><verb> sample_cs.mk README.sample_cs modules/sample_cs.c modules/sample_cs.h etc/sample etc/sample.opts man/sample_cs.4 </verb></tscreen> <!-- With this arrangement, when the contributed driver is unpacked, it becomes essentially part of the PCMCIA source tree. It can make use of the PCMCIA header files, as well as the machinery for checking the user's system configuration, and automatic dependency checking, just like a ``normal'' client driver. --> このファイル配置であれば、寄付されたドライバのパッケージを展開した時に、 実質的に PCMCIA のソースツリーの一部となります。PCMCIA のヘッダファイル やユーザのシステム設定を調べる仕組みの利用、ファイルの依存関係の自動チェック を「通常の」クライアントドライバと同じように行うことができます。 <!-- I will accept client drivers prepared according to this specification and place them in the <tt>/pcmcia/contrib</tt> directory on <tt/sourceforge.org/. The README in this directory will describe how to unpack a contributed driver. --> 私はこの仕様に準拠しているクライアントドライバを受け取れば、 <tt/sourceforge.org/ の <tt>/pcmcia/contrib</tt> ディレクトリに置きま す。このディレクトリにある README ファイルに、寄付されたドライバの 展開方法が書いてあります。 <!-- The client driver interface has not changed much over time, and has almost always preserved backwards compatibility. A client driver will not normally need to be updated for minor revisions in the main package. I will try to notify authors of contributed drivers of changes that require updates to their drivers. --> クライアントドライバのインタフェースは昔からあまり変わっていませんし、 後方互換性はほぼ保たれています。本家のパッケージのマイナーバージョンが 上がっても普通は更新の必要はないでしょう。ドライバの更新が必要となるよ うな変更があれば、ドライバを寄付してくださった作者の方々にはできるだけ お知らせするようにします。 <!-- <sect1>Guidelines for Linux distribution maintainers --> <sect1>Linux ディストリビューションのメンテナのための手引き <p> <!-- If your distribution has system configuration tools that you would like to be PCMCIA-aware, please use the <tt>*.opts</tt> files in <tt>/etc/pcmcia</tt> for your ``hooks.'' These files will not be modified if a user compiles and installs a new release of the PCMCIA package. If you modify the main configuration scripts, then a fresh install will silently overwrite your custom scripts and break the connection with your configuration tools. Contact me if you are not sure how to write an appropriate option script, or if you need additional capabilities. --> あなたが作っているディストリビューションのシステム設定ツールを PCMCIA 対応にしようとしているのなら、<tt>/etc/pcmcia</tt> にある <tt>*.opts</tt> ファイルを「止め具」として使ってください。これらの ファイルは、ユーザが新しいバージョンの PCMCIA パッケージのコンパイルと インストールを行っても変更されません。メインの設定スクリプトを修正する と、最初からのインストールを行った時にカスタマイズしたスクリプトが黙っ て上書きされ、設定ツールとの連係が途切れてしまいます。適切なオプション スクリプトの書き方が分からない場合や、追加の機能が必要な場合は、私に相 談してください。 <!-- It is helpful for users (and for me) if you can document how your distribution deviates from the PCMCIA package as described in this document. In particular, please document changes to the startup script and configuration scripts. If you send me the appropriate information, I will include it in the <ref id="distributions" name="Notes about specific Linux distributions">. --> あなたのディストリビューションとこの文書で説明している PCMCIA パッケージ の相違点を文書化してくだされば、ユーザにとって(そして私にとっても)役立 つでしょう。特に、起動スクリプトと設定スクリプトに関する変更点はぜひ 文書化してください。適切な情報を私まで送っていただければ、 <ref id="distributions" name="個別ディストリビューションに関する注意"> の節に追加させていただきます。 <!-- When building PCMCIA for distribution, consider including contributed drivers that are not part of the main PCMCIA package. For reasons of maintainability, I am trying to limit the core package size, by only adding new drivers if I think they are of particularly broad interest. Other drivers will be distributed separately, as described in the previous section. The split between integral and separate drivers is somewhat arbitrary and partly historical, and should not imply a difference in quality. --> ディストリビューション用に PCMCIA パッケージを作る際には、寄付された ドライバ群は本家の PCMCIA パッケージの一部ではない点を覚えていてくださ い。メンテナンス上の理由により中心となるパッケージのサイズは制限しよう としており、新しいドライバを追加するのは特に需要が高いと思われるときだ けです。その他のドライバについては前の章で説明した通り、本家とは別に配 布しています。本家に統合されているドライバと別配布になっているドライバ の違いにはたいした意味はなく、歴史的経緯もある程度含まれています。また、 品質的な違いがあるわけでは決してありません。 <sect>日本語訳について<p> 日本語訳は Linux Japanese FAQ Project が行いました。 翻訳に関するご意見は JF プロジェクト <JF@linux.or.jp> 宛に連絡してください。 改訂履歴を以下に示します。 <descrip> <tag>v1.84j, 10 June 1996</tag> 翻訳: 小島 三弘(<htmlurl url="mailto:kojima@linet.gr.jp" name="kojima@linet.gr.jp">), 播口 陽一(<htmlurl url="mailto:hariguti@lsidiv.kawasaki-steel.co.jp" name="hariguti@lsidiv.kawasaki-steel.co.jp">) <tag>v2.32j, 26 July 1999</tag> 更新: 藤原 輝嘉(<htmlurl url="mailto:fujiwara@linux.or.jp" name="fujiwara@linux.or.jp">), 校正: 武井 伸光(<htmlurl url="mailto:takei@cc.kochi-u.ac.jp" name="takei@cc.kochi-u.ac.jp">) <tag>v2.46j, 18 December 1999</tag> 更新: 藤原 輝嘉(<htmlurl url="mailto:fujiwara@linux.or.jp" name="fujiwara@linux.or.jp">), </descrip> </article>