Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add HA session parameter Bounceback IP #631

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions dash-pipeline/SAI/specs/dash_ha.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,19 @@ sai_apis:
valid_only: null
is_vlan: false
deprecated: false
- !!python/object:utils.sai_spec.sai_attribute.SaiAttribute
name: SAI_HA_SET_ATTR_PEER_BOUNCEBACK_IP
description: Action parameter peer bounceback IP
type: sai_ip_address_t
attr_value_field: ipaddr
default: 0.0.0.0
isresourcetype: false
flags: CREATE_AND_SET
object_name: null
allow_null: false
valid_only: null
is_vlan: false
deprecated: false
stats:
- !!python/object:utils.sai_spec.sai_attribute.SaiAttribute
name: SAI_HA_SET_STAT_DP_PROBE_REQ_RX_BYTES
Expand Down
2 changes: 2 additions & 0 deletions dash-pipeline/bmv2/dash_metadata.p4
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,8 @@ struct ha_data_t {
bit<16> dp_channel_dst_port;
bit<16> dp_channel_src_port_min;
bit<16> dp_channel_src_port_max;
bit<1> peer_bounceback_ip_is_v6;
IPv4ORv6Address peer_bounceback_ip;
}

#ifdef TARGET_DPDK_PNA
Expand Down
6 changes: 5 additions & 1 deletion dash-pipeline/bmv2/stages/ha.p4
Original file line number Diff line number Diff line change
Expand Up @@ -71,10 +71,14 @@ control ha_stage(inout headers_t hdr,
bit<32> dp_channel_probe_interval_ms,
bit<32> dp_channel_probe_fail_threshold,
@SaiVal[isreadonly="true"] bit<1> dp_channel_is_alive,
bit<32> dpu_driven_ha_switchover_wait_time_ms
bit<32> dpu_driven_ha_switchover_wait_time_ms,
bit<1> peer_bounceback_ip_is_v6,
@SaiVal[type="sai_ip_address_t"] IPv4ORv6Address peer_bounceback_ip
) {
meta.ha.peer_ip_is_v6 = peer_ip_is_v6;
meta.ha.peer_ip = peer_ip;
meta.ha.peer_bounceback_ip_is_v6 = peer_bounceback_ip_is_v6;
meta.ha.peer_bounceback_ip = peer_bounceback_ip;

meta.ha.dp_channel_dst_port = dp_channel_dst_port;
meta.ha.dp_channel_src_port_min = dp_channel_min_src_port;
Expand Down
Loading