LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Wireless Networking (https://www.linuxquestions.org/questions/linux-wireless-networking-41/)
-   -   Wireless range reduced on linux than windows (https://www.linuxquestions.org/questions/linux-wireless-networking-41/wireless-range-reduced-on-linux-than-windows-807249/)

paspa 05-11-2010 07:12 PM

Wireless range reduced on linux than windows
 
Hi, i've just decided to install the latest version of xubuntu and i've encountered a strange behavior of my wireless adapter.

Before, when windows was installed on my laptop, the connection with my ap was good, now using xubuntu (as well with other linux distro) in the same place of the house the connection is around 40% but is extremely hard to hold the connection for more than 1 minute and sometimes it doesn't simply connects to the network. My laptop should have a RaLink RT2500 mPCI card, but launching lspci it returns that I have an rt61, I think it's maybe cause of a generic driver.

Someone has any advice for keeping up the connection?

thanks in advance.



P.S. Sorry for writing mistake, i'm Italian

Larry Webb 05-13-2010 05:46 AM

According to Ralink you have the wrong driver



From what I could quickly read the driver you have is supposed to replace the original driver.


I personally have not had to deal with this problem but you will probably have to blacklist the driver you have now and install the right driver or use windows driver with ndiswrapper.

paspa 05-13-2010 06:22 AM

Hi , thanks for your answer, i've tried to install the driver given by RaLink, but despite I followed the instruction the make command keep giving me this:
Quote:

make -C /lib/modules/2.6.32-22-generic/build SUBDIRS=/usr/src/RT61/Module modules
make[1]: ingresso nella directory «/usr/src/linux-headers-2.6.32-22-generic»
scripts/Makefile.build:49: *** CFLAGS was changed in "/usr/src/RT61/Module/Makefile". Fix it to use EXTRA_CFLAGS. Arresto.
make[1]: *** [_module_/usr/src/RT61/Module] Errore 2
make[1]: uscita dalla directory «/usr/src/linux-headers-2.6.32-22-generic»
make: *** [all] Errore 2
I've searched a lot around severals forums, I followed about 10 guides installing build-essential, headers, kernel sources. Nothing happened, still the error quoted.

Any other advice?

I really apreciate your help.

Nicola

Larry Webb 05-13-2010 11:15 AM

I have not experienced ralink problems.

I did have a similar problem with a 4306 broadcom card. I ended up using ndiswrapper with the windows driver which is painful because you have to blacklist all the native drivers. With the native driver it would not connect half the time and if it did the signal was low.

brucehinrichs 05-13-2010 11:43 AM

Seems your problem is:
Quote:

scripts/Makefile.build:49: *** CFLAGS was changed in "/usr/src/RT61/Module/Makefile". Fix it to use EXTRA_CFLAGS. Arresto.
If you open the Makefile (/usr/src/RT61/Module/Makefile) with your favorite text editor (as root), go to line 49 and replace every instance of 'CFLAGS' with 'EXTRA_CFLAGS', that should solve the error.

EDIT: Just thought of something: that probably isn't the only instance of 'CFLAGS', only the first. To replace all instances of 'CFLAGS' you could do (also as root):
Code:

sed 's/CFLAGS/CFLAGS_EXTRA/' /usr/src/RT61/Module/Makefile
to find and replace every instance .

paspa 05-13-2010 01:59 PM

Tomorrow i'll try, thanks for now :D

paspa 05-14-2010 01:03 AM

Hi I've tryed your solution, it gives me other errors, looks like there is something wrong in rtmp_main.c.

I've figured that the struct net_device hasn't any member called priv, and so on for other struct. In the quoted output of make I marked in red an odd error, it doesn't find my linux header (that i've installed) and the odd thing is that is looking in a x86 folder (scrolling down you can see the complete path), i'm using an amd64 version of ubuntu. Peraphs I have to change something in some file telling him i've an amd64 architecture?

Quote:

CC [M] /usr/src/RT61/Module/rtmp_main.o
In file included from include/linux/gfp.h:4,
from include/linux/kmod.h:22,
from include/linux/module.h:13,
from /usr/src/RT61/Module/rt_config.h:69,
from /usr/src/RT61/Module/rtmp_main.c:40:
include/linux/mmzone.h:18:26: error: linux/bounds.h: Nessun file o directory
include/linux/mmzone.h:258:5: warning: "MAX_NR_ZONES" is not defined
include/linux/mmzone.h:260:7: warning: "MAX_NR_ZONES" is not defined
include/linux/mmzone.h:262:7: warning: "MAX_NR_ZONES" is not defined
In file included from include/linux/gfp.h:4,
from include/linux/kmod.h:22,
from include/linux/module.h:13,
from /usr/src/RT61/Module/rt_config.h:69,
from /usr/src/RT61/Module/rtmp_main.c:40:
include/linux/mmzone.h:300: error: ‘MAX_NR_ZONES’ undeclared here (not in a function)
In file included from /usr/src/linux-headers-2.6.32-22-generic/arch/x86/include/asm/pci.h:4,
from include/linux/pci.h:1126,
from /usr/src/RT61/Module/rt_config.h:79,
from /usr/src/RT61/Module/rtmp_main.c:40:
include/linux/mm.h:454:63: warning: "NR_PAGEFLAGS" is not defined
include/linux/mm.h:502:62: warning: "NR_PAGEFLAGS" is not defined
In file included from /usr/src/linux-headers-2.6.32-22-generic/arch/x86/include/asm/unistd.h:5,
from include/linux/unistd.h:7,
from /usr/src/linux-headers-2.6.32-22-generic/arch/x86/include/asm/seccomp_64.h:4,
from /usr/src/linux-headers-2.6.32-22-generic/arch/x86/include/asm/seccomp.h:4,
from include/linux/seccomp.h:8,
from include/linux/sched.h:80,
from /usr/src/linux-headers-2.6.32-22-generic/arch/x86/include/asm/compat.h:8,
from include/linux/compat.h:14,
from include/linux/wireless.h:693,
from /usr/src/RT61/Module/rt_config.h:84,
from /usr/src/RT61/Module/rtmp_main.c:40:
/usr/src/linux-headers-2.6.32-22-generic/arch/x86/include/asm/unistd_64.h:693:29: error: asm/asm-offsets.h: Nessun file o directory

/usr/src/RT61/Module/rtmp_main.c: In function ‘rt61_get_drvinfo’:
/usr/src/RT61/Module/rtmp_main.c:78: error: ‘struct net_device’ has no member named ‘priv’
/usr/src/RT61/Module/rtmp_main.c:78: warning: unused variable ‘pAd’
/usr/src/RT61/Module/rtmp_main.c: In function ‘rt61_get_regs_len’:
/usr/src/RT61/Module/rtmp_main.c:97: warning: no return statement in function returning non-void
/usr/src/RT61/Module/rtmp_main.c: In function ‘rt61_get_regs’:
/usr/src/RT61/Module/rtmp_main.c:103: error: ‘struct net_device’ has no member named ‘priv’
/usr/src/RT61/Module/rtmp_main.c:104: warning: unused variable ‘counter’
/usr/src/RT61/Module/rtmp_main.c:103: warning: unused variable ‘pAd’
/usr/src/RT61/Module/rtmp_main.c: In function ‘rt61_ethtool_get_link’:
/usr/src/RT61/Module/rtmp_main.c:120: warning: unused variable ‘pAd’
/usr/src/RT61/Module/rtmp_main.c:130: warning: no return statement in function returning non-void
/usr/src/RT61/Module/rtmp_main.c: In function ‘rt61_get_eeprom_len’:
/usr/src/RT61/Module/rtmp_main.c:139: warning: no return statement in function returning non-void
/usr/src/RT61/Module/rtmp_main.c: In function ‘rt61_get_eeprom’:
/usr/src/RT61/Module/rtmp_main.c:145: error: ‘struct net_device’ has no member named ‘priv’
/usr/src/RT61/Module/rtmp_main.c:146: warning: unused variable ‘counter’
/usr/src/RT61/Module/rtmp_main.c:145: warning: unused variable ‘pAd’
/usr/src/RT61/Module/rtmp_main.c:159: warning: no return statement in function returning non-void
/usr/src/RT61/Module/rtmp_main.c: At top level:
/usr/src/RT61/Module/rtmp_main.c:169: warning: initialization from incompatible pointer type
/usr/src/RT61/Module/rtmp_main.c: In function ‘RT61_probe’:
/usr/src/RT61/Module/rtmp_main.c:238: warning: assignment discards qualifiers from pointer target type
/usr/src/RT61/Module/rtmp_main.c:287: error: ‘struct net_device’ has no member named ‘priv’
/usr/src/RT61/Module/rtmp_main.c:290: error: ‘struct net_device’ has no member named ‘priv’
/usr/src/RT61/Module/rtmp_main.c:294: error: ‘struct net_device’ has no member named ‘priv’
/usr/src/RT61/Module/rtmp_main.c:305: error: ‘struct net_device’ has no member named ‘open’
/usr/src/RT61/Module/rtmp_main.c:306: error: ‘struct net_device’ has no member named ‘hard_start_xmit’
/usr/src/RT61/Module/rtmp_main.c:307: error: ‘struct net_device’ has no member named ‘stop’
/usr/src/RT61/Module/rtmp_main.c:308: error: ‘struct net_device’ has no member named ‘get_stats’
/usr/src/RT61/Module/rtmp_main.c:317: error: ‘struct net_device’ has no member named ‘set_multicast_list’
/usr/src/RT61/Module/rtmp_main.c:318: error: ‘struct net_device’ has no member named ‘do_ioctl’
/usr/src/RT61/Module/rtmp_main.c:328: error: ‘struct net_device’ has no member named ‘validate_addr’
/usr/src/RT61/Module/rtmp_main.c:344: warning: ISO C90 forbids mixed declarations and code
/usr/src/RT61/Module/rtmp_main.c: In function ‘RT61_open’:
/usr/src/RT61/Module/rtmp_main.c:422: error: ‘struct net_device’ has no member named ‘priv’
/usr/src/RT61/Module/rtmp_main.c:472: warning: passing argument 2 of ‘request_irq’ from incompatible pointer type
include/linux/interrupt.h:117: note: expected ‘irq_handler_t’ but argument is of type ‘enum irqreturn_t (*)(int, void *, struct pt_regs *)’
/usr/src/RT61/Module/rtmp_main.c: In function ‘RTMPSendPackets’:
/usr/src/RT61/Module/rtmp_main.c:627: error: ‘struct net_device’ has no member named ‘priv’
/usr/src/RT61/Module/rtmp_main.c: In function ‘RTMPIsr’:
/usr/src/RT61/Module/rtmp_main.c:713: error: ‘struct net_device’ has no member named ‘priv’
/usr/src/RT61/Module/rtmp_main.c: In function ‘RT61_get_wireless_stats’:
/usr/src/RT61/Module/rtmp_main.c:825: error: ‘struct net_device’ has no member named ‘priv’
/usr/src/RT61/Module/rtmp_main.c: In function ‘RT61_get_ether_stats’:
/usr/src/RT61/Module/rtmp_main.c:873: error: ‘struct net_device’ has no member named ‘priv’
/usr/src/RT61/Module/rtmp_main.c: In function ‘RT61_close’:
/usr/src/RT61/Module/rtmp_main.c:942: error: ‘struct net_device’ has no member named ‘priv’
/usr/src/RT61/Module/rtmp_main.c: In function ‘RT61_remove_one’:
/usr/src/RT61/Module/rtmp_main.c:1002: error: ‘struct net_device’ has no member named ‘priv’
make[2]: *** [/usr/src/RT61/Module/rtmp_main.o] Errore 1
make[1]: *** [_module_/usr/src/RT61/Module] Errore 2
make[1]: uscita dalla directory «/usr/src/linux-headers-2.6.32-22-generic»
make: *** [all] Errore 2
thanks in advance. We made a new step :D

paspa 05-14-2010 07:08 AM

HI, i've managed to resolve the "no such file" error.

Now I have only the "has no member called priv" error remaning, is it possible that in the newer version of the kernel what was called priv now has changed name in something else?

thanks for you help.


Nicola


All times are GMT -5. The time now is 11:24 AM.