Skip to content

Commit 46db2be

Browse files
author
Martin Liao
committed
Create API for fast linkup configuration.
Signed-off-by: Martin Liao <[email protected]>
1 parent f56f534 commit 46db2be

File tree

4 files changed

+94
-0
lines changed

4 files changed

+94
-0
lines changed

doc/SAI-Proposal-Fast-Linkup.md

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
# Fast Link-Up
2+
-------------------------------------------------------------------------------
3+
Title | Fast Link-Up
4+
-------------|-----------------------------------------------------------------
5+
Authors | Eddy Kvetny, Nvidia
6+
Status | In review
7+
Type | Standards track
8+
Created | 2025-09-09
9+
SAI-Version | 1.17
10+
-------------------------------------------------------------------------------
11+
12+
# 1. Overview
13+
In some cases the equalization parameters from the previous session can be used for a new link-up process. It can significantly reduce time of the Link-Up process
14+
15+
# 2. Scope
16+
This approach is applicable to devices (switch-to-switch or switch-to-NIC) supporting this process, usually from the same vendor or from different vendors aligned on the process
17+
18+
# 3. Architecture
19+
This feature shall be enabled per-port using a new SAI attribute - SAI_PORT_ATTR_FAST_LINKUP_ENABLED
20+
21+
On ports with the enabled feature the ASIC FW shall try first to bring a link up using the equalization parameter stored from the previous successul session. The time given to ASIC to try to bring a link up with the old EQ parameters is limited by the Fast Link-Up Polling Timer. The time value is configured using a new SAI attribute - SAI_SWITCH_ATTR_FAST_LINKUP_POLLING_TIME. The supported range for this value (in secs) can be read by NOS using a new SAI attribute SAI_SWITCH_ATTR_FAST_LINKUP_POLLING_TIME_RANGE
22+
23+
If the process of brining a link up with the previosly used EQ parameters doesn't succeed the regular link-up process with new negotiated EQ parameters is triggered
24+
25+
If the link succeeds moving to the Operation UP state then the BER level shall be checked to make sure that the establish link has a good quality. To do that another timer called Guard Timer is used. Its value is also configurable using a new SAI attribute (SAI_SWITCH_ATTR_FAST_LINKUP_GUARD_TIME)
26+
27+
28+
When the Guard Timer expires the BER is measured and compared with the "good" BER value configured using a new SAI attribure SAI_SWITCH_ATTR_FAST_LINKUP_BER_THRESHOLD. Only if the measured BER is equal or better than the configured BER threshold the process is considered completed. Otherwise, the fallback to the regular link-up process is done and link's Oper status changes to DOWN
29+
30+
Note that the State Machine is implemented by ASIC FW and can vary between vendors. The proposal just defines just high level flow and SAI configuration for this flow
31+
32+
The following State Machine is proposed for the Fast Link-UP process described above
33+
34+
![](figures/sai_fast_linkup_state_machine.png)
80.8 KB
Loading

inc/saiport.h

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2712,6 +2712,15 @@ typedef enum _sai_port_attr_t
27122712
*/
27132713
SAI_PORT_ATTR_PAM4_EYE_VALUES,
27142714

2715+
/**
2716+
* @brief Enables the fast link-up for a port on port/link recovery. Vendors can use to reduce linkup time on remote link failure
2717+
*
2718+
* @type bool
2719+
* @flags CREATE_AND_SET
2720+
* @default false
2721+
*/
2722+
SAI_PORT_ATTR_FAST_LINKUP_ENABLED,
2723+
27152724
/**
27162725
* @brief End of attributes
27172726
*/

inc/saiswitch.h

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3468,6 +3468,57 @@ typedef enum _sai_switch_attr_t
34683468
*/
34693469
SAI_SWITCH_ATTR_NEXT_HOP_USER_META_DATA_RANGE,
34703470

3471+
/**
3472+
* @brief Linkup polling time range (in secs)
3473+
*
3474+
* @type sai_u16_range_t
3475+
* @flags READ_ONLY
3476+
*/
3477+
SAI_SWITCH_ATTR_FAST_LINKUP_POLLING_TIME_RANGE,
3478+
3479+
/**
3480+
* @brief Time (in sec) during which the fast link-up is attempted.
3481+
*
3482+
* If this timer expires before the link is UP the regular link-up will be performed
3483+
* Supported range can be obtained using SAI_SWITCH_ATTR_FAST_LINKUP_POLLING_TIME_RANGE
3484+
*
3485+
* @type sai_uint16_t
3486+
* @flags CREATE_AND_SET
3487+
* @default 60
3488+
*/
3489+
SAI_SWITCH_ATTR_FAST_LINKUP_POLLING_TIME,
3490+
3491+
/**
3492+
* @brief Linkup guard time range (in secs)
3493+
*
3494+
* @type sai_u16_range_t
3495+
* @flags READ_ONLY
3496+
*/
3497+
SAI_SWITCH_ATTR_FAST_LINKUP_GUARD_TIME_RANGE,
3498+
3499+
/**
3500+
* @brief Time (in secs) during which the link must be UP with the BER below the level configured with SAI_SWITCH_ATTR_FAST_LINKUP_GUARD_TIME_BER to keep the fast link-up configuration.
3501+
*
3502+
* If either link failures happens within this time or high BER is measured at the end of this period of time the link should undergo regular link up process
3503+
* Supported range can be obtained using SAI_SWITCH_ATTR_FAST_LINKUP_GUARD_TIME_RANGE
3504+
*
3505+
* @type sai_uint8_t
3506+
* @flags CREATE_AND_SET
3507+
* @default 10
3508+
*/
3509+
SAI_SWITCH_ATTR_FAST_LINKUP_GUARD_TIME,
3510+
3511+
/**
3512+
* @brief Configures the BER (negative exponent only, mantissa is always 1) which is if measured during
3513+
*
3514+
* SAI_SWITCH_ATTR_FAST_LINKUP_GUARD_TIME causes the full link-up flow. For example, "12" configured here is 1e^-12)
3515+
*
3516+
* @type sai_uint8_t
3517+
* @flags CREATE_AND_SET
3518+
* @default 12
3519+
*/
3520+
SAI_SWITCH_ATTR_FAST_LINKUP_BER_THRESHOLD,
3521+
34713522
/**
34723523
* @brief End of attributes
34733524
*/

0 commit comments

Comments
 (0)