Bug 252532 - ifconfig incorrectly displays stp roles
Summary: ifconfig incorrectly displays stp roles
Status: New
Alias: None
Product: Base System
Classification: Unclassified
Component: kern (show other bugs)
Version: CURRENT
Hardware: amd64 Any
: --- Affects Many People
Assignee: freebsd-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-01-08 20:16 UTC by jcaplan
Modified: 2021-01-12 18:43 UTC (History)
0 users

See Also:


Attachments
proposed patch (595 bytes, patch)
2021-01-12 18:43 UTC, jcaplan
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description jcaplan 2021-01-08 20:16:06 UTC
Overview: 

Steps to Reproduce:

1. create a bridge
2. add a member interface
3. enable stp for the member
4. check member role in ifconfig output


Actual Results: 

# ifconfig bridge0
bridge0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500                                                                                                                               
        ether 58:9c:fc:10:ff:e0                                                                                                                                                                             
        id 02:21:4d:ed:52:0b priority 32768 hellotime 2 fwddelay 15                                                                                                                                         
        maxage 20 holdcnt 6 proto stp-rstp maxaddr 2000 timeout 1200                                                                                                                                        
        root id 02:21:4d:ed:52:0a priority 32768 ifcost 2000 port 11                                                                                                                                        
        member: epair2b flags=1c7<LEARNING,DISCOVER,STP,AUTOEDGE,PTP,AUTOPTP>                                                                                                                               
                ifmaxaddr 0 port 11 priority 128 path cost 2000 <unknown proto 2>                                                                                                                           
                <unknown role 1> state forwarding                                


Expected Results: 

# ifconfig bridge0
bridge0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500                                                                                                                               
        ether 58:9c:fc:10:ff:e0                                                                                                                                                                             
        id 02:21:4d:ed:52:0b priority 32768 hellotime 2 fwddelay 15                                                                                                                                         
        maxage 20 holdcnt 6 proto stp-rstp maxaddr 2000 timeout 1200                                                                                                                                        
        root id 02:21:4d:ed:52:0a priority 32768 ifcost 2000 port 11                                                                                                                                        
        member: epair2b flags=1c7<LEARNING,DISCOVER,STP,AUTOEDGE,PTP,AUTOPTP>                                                                                                                               
                ifmaxaddr 0 port 11 priority 128 path cost 2000 <unknown proto 2>                                                                                                                           
                role root state forwarding                                

Build Date & Hardware:

13.0-CURRENT FreeBSD 13.0-CURRENT #0 r368820: Tue Jan  5 17:30:19 EST 2021
Comment 1 jcaplan 2021-01-12 18:43:01 UTC
Created attachment 221504 [details]
proposed patch