ironic.drivers.modules.inspector.lldp_tlvs module

Link Layer Discovery Protocol TLVs

ironic.drivers.modules.inspector.lldp_tlvs.bytes_to_int(obj)[source]

Convert bytes to an integer

Param:

obj - array of bytes

ironic.drivers.modules.inspector.lldp_tlvs.get_autoneg_cap(pmd)[source]

Get autonegotiated capability strings

This returns a list of capability strings from the Physical Media Dependent (PMD) capability bits.

Parameters:

pmd – PMD bits

Returns:

Sorted ist containing capability strings

ironic.drivers.modules.inspector.lldp_tlvs.mapping_for_enum(mapping)[source]

Return tuple used for keys as a dict

Param:

mapping - dict with tuple as keys

ironic.drivers.modules.inspector.lldp_tlvs.mapping_for_switch(mapping)[source]

Return dict from values

Param:

mapping - dict with tuple as keys