Use RTL8192SE wireless card in Gentoo with kernel 3

Although I had solve this problem earlier, I forgot the solution when I built a new system today. The configuration in kernel’s menuconfig is:

Symbol: RTL8192SE [=m]
Type  : tristate
Prompt: Realtek RTL8192SE/RTL8191SE PCIe Wireless Network Adapter
Defined at drivers/net/wireless/rtlwifi/Kconfig:13
Depends on: NETDEVICES [=y] && WLAN [=y] && MAC80211 [=m] && EXPERIMENTAL [=y]
-> Device Drivers
-> Network device support (NETDEVICES [=y])
-> Wireless LAN (WLAN [=y])
Selects: FW_LOADER [=y] && RTLWIFI [=m]

But after reboot, it still not loaded. Via dmesg, it caused by firmware missing. There’s a package named rtl8192se-firmware in portage tree but it is NOT the one we need. What we need to do is to:
# emerge linux-firmware.
After this step, it works. 🙂

Partially to make rtl8192se works with kernel 3.0

My laptop is Lenovo X201 with a RTL8191SEvB wireless card. In kernel 2.6.3x version, I’ve to install the rtl8192se and rtl8192se-firmware packages to make it works. In the previous settings, the module named r8192se_pci and with a parameter hwwep=0 can led to a stable network connection no matter my gentoo or ubuntu box.

But the nightmare comes back when I upgrade to kernel-3.0.x with built-in rtl8192se modules in rtlwifi catalog. The issues are:
1) Network connection are hard to established and will disconnected dynamically itself.
2) My ad-hoc connection shared by Windows cannot be established.
3) And so on.

The symptoms of the issues are: the configurations via ifconfig, iwconfig even route are all CORRECTLY, but I still CANNOT ping the default gateway.

But now I found a PARTIAL solution. That is, to set a new parameter swenc=1 to make the module use software encryption rather than hardware one, which similar the old hwwep=0 with r8192se_pci modules.

To make it set on loaded, adding a configuration file via:
echo "options rtl8192se swenc=1" > /etc/modprobe.d/rtl8192se.conf

If you encounter the same problem with rtl8192se driver on RTL8191SEvB card, Try it. 🙂

[20111114 edit] From the forum, the developer suggest me to install iw and set the CRDA for the wirless card. After I try # iw reg set TW, my network connection in Ubuntu more stable. Maybe this is another trick, too.