Contribute
Register

Rebranding the Atheros 928x cards - The guide

Status
Not open for further replies.
Well I was able to bypass the whitelist with that modification.
I did have to remove the built in battery to allow for space inside the laptop for the card not really a big deal though.

Now I need some help with the DSDT changes and getting the card picked up as an atheros card....

Thats great news! So what guide did you follow? Also, is your card not a half card? I'm jealous now, why didn't mine work I wonder?
 

Attachments

  • Erik’s MacBook Air.ioreg
    1.6 MB · Views: 182
Thats great news! So what guide did you follow? Also, is your card not a half card? I'm jealous now, why didn't mine work I wonder?

I did the flash via linux.
The card is a 1/2 height card ... hopefully thats not an issue...
 
That hasn't been working for me so far...
I added the Intel device info into the IOPCIPrimayMatch (0x08b28086) list along side the current (0x0034168c 0x002a168c).
This shows the device attaching in the IOReg but the Atheros kext isn't loading and therefore there is no WiFi.

You will need an injector kext to cause the kext to be loaded (that matches on your rebranded id). And you'll need to inject RM,device-id and RM,vendor-id with the actual ids (eg. 0x168c:2a for AR9280).

Or you can inject device-id and vendor-id with a DSDT patch. The DSDT patch will work for both (IOKit matching and FakePCIID spoofing).

Read the FakePCIID README.

The FakePCIID_AR9280_as_AR946x.kext provides a very complete example.
 
You will need an injector kext to cause the kext to be loaded (that matches on your rebranded id). And you'll need to inject RM,device-id and RM,vendor-id with the actual ids (eg. 0x168c:2a for AR9280).

Or you can inject device-id and vendor-id with a DSDT patch. The DSDT patch will work for both (IOKit matching and FakePCIID spoofing).

Read the FakePCIID README.

The FakePCIID_AR9280_as_AR946x.kext provides a very complete example.

I have the modification previously mentioned inplace on the fakepci kext and the following DSDT patch has been added:

Code:
into method label _DSM parent_label EXP2 remove_entry;
into device label EXP2 parent_label PCI0 insert
begin
Method (_DSM, 4, NotSerialized)\n
{\n
    If (LEqual (Arg2, Zero)) { Return (Buffer() { 0x03 } ) }\n
    Return (Package()\n
    {\n
        "vendor-id", Buffer() { 0x8c, 0x16, 0x00, 0x00 },\n
        "device-id", Buffer() { 0x2a, 0x00, 0x00, 0x00 },\n
        "subsystem-id", Buffer() { 0x8F, 0x00, 0x00, 0x00 },\n
        "subsystem-vendor-id", Buffer() { 0x6B, 0x10, 0x00, 0x00 },\n
        "compatible", "pci168c,2a",\n
        "IOName", "pci168c,2a",\n
        "name", "pci168c,2a",\n
        "AAPL,slot-name", Buffer() { "AirPort" },\n
        "device_type", Buffer() { "AirPort" },\n
        "model", Buffer() { "Atheros 928x 802.11 b/g/n Wireless Network Adapter" },\n
    })\n
}\n
end;

lspci shows (the Intel card is nowhere to be found):
Code:
03:00.0 Network controller [0280]: Atheros Communications Inc. AR928X Wireless Network Adapter (PCI-Express) [168c:002a] (rev 01)
	Subsystem: Apple Computer Inc. Unknown device [106b:008f]
However DPCIManager shows both an atheros card and the intel card.


I have set clover to force loading the atheros kext and kextstat shows it loaded
Code:
Eriks-MacBook-Air:~ erikweiman$ kextstat |grep -i ath
   51    0 0xffffff7f816ed000 0x14e000   0x14e000   com.apple.driver.AirPort.Atheros40 (700.74.5) <50 48 12 7 5 4 3 1>
Maybe you'll have some ideas for me from the latest ioreg i just took.
 

Attachments

  • Erik’s MacBook Air.ioreg
    1.5 MB · Views: 175
  • Screen Shot 2015-02-05 at 6.59.56 PM.jpg
    Screen Shot 2015-02-05 at 6.59.56 PM.jpg
    138.6 KB · Views: 199
I have the modification previously mentioned inplace on the fakepci kext and the following DSDT patch has been added:

Code:
into method label _DSM parent_label EXP2 remove_entry;
into device label EXP2 parent_label PCI0 insert
begin
Method (_DSM, 4, NotSerialized)\n
{\n
    If (LEqual (Arg2, Zero)) { Return (Buffer() { 0x03 } ) }\n
    Return (Package()\n
    {\n
        "vendor-id", Buffer() { 0x8c, 0x16, 0x00, 0x00 },\n
        "device-id", Buffer() { 0x2a, 0x00, 0x00, 0x00 },\n
        "subsystem-id", Buffer() { 0x8F, 0x00, 0x00, 0x00 },\n
        "subsystem-vendor-id", Buffer() { 0x6B, 0x10, 0x00, 0x00 },\n
        "compatible", "pci168c,2a",\n
        "IOName", "pci168c,2a",\n
        "name", "pci168c,2a",\n
        "AAPL,slot-name", Buffer() { "AirPort" },\n
        "device_type", Buffer() { "AirPort" },\n
        "model", Buffer() { "Atheros 928x 802.11 b/g/n Wireless Network Adapter" },\n
    })\n
}\n
end;

lspci shows (the Intel card is nowhere to be found):
Code:
03:00.0 Network controller [0280]: Atheros Communications Inc. AR928X Wireless Network Adapter (PCI-Express) [168c:002a] (rev 01)
	Subsystem: Apple Computer Inc. Unknown device [106b:008f]
However DPCIManager shows both an atheros card and the intel card.


I have set clover to force loading the atheros kext and kextstat shows it loaded
Code:
Eriks-MacBook-Air:~ erikweiman$ kextstat |grep -i ath
   51    0 0xffffff7f816ed000 0x14e000   0x14e000   com.apple.driver.AirPort.Atheros40 (700.74.5) <50 48 12 7 5 4 3 1>
Maybe you'll have some ideas for me from the latest ioreg i just took.

Your DSDT patch is applied to the wrong node. In fact, your DSDT may not have an appropriate node to apply it to (it would have to be added). The reason there is no ACPI node for it is because it is connected to a PCI bridge.

With a correctly created injector kext (use the existing one as an example), DSDT patching is not necessary.

You might need to post ioreg with the original Intel card installed (and no DSDT patches/injectors installed). Also, an ioreg with the new card installed (but no DSDT patches/injectors). Once you start messing around with incorrect injectors/incorrect DSDT patches it becomes difficult to tell what the correct result should be.

Edit: Your first attempt (no DSDT patch) was closer than the latest. What you missed... is changing the AppleUSBMergeNub so it also loads against your device. And perhaps the injector portion (the personality that causes the driver to load). There are three components that are needed here (AppleUSBMergeNub to inject properties on the parent device, Atheros40, and FakePCIID). Miss one, and it won't work.
 
Your DSDT patch is applied to the wrong node. In fact, your DSDT may not have an appropriate node to apply it to (it would have to be added). The reason there is no ACPI node for it is because it is connected to a PCI bridge.

With a correctly created injector kext (use the existing one as an example), DSDT patching is not necessary.

You might need to post ioreg with the original Intel card installed (and no DSDT patches/injectors installed). Also, an ioreg with the new card installed (but no DSDT patches/injectors). Once you start messing around with incorrect injectors/incorrect DSDT patches it becomes difficult to tell what the correct result should be.

Edit: Your first attempt (no DSDT patch) was closer than the latest. What you missed... is changing the AppleUSBMergeNub so it also loads against your device. And perhaps the injector portion (the personality that causes the driver to load). There are three components that are needed here (AppleUSBMergeNub to inject properties on the parent device, Atheros40, and FakePCIID). Miss one, and it won't work.

Ok, so I've undone the DSDT patch as it seems I don't know how to create the appropriate node so that it affects the actual wifi device instead of the node above it.

I've changed to the debug version of the kext but I dont see any logging changes.

Attached is a new ioreg with the kext modified to have the intel id for both the USB section and the fakepciid bundle.
Still no dice... :(

I did notice this line in the system.log file which mentions the Intel device info:

Code:
Feb  5 21:20:28 localhost kernel[0]: pci8086,8b2 cannot assert wake from D3cold

Here are the only lines logged about FakePCIID:
Code:
Feb  5 21:20:28 localhost kernel[0]: FakePCIID v1.0 starting.
Feb  5 21:20:28 localhost kernel[0]: FakePCIID v1.0 starting.
Feb  5 21:20:29 Eriks-MacBook-Air kernel[0]: FakePCIID: configRead32(0x02), result 0x0a168086 -> 0x04128086
Feb  5 21:20:29 Eriks-MacBook-Air kernel[0]: FakePCIID: configRead32(0x00), result 0x0a168086 -> 0x04128086
Feb  5 21:20:29 Eriks-MacBook-Air kernel[0]: FakePCIID: configRead32(0x2c), result 0x220c17aa -> 0x220c106b
 

Attachments

  • Erik’s MacBook Air-.ioreg
    1.4 MB · Views: 188
The Atheros driver is not loading... Upload the injector kext you created.
 
Here is the kext being used.

This one is the release one rather than the debug one as it didn't seem to make a difference which was being used.
 

Attachments

  • FakePCIID_AR9280_as_AR946x.kext.zip
    2.2 KB · Views: 143
Here is the kext being used.

This one is the release one rather than the debug one as it didn't seem to make a difference which was being used.

The "AirPort AR9280 as AR946x" personality does not have an IONameMatch entry for your device, "pci8086,8b2". No expectation for IOKit to load the Atheros driver without a matching IOKItPersonality.

Note: You should rename the kext to better reflect its purpose.
 
Status
Not open for further replies.
Back
Top