Jump to content
jalavoui

Atheros wireless driver OS X 10.11/12 for unsupported cards

618 posts in this topic

Recommended Posts

Advertisement

@jalavoui I suspect the issue we're running into on AR9462 is broken eeprom reads affecting rx/tx power management (even though the ucode is fine). Do the OS X eeprom functions work fine for you or are they having issues for you too?

Share this post


Link to post
Share on other sites

if u have a working apple ethernet driver try to debug it on a cold boot

 

u can inject a int 3 (hex code CC) in code so the debugger stops where u want

 

anyway the card works after reboot from windows/linux - that's fine 4 now

Share this post


Link to post
Share on other sites

if u have a working apple ethernet driver try to debug it on a cold boot

 

u can inject a int 3 (hex code CC) in code so the debugger stops where u want

 

anyway the card works after reboot from windows/linux - that's fine 4 now

 

@jalavoui CoolStar and I have been investigating this, and unfortunately, it seems that USB Ethernet is not supported with Two-Machine Remote Kernel Debug even when that USB Ethernet is supported by an Apple Ethernet driver (USB Ethernet works OotB). :/

 

Do you know of a way to get Two-Machine Kernel Remote Debug working with USB Ethernet? Thanks! ^_^

Share this post


Link to post
Share on other sites

@jalavoui just wondering, can you run this command in Linux: "sudo cat /sys/kernel/debug/ieee80211/phy0/ath9k/base_eeprom"

 

for the rx/tx ucodes, Linux appears to load the relevant ucode based on which rx/tx ucode index is in eeprom. For the AR9462 I have, it's set to index 1 for both rx and tx.

Share this post


Link to post
Share on other sites

Has anyone encountered very low network speeds with this driver compared to what the card is capable of doing on other OS's? I mean it's still better than nothing, but the most I've been able to get under OS X was 10Mbps (when under Windows/Linux I can get at least 50Mbps without much effort), and even that's not always the case, right now for example I'm only getting 1Mbps next to the router. Wireless Diagnostics says that the noise is always above RSSI by exactly 1 dBm, Quality is always -1, and the Tx Rate is always 11 Mbps. (Country Code is JP, but that shouldn't make much of a difference except for what channels it can use, right?)

 

If not, could someone please let me know where to start looking in order to figure out what's causing this and eventually fix it? Programming/reverse engineering isn't an issue, but I'm not familiar with Wi-Fi drivers at all.

 

Thanks!

Share this post


Link to post
Share on other sites

@bogdacutu which wireless card are you using? Are you using AR9462 or AR9565?

AR9565

 

 

ubuntu@ubuntu:~$ sudo inxi -Fx | grep Wireless
           Card-2: Qualcomm Atheros QCA9565 / AR9565 Wireless Network Adapter driver: ath9k bus-ID: 02:00.0

Share this post


Link to post
Share on other sites

AR9565

 

ubuntu@ubuntu:~$ sudo inxi -Fx | grep Wireless           Card-2: Qualcomm Atheros QCA9565 / AR9565 Wireless Network Adapter driver: ath9k bus-ID: 02:00.0
Hi, @Bogdacutu I also have similar problem with my card QCA9565 / AR9565 (300Mbps, aka WB335). The maximum download and upload speed are both about 5 mbps, but in windows the speed is at least 50 mbps. Have you found any solution? Thank you.

Share this post


Link to post
Share on other sites

Hi, @Bogdacutu I also have similar problem with my card QCA9565 / AR9565 (300Mbps, aka WB335). The maximum download and upload speed are both about 5 mbps, but in windows the speed is at least 50 mbps. Have you found any solution? Thank you.

Nope, I have noticed though that on some networks it works fine (for example, if I make a hotspot with my phone, I get the speeds I'm supposed to get). I planned to write my own driver to get rid of this issue, and even got send/receive working as well as it does on Windows/Linux, but all the Airport stuff is closed source (not that it's necessarily an issue, but my driver doesn't unload cleanly anymore if I switch from IOEthernetController to IO80211Controller :/ ), so I'm not going any further with that right now.

Share this post


Link to post
Share on other sites

Nope, I have noticed though that on some networks it works fine (for example, if I make a hotspot with my phone, I get the speeds I'm supposed to get). I planned to write my own driver to get rid of this issue, and even got send/receive working as well as it does on Windows/Linux, but all the Airport stuff is closed source (not that it's necessarily an issue, but my driver doesn't unload cleanly anymore if I switch from IOEthernetController to IO80211Controller :/ ), so I'm not going any further with that right now.

Interested in this. Have you seen Voodoo80211? It has reverse engineered IO80211Family headers up to 10.7 (although I'm not sure if the 10.7 ones work, the 10.6 ones do though).

Share this post


Link to post
Share on other sites

I have AR9565 that Used to work fine on ElCapitan. But it doesnt work on 10.12 Sierra. How do I make it work on Sierra?

Share this post


Link to post
Share on other sites

Interested in this. Have you seen Voodoo80211? It has reverse engineered IO80211Family headers up to 10.7 (although I'm not sure if the 10.7 ones work, the 10.6 ones do though).

I have, and there's also this for 10.9: http://www.insanelymac.com/forum/topic/292645-guide-surfacepro-1-2-osx-android-windows-multiboot/?p=2017083. Of course, they don't work on 10.11 either, but they aren't particularly difficult to bring up to date, as all the function names are exported and include C++ argument info, and the virtual method tables are exported too. I'm fairly certain though the the headers I've made are correct, as the linker used to complain before if they weren't, plus right now my issue isn't that they don't work, it's that corecapture keeps a reference to my IO80211Controller, so I can't iterate quickly anymore because I'd need to reboot for every change, which I don't want to do. I suspect that corecapture doesn't release the instance because it's being retained by something from userspace, but I have no idea how to debug that.

Share this post


Link to post
Share on other sites

Ok so I boot verbose and found out that your version of io80211family uses some headers that were not present in sierra. Ran kextlibs on the kext from sierra and then from el capitan on another machine. The absent headers were in corecapture so I used the corecapture kext from el capitan and now the wifi works.

 

I would however love to have a more permanent solution like an injector or clover patch. Again thanks for the great work.

Share this post


Link to post
Share on other sites

@jalavoui yes, I enabled bluetooth with BTFirmwareUploader

 

Also, in case this helps, I made 2 text files of which bytes I patched (excluding ucode) and a text file of the ucode I patched in. Hope this makes it easier to look at my rx/tx patch.

Looking into diff-patch12.txt, how did you patch the binary exactly?

 

 

Example: 

 

AirPortAtheros40 -> AirPortAtheros40-patch12

  addr  val1 val2   desc
--------------------------------------------------------------
472261 342  56 <-- _ath_hal_probe jump                       
 472262   0   1 <-- _ath_hal_probe jump
 472766  60  64 <-- _ath_hal_attach dev id
 472914  60  64 <-- _ath_hal_attach dev id
 
The value on the left is the hex address. What do val1 and 2 mean?
 
Thank you

Share this post


Link to post
Share on other sites

They are the values before (val 1) and after (val 2) the patch.

Weird, when checking the binary at those addresses there are always different values. Neither val1 or val2. They seem to have a different meaning or I'm using the wrong hex editor.

Share this post


Link to post
Share on other sites

Weird, when checking the binary at those addresses there are always different values. Neither val1 or val2. They seem to have a different meaning or I'm using the wrong hex editor.

 

The address at the left are actually in decimal format, not in hex. Make sure you put the address in "dec" format in your hex editor. Also, we were working on the kext from 10.11.5.

 

I have updated most of the patches for 10.12 here but I can't get the kext to connect to wifi networks yet, although it does scan successfully. I'll have to run some more tests and see.

Share this post


Link to post
Share on other sites

The address at the left are actually in decimal format, not in hex. Make sure you put the address in "dec" format in your hex editor. Also, we were working on the kext from 10.11.5.

 

I have updated most of the patches for 10.12 here but I can't get the kext to connect to wifi networks yet, although it does scan successfully. I'll have to run some more tests and see.

In any case, can you write a kext to patch or plist edit for us non-developer ? It will be great :)

Share this post


Link to post
Share on other sites

Ok so I boot verbose and found out that your version of io80211family uses some headers that were not present in sierra. Ran kextlibs on the kext from sierra and then from el capitan on another machine. The absent headers were in corecapture so I used the corecapture kext from el capitan and now the wifi works.

 

I would however love to have a more permanent solution like an injector or clover patch. Again thanks for the great work.

 

Can you pass me your corecapture.kext ?

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.

×