MACsec Intel FPGA System Design User Guide

ID 767516
Date 3/03/2023
Public

A newer version of this document is available. Customers should click here to go to the newest version.

Document Table of Contents

6.6.5. macsec_set_sa_attributes

macsec_set_sa_attributes

Synopsis
int macsec_set_sa_attr (struct macsec_info *info, uint32_t port, uint32_t sc, uint32_t sa, enum macsec_sa_attr attr, const void *value)
Description

Sets a MACsec SA attribute.

Sets attribute for a given (sc,sa) pair for the specified port.

Arguments

info—points to the macsec_info structure.

port—logical port value.

sc—secure channel value.

sa—secure association value.

attr—MACsec SA attribute.

value—points to the value to set for the attribute.

Returns

MACSEC_OK if successful.

MACSEC_ERR_INVALID_ARG if value, macsec_attr or info is NULL or SC/SA invalid.

MACSEC_ERR_INVALID_PORT if port not associated with any port.

MACSEC_ERR_INVALID_ATTR if the attribute is unknown or the key or salt attribute is tried to be read.

MACSEC_ERR_INVALID_VALUE if the MACsec instance is invalid.

MACSEC_ERR_WRITE if fails to write to the csr register.