Summary: | [new driver] Port openbsd rtwn, new rtl8188ce driver | ||
---|---|---|---|
Product: | Base System | Reporter: | Tony Narlock <tony> |
Component: | wireless | Assignee: | freebsd-wireless (Nobody) <wireless> |
Status: | Closed FIXED | ||
Severity: | Affects Only Me | CC: | Alex.R.Laurie, adrian, avos, brueffer, evil.lombo, gardnerbell, id, jkim, kevlo, mizhka |
Priority: | --- | ||
Version: | CURRENT | ||
Hardware: | Any | ||
OS: | Any |
Description
Tony Narlock
2015-09-14 19:28:38 UTC
I would like to give this a stab myself on the weekend to learn the internals more and get in a contribution. It would be superb to see if this could make it in 11-CURRENT. If you already are on this and want to give it shot / could do it easily, no problem, just mention here. Is the fact that this module is separate from urtwn pose a problem? (OpenBSD made a whole different module for rtl8188ce called rtwn instead of having it in urtwn, I suppose they have a good reason) What exactly is the difference? Is this the PCIe version? (In reply to Adrian Chadd from comment #2) Yes, it seems so: http://www.realtek.com/products/productsView.aspx?Langid=1&PFid=48&Level=5&Conn=4&ProdID=272 They're almost the same chips though. How similar are the drivers? Well, I remember someone would send this wifi card to me, but unfortunately, I haven't received it yet. Porting OpenBSD's rtwn(4) to FreeBSD is not hard, the harder part would be maintaining rtwn(4) stability and performance. (In reply to Kevin Lo from comment #5) Sorry for the late response, I meant to get back to this during the weekend. I am reading FreeBSD Device Drivers, TDAIOTFOS, https://wiki.freebsd.org/WiFi, https://wiki.freebsd.org/WifiTxNotes, https://wiki.freebsd.org/WiFiDebugging and have an Thinkpad x230 with this card. I'm looking at if_urtwn.c. What other places do you think would be helpful to look at? I'm wondering if_urtwn.c may not be such a good example since it has USB everywhere. It may be too tall of an order to port something like this over by myself. > the harder part would be maintaining rtwn(4) stability and performance. What would that entail? Is it looking at coredumps if the kernel panics, running it on a machine until certain conditions popup, finding where in the code it's happening, trying to tweak it, recompiling, kldunload, kldload? Looking over tickets for behavior for the driver and trying to ask for more info to recreate it? Do we have an irc channel for freebsd-wireless? yup, #freebsd-wifi on efnet. Kevin/I have talked about taking urtwn and turning it into a standalone driver that we can start making into a HAL structure. I'd rather we did that and then added the PCIe bits to it versus maintaining multiple almost-the-same drivers. Hows that sound to you? Hi, I have Lenovo T530i with RTL8188CE driver, so I'll one of tester for this ticket. :) none2@pci0:3:0:0: class=0x028000 card=0x819510ec chip=0x817610ec rev=0x01 hdr=0x00 vendor = 'Realtek Semiconductor Co., Ltd.' device = 'RTL8188CE 802.11b/g/n WiFi Adapter' class = network I have a toshiba satellite with this card and would be happy to test when a driver becomes available. none2@pci0:3:0:0: class=0x028000 card=0x819510ec chip=0x817610ec rev=0x01 hdr=0x00 vendor = 'Realtek Semiconductor Co., Ltd.' device = 'RTL8188CE 802.11b/g/n WiFi Adapter' class = network I finally got my rtl8188ce wifi adapter. I'm working on it, please stay tuned! I have a Lenovo SL510 with a rtl8188CE. Currently running OpenBSD-Current on it and the driver is working well. I'd be happy to test on FreeBSD. Me too willing to help, with a HP Pavillon g6 and the dreadful RTL8188CE. It used to work somehow with NDIS but with some annoying quirks. Just to keep the records up to date, adrian committed a preliminary driver to HEAD in r293010. (In reply to Christian Brueffer from comment #13) Yep, we have a start! On a Thinkpad x230 I am able to connect to connect to my network via WPA2 and ping an external domain, load a page or two also. FreeBSD x230 11.0-CURRENT FreeBSD 11.0-CURRENT #11: Sun Jan 3 04:21:01 CST 2016 root@x230:/usr/obj/usr/src/sys/GENERIC amd64 amd64 1100093 1100093 I will follow up with more soon Hi, tried the module and the card was detected fine and it's working. So far I get three issues with it: - WPA2 authentication seems to work only the first time to me. If I stop wpa_supplicant or put down the wifi card via ifconfig, the further authenticaitona fails for expired timeout. -Speed seems limited to 16Mbps rate (around 120 kbps on downstream),even though the ifconfig summary show 802.11g/56mbps. - After heavy usage, it stops working and dmesg shows a "rtwn0: can't map to rbuf (error: 12)" (12 = ENOMEM) and after some mins of this error, the kernel panics. I can't restore the wifi status via ifconfig and I have to reboot the laptop. Which kind of info do you need for troubleshooting? Thanks, Simone (In reply to Simone Mario Lombardo from comment #15) Hi, > - WPA2 authentication seems to work only the first time to me. If I stop > wpa_supplicant or put down the wifi card via ifconfig, the further > authenticaitona fails for expired timeout. Can you test the patch from https://reviews.freebsd.org/D4820 ? It should fix this issue. Also, > or put down the wifi card via ifconfig If I understand this correctly (ifconfig wlan0 down; ifconfig wlan0 up), then you will need to restart wpa_supplicant too (wpa_supplicant -i wlan0 -c /etc/wpa_supplicant.conf) (+ 'dhclient wlan0' for DHCP); or just recreate the interface (ifconfig wlan0 down && ifconfig wlan0 destroy && ifconfig wlan0 create wlandev rtwn0) Please open a new problem report for bugs. :-) This one was just for "port driver!" Thanks! -a A commit references this bug: Author: avos Date: Sun Feb 21 18:51:49 UTC 2016 New revision: 295865 URL: https://svnweb.freebsd.org/changeset/base/295865 Log: rtwn: import r290048. - Fix scanning from AUTH state. Tested by: Simone Mario Lombardo <evil.lombo@gmail.com> PR: 203105 Reviewed by: kevlo Approved by: adrian (mentor) Differential Revision: https://reviews.freebsd.org/D4820 Changes: head/sys/dev/rtwn/if_rtwn.c |