• Hangbin Liu's avatar
    doc/netlink/specs: Add bond support to rt_link.yaml · 4ede4575
    Hangbin Liu authored
    Add bond support to rt_link.yaml. Here is an example output:
    
     $ ./tools/net/ynl/cli.py --spec Documentation/netlink/specs/rt_link.yaml \
       --do getlink --json '{"ifname": "bond0"}' --output-json | jq '.linkinfo'
     {
       "kind": "bond",
       "data": {
         "mode": 4,
         "miimon": 100,
         ...
         "arp-interval": 0,
         "arp-ip-target": [
           "192.168.1.1",
           "192.168.1.2"
         ],
         "arp-validate": 0,
         "arp-all-targets": 0,
         "ns-ip6-target": [
           "2001::1",
           "2001::2"
         ],
         "primary-reselect": 0,
         ...
         "missed-max": 2,
         "ad-info": {
           "aggregator": 1,
           "num-ports": 1,
           "actor-key": 0,
           "partner-key": 1,
           "partner-mac": "00:00:00:00:00:00"
         }
       }
     }
    
    And here is the downlink info.
    
     $ ./tools/net/ynl/cli.py --spec Documentation/netlink/specs/rt_link.yaml \
       --do getlink --json '{"ifname": "dummy0"}' --output-json | jq '.linkinfo'
     {
       "kind": "dummy",
       "slave-kind": "bond",
       "slave-data": {
         "state": 0,
         "mii-status": 0,
         "link-failure-count": 0,
         "perm-hwaddr": "f2:82:f7:cc:47:13",
         "queue-id": 0,
         "prio": 0
       }
     }
    Signed-off-by: default avatarHangbin Liu <liuhangbin@gmail.com>
    Link: https://lore.kernel.org/r/20240409083504.3900877-1-liuhangbin@gmail.comSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
    4ede4575
rt_link.yaml 38 KB