()
| 1958 | return names |
| 1959 | |
| 1960 | |
| 1961 | def _iface_link_details(iface): |
| 1962 | """MAC, operstate, and VLAN info from `ip -d link show`.""" |
| 1963 | res = _run(['ip', '-d', 'link', 'show', 'dev', iface], timeout=5) |
| 1964 | out = res['out'] |
| 1965 | d = {'mac': None, 'operstate': None, 'vlan_id': None, 'vlan_proto': None} |
| 1966 | m = re.search(r'state (\S+)', out) |
| 1967 | if m: |
| 1968 | d['operstate'] = m.group(1) |
| 1969 | m = re.search(r'link/\w+\s+([0-9a-fA-F:]{17})', out) |
nothing calls this directly
no test coverage detected