# [SOLVED] RaLink Device 5390

## ChrisCummins

Hi,

I have a new laptop and decided to take the opportunity to migrate over from Arch to Gentoo. So far I'm having a wail of a time - in the last few days I've learned more about Linux than in all the previous years combined! I've hit a brick wall though - the laptop uses a wireless card that doesn't seem to be supported by default. Neither Gentoo or Ubuntu live disks recognised it and every 'how to' guide seems to be outdated or broken.

I downloaded the latest driver from the Ralink website (2011_0406_RT5390_RT5392_Linux_STA_V2.5.0.3_DPO) and get this error when I run make:

```

make -C tools

make[1]: Entering directory `/home/ellis/Downloads/RT/2011_0406_RT5390_RT5392_Linux_STA_V2.5.0.3_DPO/tools'

gcc -g bin2h.c -o bin2h

make[1]: Leaving directory `/home/ellis/Downloads/RT/2011_0406_RT5390_RT5392_Linux_STA_V2.5.0.3_DPO/tools'

/home/ellis/Downloads/RT/2011_0406_RT5390_RT5392_Linux_STA_V2.5.0.3_DPO/tools/bin2h

cp -f os/linux/Makefile.6 /home/ellis/Downloads/RT/2011_0406_RT5390_RT5392_Linux_STA_V2.5.0.3_DPO/os/linux/Makefile

make -C /lib/modules/3.1.6-gentoo/build SUBDIRS=/home/ellis/Downloads/RT/2011_0406_RT5390_RT5392_Linux_STA_V2.5.0.3_DPO/os/linux modules

make[1]: Entering directory `/usr/src/linux-3.1.6-gentoo'

  CC [M]  /home/ellis/Downloads/RT/2011_0406_RT5390_RT5392_Linux_STA_V2.5.0.3_DPO/os/linux/../../os/linux/sta_ioctl.o

/home/ellis/Downloads/RT/2011_0406_RT5390_RT5392_Linux_STA_V2.5.0.3_DPO/os/linux/../../os/linux/sta_ioctl.c:2225:2: error: unknown field 'private' specified in initializer

/home/ellis/Downloads/RT/2011_0406_RT5390_RT5392_Linux_STA_V2.5.0.3_DPO/os/linux/../../os/linux/sta_ioctl.c:2225:2: warning: initialization from incompatible pointer type

/home/ellis/Downloads/RT/2011_0406_RT5390_RT5392_Linux_STA_V2.5.0.3_DPO/os/linux/../../os/linux/sta_ioctl.c:2226:2: error: unknown field 'num_private' specified in initializer

/home/ellis/Downloads/RT/2011_0406_RT5390_RT5392_Linux_STA_V2.5.0.3_DPO/os/linux/../../os/linux/sta_ioctl.c:2226:2: warning: excess elements in struct initializer

/home/ellis/Downloads/RT/2011_0406_RT5390_RT5392_Linux_STA_V2.5.0.3_DPO/os/linux/../../os/linux/sta_ioctl.c:2226:2: warning: (near initialization for 'rt28xx_iw_handler_def')

/home/ellis/Downloads/RT/2011_0406_RT5390_RT5392_Linux_STA_V2.5.0.3_DPO/os/linux/../../os/linux/sta_ioctl.c:2227:2: error: unknown field 'private_args' specified in initializer

/home/ellis/Downloads/RT/2011_0406_RT5390_RT5392_Linux_STA_V2.5.0.3_DPO/os/linux/../../os/linux/sta_ioctl.c:2227:26: warning: excess elements in struct initializer

/home/ellis/Downloads/RT/2011_0406_RT5390_RT5392_Linux_STA_V2.5.0.3_DPO/os/linux/../../os/linux/sta_ioctl.c:2227:26: warning: (near initialization for 'rt28xx_iw_handler_def')

/home/ellis/Downloads/RT/2011_0406_RT5390_RT5392_Linux_STA_V2.5.0.3_DPO/os/linux/../../os/linux/sta_ioctl.c:2228:2: error: unknown field 'num_private_args' specified in initializer

/home/ellis/Downloads/RT/2011_0406_RT5390_RT5392_Linux_STA_V2.5.0.3_DPO/os/linux/../../os/linux/sta_ioctl.c:2228:2: warning: excess elements in struct initializer

/home/ellis/Downloads/RT/2011_0406_RT5390_RT5392_Linux_STA_V2.5.0.3_DPO/os/linux/../../os/linux/sta_ioctl.c:2228:2: warning: (near initialization for 'rt28xx_iw_handler_def')

make[2]: *** [/home/ellis/Downloads/RT/2011_0406_RT5390_RT5392_Linux_STA_V2.5.0.3_DPO/os/linux/../../os/linux/sta_ioctl.o] Error 1

make[1]: *** [_module_/home/ellis/Downloads/RT/2011_0406_RT5390_RT5392_Linux_STA_V2.5.0.3_DPO/os/linux] Error 2

make[1]: Leaving directory `/usr/src/linux-3.1.6-gentoo'

make: *** [LINUX] Error 2

```

Output of 'lspci -k':

```
00:00.0 Host bridge: Intel Corporation Device 0104 (rev 09)

   Subsystem: Hewlett-Packard Company Device 166f

   Kernel driver in use: agpgart-intel

00:02.0 VGA compatible controller: Intel Corporation Device 0116 (rev 09)

   Subsystem: Hewlett-Packard Company Device 166f

   Kernel driver in use: i915

00:16.0 Communication controller: Intel Corporation Cougar Point HECI Controller #1 (rev 04)

   Subsystem: Hewlett-Packard Company Device 166f

00:1a.0 USB Controller: Intel Corporation Cougar Point USB Enhanced Host Controller #2 (rev 05)

   Subsystem: Hewlett-Packard Company Device 166f

   Kernel driver in use: ehci_hcd

00:1b.0 Audio device: Intel Corporation Cougar Point High Definition Audio Controller (rev 05)

   Subsystem: Hewlett-Packard Company Device 166f

   Kernel driver in use: snd_hda_intel

00:1c.0 PCI bridge: Intel Corporation Cougar Point PCI Express Root Port 1 (rev b5)

   Kernel driver in use: pcieport

00:1c.1 PCI bridge: Intel Corporation Cougar Point PCI Express Root Port 2 (rev b5)

   Kernel driver in use: pcieport

00:1c.2 PCI bridge: Intel Corporation Cougar Point PCI Express Root Port 3 (rev b5)

   Kernel driver in use: pcieport

00:1d.0 USB Controller: Intel Corporation Cougar Point USB Enhanced Host Controller #1 (rev 05)

   Subsystem: Hewlett-Packard Company Device 166f

   Kernel driver in use: ehci_hcd

00:1f.0 ISA bridge: Intel Corporation Device 1c49 (rev 05)

   Subsystem: Hewlett-Packard Company Device 166f

00:1f.2 SATA controller: Intel Corporation Cougar Point 6 port SATA AHCI Controller (rev 05)

   Subsystem: Hewlett-Packard Company Device 166f

   Kernel driver in use: ahci

00:1f.3 SMBus: Intel Corporation Cougar Point SMBus Controller (rev 05)

   Subsystem: Hewlett-Packard Company Device 166f

   Kernel driver in use: i801_smbus

01:00.0 Network controller: RaLink Device 5390

   Subsystem: Hewlett-Packard Company Device 1636

02:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8101E/RTL8102E PCI Express Fast Ethernet controller (rev 05)

   Subsystem: Hewlett-Packard Company Device 166f

   Kernel driver in use: r8169

03:00.0 Class ff00: Realtek Semiconductor Co., Ltd. Device 5209 (rev 01)

   Subsystem: Hewlett-Packard Company Device 166f

```

Any help would be greatly appreciated.

Best regards,

ChrisLast edited by ChrisCummins on Thu Jan 05, 2012 12:43 pm; edited 2 times in total

----------

## Gusar

It is supported by default, though I think only starting with kernel 3.1

```
  │     -> Device Drivers                                                                             │  

  │       -> Network device support (NETDEVICES [=y])                                                 │  

  │         -> Wireless LAN (WLAN [=y])                                                               │  

  │           -> Ralink driver support (RT2X00 [=m])                                                  │  

  │             -> Ralink rt27xx/rt28xx/rt30xx (PCI/PCIe/PCMCIA) support (RT2800PCI [=m])             │  

  │               -> rt2800pci - Include support for rt53xx devices (EXPERIMENTAL)                    │  

```

You also need the linux-firmware package.

----------

## ChrisCummins

Many thanks Gusar, sure enough iwconfig now confirms:

```

lo        no wireless extensions.

eth0      no wireless extensions.

sit0      no wireless extensions.

wlan0     IEEE 802.11bgn  ESSID:off/any  

          Mode:Managed  Access Point: Not-Associated   Tx-Power=20 dBm   

          Retry  long limit:7   RTS thr:off   Fragment thr:off

          Encryption key:off

          Power Management:off

```

nm-applet is displaying the list of wireless networks available but does nothing when I try and select one, so I'll do some reading and see if I can figure it out. Seems like the hard part is done.

Best regards,

Chris

----------

## ChrisCummins

I unintentionally solved the wireless issue while addressing a problem about suspend authorization. It seems it was a policykit/consolekit issue. Wireless is working 100% now.

----------

