Skip to content

Commit ec22e22

Browse files
committed
Merge branch '202505' of https://github.com/sonic-net/sonic-buildimage into 202506
2 parents 2b71a41 + 8dbbf05 commit ec22e22

100 files changed

Lines changed: 997 additions & 770 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

device/arista/x86_64-arista_7060x6_64pe/platform.json

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,14 @@
110110
{
111111
"name": "Management Card Inlet",
112112
"controllable": false
113+
},
114+
{
115+
"name": "TH5 Diode 1",
116+
"controllable": false
117+
},
118+
{
119+
"name": "TH5 Diode 2",
120+
"controllable": false
113121
}
114122
],
115123
"sfps": [

device/arista/x86_64-arista_7060x6_64pe/sensors.conf

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,6 @@ bus "i2c-29" "SCD 0000:03:00.0 SMBus master 1 bus 4"
55
chip "max6581-i2c-25-4d"
66
ignore temp5
77
ignore temp6
8-
ignore temp7
9-
ignore temp8
108

119
chip "nvme-pci-0400"
1210
# TODO: sensors complaining about tempX_min and tempX_max

device/arista/x86_64-arista_7060x6_64pe_b/platform.json

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,14 @@
118118
{
119119
"name": "Management Card Inlet",
120120
"controllable": false
121+
},
122+
{
123+
"name": "TH5 Diode 1",
124+
"controllable": false
125+
},
126+
{
127+
"name": "TH5 Diode 2",
128+
"controllable": false
121129
}
122130
],
123131
"sfps": [

device/arista/x86_64-arista_7060x6_64pe_b/sensors.conf

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,6 @@ bus "i2c-31" "SCD 0000:08:00.0 SMBus master 1 bus 4"
55
chip "max6581-i2c-27-4d"
66
ignore temp5
77
ignore temp6
8-
ignore temp7
9-
ignore temp8
108

119
chip "nvme-pci-0400"
1210
# TODO: sensors complaining about tempX_min and tempX_max

dockers/docker-fpm-frr/base_image_files/prefix_list

Lines changed: 33 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -32,17 +32,37 @@ check_root_privileges() {
3232
fi
3333
}
3434

35-
# Function to check if the device is supported device with type spine routers and subtype UpstreamLC
36-
check_spine_router() {
37-
type=$(sonic-cfggen -d -v DEVICE_METADATA.localhost.type)
38-
subtype=$(sonic-cfggen -d -v DEVICE_METADATA.localhost.subtype)
39-
40-
# only supported on UpstreamLC or UpperSpineRouter
41-
if [[ ("$type" == "SpineRouter" && "$subtype" == "UpstreamLC") || "$type" == "UpperSpineRouter" ]]; then
42-
return
35+
# Function to check if the device is a supported device type
36+
DEVICE_TYPE=""
37+
DEVICE_SUBTYPE=""
38+
39+
read_device_metadata() {
40+
if [[ -z "$DEVICE_TYPE" ]]; then
41+
DEVICE_TYPE=$(sonic-cfggen -d -v DEVICE_METADATA.localhost.type)
42+
DEVICE_SUBTYPE=$(sonic-cfggen -d -v DEVICE_METADATA.localhost.subtype)
4343
fi
44+
}
4445

45-
echo "Operation is only supported on Upstream SpineRouter." >&2
46+
declare -A prefix_type_devices
47+
prefix_type_devices=(
48+
["ANCHOR_PREFIX"]="SpineRouter:UpstreamLC UpperSpineRouter"
49+
["SUPPRESS_PREFIX"]=""
50+
)
51+
52+
validate_device_for_type() {
53+
local prefix_type=$1
54+
local allowed="${prefix_type_devices[$prefix_type]}"
55+
[[ -z "$allowed" ]] && return
56+
read_device_metadata
57+
local device_id="$DEVICE_TYPE:$DEVICE_SUBTYPE"
58+
for entry in $allowed; do
59+
if [[ "$entry" == *":"* ]]; then
60+
[[ "$device_id" == "$entry" ]] && return
61+
else
62+
[[ "$DEVICE_TYPE" == "$entry" ]] && return
63+
fi
64+
done
65+
echo "Prefix type '$prefix_type' is not supported on device type '$DEVICE_TYPE' (subtype: '$DEVICE_SUBTYPE')." >&2
4666
exit 1
4767
}
4868

@@ -147,7 +167,7 @@ handle_prefix_list_single() {
147167
}
148168

149169
prefix_list_operations=("add" "remove" "status")
150-
supported_prefix_types=("ANCHOR_PREFIX")
170+
supported_prefix_types=("ANCHOR_PREFIX" "SUPPRESS_PREFIX")
151171
# Main script execution
152172
if [[ "$1" == "-h" || "$1" == "--help" ]]; then
153173
display_help
@@ -156,10 +176,12 @@ fi
156176
if [ "$1" != "status" ]; then
157177
check_root_privileges
158178
fi
159-
check_spine_router
160179
skip_chassis_supervisor
161180

162181
validate_operation $1 $2
182+
if [[ "$1" == "add" || "$1" == "remove" ]]; then
183+
validate_device_for_type "$2"
184+
fi
163185

164186
# Read SONiC immutable variables
165187
[ -f /etc/sonic/sonic-environment ] && . /etc/sonic/sonic-environment
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{{ data.ipv }} prefix-list {{ data.prefix_list_name }} permit {{ data.prefix }}
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
no {{ data.ipv }} prefix-list {{ data.prefix_list_name }} permit {{ data.prefix }}

dockers/docker-platform-monitor/Dockerfile.j2

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ RUN apt-get install -y -t bookworm-backports \
4444
# install any dependencies required by the Arista sonic_platform package.
4545
# TODO: eliminate the need to install these explicitly.
4646
RUN pip3 install grpcio==1.51.1 \
47-
grpcio-tools==1.51.1
47+
grpcio-tools==1.51.1 --no-build-isolation
4848

4949
# Barefoot platform vendors' sonic_platform packages import these Python libraries
5050
RUN pip3 install thrift==0.13.0 netifaces

dockers/docker-ptf-sai/Dockerfile.j2

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,9 +45,8 @@ RUN dpkg -r python-ptf
4545
RUN pip3 install setuptools==51.0.0
4646
{% endif %}
4747
# Install new ptf package
48-
RUN git clone https://github.com/p4lang/ptf.git \
49-
&& cd ptf \
50-
&& python3 setup.py install --single-version-externally-managed --record /tmp/ptf_install.txt
48+
RUN pip3 install git+https://github.com/p4lang/ptf.git \
49+
&& pip3 show -f ptf > /tmp/ptf_install.txt
5150

5251
run echo "declare -x LANG=\"C.UTF-8\"" >> /root/.bashrc
5352
run echo "declare -x LC_ALL=\"C.UTF-8\"" >> /root/.bashrc

0 commit comments

Comments
 (0)