how to build the rt2x00 drivers

Live forum: http://rt2x00.serialmonkey.com/viewtopic.php?t=5136

pmilosev

22-12-2008 18:57:08

Hi

I have debian etch (kernel 2.6.18) with Level One (RT61 chipset) wifi card.
I need to run the wifi in MASTER mode

The original Ralink drivers do not support MASTER mode (I also could not set this mode using the legacy drivers you provide)
I have also tried with the rt2x00 drivers found in debian repository, but failed again (sources in debian repository are from 2006)

So I need an short step by step guide on how can I build a newer version of the drivers.
Do I need to recompile the whole kernel ?
If NO ... how can I compile only rt61pci.ko (and dependencies) from the kernel sources I got with GIT ?
If YES ... how to do this (I tried this but I couldn't find the rt61pci.ko files ... only the object files rt61pci.o) ?
Can I only install the rt2x00 drivers or I will need to instal the whole recompiled kernel ?
If I install the whole kernel then how can I configure it to match my current kernel (with just the rt2x00 drivers included) ?

I spent many sleepless nights last week trying to get things right but ...
So any help would be appreciated.

thanks

IvD

22-12-2008 19:00:12


Do I need to recompile the whole kernel ?
[/quotev2hujtv8]

yes Or you can use the wireless-compat
Check linuxwireless.org


If YES ... how to do this (I tried this but I couldn't find the rt61pci.ko files ... only the object files rt61pci.o) ?
[/quotev2hujtv8]

Google Howto compile Linux kernel


Can I only install the rt2x00 drivers or I will need to instal the whole recompiled kernel ?
[/quotev2hujtv8]

Entire kernel


If I install the whole kernel then how can I configure it to match my current kernel (with just the rt2x00 drivers included) ?
[/quotev2hujtv8]

That is discussed in the results you get from Google as well.

pmilosev

22-12-2008 19:09:16

) 10x

now at least I know I would need to recompile and install the whole kernel
since wireless-compat seams to work for kernels > 2.18

regards

pmilosev

22-12-2008 23:06:46

ok

I think I finally got it )
Before I was confused because I did not know the version
of the kernel I have checked out following your GIT guide
http//rt2x00.serialmonkey.com/wiki/ind ... structions

But now I have found out that there is a tag for every kernel version
so the appropriate cg-clone command would be
cg-clone git//git.kernel.org/pub/scm/linux/kern ... .git#XXXXX

In my case the XXXXX=v2.6.18-rc4

For debian users here is a simple but good tutorial on how to recompile the kernel
http//www.howtoforge.com/kernel_compil ... an_etch_p2

ATM I am still checking out the kernel sources ...
I will post the results (POSITIVE / NEGATIVE) as soon as I finish the whole process

regards

IvD

22-12-2008 23:10:00


But now I have found out that there is a tag for every kernel version
so the appropriate cg-clone command would be
cg-clone git//git.kernel.org/pub/scm/linux/kern ... .git#XXXXX

In my case the XXXXX=v2.6.18-rc4
[/quote2xwcdvvk]

Normally users would go for the "latest" version, so using a tag is not needed.
if you are checking out a specific vanilla version anyway, you might as well download the kernel from kernel.org.

pmilosev

22-12-2008 23:23:48

hmmm

but checking out the HEAD ... it would be kernel version > 2.6.28
and I am not sure if everything would end up OK

that's why I was looking for kernel version matching my system
compile the kernel with exact same configuration from /boot/MY_SYSTEM_CONFIG
and just change the flags for the RT drivers I need

but if you suggest to use the HEAD version then ...

regards

IvD

22-12-2008 23:35:28

Yes, but you are checking out a tag which is released as 2.6.18-rc4 (why rc? and not the actual 2.6.18 release itself?)
besides there was no rt2x00 in 2.6.18, rt2x00 was introduced in 2.6.22 and didn't had Master mode capabilities until 2.6.26.

pmilosev

22-12-2008 23:44:44

rc4 because my current kernel version is 2.6.18-4
... you are right the rt2x00 drivers are in the kernel
after 2008 (2 years later) )

it is too late to have everything in mind

well then I guess I will have to give it a try to the HEAD version

10x for the tips

regards

IvD

22-12-2008 23:49:03

2.6.18-4 does not equal 2.6.18-rc4

rc stands for Release Candidate and not for the final version.
2.6.18-4 means the 4 version of 2.6.18 used by debian, this might be equal to 2.6.18-r4 (revision 4 of that kernel) or version 4 for the Debian release management.

pmilosev

23-12-2008 07:47:22

ok

thanks a lot

regards

pmilosev

26-12-2008 21:56:44

OK ... me again

These days I have played around recompiling the kernel
until I finally managed to configure it well to support my old functionality

I have also build the rt2x00 / rt61pci modules

When I tried to bring the interface (wlan0) up
the system was complaining about missing firmware (debug output enabled)

Do I need the original rt*.bin firmware files from Ralink
or I need something else ?

I have tried copying the original Ralink firmware (http//www.ralinktech.com.tw/data/drive ... .2.tar.bz2)
and it works fine for Managed and Ad-Hoc mode, but
I can not set master mode
Error for wireless request "Set Mode" (8B06)
SET failed on device wlan0 ; Invalid argument.

I really need help on this
regards

IvD

27-12-2008 11:27:21

Use search button regarding the "iwconfig wlan0 mode master" it has been discussed in dozens of topics by now.

piotrv

06-02-2009 15:19:49

[quote1b85h2vx]Do I need to recompile the whole kernel ?


[quote1b85h2vx]yes Or you can use the wireless-compat
Check linuxwireless.org[/quote1b85h2vx][/quote1b85h2vx]
Hi ivo

I installed the compat-wireless-old package (since I run 2.6.24) to shorcut recompiling the whole kernel.

[code1b85h2vx]
> modinfo rt61pci
filename: /lib/modules/2.6.24-etchnhalf.1-686/updates/drivers/net/wireless/rt2x00/rt61pci.ko
author: http://rt2x00.serialmonkey.com
version: 2.1.8
description: Ralink RT61 PCI & PCMCIA Wireless LAN driver.
firmware: rt2561.bin
firmware: rt2561s.bin
firmware: rt2661.bin
license: GPL
vermagic: 2.6.24-etchnhalf.1-686 SMP mod_unload 686
depends: rt2x00lib,rt2x00pci,crc-itu-t,eeprom_93cx6
alias: pci:v00001814d00000301sv*sd*bc*sc*i*
alias: pci:v00001814d00000302sv*sd*bc*sc*i*
alias: pci:v00001814d00000401sv*sd*bc*sc*i*
srcversion: 0B2FDADE4397EEE5231D058[/code1b85h2vx]
iwconfig, iwlist wlan0 scan etc. ok

I am trying now wpa_supplicant

My wpa_supplicant.conf
[code1b85h2vx]
ctrl_interface=/var/run/wpa_supplicant
ctrl_interface_group=0

ap_scan=0

#The Network:
network={
ssid="<my_ssid>"
scan_ssid=1
# WPA2
proto=RSN
# AES
pairwise=CCMP
group=CCMP
key_mgmt=WPA-PSK
psk=<my_hexcode>
priority=5
}
[/code1b85h2vx]
[b1b85h2vx]Note[/b1b85h2vx]
[list1b85h2vx]
[*1b85h2vx]scan_ssid=2 is not allowed (max value 1) so how do I set for a 'hidden" ssid?[/*m1b85h2vx]
[*1b85h2vx]my psk seems to be too long (> 63 characters, not allowed)[/*m1b85h2vx][/listu1b85h2vx]
[code1b85h2vx]> wpa_supplicant -B -iwlan0 -Dwext -c/etc/wpa_supplicant/wpa_supplicant.conf

ioctl[SIOCSIWAUTH]: Operation not supported [/code1b85h2vx]
? ?

Do I still need to recompile the kernel and set some flags ?

A last resort might be ndiswrapper, but I am not sure if this will be less memory efficient (128MB RAM on my old notebook) and I rather have the rt2x00 working....

Groetjes,

Peter

IvD

06-02-2009 18:35:53


  • scan_ssid=2 is not allowed (max value 1) so how do I set for a 'hidden" ssid?
    [/quote3mbppgcr]

    Well you have to know the essid of the AP you are connecting to. The "hidden" ssid is only a fake and bad security feature where the client has to send the essid to the AP when associating.


    • my psk seem to be too long (> 63 characters, not allowed)
      [/quote3mbppgcr]

      Well then you have to check the wpa_supplicant manuals.

      ioctl[SIOCSIWAUTH] Operation not supported [/quote3mbppgcr]

      This doesn't sound like a problem, and can be ignored.

piotrv

06-02-2009 22:23:13



ioctl[SIOCSIWAUTH] Operation not supported [/quote3ub6u24x]
This doesn't sound like a problem, and can be ignored.

.....you have to check the wpa_supplicant manuals.
[/quote3ub6u24x]
You got a point. I have been lazy ;-)
After reading the wpa_supplicant documentation I checked by dynamically configuring the interface thru [i3ub6u24x]wpa_cli [/i3ub6u24x] and managed to connect to the AP with WPA2 encryption -)

Hidden ssid is also working since I put ap_scan=2 in the main and scan_ssid=1in the network config
(yes, an illusive protection, but hey, I just wanted to know if it's working with rt2x00 !)

So I am a very happy with the rt2x00 drivers, even if I am not using the most recent.
It's doing a fine job now anyway.

Thanks for the feedback and the serialmonkey people for all the effort put into the development of it!

Peter

[code3ub6u24x]>wpa_cli status
Selected interface 'wlan0'
bssid=00:36:25:14:a1:6b
ssid=<my_ssid>
id=0
pairwise_cipher=CCMP
group_cipher=CCMP
key_mgmt=WPA2-PSK
wpa_state=COMPLETED
ip_address=10.0.0.33[/code3ub6u24x]

anon4321

09-04-2009 01:07:07

Hello All,

I asked about finding support for a new version of a Linksys WUSB54GC using a RT2070 which seems similar to a RT3080 which I'm told is supported by the rt2800usb driver which is currently in development. I was instructed to try using the rt2x00.git which I took as meaning that I needed to download the repository which has both the latest kernel and rt2800usb driver and build everything.

I REALLY don't know what I'm doing so I found this thread.

It seems that wireless-compat is one way around having to figure out how to build a kernel.

My question is how up-to-date is the source pulled from wireless-compat compared to the rt2x00.git repository? Could I use the wireless-compat source to get and build the rt2800usb driver?

Sorry if I'm way off, this is a lot to absorb...

Thanks in advance.

anon4321

09-04-2009 01:19:04

Sorry, it looks like that from the threads titled "rt2800 testing" and "Next-generation rt2x00 drivers and the wireless-testing tree" I'm guessing that I would need to pull the rt2x00.git repository.

Is this my only option?

IvD

09-04-2009 08:58:01

At this moment yes, if you want to test the rt2800 driver, then you need to use git.
Because of some bugs in the rt2800 drivers they have not yet been released.
On our wiki is a page with instructions on how to pull the rt2x00.git tree
http//rt2x00.serialmonkey.com/wiki/ind ... structions