lldp_mgmt.c
error_t lldpGetFirstTlv(LldpDataUnit *lldpdu, LldpTlv *tlv)
Extract the first TLV from an LLDPDU.
Definition: lldp_tlv.c:247
error_t lldpMgmtGetRemoteSysName(LldpNeighborEntry *entry, const char_t **sysName, size_t *sysNameLen)
Extract system name from remote systems MIB.
Definition: lldp_mgmt.c:1403
error_t lldpMgmtSetReinitDelay(LldpAgentContext *context, uint_t reinitDelay, bool_t commit)
Set re-initialization delay.
Definition: lldp_mgmt.c:172
error_t lldpMgmtGetMsgTxInterval(LldpAgentContext *context, uint_t *msgTxInterval)
Get transmit interval.
Definition: lldp_mgmt.c:445
error_t lldpMgmtGetLocalChassisId(LldpAgentContext *context, LldpChassisIdSubtype *chassisIdSubtype, const uint8_t **chassisId, size_t *chassisIdLen)
Extract chassis ID from local system MIB.
Definition: lldp_mgmt.c:694
int_t lldpMgmtFindRemoteMgmtAddr(LldpNeighborEntry *entry, uint8_t mgmtAddrSubtype, const uint8_t *mgmtAddr, size_t mgmtAddrLen)
Search the remote system MIB for a given management address.
Definition: lldp_mgmt.c:1539
error_t lldpMgmtGetStatsRemTablesAgeouts(LldpAgentContext *context, uint32_t *statsRemTablesAgeouts)
Get the value of the statsRemTablesAgeouts statistics counter.
Definition: lldp_mgmt.c:2102
error_t lldpMgmtSetMsgTxInterval(LldpAgentContext *context, uint_t msgTxInterval, bool_t commit)
Set transmit interval.
Definition: lldp_mgmt.c:81
error_t lldpMgmtSetNotificationEnable(LldpAgentContext *context, uint_t portIndex, bool_t notificationEnable, bool_t commit)
Enable or disable notifications.
Definition: lldp_mgmt.c:355
error_t lldpGetNextTlv(LldpDataUnit *lldpdu, LldpTlv *tlv)
Extract the next TLV from an LLDPDU.
Definition: lldp_tlv.c:264
error_t lldpMgmtGetRemoteMgmtAddr(LldpNeighborEntry *entry, uint_t index, LldpMgmtAddrSubtype *mgmtAddrSubtype, const uint8_t **mgmtAddr, size_t *mgmtAddrLen, LldpIfNumSubtype *ifNumSubtype, uint32_t *ifNum, const uint8_t **oid, size_t *oidLen)
Extract management address from remote systems MIB.
Definition: lldp_mgmt.c:1608
error_t lldpMgmtGetStatsAgeoutsTotal(LldpAgentContext *context, uint_t portIndex, uint32_t *statsAgeoutsTotal)
Get the value of the statsAgeoutsTotal statistics counter.
Definition: lldp_mgmt.c:1951
error_t lldpMgmtGetLocalPortDesc(LldpAgentContext *context, uint_t portIndex, const char_t **portDesc, size_t *portDescLen)
Extract port description from local system MIB.
Definition: lldp_mgmt.c:817
error_t lldpMgmtGetReinitDelay(LldpAgentContext *context, uint_t *reinitDelay)
Get re-initialization delay.
Definition: lldp_mgmt.c:499
void lldpMgmtUnlock(LldpAgentContext *context)
Release exclusive access to the LLDP agent context.
Definition: lldp_mgmt.c:63
error_t lldpMgmtGetLocalSysDesc(LldpAgentContext *context, const char_t **sysDesc, size_t *sysDescLen)
Extract system description from local system MIB.
Definition: lldp_mgmt.c:919
error_t lldpMgmtSetMsgTxHold(LldpAgentContext *context, uint_t msgTxHold, bool_t commit)
Set transmit hold multiplier.
Definition: lldp_mgmt.c:127
error_t lldpMgmtGetStatsTLVsDiscardedTotal(LldpAgentContext *context, uint_t portIndex, uint32_t *statsTLVsDiscardedTotal)
Get the value of the statsTLVsDiscardedTotal statistics counter.
Definition: lldp_mgmt.c:1876
error_t lldpMgmtSetBasicTlvFilter(LldpAgentContext *context, uint_t portIndex, uint8_t mask, bool_t commit)
Set the list of TLVs enabled for transmission.
Definition: lldp_mgmt.c:399
void lldpMgmtLock(LldpAgentContext *context)
Acquire exclusive access to the LLDP agent context.
Definition: lldp_mgmt.c:51
error_t lldpMgmtGetStatsTLVsUnrecognizedTotal(LldpAgentContext *context, uint_t portIndex, uint32_t *statsTLVsUnrecognizedTotal)
Get the value of the statsTLVsUnrecognizedTotal statistics counter.
Definition: lldp_mgmt.c:1914
error_t lldpMgmtGetTxDelay(LldpAgentContext *context, uint_t *txDelay)
Get transmit delay.
Definition: lldp_mgmt.c:525
error_t lldpMgmtGetMibBasicTlvsTxEnable(LldpAgentContext *context, uint_t portIndex, uint8_t *mibBasicTlvsTxEnable)
Get the list of TLVs enabled for transmission.
Definition: lldp_mgmt.c:656
Data logging functions for debugging purpose (LLDP)
@ LLDP_ADMIN_STATUS_DISABLED
The local LLDP agent can neither transmit or receive LLDP frames.
Definition: lldp.h:188
error_t lldpMgmtGetRemoteOrgDefInfo(LldpNeighborEntry *entry, uint32_t oui, uint8_t subtype, uint_t index, const uint8_t **info, size_t *infoLen)
Extract organizationally defined TLV from remote systems MIB.
Definition: lldp_mgmt.c:1705
error_t lldpMgmtGetAdminStatus(LldpAgentContext *context, uint_t portIndex, LldpAdminStatus *adminStatus)
Get administrative status.
Definition: lldp_mgmt.c:580
error_t lldpMgmtGetRemotePortDesc(LldpNeighborEntry *entry, const char_t **portDesc, size_t *portDescLen)
Extract port description from remote systems MIB.
Definition: lldp_mgmt.c:1360
error_t lldpMgmtGetNotificationInterval(LldpAgentContext *context, uint_t *notificationInterval)
Get notification interval.
Definition: lldp_mgmt.c:551
error_t lldpMgmtGetLocalMgmtAddr(LldpAgentContext *context, uint_t index, LldpMgmtAddrSubtype *mgmtAddrSubtype, const uint8_t **mgmtAddr, size_t *mgmtAddrLen, LldpIfNumSubtype *ifNumSubtype, uint32_t *ifNum, const uint8_t **oid, size_t *oidLen)
Extract management address from local system MIB.
Definition: lldp_mgmt.c:1116
error_t lldpMgmtGetStatsRemTablesDrops(LldpAgentContext *context, uint32_t *statsRemTablesDrops)
Get the value of the statsRemTablesDrops statistics counter.
Definition: lldp_mgmt.c:2073
int_t lldpMgmtFindLocalMgmtAddr(LldpAgentContext *context, uint8_t mgmtAddrSubtype, const uint8_t *mgmtAddr, size_t mgmtAddrLen)
Search the local system MIB for a given management address.
Definition: lldp_mgmt.c:1023
error_t lldpGetOrgDefTlv(LldpDataUnit *lldpdu, uint32_t oui, uint8_t subtype, uint_t index, const uint8_t **value, size_t *length)
Search an LLDPDU for an organizationally specific TLV.
Definition: lldp_tlv.c:651
@ LLDP_ADMIN_STATUS_ENABLED_RX_ONLY
The local LLDP agent can only receive LLDP frames.
Definition: lldp.h:190
error_t lldpMgmtGetStatsFramesInTotal(LldpAgentContext *context, uint_t portIndex, uint32_t *statsFramesInTotal)
Get the value of the statsFramesInTotal statistics counter.
Definition: lldp_mgmt.c:1838
Helper functions for LLDP.
error_t lldpGetTlv(LldpDataUnit *lldpdu, uint8_t type, uint_t index, const uint8_t **value, size_t *length)
Search a LLDPDU for a given TLV.
Definition: lldp_tlv.c:200
error_t lldpMgmtGetLocalSysName(LldpAgentContext *context, const char_t **sysName, size_t *sysNameLen)
Extract system name from local system MIB.
Definition: lldp_mgmt.c:871
error_t lldpMgmtGetStatsFramesDiscardedTotal(LldpAgentContext *context, uint_t portIndex, uint32_t *statsFramesDiscardedTotal)
Get the value of the statsFramesDiscardedTotal statistics counter.
Definition: lldp_mgmt.c:1762
error_t lldpMgmtGetStatsRemTablesLastChangeTime(LldpAgentContext *context, uint32_t *statsRemTablesLastChangeTime)
Get the value of the statsRemTablesLastChangeTime statistics counter.
Definition: lldp_mgmt.c:1988
error_t lldpMgmtGetRemoteSysDesc(LldpNeighborEntry *entry, const char_t **sysDesc, size_t *sysDescLen)
Extract system description from remote systems MIB.
Definition: lldp_mgmt.c:1446
error_t lldpMgmtGetNotificationEnable(LldpAgentContext *context, uint_t portIndex, bool_t *notificationEnable)
Check whether notifications are enabled or disabled.
Definition: lldp_mgmt.c:618
error_t lldpMgmtGetRemoteSysCap(LldpNeighborEntry *entry, uint16_t *supportedCap, uint16_t *enabledCap)
Extract system capabilities from remote systems MIB.
Definition: lldp_mgmt.c:1489
error_t lldpMgmtSetNotificationInterval(LldpAgentContext *context, uint_t notificationInterval, bool_t commit)
Set notification interval.
Definition: lldp_mgmt.c:254
error_t lldpMgmtGetStatsRemTablesDeletes(LldpAgentContext *context, uint32_t *statsRemTablesDeletes)
Get the value of the statsRemTablesDeletes statistics counter.
Definition: lldp_mgmt.c:2044
error_t lldpMgmtGetLocalSysCap(LldpAgentContext *context, uint16_t *supportedCap, uint16_t *enabledCap)
Extract system capabilities from local system MIB.
Definition: lldp_mgmt.c:968
error_t lldpMgmtGetStatsFramesOutTotal(LldpAgentContext *context, uint_t portIndex, uint32_t *statsFramesOutTotal)
Get the value of the statsFramesOutTotal statistics counter.
Definition: lldp_mgmt.c:1724
error_t lldpMgmtGetRemotePortId(LldpNeighborEntry *entry, LldpPortIdSubtype *portIdSubtype, const uint8_t **portId, size_t *portIdLen)
Extract port ID from remote systems MIB.
Definition: lldp_mgmt.c:1309
void lldpSomethingChangedLocal(LldpAgentContext *context)
Notify LLDP that an object in the LLDP local system MIB has changed.
Definition: lldp_misc.c:806
void osAcquireMutex(OsMutex *mutex)
Acquire ownership of the specified mutex object.
Definition: os_port_chibios.c:396
void osReleaseMutex(OsMutex *mutex)
Release ownership of the specified mutex object.
Definition: os_port_chibios.c:408
error_t lldpDecodeMgmtAddrTlv(const uint8_t *value, size_t length, const LldpMgmtAddrTlv1 **mgmtAddr1, const LldpMgmtAddrTlv2 **mgmtAddr2)
Decode the contents of a Management Address TLV.
Definition: lldp_tlv.c:380
error_t lldpMgmtGetRemoteChassisId(LldpNeighborEntry *entry, LldpChassisIdSubtype *chassisIdSubtype, const uint8_t **chassisId, size_t *chassisIdLen)
Extract chassis ID from remote systems MIB.
Definition: lldp_mgmt.c:1257
LldpNeighborEntry * lldpMgmtFindRemoteTableEntry(LldpAgentContext *context, uint32_t timeMark, uint_t portIndex, uint32_t index)
Search the remote systems MIB for a given entry.
Definition: lldp_mgmt.c:1218
Management of the LLDP agent.
error_t lldpMgmtSetTxDelay(LldpAgentContext *context, uint_t txDelay, bool_t commit)
Set transmit delay.
Definition: lldp_mgmt.c:213
error_t lldpMgmtGetLocalPortId(LldpAgentContext *context, uint_t portIndex, LldpPortIdSubtype *portIdSubtype, const uint8_t **portId, size_t *portIdLen)
Extract port ID from local system MIB.
Definition: lldp_mgmt.c:752
LLDP (Link Layer Discovery Protocol)
TCP/IP stack core.
error_t lldpMgmtGetMsgTxHold(LldpAgentContext *context, uint_t *msgTxHold)
Get transmit hold multiplier.
Definition: lldp_mgmt.c:473
error_t lldpMgmtGetRemoteUnknownTlv(LldpNeighborEntry *entry, uint8_t type, uint_t index, const uint8_t **info, size_t *infoLen)
Extract unknown TLV from remote systems MIB.
Definition: lldp_mgmt.c:1686
Debugging facilities.
error_t lldpMgmtGetStatsRemTablesInserts(LldpAgentContext *context, uint32_t *statsRemTablesInserts)
Get the value of the statsRemTablesInserts statistics counter.
Definition: lldp_mgmt.c:2016
error_t lldpMgmtSetAdminStatus(LldpAgentContext *context, uint_t portIndex, LldpAdminStatus adminStatus, bool_t commit)
Set administrative status.
Definition: lldp_mgmt.c:297
error_t lldpMgmtGetStatsFramesInErrorsTotal(LldpAgentContext *context, uint_t portIndex, uint32_t *statsFramesInErrorsTotal)
Get the value of the statsFramesInErrorsTotal statistics counter.
Definition: lldp_mgmt.c:1800
@ LLDP_ADMIN_STATUS_ENABLED_TX_ONLY
The local LLDP agent can only transmit LLDP frames.
Definition: lldp.h:189