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)
Nov 15 2024, 8:16 PM
Unknown Object (File)
Sep 24 2024, 12:09 AM
Unknown Object (File)
Sep 20 2024, 3:46 PM
Unknown Object (File)
Sep 18 2024, 6:46 AM
Unknown Object (File)
Sep 8 2024, 4:52 PM
Unknown Object (File)
Sep 8 2024, 12:12 PM
Unknown Object (File)
Sep 7 2024, 6:43 PM
Unknown Object (File)
Aug 6 2024, 4:10 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.