
Ubuntu日本語フォーラム

ログインしていません。
さて、ソニー製PCV-J15 メモリ128MB+256MB windowsXP3とubuntu10.04のデァルブートしていますが、LAN-W300N/U2が使用できない。ubuntu Magazine vol04に記載があるのですが、うまくいきません
どうすればうまくできるのでしょうか
オフライン
yasushi04 による投稿:
LAN-W300N/U2が使用できない。ubuntu Magazine vol04に記載があるのですが、うまくいきません
どうすればうまくできるのでしょうか
なにか試したこと、調べたことがある場合は、その内容をできるだけ詳細に投稿いただけると解決に近づき易くなるかと思います。
とりあえずは、上記に加え、
LAN-W300N/U2をPCに装着し、
画面上部のパネルから、アプリケーション->アクセサリ->端末を開いて、
$ lsusb
$ ifconfig
$ iwconfig
$ lsmod
した結果を投稿してみて下さい。
オフライン
僕の友人も同じことで悩んでいます.
見てみると,どうやらUbuntu Magazineの記事(43頁)で,makeするところの真ん中あたりで,「build」と「M」の間のスペースが抜けて,くっついているようです.
ここにスペースを入れてやってみてください.
あと,環境によりディレクトリ名が微妙に違う(たとえば記事では「/lib/modules/2.6.32-22-generic-pae」なのが,うちでは「/lib/modules/2.6.32-22-generic」だったり)ので,そこら辺が要注意と思います.
オフライン
LAN-W300N/U2がubuntu10.04で認識できない。
yasushi@yasushi-desktop:~$ lsusb
Bus 007 Device 002: ID 04b8:082f Seiko Epson Corp. Stylus DX4050
Bus 007 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 006 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 002 Device 006: ID 04bb:0c45 I-O Data Device, Inc.
Bus 002 Device 005: ID 1307:0163 Transcend Information, Inc. 512MB/1GB Flash Drive
Bus 002 Device 003: ID 0409:005a NEC Corp. HighSpeed Hub
Bus 002 Device 002: ID 04bb:020d I-O Data Device, Inc.
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 003: ID 0789:0166 Logitec Corp.
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
yasushi@yasushi-desktop:~$ ifconfig
eth0 Link encap:イーサネット ハードウェアアドレス 00:07:40:8f:dc:73
inetアドレス:192.168.2.101 ブロードキャスト:192.168.2.255 マスク:255.255.255.0
inet6アドレス: fe80::207:40ff:fe8f:dc73/64 範囲:リンク
UP BROADCAST RUNNING MULTICAST MTU:1500 メトリック:1
RXパケット:13 エラー:0 損失:0 オーバラン:0 フレーム:0
TXパケット:32 エラー:0 損失:0 オーバラン:0 キャリア:0
衝突(Collisions):0 TXキュー長:1000
RXバイト:2412 (2.4 KB) TXバイト:5189 (5.1 KB)
割り込み:10 ベースアドレス:0xb400
lo Link encap:ローカルループバック
inetアドレス:127.0.0.1 マスク:255.0.0.0
inet6アドレス: ::1/128 範囲:ホスト
UP LOOPBACK RUNNING MTU:16436 メトリック:1
RXパケット:74 エラー:0 損失:0 オーバラン:0 フレーム:0
TXパケット:74 エラー:0 損失:0 オーバラン:0 キャリア:0
衝突(Collisions):0 TXキュー長:0
RXバイト:8475 (8.4 KB) TXバイト:8475 (8.4 KB)
yasushi@yasushi-desktop:~$ iwconfig
lo no wireless extensions.
eth0 no wireless extensions.
yasushi@yasushi-desktop:~$ lsmod
Module Size Used by
nls_iso8859_1 3249 1
nls_cp437 4919 1
vfat 8933 1
fat 47767 1 vfat
sis 4640 2
drm 162377 3 sis
sisfb 232419 1 sis
binfmt_misc 6587 1
snd_cmipci 30437 2
gameport 9089 1 snd_cmipci
snd_pcm_oss 35308 0
snd_mixer_oss 13746 1 snd_pcm_oss
snd_pcm 70662 2 snd_cmipci,snd_pcm_oss
snd_page_alloc 7076 1 snd_pcm
snd_opl3_lib 8966 1 snd_cmipci
snd_hwdep 5412 1 snd_opl3_lib
snd_mpu401_uart 5617 1 snd_cmipci
snd_seq_dummy 1338 0
snd_seq_oss 26726 0
snd_seq_midi 4557 0
snd_rawmidi 19056 2 snd_mpu401_uart,snd_seq_midi
snd_seq_midi_event 6003 2 snd_seq_oss,snd_seq_midi
snd_seq 47263 6 snd_seq_dummy,snd_seq_oss,snd_seq_midi,snd_seq_midi_event
snd_timer 19098 3 snd_pcm,snd_opl3_lib,snd_seq
fbcon 35102 71
tileblit 2031 1 fbcon
snd_seq_device 5700 6 snd_opl3_lib,snd_seq_dummy,snd_seq_oss,snd_seq_midi,snd_rawmidi,snd_seq
font 7557 1 fbcon
bitblit 4707 1 fbcon
uvcvideo 56990 0
softcursor 1189 1 bitblit
ppdev 5259 0
sis_agp 4047 1
lp 7028 0
snd 54148 16 snd_cmipci,snd_pcm_oss,snd_mixer_oss,snd_pcm,snd_opl3_lib,snd_hwdep,snd_mpu401_uart,snd_seq_oss,snd_rawmidi,snd_seq,snd_timer,snd_seq_device
vga16fb 11385 1
psmouse 63245 0
videodev 34361 1 uvcvideo
parport_pc 25962 1
vgastate 8961 1 vga16fb
usblp 10481 0
v4l1_compat 13251 2 uvcvideo,videodev
serio_raw 3978 0
i2c_sis630 4757 0
agpgart 31724 2 drm,sis_agp
shpchp 28820 0
soundcore 6620 1 snd
parport 32635 3 ppdev,lp,parport_pc
ohci1394 26950 0
usb_storage 39425 1
8139too 18545 0
ieee1394 81181 1 ohci1394
8139cp 16186 0
floppy 53016 0
mii 4381 2 8139too,8139cp
yasushi@yasushi-desktop:~$
Ubuntu 10.04LTS 日本語Remix CD でインストールしてますが、デスクトップ上には、無線アイコンの表示がありません。
ためしに、GWーUSMicroNで無線LANの接続をやると追加できないエラーが発生しています。
オフライン
Ubuntu Magazineの記事(43頁)で,makeで次のエラーが発生しました。
yasushi@yasushi-desktop:~$ sudo gedit
yasushi@yasushi-desktop:~$ sudo gedit
yasushi@yasushi-desktop:~$ sudo make -C /lib/modules/2.6.32-22-generic-pae/build M=/usr/src/linux-source2.6.32/drivers/staging/rt2870 modules
make: *** /lib/modules/2.6.32-22-generic-pae/build: No such file or directory. 中止.
yasushi@yasushi-desktop:~$ sudo make -C /lib/modules/2.6.32-22-generic-pae/buildM=/usr/src/linux-source2.6.32/drivers/staging/rt2870 modules
make: *** /lib/modules/2.6.32-22-generic-pae/buildM=/usr/src/linux-source2.6.32/drivers/staging/rt2870: No such file or directory. 中止.
yasushi@yasushi-desktop:~$ sudo make -C /lib/modules/2.6.32-22-generic-pae/buildM=/usr/src/linux-source2.6.32/drivers/staging/rt2870 modules
make: *** /lib/modules/2.6.32-22-generic-pae/buildM=/usr/src/linux-source2.6.32/drivers/staging/rt2870: No such file or directory. 中止.
yasushi@yasushi-desktop:~$
なお、関係ないと思われますが、Ubuntuソフトウェアからソフトのインストールが不可能となっています。
現在、パソコンは、ソニー製 PCVーJ15 HDD80GB WindowsXP SP3 Ubuntu 9.10LST Ubuntu9.10のの三つで利用しています。なお。ubuntu9.10からアップグレードに失敗しました。そのため、Ubuntu10.04 ubuntu9.10の順で再インストールしております。 なお、ubuntu9.10では。GWーUSMicroNを認識し、インターネットに接続ができます。
オフライン
USBデバイスのIDが
0789:0162
0789:0163
0789:0164
あたりなら自動でドライバを読み込んでくれたっぽいのですが、
0789:0166
はダメっぽいですね。
yasushi04 による投稿:
Ubuntu Magazineの記事(43頁)で,makeで次のエラーが発生しました。
yasushi@yasushi-desktop:~$ sudo make -C /lib/modules/2.6.32-22-generic-pae/build M=/usr/src/linux-source2.6.32/drivers/staging/rt2870 modules
make: *** /lib/modules/2.6.32-22-generic-pae/build: No such file or directory. 中止.
yasushi@yasushi-desktop:~$ sudo make -C /lib/modules/2.6.32-22-generic-pae/buildM=/usr/src/linux-source2.6.32/drivers/staging/rt2870 modules
make: *** /lib/modules/2.6.32-22-generic-pae/buildM=/usr/src/linux-source2.6.32/drivers/staging/rt2870: No such file or directory. 中止.
yasushi@yasushi-desktop:~$ sudo make -C /lib/modules/2.6.32-22-generic-pae/buildM=/usr/src/linux-source2.6.32/drivers/staging/rt2870 modules
make: *** /lib/modules/2.6.32-22-generic-pae/buildM=/usr/src/linux-source2.6.32/drivers/staging/rt2870: No such file or directory. 中止.
yasushi@yasushi-desktop:~$
あたりはデバイスIDを追記して、ドライバ(カーネルモジュール)を再構築する手順の一部だと思われますが、エラーの発生原因についてはDemmieさんが下記にご指摘のように、
1.buildとMの間の空白が抜けている
2.カーネルのタイプ、バージョンの相違
であるように思われます。
Demmie による投稿:
見てみると,どうやらUbuntu Magazineの記事(43頁)で,makeするところの真ん中あたりで,「build」と「M」の間のスペースが抜けて,くっついているようです.
ここにスペースを入れてやってみてください.
あと,環境によりディレクトリ名が微妙に違う(たとえば記事では「/lib/modules/2.6.32-22-generic-pae」なのが,うちでは「/lib/modules/2.6.32-22-generic」だったり)ので,そこら辺が要注意と思います.
make: *** /lib/modules/2.6.32-22-generic-pae/build: No such file or directory. 中止.
とありますので、端末上で、
$ ls /lib/modules
して表示されるディレクトリのうち、一番数字の大きいものに読み替えて以降を実行してみてください。
なお、makeにいたるまでの過程が判りませんが、そこにいたるまでの手順に問題があれば、この部分は解決しても問題解決には至らないと思われますので、うまくいかない場合は実施した手順を最初からできるだけ詳細に投稿いただければと思います。
オフライン
yasushi@yasushi-desktop:~$ ls /lib/modules
2.6.32-21-generic 2.6.32-23-generic
yasushi@yasushi-desktop:~$
yasushi@yasushi-desktop:/usr/src$ lsusb
Bus 007 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 006 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 002 Device 006: ID 04bb:0c45 I-O Data Device, Inc.
Bus 002 Device 005: ID 1307:0163 Transcend Information, Inc. 512MB/1GB Flash Drive
Bus 002 Device 004: ID 1307:0165 Transcend Information, Inc. 2GB/4GB Flash Drive
Bus 002 Device 003: ID 0409:005a NEC Corp. HighSpeed Hub
Bus 002 Device 002: ID 04bb:020d I-O Data Device, Inc.
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 002: ID 2019:ed14 PLANEX
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
yasushi@yasushi-desktop:/usr/src$ cd linux-source-2.6.32
yasushi@yasushi-desktop:/usr/src/linux-source-2.6.32$ cd drivers
yasushi@yasushi-desktop:/usr/src/linux-source-2.6.32/drivers$ cd stag-ing
bash: cd: stag-ing: No such file or directory
yasushi@yasushi-desktop:/usr/src/linux-source-2.6.32/drivers$ cd staing
bash: cd: staing: No such file or directory
yasushi@yasushi-desktop:/usr/src/linux-source-2.6.32/drivers$ staging
staging: command not found
yasushi@yasushi-desktop:/usr/src/linux-source-2.6.32/drivers$ dir
Kconfig cpufreq ide mfd pps tc
Makefile cpuidle idle misc ps3 telephony
accessibility crypto ieee1394 mmc rapidio thermal
acpi dca ieee802154 mtd regulator uio
amba dio infiniband net rtc usb
ata dma input nubus s390 uwb
atm edac isdn of sbus video
auxdisplay eisa leds oprofile scsi virtio
base firewire lguest parisc serial vlynq
block firmware macintosh parport sfi w1
bluetooth gpio mca pci sh watchdog
cdrom gpu md pcmcia sn xen
char hid media platform spi zorro
clocksource hwmon memstick pnp ssb
connector i2c message power staging
yasushi@yasushi-desktop:/usr/src/linux-source-2.6.32/drivers$ cd staging
yasushi@yasushi-desktop:/usr/src/linux-source-2.6.32/drivers/staging$ cd rt2870yasushi@yasushi-desktop:/usr/src/linux-source-2.6.32/drivers/staging/rt2870$ sudo gedit 2870_main_dev.c
yasushi@yasushi-desktop:/usr/src/linux-source-2.6.32/drivers/staging/rt2870$ cd /usr/src
yasushi@yasushi-desktop:/usr/src$ sudo make -c /lib/modules/2.6.32-23-generic-pae/buildM=/usr/src/linux-source2.6.32/drivers/staging/rt2870 modules
make: invalid option -- 'c'
使い方: make [オプション] [ターゲット] ...
オプション:
-b, -m 互換性のためのもので, 無視される.
-B, --always-make 無条件に全ターゲットを make する.
-C DIRECTORY, --directory=DIRECTORY
make 開始前にディレクトリ DIRECTORY へ移動する.
-d デバッグ情報を大量に表示する.
--debug[=FLAGS] 様々なタイプのデバッグ情報を表示する.
-e, --environment-overrides
環境変数が makefile 中の記述に優先する
-f FILE, --file=FILE, --makefile=FILE
FILE を makefile として読み込む
-h, --help このメッセージを表示して終了する.
-i, --ignore-errors コマンドから返されたエラーを無視する.
-I DIRECTORY, --include-dir=DIRECTORY
Search DIRECTORY for included makefiles.
インクルードする makefile を探索する DIRECTORY.
-j [N], --jobs[=N] 一度に N 個までのジョブを許可; 無引数だとジョブ数制限なし.
-k, --keep-going あるターゲットが make できなくても実行を続ける.
-l [N], --load-average[=N], --max-load[=N]
負荷 が N 未満でない限り複数のジョブを開始しない.
-L, --check-symlink-times Use the latest mtime between symlinks and target.
-n, --just-print, --dry-run, --recon
コマンドを実際に実行しない; 表示するのみ.
-o FILE, --old-file=FILE, --assume-old=FILE
FILE をとても古いものと見なして, 再 make しない.
-p, --print-data-base make の内部データベースを表示する.
-q, --question コマンドを実行しない; 更新済であるかどうかを終了ステータスで通知.
-r, --no-builtin-rules ビルトインの暗黙ルールを無効にする.
-R, --no-builtin-variables ビルトインの変数設定を無効にする.
-s, --silent, --quiet コマンド表示をエコーしない.
-S, --no-keep-going, --stop
-k オプションをオフにする.
-t, --touch ターゲットを再 make する代わりにタッチする.
-v, --version make のバージョン番号を表示して終了する.
-w, --print-directory カレントディレクトリを表示する.
--no-print-directory -w をオフにする. 暗黙に有効な場合でもオフにする.
-W FILE, --what-if=FILE, --new-file=FILE, --assume-new=FILE
FILE をいつでも最新として見なす.
--warn-undefined-variables 未定義の変数が参照されたときに警告を発する.
このプログラムは i486-pc-linux-gnu 用にビルドされました
バグレポートは <[email protected]> まで.
yasushi@yasushi-desktop:/usr/src$ cd /usr/src sudo make -c /lib/modules/2.6.32-23-generic-pae/build M=/usr/src/linux-source2.6.32/drivers/staging/rt2870 modules
yasushi@yasushi-desktop:/usr/src$
yasushi@yasushi-desktop:/usr/src$ cd /usr/src sudo make -c /lib/modules/2.6.32-23-generic-pae/build M=/usr/src/linux-source2.6.32/drivers/staging/rt2870 modules
yasushi@yasushi-desktop:/usr/src$ cd /usr/src sudo make -c /lib/modules/2.6.32-23-generic-pae/buildM=/usr/src/linux-source2.6.32/drivers/staging/rt2870 modules
yasushi@yasushi-desktop:/usr/src$ cd /usr/src sudo make -c /lib/modules/2.6.32-23-generic-pae/buildM=/usr/src/linux-source2.6.32/drivers/staging/rt2870 modules
yasushi@yasushi-desktop:/usr/src$
このような形担っています。
差し込みすれば認識できるGWーUSMicroNをubuntu10.04でも自動で認識せず。
無線LAN設定で、設定をしようとしていますが、ubuntu10.04が無線接続の追加設定に失敗しました。というエラーが発生します。
現在 WindowsXP SP3(無線LANは、LANーW300N/Uを使用, Ubuntu10.04(新規インストール),ubuntu9.10(無線LAN子機はGWーUSMicroNを利用しています。)
面倒くさいですが、パーテションの一部をデーター領域としてFAT32で各OSからアクセスできるように設定しています。
ubuntu9.10からubuntu10.04アップグレードしてもGWーUSMicroNは、自動認識せず。
オフライン
僕の友人のケースはうまくコンパイルできたようなので,頑張ってみてください.
yasushi@yasushi-desktop:/usr/src$ sudo make -c /lib/modules/2.6.32-23-generic-pae/build M=/usr/src/linux-source2.6.32/drivers/staging/rt2870 modules
のところで,
1)「make -c」の「c」は大文字の「C」が正しいようなので,直してみてください.
2)「/lib/modules/2.6.32-23-generic-pae」というディレクトリは実在しますか?
たとえば,「/lib/modules/2.6」あたりまでタイプしてTABキーを3回くらい押したときに,どのように補完されますか?
オフライン
あ,それから
yasushi@yasushi-desktop:/usr/src$ cd /usr/src sudo make -c /lib/modules/2.6.32-23-generic-pae/buildM=/usr/src/linux-source2.6.32/drivers/staging/rt2870 modules
は,頭の「cd /usr/src」は余計なので,消した方が良いと思います.
オフライン
/lib/modules/2.6.32-23-generic-pae のディレクトリがありません。隠しファイルの表示をさせても見つかりません
オフライン
sudo make -C /lib/modules/$(uname -r)/build M=/usr/src/linux-source-2.6.32/drivers/staging/rt2870 modules
オフライン
さて、jackalope様からいただいたコード次のようになりました
yasushi@yasushi-desktop:~$ sudo make -C /lib/modules/$(uname -r)/build M=/usr/src/linux-source-2.6.32/drivers/staging/rt2870 modules
make: ディレクトリ `/usr/src/linux-headers-2.6.32-24-generic' に入ります
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/md5.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/mlme.o
In file included from /usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/mlme.c:1:
/usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/../../rt2860/common/mlme.c: In function ‘BssTableSortByRssi’:
/usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/../../rt2860/common/mlme.c:4094: warning: the frame size of 1572 bytes is larger than 1024 bytes
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/rtmp_wep.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/action.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/cmm_data.o
In file included from /usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/cmm_data.c:1:
/usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/../../rt2860/common/cmm_data.c: In function ‘deaggregate_AMSDU_announce’:
/usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/../../rt2860/common/cmm_data.c:2015: warning: ‘return’ with no value, in function returning non-void
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/rtmp_init.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/rtmp_tkip.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/cmm_sync.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/eeprom.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/cmm_sanity.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/cmm_info.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/cmm_wpa.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/dfs.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/spectrum.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta/assoc.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta/aironet.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta/auth.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta/auth_rsp.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta/sync.o
In file included from /usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta/sync.c:1:
/usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta/../../rt2860/sta/sync.c: In function ‘PeerBeacon’:
/usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta/../../rt2860/sta/sync.c:1607: warning: the frame size of 1312 bytes is larger than 1024 bytes
/usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta/../../rt2860/sta/sync.c: In function ‘PeerBeaconAtJoinAction’:
/usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta/../../rt2860/sta/sync.c:940: warning: the frame size of 1252 bytes is larger than 1024 bytes
/usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta/../../rt2860/sta/sync.c: In function ‘PeerBeaconAtScanAction’:
/usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta/../../rt2860/sta/sync.c:695: warning: the frame size of 1256 bytes is larger than 1024 bytes
/usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta/../../rt2860/sta/sync.c: In function ‘MlmeStartReqAction’:
/usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta/../../rt2860/sta/sync.c:567: warning: the frame size of 1064 bytes is larger than 1024 bytes
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta/sanity.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta/rtmp_data.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta/connect.o
In file included from /usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta/connect.c:1:
/usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta/../../rt2860/sta/connect.c: In function ‘CntlOidScanProc’:
/usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta/../../rt2860/sta/connect.c:325: warning: the frame size of 1600 bytes is larger than 1024 bytes
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta/wpa.o
In file included from /usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta/wpa.c:1:
/usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta/../../rt2860/sta/wpa.c: In function ‘CCKMPRF’:
/usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta/../../rt2860/sta/wpa.c:1846: warning: the frame size of 1044 bytes is larger than 1024 bytes
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/rt_linux.o
In file included from /usr/src/linux-source-2.6.32/drivers/staging/rt2870/rt_linux.c:1:
/usr/src/linux-source-2.6.32/drivers/staging/rt2870/../rt2860/rt_linux.c: In function ‘send_monitor_packets’:
/usr/src/linux-source-2.6.32/drivers/staging/rt2870/../rt2860/rt_linux.c:973: warning: the frame size of 1084 bytes is larger than 1024 bytes
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/rt_profile.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/rt_main_dev.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta_ioctl.o
In file included from /usr/src/linux-source-2.6.32/drivers/staging/rt2870/sta_ioctl.c:1:
/usr/src/linux-source-2.6.32/drivers/staging/rt2870/../rt2860/sta_ioctl.c: In function ‘rt_ioctl_iwaplist’:
/usr/src/linux-source-2.6.32/drivers/staging/rt2870/../rt2860/sta_ioctl.c:834: warning: the frame size of 1288 bytes is larger than 1024 bytes
/usr/src/linux-source-2.6.32/drivers/staging/rt2870/../rt2860/sta_ioctl.c: In function ‘rt_ioctl_siwmlme’:
/usr/src/linux-source-2.6.32/drivers/staging/rt2870/../rt2860/sta_ioctl.c:1899: warning: the frame size of 1584 bytes is larger than 1024 bytes
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/ba_action.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/2870_main_dev.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/2870_rtmp_init.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/rtusb_io.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/rtusb_bulk.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/rtusb_data.o
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/common/cmm_data_2870.o
LD [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/rt2870sta.o
Building modules, stage 2.
MODPOST 1 modules
WARNING: modpost: Found 1 section mismatch(es).
To see full details build your kernel with:
'make CONFIG_DEBUG_SECTION_MISMATCH=y'
CC /usr/src/linux-source-2.6.32/drivers/staging/rt2870/rt2870sta.mod.o
LD [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/rt2870sta.ko
make: ディレクトリ `/usr/src/linux-headers-2.6.32-24-generic' から出ます
yasushi@yasushi-desktop:~$
この後どうすればいいのでしょうか。はやく LANーW300N/U2が使用できればうれしいですが、
(追伸一ヶ月ほどほったかしにしていましたが、東北地方北部が、最高気温が30度以上の日が連続したため。パソコンの使用を控えていました。家にエアコンもないので、)
オフライン
#11は#5の「Ubuntu Magazineの記事(43頁)で,makeで次のエラーが発生しました。」の問題解決策で、#12の投稿内容ではmakeのエラーは解消されています。
yasushi04さん による投稿:
この後どうすればいいのでしょうか。
私は、Ubuntu Magazine vol04を所有していませんので質問にはお答えできません。
オフライン
雑誌には、元のドライバをバックアップとして
cd /lib/modules/2.6.32-22-generic-pae/kernel/drivers/staging/rt2870 エンタキー
sudo mv rt2870sta.ko rt2870sta.ko.org
と書いてありますが、cd /lib/modules/2.6.32-24-generic/kernel/drivers/staging/rt2870 エンタキー
sudo mv rt2870sta.ko rt2870sta.ko.org
に修正しましたが、うまくいきませんでした。
新しいドライバをコピー
sudo cp /usr/src/linux-source-2.6.32/drivers/staging/rt2870/rt2870sta.ko .エンタキー
雑誌の次は、Ralinkからドライバーをダウンロードし、「RT2870STA.dat」をホームフォルダへコピー
ディレクトリーの作成
sudo mkdir -p /etc/Wireless/RT3070STA エンタキー
ファイルのコピー
sudo cp ~/RT2870STA.dat /etc/Wireless?RT3070STA/RT3070STA.dat エンタキー
となっていますが、うまくいきません
オフライン
modinfo rt2870sta | grep 0789の結果をお知らせ下さい。
オフライン
jackalope様 modinfo rt2870sta | grep 0789の結果をお知らせいたします。
yasushi@yasushi-desktop:~$ modinfo rt2870sta | grep 0789
alias: usb:v0789p0164d*dc*dsc*dp*ic*isc*ip*
alias: usb:v0789p0163d*dc*dsc*dp*ic*isc*ip*
alias: usb:v0789p0162d*dc*dsc*dp*ic*isc*ip*
yasushi@yasushi-desktop:~$
オフライン
LAN-W300N/U2のID、0789,0166がありませんので、ドライバー作成作業で間違いをしています。
ドライバーの作成をやり直して下さい。
オフライン
Yasushi04 による投稿:
と書いてありますが、cd /lib/modules/2.6.32-24-generic/kernel/drivers/staging/rt2870 エンタキー
sudo mv rt2870sta.ko rt2870sta.ko.org
に修正しましたが、うまくいきませんでした。
とありますが,具体的にどううまくいかないんでしょう?
上記の場合,ファイル名の変更ができなかったのでしょうか?
それとも,もともとrt2870sta.koというファイルが存在しなかったのでしょうか?
make自体はうまくいってる感じなので,もうひといきだと思います.
ここまできたら,「動きました!」っていう報告を聞きたいです.
オフライン
こんがらってきたので、ドライバの作成
/usr/src/linux-source-2.6.32/drivers/staging/rt2870/2870_main_dev.cのファイル内容
*
*************************************************************************
* Ralink Tech Inc.
* 5F., No.36, Taiyuan St., Jhubei City,
* Hsinchu County 302,
* Taiwan, R.O.C.
*
* (c) Copyright 2002-2007, Ralink Technology, Inc.
*
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
* This program is distributed in the hope that it will be useful, *
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
* GNU General Public License for more details. *
* *
* You should have received a copy of the GNU General Public License *
* along with this program; if not, write to the *
* Free Software Foundation, Inc., *
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
* *
*************************************************************************
Module Name:
rtmp_main.c
Abstract:
main initialization routines
Revision History:
Who When What
-------- ---------- ----------------------------------------------
Name Date Modification logs
Jan Lee 01-10-2005 modified
Sample Jun/01/07 Merge RT2870 and RT2860 drivers.
*/
#include "rt_config.h"
// Following information will be show when you run 'modinfo'
// *** If you have a solution for the bug in current version of driver, please mail to me.
// Otherwise post to forum in ralinktech's web site(www.ralinktech.com) and let all users help you. ***
MODULE_AUTHOR("Paul Lin <[email protected]>");
MODULE_DESCRIPTION(RT28xx_CHIP_NAME " Wireless LAN Linux Driver");
MODULE_LICENSE("GPL");
#ifdef MODULE_VERSION
MODULE_VERSION(STA_DRIVER_VERSION);
#endif
MODULE_ALIAS("rt3070sta");
/* Kernel thread and vars, which handles packets that are completed. Only
* packets that have a "complete" function are sent here. This way, the
* completion is run out of kernel context, and doesn't block the rest of
* the stack. */
extern INT __devinit rt28xx_probe(IN void *_dev_p, IN void *_dev_id_p,
IN UINT argc, OUT PRTMP_ADAPTER *ppAd);
struct usb_device_id rtusb_usb_id[] = {
{ USB_DEVICE(0x148F, 0x2770) }, /* Ralink */
{ USB_DEVICE(0x1737, 0x0071) }, /* Linksys WUSB600N */
{ USB_DEVICE(0x1737, 0x0070) }, /* Linksys */
{ USB_DEVICE(0x148F, 0x2870) }, /* Ralink */
{ USB_DEVICE(0x148F, 0x3070) }, /* Ralink 3070 */
{ USB_DEVICE(0x148F, 0x3071) }, /* Ralink 3071 */
{ USB_DEVICE(0x148F, 0x3072) }, /* Ralink 3072 */
{ USB_DEVICE(0x0B05, 0x1731) }, /* Asus */
{ USB_DEVICE(0x0B05, 0x1732) }, /* Asus */
{ USB_DEVICE(0x0B05, 0x1742) }, /* Asus */
{ USB_DEVICE(0x0DF6, 0x0017) }, /* Sitecom */
{ USB_DEVICE(0x0DF6, 0x002B) }, /* Sitecom */
{ USB_DEVICE(0x0DF6, 0x002C) }, /* Sitecom */
{ USB_DEVICE(0x0DF6, 0x003E) }, /* Sitecom 3070 */
{ USB_DEVICE(0x0DF6, 0x002D) }, /* Sitecom */
{ USB_DEVICE(0x0DF6, 0x0039) }, /* Sitecom 2770 */
{ USB_DEVICE(0x0DF6, 0x003F) }, /* Sitecom WL-608 */
{ USB_DEVICE(0x14B2, 0x3C06) }, /* Conceptronic */
{ USB_DEVICE(0x14B2, 0x3C28) }, /* Conceptronic */
{ USB_DEVICE(0x2019, 0xED06) }, /* Planex Communications, Inc. */
{ USB_DEVICE(0x2019, 0xED14) }, /* Planex Communications, Inc. */
{ USB_DEVICE(0x2019, 0xAB25) }, /* Planex Communications, Inc. RT3070 */
{ USB_DEVICE(0x07D1, 0x3C09) }, /* D-Link */
{ USB_DEVICE(0x07D1, 0x3C11) }, /* D-Link */
{ USB_DEVICE(0x2001, 0x3C09) }, /* D-Link */
{ USB_DEVICE(0x2001, 0x3C0A) }, /* D-Link 3072*/
{ USB_DEVICE(0x14B2, 0x3C07) }, /* AL */
{ USB_DEVICE(0x14B2, 0x3C12) }, /* AL 3070 */
{ USB_DEVICE(0x050D, 0x8053) }, /* Belkin */
{ USB_DEVICE(0x050D, 0x815C) }, /* Belkin */
{ USB_DEVICE(0x050D, 0x825a) }, /* Belkin */
{ USB_DEVICE(0x14B2, 0x3C23) }, /* Airlink */
{ USB_DEVICE(0x14B2, 0x3C27) }, /* Airlink */
{ USB_DEVICE(0x07AA, 0x002F) }, /* Corega */
{ USB_DEVICE(0x07AA, 0x003C) }, /* Corega */
{ USB_DEVICE(0x07AA, 0x003F) }, /* Corega */
{ USB_DEVICE(0x18C5, 0x0012) }, /* Corega 3070 */
{ USB_DEVICE(0x1044, 0x800B) }, /* Gigabyte */
{ USB_DEVICE(0x1044, 0x800D) }, /* Gigabyte GN-WB32L 3070 */
{ USB_DEVICE(0x15A9, 0x0006) }, /* Sparklan */
{ USB_DEVICE(0x083A, 0xB522) }, /* SMC */
{ USB_DEVICE(0x083A, 0xA618) }, /* SMC */
{ USB_DEVICE(0x083A, 0x8522) }, /* Arcadyan */
{ USB_DEVICE(0x083A, 0x7512) }, /* Arcadyan 2770 */
{ USB_DEVICE(0x083A, 0x7522) }, /* Arcadyan */
{ USB_DEVICE(0x083A, 0x7511) }, /* Arcadyan 3070 */
{ USB_DEVICE(0x0CDE, 0x0022) }, /* ZCOM */
{ USB_DEVICE(0x0586, 0x3416) }, /* Zyxel */
{ USB_DEVICE(0x0CDE, 0x0025) }, /* Zyxel */
{ USB_DEVICE(0x1740, 0x9701) }, /* EnGenius */
{ USB_DEVICE(0x1740, 0x9702) }, /* EnGenius */
{ USB_DEVICE(0x1740, 0x9703) }, /* EnGenius 3070 */
{ USB_DEVICE(0x0471, 0x200f) }, /* Philips */
{ USB_DEVICE(0x14B2, 0x3C25) }, /* Draytek */
{ USB_DEVICE(0x13D3, 0x3247) }, /* AzureWave */
{ USB_DEVICE(0x13D3, 0x3273) }, /* AzureWave 3070*/
{ USB_DEVICE(0x083A, 0x6618) }, /* Accton */
{ USB_DEVICE(0x15c5, 0x0008) }, /* Amit */
{ USB_DEVICE(0x0E66, 0x0001) }, /* Hawking */
{ USB_DEVICE(0x0E66, 0x0003) }, /* Hawking */
{ USB_DEVICE(0x129B, 0x1828) }, /* Siemens */
{ USB_DEVICE(0x157E, 0x300E) }, /* U-Media */
{ USB_DEVICE(0x050d, 0x805c) },
{ USB_DEVICE(0x1482, 0x3C09) }, /* Abocom*/
{ USB_DEVICE(0x14B2, 0x3C09) }, /* Alpha */
{ USB_DEVICE(0x04E8, 0x2018) }, /* samsung */
{ USB_DEVICE(0x07B8, 0x3070) }, /* AboCom 3070 */
{ USB_DEVICE(0x07B8, 0x3071) }, /* AboCom 3071 */
{ USB_DEVICE(0x07B8, 0x2870) }, /* AboCom */
{ USB_DEVICE(0x07B8, 0x2770) }, /* AboCom */
{ USB_DEVICE(0x07B8, 0x3072) }, /* Abocom 3072 */
{ USB_DEVICE(0x7392, 0x7711) }, /* Edimax 3070 */
{ USB_DEVICE(0x5A57, 0x0280) }, /* Zinwell */
{ USB_DEVICE(0x5A57, 0x0282) }, /* Zinwell */
{ USB_DEVICE(0x1A32, 0x0304) }, /* Quanta 3070 */
{ USB_DEVICE(0x0789, 0x0162) }, /* Logitec 2870 */
{ USB_DEVICE(0x0789, 0x0163) }, /* Logitec 2870 */
{ USB_DEVICE(0x0789, 0x0164) }, /* Logitec 2870 */
{ USB_DEVICE(0x7392, 0x7717) }, /* Edimax */
{ USB_DEVICE(0x1EDA, 0x2310) }, /* AirTies 3070 */
{ USB_DEVICE(0x1737, 0x0077) }, /* Linksys WUSB54GC-EU v3 */
{ USB_DEVICE(0x0411, 0x015D) }, /* Buffalo Airstation WLI-UC-GN */
{ USB_DEVICE(0x0789, 0x0166) }, /* Logitec orijinaru2870 */
{ } /* Terminating entry */
};
INT const rtusb_usb_id_len = sizeof(rtusb_usb_id) / sizeof(struct usb_device_id);
MODULE_DEVICE_TABLE(usb, rtusb_usb_id);
#ifndef PF_NOFREEZE
#define PF_NOFREEZE 0
#endif
#ifdef CONFIG_PM
static int rt2870_suspend(struct usb_interface *intf, pm_message_t state);
static int rt2870_resume(struct usb_interface *intf);
#endif // CONFIG_PM //
/**************************************************************************/
/**************************************************************************/
//tested for kernel 2.6series
/**************************************************************************/
/**************************************************************************/
static int rtusb_probe (struct usb_interface *intf,
const struct usb_device_id *id);
static void rtusb_disconnect(struct usb_interface *intf);
struct usb_driver rtusb_driver = {
.name="rt2870",
.probe=rtusb_probe,
.disconnect=rtusb_disconnect,
.id_table=rtusb_usb_id,
#ifdef CONFIG_PM
suspend: rt2870_suspend,
resume: rt2870_resume,
#endif
};
#ifdef CONFIG_PM
VOID RT2860RejectPendingPackets(
IN PRTMP_ADAPTER pAd)
{
// clear PS packets
// clear TxSw packets
}
static int rt2870_suspend(
struct usb_interface *intf,
pm_message_t state)
{
struct net_device *net_dev;
PRTMP_ADAPTER pAd = usb_get_intfdata(intf);
DBGPRINT(RT_DEBUG_TRACE, ("===> rt2870_suspend()\n"));
net_dev = pAd->net_dev;
netif_device_detach (net_dev);
pAd->PM_FlgSuspend = 1;
if (netif_running(net_dev)) {
RTUSBCancelPendingBulkInIRP(pAd);
RTUSBCancelPendingBulkOutIRP(pAd);
}
DBGPRINT(RT_DEBUG_TRACE, ("<=== rt2870_suspend()\n"));
return 0;
}
static int rt2870_resume(
struct usb_interface *intf)
{
struct net_device *net_dev;
PRTMP_ADAPTER pAd = usb_get_intfdata(intf);
DBGPRINT(RT_DEBUG_TRACE, ("===> rt2870_resume()\n"));
pAd->PM_FlgSuspend = 0;
net_dev = pAd->net_dev;
netif_device_attach (net_dev);
netif_start_queue(net_dev);
netif_carrier_on(net_dev);
netif_wake_queue(net_dev);
DBGPRINT(RT_DEBUG_TRACE, ("<=== rt2870_resume()\n"));
return 0;
}
#endif // CONFIG_PM //
// Init driver module
INT __init rtusb_init(void)
{
printk("rtusb init --->\n");
return usb_register(&rtusb_driver);
}
// Deinit driver module
VOID __exit rtusb_exit(void)
{
usb_deregister(&rtusb_driver);
printk("<--- rtusb exit\n");
}
module_init(rtusb_init);
module_exit(rtusb_exit);
/*--------------------------------------------------------------------- */
/* function declarations */
/*--------------------------------------------------------------------- */
/*
========================================================================
Routine Description:
MLME kernel thread.
Arguments:
*Context the pAd, driver control block pointer
Return Value:
0 close the thread
Note:
========================================================================
*/
INT MlmeThread(
IN void *Context)
{
PRTMP_ADAPTER pAd = (PRTMP_ADAPTER)Context;
POS_COOKIE pObj;
int status;
pObj = (POS_COOKIE)pAd->OS_Cookie;
rtmp_os_thread_init("rt2870MlmeThread", (PVOID)&(pAd->mlmeComplete));
while (pAd->mlme_kill == 0)
{
/* lock the device pointers */
//down(&(pAd->mlme_semaphore));
status = down_interruptible(&(pAd->mlme_semaphore));
/* lock the device pointers , need to check if required*/
//down(&(pAd->usbdev_semaphore));
if (!pAd->PM_FlgSuspend)
MlmeHandler(pAd);
/* unlock the device pointers */
//up(&(pAd->usbdev_semaphore));
if (status != 0)
{
RTMP_SET_FLAG(pAd, fRTMP_ADAPTER_HALT_IN_PROGRESS);
break;
}
}
/* notify the exit routine that we're actually exiting now
*
* complete()/wait_for_completion() is similar to up()/down(),
* except that complete() is safe in the case where the structure
* is getting deleted in a parallel mode of execution (i.e. just
* after the down() -- that's necessary for the thread-shutdown
* case.
*
* complete_and_exit() goes even further than this -- it is safe in
* the case that the thread of the caller is going away (not just
* the structure) -- this is necessary for the module-remove case.
* This is important in preemption kernels, which transfer the flow
* of execution immediately upon a complete().
*/
DBGPRINT(RT_DEBUG_TRACE,( "<---%s\n",__func__));
pObj->MLMEThr_pid = NULL;
complete_and_exit (&pAd->mlmeComplete, 0);
return 0;
}
/*
========================================================================
Routine Description:
USB command kernel thread.
Arguments:
*Context the pAd, driver control block pointer
Return Value:
0 close the thread
Note:
========================================================================
*/
INT RTUSBCmdThread(
IN void * Context)
{
PRTMP_ADAPTER pAd = (PRTMP_ADAPTER)Context;
POS_COOKIE pObj;
int status;
pObj = (POS_COOKIE)pAd->OS_Cookie;
rtmp_os_thread_init("rt2870CmdThread", (PVOID)&(pAd->CmdQComplete));
NdisAcquireSpinLock(&pAd->CmdQLock);
pAd->CmdQ.CmdQState = RT2870_THREAD_RUNNING;
NdisReleaseSpinLock(&pAd->CmdQLock);
while (pAd->CmdQ.CmdQState == RT2870_THREAD_RUNNING)
{
/* lock the device pointers */
//down(&(pAd->RTUSBCmd_semaphore));
status = down_interruptible(&(pAd->RTUSBCmd_semaphore));
if (pAd->CmdQ.CmdQState == RT2870_THREAD_STOPED)
break;
if (status != 0)
{
RTMP_SET_FLAG(pAd, fRTMP_ADAPTER_HALT_IN_PROGRESS);
break;
}
/* lock the device pointers , need to check if required*/
//down(&(pAd->usbdev_semaphore));
if (!pAd->PM_FlgSuspend)
CMDHandler(pAd);
/* unlock the device pointers */
//up(&(pAd->usbdev_semaphore));
}
if (!pAd->PM_FlgSuspend)
{ // Clear the CmdQElements.
CmdQElmt *pCmdQElmt = NULL;
NdisAcquireSpinLock(&pAd->CmdQLock);
pAd->CmdQ.CmdQState = RT2870_THREAD_STOPED;
while(pAd->CmdQ.size)
{
RTUSBDequeueCmd(&pAd->CmdQ, &pCmdQElmt);
if (pCmdQElmt)
{
if (pCmdQElmt->CmdFromNdis == TRUE)
{
if (pCmdQElmt->buffer != NULL)
NdisFreeMemory(pCmdQElmt->buffer, pCmdQElmt->bufferlength, 0);
NdisFreeMemory(pCmdQElmt, sizeof(CmdQElmt), 0);
}
else
{
if ((pCmdQElmt->buffer != NULL) && (pCmdQElmt->bufferlength != 0))
NdisFreeMemory(pCmdQElmt->buffer, pCmdQElmt->bufferlength, 0);
{
NdisFreeMemory(pCmdQElmt, sizeof(CmdQElmt), 0);
}
}
}
}
NdisReleaseSpinLock(&pAd->CmdQLock);
}
/* notify the exit routine that we're actually exiting now
*
* complete()/wait_for_completion() is similar to up()/down(),
* except that complete() is safe in the case where the structure
* is getting deleted in a parallel mode of execution (i.e. just
* after the down() -- that's necessary for the thread-shutdown
* case.
*
* complete_and_exit() goes even further than this -- it is safe in
* the case that the thread of the caller is going away (not just
* the structure) -- this is necessary for the module-remove case.
* This is important in preemption kernels, which transfer the flow
* of execution immediately upon a complete().
*/
DBGPRINT(RT_DEBUG_TRACE,( "<---RTUSBCmdThread\n"));
pObj->RTUSBCmdThr_pid = NULL;
complete_and_exit (&pAd->CmdQComplete, 0);
return 0;
}
static void RT2870_TimerQ_Handle(RTMP_ADAPTER *pAd)
{
int status;
RALINK_TIMER_STRUCT *pTimer;
RT2870_TIMER_ENTRY *pEntry;
unsigned long irqFlag;
while(!pAd->TimerFunc_kill)
{
// printk("waiting for event!\n");
pTimer = NULL;
status = down_interruptible(&(pAd->RTUSBTimer_semaphore));
if (pAd->TimerQ.status == RT2870_THREAD_STOPED)
break;
// event happened.
while(pAd->TimerQ.pQHead)
{
RTMP_IRQ_LOCK(&pAd->TimerQLock, irqFlag);
pEntry = pAd->TimerQ.pQHead;
if (pEntry)
{
pTimer = pEntry->pRaTimer;
// update pQHead
pAd->TimerQ.pQHead = pEntry->pNext;
if (pEntry == pAd->TimerQ.pQTail)
pAd->TimerQ.pQTail = NULL;
// return this queue entry to timerQFreeList.
pEntry->pNext = pAd->TimerQ.pQPollFreeList;
pAd->TimerQ.pQPollFreeList = pEntry;
}
RTMP_IRQ_UNLOCK(&pAd->TimerQLock, irqFlag);
if (pTimer)
{
if (pTimer->handle != NULL)
if (!pAd->PM_FlgSuspend)
pTimer->handle(NULL, (PVOID) pTimer->cookie, NULL, pTimer);
if ((pTimer->Repeat) && (pTimer->State == FALSE))
RTMP_OS_Add_Timer(&pTimer->TimerObj, pTimer->TimerValue);
}
}
if (status != 0)
{
pAd->TimerQ.status = RT2870_THREAD_STOPED;
RTMP_SET_FLAG(pAd, fRTMP_ADAPTER_HALT_IN_PROGRESS);
break;
}
}
}
INT TimerQThread(
IN OUT PVOID Context)
{
PRTMP_ADAPTER pAd;
POS_COOKIE pObj;
pAd = (PRTMP_ADAPTER)Context;
pObj = (POS_COOKIE) pAd->OS_Cookie;
rtmp_os_thread_init("rt2870TimerQHandle", (PVOID)&(pAd->TimerQComplete));
RT2870_TimerQ_Handle(pAd);
/* notify the exit routine that we're actually exiting now
*
* complete()/wait_for_completion() is similar to up()/down(),
* except that complete() is safe in the case where the structure
* is getting deleted in a parallel mode of execution (i.e. just
* after the down() -- that's necessary for the thread-shutdown
* case.
*
* complete_and_exit() goes even further than this -- it is safe in
* the case that the thread of the caller is going away (not just
* the structure) -- this is necessary for the module-remove case.
* This is important in preemption kernels, which transfer the flow
* of execution immediately upon a complete().
*/
DBGPRINT(RT_DEBUG_TRACE,( "<---%s\n",__func__));
pObj->TimerQThr_pid = NULL;
complete_and_exit(&pAd->TimerQComplete, 0);
return 0;
}
RT2870_TIMER_ENTRY *RT2870_TimerQ_Insert(
IN RTMP_ADAPTER *pAd,
IN RALINK_TIMER_STRUCT *pTimer)
{
RT2870_TIMER_ENTRY *pQNode = NULL, *pQTail;
unsigned long irqFlags;
RTMP_IRQ_LOCK(&pAd->TimerQLock, irqFlags);
if (pAd->TimerQ.status & RT2870_THREAD_CAN_DO_INSERT)
{
if(pAd->TimerQ.pQPollFreeList)
{
pQNode = pAd->TimerQ.pQPollFreeList;
pAd->TimerQ.pQPollFreeList = pQNode->pNext;
pQNode->pRaTimer = pTimer;
pQNode->pNext = NULL;
pQTail = pAd->TimerQ.pQTail;
if (pAd->TimerQ.pQTail != NULL)
pQTail->pNext = pQNode;
pAd->TimerQ.pQTail = pQNode;
if (pAd->TimerQ.pQHead == NULL)
pAd->TimerQ.pQHead = pQNode;
}
RTMP_IRQ_UNLOCK(&pAd->TimerQLock, irqFlags);
if (pQNode)
up(&pAd->RTUSBTimer_semaphore);
//wake_up(&timerWaitQ);
}
else
{
RTMP_IRQ_UNLOCK(&pAd->TimerQLock, irqFlags);
}
return pQNode;
}
BOOLEAN RT2870_TimerQ_Remove(
IN RTMP_ADAPTER *pAd,
IN RALINK_TIMER_STRUCT *pTimer)
{
RT2870_TIMER_ENTRY *pNode, *pPrev = NULL;
unsigned long irqFlags;
RTMP_IRQ_LOCK(&pAd->TimerQLock, irqFlags);
if (pAd->TimerQ.status >= RT2870_THREAD_INITED)
{
pNode = pAd->TimerQ.pQHead;
while (pNode)
{
if (pNode->pRaTimer == pTimer)
break;
pPrev = pNode;
pNode = pNode->pNext;
}
// Now move it to freeList queue.
if (pNode)
{
if (pNode == pAd->TimerQ.pQHead)
pAd->TimerQ.pQHead = pNode->pNext;
if (pNode == pAd->TimerQ.pQTail)
pAd->TimerQ.pQTail = pPrev;
if (pPrev != NULL)
pPrev->pNext = pNode->pNext;
// return this queue entry to timerQFreeList.
pNode->pNext = pAd->TimerQ.pQPollFreeList;
pAd->TimerQ.pQPollFreeList = pNode;
}
}
RTMP_IRQ_UNLOCK(&pAd->TimerQLock, irqFlags);
return TRUE;
}
void RT2870_TimerQ_Exit(RTMP_ADAPTER *pAd)
{
RT2870_TIMER_ENTRY *pTimerQ;
unsigned long irqFlags;
RTMP_IRQ_LOCK(&pAd->TimerQLock, irqFlags);
while (pAd->TimerQ.pQHead)
{
pTimerQ = pAd->TimerQ.pQHead;
pAd->TimerQ.pQHead = pTimerQ->pNext;
// remove the timeQ
}
pAd->TimerQ.pQPollFreeList = NULL;
os_free_mem(pAd, pAd->TimerQ.pTimerQPoll);
pAd->TimerQ.pQTail = NULL;
pAd->TimerQ.pQHead = NULL;
pAd->TimerQ.status = RT2870_THREAD_STOPED;
RTMP_IRQ_UNLOCK(&pAd->TimerQLock, irqFlags);
}
void RT2870_TimerQ_Init(RTMP_ADAPTER *pAd)
{
int i;
RT2870_TIMER_ENTRY *pQNode, *pEntry;
unsigned long irqFlags;
NdisAllocateSpinLock(&pAd->TimerQLock);
RTMP_IRQ_LOCK(&pAd->TimerQLock, irqFlags);
NdisZeroMemory(&pAd->TimerQ, sizeof(pAd->TimerQ));
//InterlockedExchange(&pAd->TimerQ.count, 0);
/* Initialise the wait q head */
//init_waitqueue_head(&timerWaitQ);
os_alloc_mem(pAd, &pAd->TimerQ.pTimerQPoll, sizeof(RT2870_TIMER_ENTRY) * TIMER_QUEUE_SIZE_MAX);
if (pAd->TimerQ.pTimerQPoll)
{
pEntry = NULL;
pQNode = (RT2870_TIMER_ENTRY *)pAd->TimerQ.pTimerQPoll;
for (i = 0 ;i <TIMER_QUEUE_SIZE_MAX; i++)
{
pQNode->pNext = pEntry;
pEntry = pQNode;
pQNode++;
}
pAd->TimerQ.pQPollFreeList = pEntry;
pAd->TimerQ.pQHead = NULL;
pAd->TimerQ.pQTail = NULL;
pAd->TimerQ.status = RT2870_THREAD_INITED;
}
RTMP_IRQ_UNLOCK(&pAd->TimerQLock, irqFlags);
}
VOID RT2870_WatchDog(IN RTMP_ADAPTER *pAd)
{
PHT_TX_CONTEXT pHTTXContext;
int idx;
ULONG irqFlags;
PURB pUrb;
BOOLEAN needDumpSeq = FALSE;
UINT32 MACValue;
idx = 0;
RTMP_IO_READ32(pAd, TXRXQ_PCNT, &MACValue);
if ((MACValue & 0xff) !=0 )
{
DBGPRINT(RT_DEBUG_TRACE, ("TX QUEUE 0 Not EMPTY(Value=0x%0x). !!!!!!!!!!!!!!!\n", MACValue));
RTMP_IO_WRITE32(pAd, PBF_CFG, 0xf40012);
while((MACValue &0xff) != 0 && (idx++ < 10))
{
RTMP_IO_READ32(pAd, TXRXQ_PCNT, &MACValue);
NdisMSleep(1);
}
RTMP_IO_WRITE32(pAd, PBF_CFG, 0xf40006);
}
//PS packets use HCCA queue when dequeue from PS unicast queue (WiFi WPA2 MA9_DT1 for Marvell B STA)
idx = 0;
if ((MACValue & 0xff00) !=0 )
{
DBGPRINT(RT_DEBUG_TRACE, ("TX QUEUE 1 Not EMPTY(Value=0x%0x). !!!!!!!!!!!!!!!\n", MACValue));
RTMP_IO_WRITE32(pAd, PBF_CFG, 0xf4000a);
while((MACValue &0xff00) != 0 && (idx++ < 10))
{
RTMP_IO_READ32(pAd, TXRXQ_PCNT, &MACValue);
NdisMSleep(1);
}
RTMP_IO_WRITE32(pAd, PBF_CFG, 0xf40006);
}
if (pAd->watchDogRxOverFlowCnt >= 2)
{
DBGPRINT(RT_DEBUG_TRACE, ("Maybe the Rx Bulk-In hanged! Cancel the pending Rx bulks request!\n"));
if ((!RTMP_TEST_FLAG(pAd, (fRTMP_ADAPTER_RESET_IN_PROGRESS |
fRTMP_ADAPTER_BULKIN_RESET |
fRTMP_ADAPTER_HALT_IN_PROGRESS |
fRTMP_ADAPTER_NIC_NOT_EXIST))))
{
DBGPRINT(RT_DEBUG_TRACE, ("Call CMDTHREAD_RESET_BULK_IN to cancel the pending Rx Bulk!\n"));
RTMP_SET_FLAG(pAd, fRTMP_ADAPTER_BULKIN_RESET);
RTUSBEnqueueInternalCmd(pAd, CMDTHREAD_RESET_BULK_IN, NULL, 0);
needDumpSeq = TRUE;
}
pAd->watchDogRxOverFlowCnt = 0;
}
for (idx = 0; idx < NUM_OF_TX_RING; idx++)
{
pUrb = NULL;
RTMP_IRQ_LOCK(&pAd->BulkOutLock[idx], irqFlags);
if ((pAd->BulkOutPending[idx] == TRUE) && pAd->watchDogTxPendingCnt)
{
pAd->watchDogTxPendingCnt[idx]++;
if ((pAd->watchDogTxPendingCnt[idx] > 2) &&
(!RTMP_TEST_FLAG(pAd, (fRTMP_ADAPTER_RESET_IN_PROGRESS | fRTMP_ADAPTER_HALT_IN_PROGRESS | fRTMP_ADAPTER_NIC_NOT_EXIST | fRTMP_ADAPTER_BULKOUT_RESET)))
)
{
// FIXME: Following code just support single bulk out. If you wanna support multiple bulk out. Modify it!
pHTTXContext = (PHT_TX_CONTEXT)(&pAd->TxContext[idx]);
if (pHTTXContext->IRPPending)
{ // Check TxContext.
pUrb = pHTTXContext->pUrb;
}
else if (idx == MGMTPIPEIDX)
{
PTX_CONTEXT pMLMEContext, pNULLContext, pPsPollContext;
//Check MgmtContext.
pMLMEContext = (PTX_CONTEXT)(pAd->MgmtRing.Cell[pAd->MgmtRing.TxDmaIdx].AllocVa);
pPsPollContext = (PTX_CONTEXT)(&pAd->PsPollContext);
pNULLContext = (PTX_CONTEXT)(&pAd->NullContext);
if (pMLMEContext->IRPPending)
{
ASSERT(pMLMEContext->IRPPending);
pUrb = pMLMEContext->pUrb;
}
else if (pNULLContext->IRPPending)
{
ASSERT(pNULLContext->IRPPending);
pUrb = pNULLContext->pUrb;
}
else if (pPsPollContext->IRPPending)
{
ASSERT(pPsPollContext->IRPPending);
pUrb = pPsPollContext->pUrb;
}
}
RTMP_IRQ_UNLOCK(&pAd->BulkOutLock[idx], irqFlags);
DBGPRINT(RT_DEBUG_TRACE, ("Maybe the Tx Bulk-Out hanged! Cancel the pending Tx bulks request of idx(%d)!\n", idx));
if (pUrb)
{
DBGPRINT(RT_DEBUG_TRACE, ("Unlink the pending URB!\n"));
// unlink it now
RTUSB_UNLINK_URB(pUrb);
// Sleep 200 microseconds to give cancellation time to work
RTMPusecDelay(200);
needDumpSeq = TRUE;
}
else
{
DBGPRINT(RT_DEBUG_ERROR, ("Unkonw bulkOut URB maybe hanged!!!!!!!!!!!!\n"));
}
}
else
{
RTMP_IRQ_UNLOCK(&pAd->BulkOutLock[idx], irqFlags);
}
}
else
{
RTMP_IRQ_UNLOCK(&pAd->BulkOutLock[idx], irqFlags);
}
}
// For Sigma debug, dump the ba_reordering sequence.
if((needDumpSeq == TRUE) && (pAd->CommonCfg.bDisableReordering == 0))
{
USHORT Idx;
PBA_REC_ENTRY pBAEntry = NULL;
UCHAR count = 0;
struct reordering_mpdu *mpdu_blk;
Idx = pAd->MacTab.Content[BSSID_WCID].BARecWcidArray[0];
pBAEntry = &pAd->BATable.BARecEntry[Idx];
if((pBAEntry->list.qlen > 0) && (pBAEntry->list.next != NULL))
{
DBGPRINT(RT_DEBUG_TRACE, ("NICUpdateRawCounters():The Queueing pkt in reordering buffer:\n"));
NdisAcquireSpinLock(&pBAEntry->RxReRingLock);
mpdu_blk = pBAEntry->list.next;
while (mpdu_blk)
{
DBGPRINT(RT_DEBUG_TRACE, ("\t%d:Seq-%d, bAMSDU-%d!\n", count, mpdu_blk->Sequence, mpdu_blk->bAMSDU));
mpdu_blk = mpdu_blk->next;
count++;
}
DBGPRINT(RT_DEBUG_TRACE, ("\npBAEntry->LastIndSeq=%d!\n", pBAEntry->LastIndSeq));
NdisReleaseSpinLock(&pBAEntry->RxReRingLock);
}
}
}
/*
========================================================================
Routine Description:
Release allocated resources.
Arguments:
*dev Point to the PCI or USB device
pAd driver control block pointer
Return Value:
None
Note:
========================================================================
*/
static void _rtusb_disconnect(struct usb_device *dev, PRTMP_ADAPTER pAd)
{
struct net_device *net_dev = NULL;
DBGPRINT(RT_DEBUG_ERROR, ("rtusb_disconnect: unregister usbnet usb-%s-%s\n",
dev->bus->bus_name, dev->devpath));
if (!pAd)
{
usb_put_dev(dev);
printk("rtusb_disconnect: pAd == NULL!\n");
return;
}
RTMP_SET_FLAG(pAd, fRTMP_ADAPTER_NIC_NOT_EXIST);
// for debug, wait to show some messages to /proc system
udelay(1);
net_dev = pAd->net_dev;
if (pAd->net_dev != NULL)
{
printk("rtusb_disconnect: unregister_netdev(), dev->name=%s!\n", net_dev->name);
unregister_netdev (pAd->net_dev);
}
udelay(1);
flush_scheduled_work();
udelay(1);
// free net_device memory
free_netdev(net_dev);
// free adapter memory
RTMPFreeAdapter(pAd);
// release a use of the usb device structure
usb_put_dev(dev);
udelay(1);
DBGPRINT(RT_DEBUG_ERROR, (" RTUSB disconnect successfully\n"));
}
/*
========================================================================
Routine Description:
Probe RT28XX chipset.
Arguments:
*dev Point to the PCI or USB device
interface
*id_table Point to the PCI or USB device ID
Return Value:
None
Note:
========================================================================
*/
static int rtusb_probe (struct usb_interface *intf,
const struct usb_device_id *id)
{
PRTMP_ADAPTER pAd;
return (int)rt28xx_probe((void *)intf, (void *)id, 0, &pAd);
}
static void rtusb_disconnect(struct usb_interface *intf)
{
struct usb_device *dev = interface_to_usbdev(intf);
PRTMP_ADAPTER pAd;
pAd = usb_get_intfdata(intf);
usb_set_intfdata(intf, NULL);
_rtusb_disconnect(dev, pAd);
}
/*
========================================================================
Routine Description:
Close kernel threads.
Arguments:
*pAd the raxx interface data pointer
Return Value:
NONE
Note:
========================================================================
*/
VOID RT28xxThreadTerminate(
IN RTMP_ADAPTER *pAd)
{
POS_COOKIE pObj = (POS_COOKIE) pAd->OS_Cookie;
INT ret;
// Sleep 50 milliseconds so pending io might finish normally
RTMPusecDelay(50000);
// We want to wait until all pending receives and sends to the
// device object. We cancel any
// irps. Wait until sends and receives have stopped.
RTUSBCancelPendingIRPs(pAd);
// Terminate Threads
if (pid_nr(pObj->TimerQThr_pid) > 0)
{
POS_COOKIE pObj = (POS_COOKIE)pAd->OS_Cookie;
printk("Terminate the TimerQThr_pid=%d!\n", pid_nr(pObj->TimerQThr_pid));
mb();
pAd->TimerFunc_kill = 1;
mb();
ret = kill_pid(pObj->TimerQThr_pid, SIGTERM, 1);
if (ret)
{
printk(KERN_WARNING "%s: unable to stop TimerQThread, pid=%d, ret=%d!\n",
pAd->net_dev->name, pid_nr(pObj->TimerQThr_pid), ret);
}
else
{
wait_for_completion(&pAd->TimerQComplete);
pObj->TimerQThr_pid = NULL;
}
}
if (pid_nr(pObj->MLMEThr_pid) > 0)
{
printk("Terminate the MLMEThr_pid=%d!\n", pid_nr(pObj->MLMEThr_pid));
mb();
pAd->mlme_kill = 1;
//RT28XX_MLME_HANDLER(pAd);
mb();
ret = kill_pid(pObj->MLMEThr_pid, SIGTERM, 1);
if (ret)
{
printk (KERN_WARNING "%s: unable to Mlme thread, pid=%d, ret=%d!\n",
pAd->net_dev->name, pid_nr(pObj->MLMEThr_pid), ret);
}
else
{
//wait_for_completion (&pAd->notify);
wait_for_completion (&pAd->mlmeComplete);
pObj->MLMEThr_pid = NULL;
}
}
if (pid_nr(pObj->RTUSBCmdThr_pid) > 0)
{
printk("Terminate the RTUSBCmdThr_pid=%d!\n", pid_nr(pObj->RTUSBCmdThr_pid));
mb();
NdisAcquireSpinLock(&pAd->CmdQLock);
pAd->CmdQ.CmdQState = RT2870_THREAD_STOPED;
NdisReleaseSpinLock(&pAd->CmdQLock);
mb();
//RTUSBCMDUp(pAd);
ret = kill_pid(pObj->RTUSBCmdThr_pid, SIGTERM, 1);
if (ret)
{
printk(KERN_WARNING "%s: unable to RTUSBCmd thread, pid=%d, ret=%d!\n",
pAd->net_dev->name, pid_nr(pObj->RTUSBCmdThr_pid), ret);
}
else
{
//wait_for_completion (&pAd->notify);
wait_for_completion (&pAd->CmdQComplete);
pObj->RTUSBCmdThr_pid = NULL;
}
}
// Kill tasklets
pAd->mlme_kill = 0;
pAd->CmdQ.CmdQState = RT2870_THREAD_UNKNOWN;
pAd->TimerFunc_kill = 0;
}
void kill_thread_task(IN PRTMP_ADAPTER pAd)
{
POS_COOKIE pObj;
pObj = (POS_COOKIE) pAd->OS_Cookie;
tasklet_kill(&pObj->rx_done_task);
tasklet_kill(&pObj->mgmt_dma_done_task);
tasklet_kill(&pObj->ac0_dma_done_task);
tasklet_kill(&pObj->ac1_dma_done_task);
tasklet_kill(&pObj->ac2_dma_done_task);
tasklet_kill(&pObj->ac3_dma_done_task);
tasklet_kill(&pObj->hcca_dma_done_task);
tasklet_kill(&pObj->tbtt_task);
}
/*
========================================================================
Routine Description:
Check the chipset vendor/product ID.
Arguments:
_dev_p Point to the PCI or USB device
Return Value:
TRUE Check ok
FALSE Check fail
Note:
========================================================================
*/
BOOLEAN RT28XXChipsetCheck(
IN void *_dev_p)
{
struct usb_interface *intf = (struct usb_interface *)_dev_p;
struct usb_device *dev_p = interface_to_usbdev(intf);
UINT32 i;
for(i=0; i<rtusb_usb_id_len; i++)
{
if (dev_p->descriptor.idVendor == rtusb_usb_id[i].idVendor &&
dev_p->descriptor.idProduct == rtusb_usb_id[i].idProduct)
{
printk("rt2870: idVendor = 0x%x, idProduct = 0x%x\n",
dev_p->descriptor.idVendor, dev_p->descriptor.idProduct);
break;
}
}
if (i == rtusb_usb_id_len)
{
printk("rt2870: Error! Device Descriptor not matching!\n");
return FALSE;
}
return TRUE;
}
/*
========================================================================
Routine Description:
Init net device structure.
Arguments:
_dev_p Point to the PCI or USB device
*net_dev Point to the net device
*pAd the raxx interface data pointer
Return Value:
TRUE Init ok
FALSE Init fail
Note:
========================================================================
*/
BOOLEAN RT28XXNetDevInit(
IN void *_dev_p,
IN struct net_device *net_dev,
IN RTMP_ADAPTER *pAd)
{
struct usb_interface *intf = (struct usb_interface *)_dev_p;
struct usb_device *dev_p = interface_to_usbdev(intf);
pAd->config = &dev_p->config->desc;
return TRUE;
}
/*
========================================================================
Routine Description:
Init net device structure.
Arguments:
_dev_p Point to the PCI or USB device
*pAd the raxx interface data pointer
Return Value:
TRUE Config ok
FALSE Config fail
Note:
========================================================================
*/
BOOLEAN RT28XXProbePostConfig(
IN void *_dev_p,
IN RTMP_ADAPTER *pAd,
IN INT32 interface)
{
struct usb_interface *intf = (struct usb_interface *)_dev_p;
struct usb_host_interface *iface_desc;
ULONG BulkOutIdx;
UINT32 i;
/* get the active interface descriptor */
iface_desc = intf->cur_altsetting;
/* get # of enpoints */
pAd->NumberOfPipes = iface_desc->desc.bNumEndpoints;
DBGPRINT(RT_DEBUG_TRACE,
("NumEndpoints=%d\n", iface_desc->desc.bNumEndpoints));
/* Configure Pipes */
BulkOutIdx = 0;
for(i=0; i<pAd->NumberOfPipes; i++)
{
if ((iface_desc->endpoint[i].desc.bmAttributes ==
USB_ENDPOINT_XFER_BULK) &&
((iface_desc->endpoint[i].desc.bEndpointAddress &
USB_ENDPOINT_DIR_MASK) == USB_DIR_IN))
{
pAd->BulkInEpAddr = iface_desc->endpoint[i].desc.bEndpointAddress;
pAd->BulkInMaxPacketSize = iface_desc->endpoint[i].desc.wMaxPacketSize;
DBGPRINT_RAW(RT_DEBUG_TRACE,
("BULK IN MaximumPacketSize = %d\n", pAd->BulkInMaxPacketSize));
DBGPRINT_RAW(RT_DEBUG_TRACE,
("EP address = 0x%2x\n", iface_desc->endpoint[i].desc.bEndpointAddress));
}
else if ((iface_desc->endpoint[i].desc.bmAttributes ==
USB_ENDPOINT_XFER_BULK) &&
((iface_desc->endpoint[i].desc.bEndpointAddress &
USB_ENDPOINT_DIR_MASK) == USB_DIR_OUT))
{
// there are 6 bulk out EP. EP6 highest priority.
// EP1-4 is EDCA. EP5 is HCCA.
pAd->BulkOutEpAddr[BulkOutIdx++] = iface_desc->endpoint[i].desc.bEndpointAddress;
pAd->BulkOutMaxPacketSize = iface_desc->endpoint[i].desc.wMaxPacketSize;
DBGPRINT_RAW(RT_DEBUG_TRACE,
("BULK OUT MaximumPacketSize = %d\n", pAd->BulkOutMaxPacketSize));
DBGPRINT_RAW(RT_DEBUG_TRACE,
("EP address = 0x%2x \n", iface_desc->endpoint[i].desc.bEndpointAddress));
}
}
if (!(pAd->BulkInEpAddr && pAd->BulkOutEpAddr[0]))
{
printk("%s: Could not find both bulk-in and bulk-out endpoints\n", __func__);
return FALSE;
}
return TRUE;
}
/*
========================================================================
Routine Description:
Disable DMA.
Arguments:
*pAd the raxx interface data pointer
Return Value:
None
Note:
========================================================================
*/
VOID RT28XXDMADisable(
IN RTMP_ADAPTER *pAd)
{
// no use
}
/*
========================================================================
Routine Description:
Enable DMA.
Arguments:
*pAd the raxx interface data pointer
Return Value:
None
Note:
========================================================================
*/
VOID RT28XXDMAEnable(
IN RTMP_ADAPTER *pAd)
{
WPDMA_GLO_CFG_STRUC GloCfg;
USB_DMA_CFG_STRUC UsbCfg;
int i = 0;
RTMP_IO_WRITE32(pAd, MAC_SYS_CTRL, 0x4);
do
{
RTMP_IO_READ32(pAd, WPDMA_GLO_CFG, &GloCfg.word);
if ((GloCfg.field.TxDMABusy == 0) && (GloCfg.field.RxDMABusy == 0))
break;
DBGPRINT(RT_DEBUG_TRACE, ("==> DMABusy\n"));
RTMPusecDelay(1000);
i++;
}while ( i <200);
RTMPusecDelay(50);
GloCfg.field.EnTXWriteBackDDONE = 1;
GloCfg.field.EnableRxDMA = 1;
GloCfg.field.EnableTxDMA = 1;
DBGPRINT(RT_DEBUG_TRACE, ("<== WRITE DMA offset 0x208 = 0x%x\n", GloCfg.word));
RTMP_IO_WRITE32(pAd, WPDMA_GLO_CFG, GloCfg.word);
UsbCfg.word = 0;
UsbCfg.field.phyclear = 0;
/* usb version is 1.1,do not use bulk in aggregation */
if (pAd->BulkInMaxPacketSize == 512)
UsbCfg.field.RxBulkAggEn = 1;
/* for last packet, PBF might use more than limited, so minus 2 to prevent from error */
UsbCfg.field.RxBulkAggLmt = (MAX_RXBULK_SIZE /1024)-3;
UsbCfg.field.RxBulkAggTOut = 0x80; /* 2006-10-18 */
UsbCfg.field.RxBulkEn = 1;
UsbCfg.field.TxBulkEn = 1;
RTUSBWriteMACRegister(pAd, USB_DMA_CFG, UsbCfg.word);
}
/*
========================================================================
Routine Description:
Write Beacon buffer to Asic.
Arguments:
*pAd the raxx interface data pointer
Return Value:
None
Note:
========================================================================
*/
VOID RT28xx_UpdateBeaconToAsic(
IN RTMP_ADAPTER *pAd,
IN INT apidx,
IN ULONG FrameLen,
IN ULONG UpdatePos)
{
PUCHAR pBeaconFrame = NULL;
UCHAR *ptr;
UINT i, padding;
BEACON_SYNC_STRUCT *pBeaconSync = pAd->CommonCfg.pBeaconSync;
UINT32 longValue;
BOOLEAN bBcnReq = FALSE;
UCHAR bcn_idx = 0;
if (pBeaconFrame == NULL)
{
DBGPRINT(RT_DEBUG_ERROR,("pBeaconFrame is NULL!\n"));
return;
}
if (pBeaconSync == NULL)
{
DBGPRINT(RT_DEBUG_ERROR,("pBeaconSync is NULL!\n"));
return;
}
//if ((pAd->WdsTab.Mode == WDS_BRIDGE_MODE) ||
// ((pAd->ApCfg.MBSSID[apidx].MSSIDDev == NULL) || !(pAd->ApCfg.MBSSID[apidx].MSSIDDev->flags & IFF_UP))
// )
if (bBcnReq == FALSE)
{
/* when the ra interface is down, do not send its beacon frame */
/* clear all zero */
for(i=0; i<TXWI_SIZE; i+=4) {
RTMP_IO_WRITE32(pAd, pAd->BeaconOffset[bcn_idx] + i, 0x00);
}
pBeaconSync->BeaconBitMap &= (~(BEACON_BITMAP_MASK & (1 << bcn_idx)));
NdisZeroMemory(pBeaconSync->BeaconTxWI[bcn_idx], TXWI_SIZE);
}
else
{
ptr = (PUCHAR)&pAd->BeaconTxWI;
if (NdisEqualMemory(pBeaconSync->BeaconTxWI[bcn_idx], &pAd->BeaconTxWI, TXWI_SIZE) == FALSE)
{ // If BeaconTxWI changed, we need to rewrite the TxWI for the Beacon frames.
pBeaconSync->BeaconBitMap &= (~(BEACON_BITMAP_MASK & (1 << bcn_idx)));
NdisMoveMemory(pBeaconSync->BeaconTxWI[bcn_idx], &pAd->BeaconTxWI, TXWI_SIZE);
}
if ((pBeaconSync->BeaconBitMap & (1 << bcn_idx)) != (1 << bcn_idx))
{
for (i=0; i<TXWI_SIZE; i+=4) // 16-byte TXWI field
{
longValue = *ptr + (*(ptr+1)<<8) + (*(ptr+2)<<16) + (*(ptr+3)<<24);
RTMP_IO_WRITE32(pAd, pAd->BeaconOffset[bcn_idx] + i, longValue);
ptr += 4;
}
}
ptr = pBeaconSync->BeaconBuf[bcn_idx];
padding = (FrameLen & 0x01);
NdisZeroMemory((PUCHAR)(pBeaconFrame + FrameLen), padding);
FrameLen += padding;
for (i = 0 ; i < FrameLen /*HW_BEACON_OFFSET*/; i += 2)
{
if (NdisEqualMemory(ptr, pBeaconFrame, 2) == FALSE)
{
NdisMoveMemory(ptr, pBeaconFrame, 2);
//shortValue = *ptr + (*(ptr+1)<<8);
//RTMP_IO_WRITE8(pAd, pAd->BeaconOffset[bcn_idx] + TXWI_SIZE + i, shortValue);
RTUSBMultiWrite(pAd, pAd->BeaconOffset[bcn_idx] + TXWI_SIZE + i, ptr, 2);
}
ptr +=2;
pBeaconFrame += 2;
}
pBeaconSync->BeaconBitMap |= (1 << bcn_idx);
// For AP interface, set the DtimBitOn so that we can send Bcast/Mcast frame out after this beacon frame.
}
}
VOID RT2870_BssBeaconStop(
IN RTMP_ADAPTER *pAd)
{
BEACON_SYNC_STRUCT *pBeaconSync;
int i, offset;
BOOLEAN Cancelled = TRUE;
pBeaconSync = pAd->CommonCfg.pBeaconSync;
if (pBeaconSync && pBeaconSync->EnableBeacon)
{
INT NumOfBcn;
NumOfBcn = MAX_MESH_NUM;
RTMPCancelTimer(&pAd->CommonCfg.BeaconUpdateTimer, &Cancelled);
for(i=0; i<NumOfBcn; i++)
{
NdisZeroMemory(pBeaconSync->BeaconBuf[i], HW_BEACON_OFFSET);
NdisZeroMemory(pBeaconSync->BeaconTxWI[i], TXWI_SIZE);
for (offset=0; offset<HW_BEACON_OFFSET; offset+=4)
RTMP_IO_WRITE32(pAd, pAd->BeaconOffset[i] + offset, 0x00);
pBeaconSync->CapabilityInfoLocationInBeacon[i] = 0;
pBeaconSync->TimIELocationInBeacon[i] = 0;
}
pBeaconSync->BeaconBitMap = 0;
pBeaconSync->DtimBitOn = 0;
}
}
VOID RT2870_BssBeaconStart(
IN RTMP_ADAPTER *pAd)
{
int apidx;
BEACON_SYNC_STRUCT *pBeaconSync;
// LARGE_INTEGER tsfTime, deltaTime;
pBeaconSync = pAd->CommonCfg.pBeaconSync;
if (pBeaconSync && pBeaconSync->EnableBeacon)
{
INT NumOfBcn;
NumOfBcn = MAX_MESH_NUM;
for(apidx=0; apidx<NumOfBcn; apidx++)
{
UCHAR CapabilityInfoLocationInBeacon = 0;
UCHAR TimIELocationInBeacon = 0;
NdisZeroMemory(pBeaconSync->BeaconBuf[apidx], HW_BEACON_OFFSET);
pBeaconSync->CapabilityInfoLocationInBeacon[apidx] = CapabilityInfoLocationInBeacon;
pBeaconSync->TimIELocationInBeacon[apidx] = TimIELocationInBeacon;
NdisZeroMemory(pBeaconSync->BeaconTxWI[apidx], TXWI_SIZE);
}
pBeaconSync->BeaconBitMap = 0;
pBeaconSync->DtimBitOn = 0;
pAd->CommonCfg.BeaconUpdateTimer.Repeat = TRUE;
pAd->CommonCfg.BeaconAdjust = 0;
pAd->CommonCfg.BeaconFactor = 0xffffffff / (pAd->CommonCfg.BeaconPeriod << 10);
pAd->CommonCfg.BeaconRemain = (0xffffffff % (pAd->CommonCfg.BeaconPeriod << 10)) + 1;
printk(RT28xx_CHIP_NAME "_BssBeaconStart:BeaconFactor=%d, BeaconRemain=%d!\n", pAd->CommonCfg.BeaconFactor, pAd->CommonCfg.BeaconRemain);
RTMPSetTimer(&pAd->CommonCfg.BeaconUpdateTimer, pAd->CommonCfg.BeaconPeriod);
}
}
VOID RT2870_BssBeaconInit(
IN RTMP_ADAPTER *pAd)
{
BEACON_SYNC_STRUCT *pBeaconSync;
int i;
NdisAllocMemory(pAd->CommonCfg.pBeaconSync, sizeof(BEACON_SYNC_STRUCT), MEM_ALLOC_FLAG);
if (pAd->CommonCfg.pBeaconSync)
{
pBeaconSync = pAd->CommonCfg.pBeaconSync;
NdisZeroMemory(pBeaconSync, sizeof(BEACON_SYNC_STRUCT));
for(i=0; i < HW_BEACON_MAX_COUNT; i++)
{
NdisZeroMemory(pBeaconSync->BeaconBuf[i], HW_BEACON_OFFSET);
pBeaconSync->CapabilityInfoLocationInBeacon[i] = 0;
pBeaconSync->TimIELocationInBeacon[i] = 0;
NdisZeroMemory(pBeaconSync->BeaconTxWI[i], TXWI_SIZE);
}
pBeaconSync->BeaconBitMap = 0;
//RTMPInitTimer(pAd, &pAd->CommonCfg.BeaconUpdateTimer, GET_TIMER_FUNCTION(BeaconUpdateExec), pAd, TRUE);
pBeaconSync->EnableBeacon = TRUE;
}
}
VOID RT2870_BssBeaconExit(
IN RTMP_ADAPTER *pAd)
{
BEACON_SYNC_STRUCT *pBeaconSync;
BOOLEAN Cancelled = TRUE;
int i;
if (pAd->CommonCfg.pBeaconSync)
{
pBeaconSync = pAd->CommonCfg.pBeaconSync;
pBeaconSync->EnableBeacon = FALSE;
RTMPCancelTimer(&pAd->CommonCfg.BeaconUpdateTimer, &Cancelled);
pBeaconSync->BeaconBitMap = 0;
for(i=0; i<HW_BEACON_MAX_COUNT; i++)
{
NdisZeroMemory(pBeaconSync->BeaconBuf[i], HW_BEACON_OFFSET);
pBeaconSync->CapabilityInfoLocationInBeacon[i] = 0;
pBeaconSync->TimIELocationInBeacon[i] = 0;
NdisZeroMemory(pBeaconSync->BeaconTxWI[i], TXWI_SIZE);
}
NdisFreeMemory(pAd->CommonCfg.pBeaconSync, HW_BEACON_OFFSET * HW_BEACON_MAX_COUNT, 0);
pAd->CommonCfg.pBeaconSync = NULL;
}
}
VOID BeaconUpdateExec(
IN PVOID SystemSpecific1,
IN PVOID FunctionContext,
IN PVOID SystemSpecific2,
IN PVOID SystemSpecific3)
{
PRTMP_ADAPTER pAd = (PRTMP_ADAPTER)FunctionContext;
LARGE_INTEGER tsfTime_a;//, tsfTime_b, deltaTime_exp, deltaTime_ab;
UINT32 delta, remain, remain_low, remain_high;
// BOOLEAN positive;
ReSyncBeaconTime(pAd);
RTMP_IO_READ32(pAd, TSF_TIMER_DW0, &tsfTime_a.u.LowPart);
RTMP_IO_READ32(pAd, TSF_TIMER_DW1, &tsfTime_a.u.HighPart);
//positive=getDeltaTime(tsfTime_a, expectedTime, &deltaTime_exp);
remain_high = pAd->CommonCfg.BeaconRemain * tsfTime_a.u.HighPart;
remain_low = tsfTime_a.u.LowPart % (pAd->CommonCfg.BeaconPeriod << 10);
remain = (remain_high + remain_low)%(pAd->CommonCfg.BeaconPeriod << 10);
delta = (pAd->CommonCfg.BeaconPeriod << 10) - remain;
pAd->CommonCfg.BeaconUpdateTimer.TimerValue = (delta >> 10) + 10;
}
となっています。
その後もう一度sudo make -C /lib/modules/$(uname -r)/build M=/usr/src/linux-source-2.6.32/drivers/staging/rt2870 modulesを行った結果は、次のとおりです。
yasushi@yasushi-desktop:~$ sudo make -C /lib/modules/$(uname -r)/build M=/usr/src/linux-source-2.6.32/drivers/staging/rt2870 modules
make: ディレクトリ `/usr/src/linux-headers-2.6.32-24-generic' に入ります
CC [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/2870_main_dev.o
LD [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/rt2870sta.o
Building modules, stage 2.
MODPOST 1 modules
WARNING: modpost: Found 1 section mismatch(es).
To see full details build your kernel with:
'make CONFIG_DEBUG_SECTION_MISMATCH=y'
LD [M] /usr/src/linux-source-2.6.32/drivers/staging/rt2870/rt2870sta.ko
make: ディレクトリ `/usr/src/linux-headers-2.6.32-24-generic' から出ます
yasushi@yasushi-desktop:~$
次は
yasushi@yasushi-desktop:~$ cd /lib/modules/2.6.32-24-generic/kernel/drivers/staging/rt2870 sudo mv rt2870sta.ko rt2870sta.ko.org
yasushi@yasushi-desktop:/lib/modules/2.6.32-24-generic/kernel/drivers/staging/rt2870$ sudo cp /usr/src/linux-source-2.6.32/drivers/staging/rt2870/rt2870sta.ko
cp: `/usr/src/linux-source-2.6.32/drivers/staging/rt2870/rt2870sta.ko'の次の目的場所ファイルオペランドがありません
詳しくは `cp --help' を実行して下さい。
という結果になりました。
ここまでのいきさつは、あってるのでしょうか・
なお、参考までにalias: usb:v0789p0164d*dc*dsc*dp*ic*isc*ip*
alias: usb:v0789p0163d*dc*dsc*dp*ic*isc*ip*
alias: usb:v0789p0162d*dc*dsc*dp*ic*isc*ip*
となって変化は、ありません。
追伸 大変みずらいコメント返信になってしましました。
原因調査のため2870_main_dev.cのファイル内容をすべて書き出しました。
オフライン
yasushi@yasushi-desktop:~$ cd /lib/modules/2.6.32-24-generic/kernel/drivers/staging/rt2870 sudo mv rt2870sta.ko rt2870sta.ko.org
これは少し変ですが、sudo mv rt2870sta.ko rt2870sta.ko.orgでファイル名を変更できて、
sudo cp /usr/src/linux-source-2.6.32/drivers/staging/rt2870/rt2870sta.koで作成したドライバをコピーしようとしていますが、
cp: `/usr/src/linux-source-2.6.32/drivers/staging/rt2870/rt2870sta.ko'の次の目的場所ファイルオペランドがありません詳しくは `cp --help' を実行して下さい。
のメッセージが出ていますのでコピーは失敗しています。
通常この状況では/lib/modules/2.6.32-24-generic/以下には、rt2870sta.koは存在しないので、modinfo rt2870sta | grep 0789コマンドはエラーメッセージ
ERROR: modinfo: could not open /lib/modules/2.6.32-24-generic/kernel/drivers/staging/rt2870/rt2870sta.ko: No such file or directory
が帰ってくるはずで、
alias: usb:v0789p0164d*dc*dsc*dp*ic*isc*ip*
alias: usb:v0789p0163d*dc*dsc*dp*ic*isc*ip*
alias: usb:v0789p0162d*dc*dsc*dp*ic*isc*ip*
の結果は不自然です。
/lib/modules/2.6.32-24-generic/以下にrt2870sta.koが存在しています。
modinfo rt2870sta | grep filenameでrt2870sta.koを探してファイル名を変更後、作成したrt2870sta.koをコピーして下さい。
オフライン
yasushi@yasushi-desktop:/lib/modules/2.6.32-24-generic/kernel/drivers/staging/rt2870$ sudo cp /usr/src/linux-source-2.6.32/drivers/staging/rt2870/rt2870sta.ko
の後に現在のディレクトリを表す「.」が必要なのでは?
つまり,
yasushi@yasushi-desktop:/lib/modules/2.6.32-24-generic/kernel/drivers/staging/rt2870$ sudo cp /usr/src/linux-source-2.6.32/drivers/staging/rt2870/rt2870sta.ko .
オフライン
もう一度二つのコメントから行った#20。#21の結果です。
yasushi@yasushi-desktop:~$ sudo make -C /lib/modules/$(uname -r)/build M=/usr/src/linux-source-2.6.32/drivers/staging/rt2870 modules
[sudo] password for yasushi:
make: ディレクトリ `/usr/src/linux-headers-2.6.32-24-generic' に入ります
Building modules, stage 2.
MODPOST 1 modules
WARNING: modpost: Found 1 section mismatch(es).
To see full details build your kernel with:
'make CONFIG_DEBUG_SECTION_MISMATCH=y'
make: ディレクトリ `/usr/src/linux-headers-2.6.32-24-generic' から出ます
yasushi@yasushi-desktop:~$ modinfo rt2870sta |grep filenama
yasushi@yasushi-desktop:~$ cd modules
yasushi@yasushi-desktop:~$ cmodprobe -l |geep rt28
No command 'geep' found, did you mean:
Command 'keep' from package 'keep' (universe)
Command 'beep' from package 'beep' (universe)
Command 'grep' from package 'grep' (main)
Command 'meep' from package 'meep' (universe)
geep: command not found
No command 'cmodprobe' found, did you mean:
Command 'modprobe' from package 'module-init-tools' (main)
cmodprobe: command not found
yasushi@yasushi-desktop:~$ modprobe -l |geep rt28
No command 'geep' found, did you mean:
Command 'keep' from package 'keep' (universe)
Command 'beep' from package 'beep' (universe)
Command 'grep' from package 'grep' (main)
Command 'meep' from package 'meep' (universe)
geep: command not found
yasushi@yasushi-desktop:~$ modprobe -l |grep rt28
kernel/drivers/net/wireless/rt2x00/rt2800usb.ko
kernel/drivers/staging/rt2860/rt2860sta.ko
kernel/drivers/staging/rt2870/rt2870sta.ko
yasushi@yasushi-desktop:~$ alias
alias egrep='egrep --color=auto'
alias fgrep='fgrep --color=auto'
alias grep='grep --color=auto'
alias l='ls -CF'
alias la='ls -A'
alias ll='ls -alF'
alias ls='ls --color=auto'
yasushi@yasushi-desktop:~$
yasushi@yasushi-desktop:~$ cd /lib/modules/2.6.32-24-generic
yasushi@yasushi-desktop:/lib/modules/2.6.32-24-generic$ cd kernel/drivers/staging/rt2870
yasushi@yasushi-desktop:/lib/modules/2.6.32-24-generic/kernel/drivers/staging/rt2870$ sudo cp /usr/src/linux-source-2.6.32/drivers/staging/rt2870/rt2870sta.ko .
yasushi@yasushi-desktop:/lib/modules/2.6.32-24-generic/kernel/drivers/staging/rt2870$ alias
alias egrep='egrep --color=auto'
alias fgrep='fgrep --color=auto'
alias grep='grep --color=auto'
alias l='ls -CF'
alias la='ls -A'
alias ll='ls -alF'
alias ls='ls --color=auto'
yasushi@yasushi-desktop:/lib/modules/2.6.32-24-generic/kernel/drivers/staging/rt2870$ dir
rt2870sta.ko
yasushi@yasushi-desktop:/lib/modules/2.6.32-24-generic/kernel/drivers/staging/rt2870$ cd /etc
yasushi@yasushi-desktop:/etc$ cd Wireless
yasushi@yasushi-desktop:/etc/Wireless$ dir
RT3070STA
yasushi@yasushi-desktop:/etc/Wireless$
オフライン
最後に,「RalinkからドライバをDLして,設定ファイルをコピーしろ」と書いてありますが,これはやりましたか?
オフライン
uasudhi04さん による投稿:
もう一度二つのコメントから行った#20。#21の結果です。
#20ではmakeをやり直せとか、modprobe,alias ,/lib/modules...,/etc/wireless...の結果がほしいなど何処にも書いていない。
オフライン
さて、jackalope様 失礼しました。
さて、今日は、もう一度 チャレンジしました。
yasushi@yasushi-desktop:~$ dir
Documents examples.desktop デスクトップ ピクチャ 草原.bmp
Music ダウンロード ドキュメント ミュージック
Pictures テンプレート ビデオ 公開
yasushi@yasushi-desktop:~$ cd ダウンロード
yasushi@yasushi-desktop:~/ダウンロード$ dir
2010_06_25_RT2870_Linux_STA_v2.4.0.0 ubuntu-10.04-server-i386.iso
2010_06_25_RT2870_Linux_STA_v2.4.0.0.tar.bz2 viewtopic.php.html
kojima.jpg viewtopic.php_files
maverick-alternate-i386.iso
yasushi@yasushi-desktop:~/ダウンロード$ cd 2010_06_25_RT2870_Linux_STA_v2.4.0.0
yasushi@yasushi-desktop:~/ダウンロード/2010_06_25_RT2870_Linux_STA_v2.4.0.0$ dirLICENSE\ ralink-firmware.txt RT2870STACard.dat os
Makefile common sta
README_STA include sta_ate_iwpriv_usage.txt
RT2870STA.dat iwpriv_usage.txt tools
yasushi@yasushi-desktop:~/ダウンロード/2010_06_25_RT2870_Linux_STA_v2.4.0.0$
yasushi@yasushi-desktop:~/ダウンロード/2010_06_25_RT2870_Linux_STA_v2.4.0.0$ cd /
yasushi@yasushi-desktop:/$ /etc
bash: /etc: はディレクトリです
yasushi@yasushi-desktop:/$ cd /etc
yasushi@yasushi-desktop:/etc$ cd Wireless/
yasushi@yasushi-desktop:/etc/Wireless$ sudo cp ~/RT2870STA.dat /etc/Wireless/RT3070STA/RT3070STA.dat
[sudo] password for yasushi:
yasushi@yasushi-desktop:/etc/Wireless$ alias
alias egrep='egrep --color=auto'
alias fgrep='fgrep --color=auto'
alias grep='grep --color=auto'
alias l='ls -CF'
alias la='ls -A'
alias ll='ls -alF'
alias ls='ls --color=auto'
yasushi@yasushi-desktop:/etc/Wireless$ modprobe -l |grep rt28
kernel/drivers/net/wireless/rt2x00/rt2800usb.ko
kernel/drivers/staging/rt2860/rt2860sta.ko
kernel/drivers/staging/rt2870/rt2870sta.ko
yasushi@yasushi-desktop:/etc/Wireless$ cmodprobe -l |geep rt28
No command 'geep' found, did you mean:
Command 'keep' from package 'keep' (universe)
Command 'beep' from package 'beep' (universe)
Command 'grep' from package 'grep' (main)
Command 'meep' from package 'meep' (universe)
geep: command not found
No command 'cmodprobe' found, did you mean:
Command 'modprobe' from package 'module-init-tools' (main)
cmodprobe: command not found
yasushi@yasushi-desktop:/etc/Wireless$ modprobe -l |geep rt28
No command 'geep' found, did you mean:
Command 'keep' from package 'keep' (universe)
Command 'beep' from package 'beep' (universe)
Command 'grep' from package 'grep' (main)
Command 'meep' from package 'meep' (universe)
geep: command not found
yasushi@yasushi-desktop:/etc/Wireless$
参考までに以下のコマンドを行いました。
yasushi@yasushi-desktop:~$ lsusb
Bus 007 Device 002: ID 04b8:082f Seiko Epson Corp. Stylus DX4050
Bus 007 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 006 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 003: ID 0789:0166 Logitec Corp.
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
yasushi@yasushi-desktop:~$ ifconfig
eth0 Link encap:イーサネット ハードウェアアドレス 00:07:40:8f:dc:73
UP BROADCAST MULTICAST MTU:1500 メトリック:1
RXパケット:0 エラー:0 損失:0 オーバラン:0 フレーム:0
TXパケット:0 エラー:0 損失:0 オーバラン:0 キャリア:0
衝突(Collisions):0 TXキュー長:1000
RXバイト:0 (0.0 B) TXバイト:0 (0.0 B)
割り込み:10 ベースアドレス:0xb400
lo Link encap:ローカルループバック
inetアドレス:127.0.0.1 マスク:255.0.0.0
inet6アドレス: ::1/128 範囲:ホスト
UP LOOPBACK RUNNING MTU:16436 メトリック:1
RXパケット:67 エラー:0 損失:0 オーバラン:0 フレーム:0
TXパケット:67 エラー:0 損失:0 オーバラン:0 キャリア:0
衝突(Collisions):0 TXキュー長:0
RXバイト:8082 (8.0 KB) TXバイト:8082 (8.0 KB)
wlan0 Link encap:イーサネット ハードウェアアドレス 00:01:8e:bf:9c:78
inet6アドレス: fe80::201:8eff:febf:9c78/64 範囲:リンク
UP BROADCAST MULTICAST MTU:1500 メトリック:1
RXパケット:5903 エラー:0 損失:0 オーバラン:0 フレーム:0
TXパケット:11232 エラー:0 損失:0 オーバラン:0 キャリア:0
衝突(Collisions):0 TXキュー長:1000
RXバイト:1621941 (1.6 MB) TXバイト:885960 (885.9 KB)
yasushi@yasushi-desktop:~$ iwconfig
lo no wireless extensions.
eth0 no wireless extensions.
wlan0 RTxx70 Wireless ESSID:"11n-AP" Nickname:"RT3070STA"
Mode:Auto Frequency=2.412 GHz Access Point: Not-Associated
Bit Rate:1 Mb/s
RTS thr:off Fragment thr:off
Link Quality=10/100 Signal level:0 dBm Noise level:-97 dBm
Rx invalid nwid:0 Rx invalid crypt:0 Rx invalid frag:0
Tx excessive retries:0 Invalid misc:0 Missed beacon:0
yasushi@yasushi-desktop:~$ lsmod
Module Size Used by
nls_iso8859_1 3249 1
nls_cp437 4919 1
vfat 8933 1
fat 47767 1 vfat
sis 4640 2
drm 162377 3 sis
sisfb 232419 1 sis
binfmt_misc 6587 1
snd_cmipci 30437 2
gameport 9089 1 snd_cmipci
snd_pcm_oss 35308 0
snd_mixer_oss 13746 1 snd_pcm_oss
snd_pcm 70662 2 snd_cmipci,snd_pcm_oss
snd_page_alloc 7076 1 snd_pcm
snd_opl3_lib 8966 1 snd_cmipci
snd_hwdep 5412 1 snd_opl3_lib
snd_mpu401_uart 5617 1 snd_cmipci
snd_seq_dummy 1338 0
snd_seq_oss 26726 0
snd_seq_midi 4557 0
snd_rawmidi 19056 2 snd_mpu401_uart,snd_seq_midi
snd_seq_midi_event 6003 2 snd_seq_oss,snd_seq_midi
snd_seq 47263 6 snd_seq_dummy,snd_seq_oss,snd_seq_midi,snd_seq_midi_event
fbcon 35102 71
tileblit 2031 1 fbcon
snd_timer 19098 3 snd_pcm,snd_opl3_lib,snd_seq
font 7557 1 fbcon
bitblit 4707 1 fbcon
softcursor 1189 1 bitblit
snd_seq_device 5700 6 snd_opl3_lib,snd_seq_dummy,snd_seq_oss,snd_seq_midi,snd_rawmidi,snd_seq
vga16fb 11385 1
psmouse 63245 0
snd 54148 16 snd_cmipci,snd_pcm_oss,snd_mixer_oss,snd_pcm,snd_opl3_lib,snd_hwdep,snd_mpu401_uart,snd_seq_oss,snd_rawmidi,snd_seq,snd_timer,snd_seq_device
vgastate 8961 1 vga16fb
ppdev 5259 0
sis_agp 4047 1
lp 7028 0
usblp 10481 0
parport_pc 25962 1
serio_raw 3978 0
rt2870sta 460434 1
soundcore 6620 1 snd
shpchp 28820 0
i2c_sis630 4757 0
agpgart 31724 2 drm,sis_agp
parport 32635 3 ppdev,lp,parport_pc
usb_storage 39425 0
ohci1394 26950 0
8139too 18545 0
ieee1394 81181 1 ohci1394
8139cp 16186 0
mii 4381 2 8139too,8139cp
floppy 53016 0
yasushi@yasushi-desktop:~$ alias
alias egrep='egrep --color=auto'
alias fgrep='fgrep --color=auto'
alias grep='grep --color=auto'
alias l='ls -CF'
alias la='ls -A'
alias ll='ls -alF'
alias ls='ls --color=auto'
yasushi@yasushi-desktop:~$
オフライン