31 #ifndef __ONLP_SFPI_H__ 32 #define __ONLP_SFPI_H__ 103 uint8_t* dst,
int len);
115 uint8_t* src,
int len);
onlp Configuration Header
int onlp_sfpi_dev_write(onlp_oid_id_t id, int devaddr, int addr, uint8_t *src, int len)
Write bytes to the target device on the given SFP port.
int onlp_sfpi_presence_bitmap_get(onlp_sfp_bitmap_t *dst)
Return the presence bitmap for all SFP ports.
SFP Management Interface.
int onlp_sfpi_post_insert(onlp_oid_id_t id, sff_info_t *info)
Perform any actions required after an SFP is inserted.
int onlp_sfpi_dev_writew(onlp_oid_id_t id, int devaddr, int addr, uint16_t value)
Write a word to the target device on the given SFP port.
int onlp_sfpi_dev_readw(onlp_oid_id_t id, int devaddr, int addr)
Read a word from the target device on the given SFP port.
int onlp_sfpi_sw_denit(void)
Deinitialize the chassis software module.
int onlp_sfpi_hw_init(uint32_t flags)
Hardware initialization of the SFP module.
int onlp_sfpi_type_get(onlp_oid_id_t id, onlp_sfp_type_t *rtype)
Determine the SFP connector type.
int onlp_sfpi_bitmap_get(onlp_sfp_bitmap_t *bmap)
Get the bitmap of SFP-capable port numbers.
uint32_t onlp_oid_id_t
Definition: oids.h:55
int onlp_sfpi_hdr_get(onlp_oid_id_t id, onlp_oid_hdr_t *hdr)
Get the SFP's OID header.
int onlp_sfpi_is_present(onlp_oid_id_t id)
Determine if an SFP is present.
aim_bitmap256_t onlp_sfp_bitmap_t
Definition: sfp.h:138
int onlp_sfpi_dev_writeb(onlp_oid_id_t id, int devaddr, int addr, uint8_t value)
Write a byte to the target device on the given SFP port.
int onlp_sfpi_port_map(onlp_oid_id_t id, int *rport)
Remap SFP user SFP port numbers before calling the SFPI interface.
int onlp_sfpi_control_get(onlp_oid_id_t id, onlp_sfp_control_t control, int *value)
Get an SFP control.
int onlp_sfpi_control_supported(onlp_oid_id_t id, onlp_sfp_control_t control, int *rv)
Returns whether or not the given control is supported on the given port.
enum onlp_sfp_type_e onlp_sfp_type_t
int onlp_sfpi_dev_read(onlp_oid_id_t id, int devaddr, int addr, uint8_t *dst, int len)
Read bytes from the target device on the given SFP port.
enum onlp_sfp_control_e onlp_sfp_control_t
int onlp_sfpi_dev_readb(onlp_oid_id_t id, int devaddr, int addr)
Read a byte from the target device on the given SFP port.
int onlp_sfpi_rx_los_bitmap_get(onlp_sfp_bitmap_t *dst)
Return the RX_LOS bitmap for all SFP ports.
int onlp_sfpi_sw_init(void)
Software initialization of the SFP module.
int onlp_sfpi_control_set(onlp_oid_id_t id, onlp_sfp_control_t control, int value)
Set an SFP control.