Page MenuHomeFreeBSD

Fix vnic fallback PHY name matching after r334880.
ClosedPublic

Authored by markj on Jul 13 2018, 7:11 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mar 6 2024, 8:15 PM
Unknown Object (File)
Jan 16 2024, 5:51 AM
Unknown Object (File)
Dec 20 2023, 1:46 AM
Unknown Object (File)
Dec 11 2023, 2:58 AM
Unknown Object (File)
Nov 25 2023, 9:41 PM
Unknown Object (File)
Nov 25 2023, 12:45 PM
Unknown Object (File)
Oct 31 2023, 11:47 AM
Unknown Object (File)
Oct 2 2023, 9:16 AM
Subscribers
None

Details

Summary

In some cases it seems that the PHY mode can only be identified by
matching against the corresponding device node name in the FDT. r334880
broke this for the case where the node name contains a unit address.
Fix the problem by allowing a match in that case.

Test Plan

vnic attaches. The relevant portions of the FDT look like this:

                                bgx0 {

                                        #address-cells = <0x1>;
                                        #size-cells = <0x0>;
                                        reg = <0x8000 0x0 0x0 0x0 0x0>;
                                        xfi@0 {

                                                reg = <0x0>;
                                                local-mac-address = [fc 15 b4 97 48 b7];                                                                     
                                                phy-handle = <0x75>;
                                        };
                                        xfi@1 {

                                                reg = <0x1>;
                                                local-mac-address = [fc 15 b4 97 48 b8];                                                                     
                                                phy-handle = <0x76>;
                                        };
                                };
...
                                        mdio@87e005003800 {                                                                                                   
                                                                                                                                                              
                                                compatible = "cavium,thunder-8890-mdio";                                                                      
                                                #address-cells = <0x1>;                                                                                       
                                                #size-cells = <0x0>;
                                                reg = <0x87e0 0x5003800 0x0 0x30>;                                                                           
                                                xfi@0 {

                                                        reg = <0x0>;                                                                                         
                                                        compatible = "cortina,cs4223-slice";                                                                 
                                                        linux,phandle = <0x75>;
                                                        phandle = <0x75>;
                                                };
                                                xfi@1 {

                                                        reg = <0x1>;
                                                        compatible = "cortina,cs4223-slice";                                                                 
                                                        linux,phandle = <0x76>;
                                                        phandle = <0x76>;
                                                };
                                        };

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

markj added reviewers: andrew, sbruno, imp, ian.

Let me do a quick test on the cluster ThunderX1 machine.

This revision is now accepted and ready to land.Jul 13 2018, 10:33 PM

This works for us in the FreeBSD cluster. Thanks!

This revision was automatically updated to reflect the committed changes.