Mieze / IntelLucy

MacOS open source driver for the Intel X500 family
31 stars 3 forks source link

x520-da2 #2

Closed rehack closed 4 months ago

rehack commented 4 months ago

I am unable to drive the x520-da2 card using IntelLucy. kext v1.0.4,v1.0.3 can work normally opencore 1.0.0 macos sonoma

Mieze commented 4 months ago

I can confirm that IntelLucy works with X520 adapters and Sonoma 14.3.1 and 14.5 because that is the type of hardware I am using in my home network. Please send me your EFI folder and an IOReg dump for diagnosing the issue. I also need to know which type of SFP+module you are using. Make sure that the dump is readable because some versions of IORegistryExplorer produce broken files.

rehack commented 4 months ago

Thank you very much for providing some information that may be helpful for your analysis. Files

Mieze commented 4 months ago

Thank you for the information you provided. Your adapter is strange as both ports identify themself as X520-DA1 (device ID 0x10fb), but the device ID of the X520-DA2 is 0x154d. Has the device been modified?

Although both ports act as independent PCIe functions, they are not exactly the same because there are some shared resources which may be accessed by the driver only after acquiring a hardware semaphore and with the ID of the X520-DA1 the driver of the second port won't acquire the correct semaphore. Another problem is that the type of the SFP+ module depends on the port it has been plugged in and will be misconfigured with the incorrect device ID.

Besides that, the driver loads and binds to both PCIe functions properly.

rehack commented 4 months ago

After trying, the module was inserted into the first optical port and the network was working properly. The second port did not recognize the network and the network card light was not on. It's really strange. Could it be that the device was modified due to installing other drivers(small tree) before.

Mieze commented 4 months ago

That's the expected behaviour because the X520-DA1 has only one port.

For the Smalltree driver to work with any X520 adapter the device's EEPROM has to be modified (change of subsystem ID) and it looks like that this has been done improperly because the device ID was also changed form X520-DA2 to X520-DA1 which causes the failure of the second port. I recommend this changes to be reverted in order to restore the operational state of the second port.

rehack commented 4 months ago

IDs of da1 and da2 are the same,How to revert this change? Which configuration file should I modify. Snipaste_2024-06-04_20-57-00

Mieze commented 4 months ago

The device ID of X520-DA1 is 0x10fb, whereas the ID of X520-DA2 is 0x154d.

The correct way to revert mostly depends what has been done to the card. Did you apply the modifications to make it work with the Smalltree driver as described on this page?

https://forums.macrumors.com/threads/modify-retail-intel-10gbe-nics-to-use-small-tree-macos-drivers.1968456/

Or has it been flashed with a firmware image of the X520-DA1?