From fb4cd63ac580ec9cfef701d5d81ea53e5e9fb985 Mon Sep 17 00:00:00 2001 From: wadelnn Date: Fri, 19 May 2017 02:05:49 +0800 Subject: [PATCH] [Ingrasys] Add Ingrasys S8900 series platform (#569) * Add Ingrasys S8900 series platform * Add Ingrasys S8900-54XC platform driver * Add Ingrasys S8900-64XC platform driver * Reorganized Ingrasys debian package * Move fancontrol config to device-specific file directory * QSFP transceivers init on S9100-32X * Update Thermal Policy in sensors.conf * Add new Ingrasys S8900 series platform for docker-orchagent/orchagent.sh Signed-off-by: Wade He --- .gitmodules | 7 +- .../INGRASYS-S8900-54XC/port_config.ini | 55 +++ .../INGRASYS-S8900-54XC/sai.profile | 1 + .../x86_64-ingrasys_s8900_54xc-r0/fancontrol | 12 + .../installer.conf | 3 + .../minigraph.xml | 121 ++++++ .../plugins/eeprom.py | 23 ++ .../plugins/sfputil.py | 82 ++++ .../sensors.conf | 39 ++ .../INGRASYS-S8900-64XC/port_config.ini | 65 ++++ .../INGRASYS-S8900-64XC/sai.profile | 1 + .../x86_64-ingrasys_s8900_64xc-r0/fancontrol | 11 + .../installer.conf | 3 + .../minigraph.xml | 359 ++++++++++++++++++ .../plugins/eeprom.py | 23 ++ .../plugins/sfputil.py | 107 ++++++ .../sensors.conf | 56 +++ .../INGRASYS-S9100-C32/port_config.ini | 64 ++-- .../x86_64-ingrasys_s9100-r0/fancontrol | 12 + .../x86_64-ingrasys_s9100-r0/sensors.conf | 4 + dockers/docker-orchagent/orchagent.sh | 4 + platform/broadcom/one-image.mk | 2 + .../platform-modules-ingrasys-s9100.mk | 11 - .../broadcom/platform-modules-ingrasys.mk | 24 ++ platform/broadcom/rules.mk | 2 +- .../broadcom/sonic-platform-modules-ingrasys | 1 + .../sonic-platform-modules-ingrasys-s9100 | 1 - 27 files changed, 1044 insertions(+), 49 deletions(-) create mode 100644 device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/INGRASYS-S8900-54XC/port_config.ini create mode 100644 device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/INGRASYS-S8900-54XC/sai.profile create mode 100644 device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/fancontrol create mode 100644 device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/installer.conf create mode 100644 device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/minigraph.xml create mode 100644 device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/plugins/eeprom.py create mode 100644 device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/plugins/sfputil.py create mode 100644 device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/sensors.conf create mode 100644 device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/INGRASYS-S8900-64XC/port_config.ini create mode 100644 device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/INGRASYS-S8900-64XC/sai.profile create mode 100644 device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/fancontrol create mode 100644 device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/installer.conf create mode 100644 device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/minigraph.xml create mode 100644 device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/plugins/eeprom.py create mode 100644 device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/plugins/sfputil.py create mode 100644 device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/sensors.conf create mode 100644 device/ingrasys/x86_64-ingrasys_s9100-r0/fancontrol delete mode 100755 platform/broadcom/platform-modules-ingrasys-s9100.mk create mode 100644 platform/broadcom/platform-modules-ingrasys.mk create mode 160000 platform/broadcom/sonic-platform-modules-ingrasys delete mode 160000 platform/broadcom/sonic-platform-modules-ingrasys-s9100 diff --git a/.gitmodules b/.gitmodules index 131b4634b5..c35e478ae4 100644 --- a/.gitmodules +++ b/.gitmodules @@ -53,11 +53,10 @@ [submodule "platform/broadcom/sonic-platform-modules-dell"] path = platform/broadcom/sonic-platform-modules-dell url = https://github.com/Azure/sonic-platform-modules-dell -[submodule "platform/broadcom/sonic-platform-modules-ingrasys-s9100"] - path = platform/broadcom/sonic-platform-modules-ingrasys-s9100 - url = https://github.com/Ingrasys-sonic/sonic-platform-ingrasys-s9100 +[submodule "platform/broadcom/sonic-platform-modules-ingrasys"] + path = platform/broadcom/sonic-platform-modules-ingrasys + url = https://github.com/Ingrasys-sonic/sonic-platform-modules-ingrasys [submodule "src/SAI"] path = src/SAI url = https://github.com/opencomputeproject/SAI branch = v0.9.4 - diff --git a/device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/INGRASYS-S8900-54XC/port_config.ini b/device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/INGRASYS-S8900-54XC/port_config.ini new file mode 100644 index 0000000000..24a2b8e292 --- /dev/null +++ b/device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/INGRASYS-S8900-54XC/port_config.ini @@ -0,0 +1,55 @@ +# name lanes alias +Ethernet0 1 +Ethernet1 2 +Ethernet2 3 +Ethernet3 4 +Ethernet4 5 +Ethernet5 6 +Ethernet6 7 +Ethernet7 8 +Ethernet8 9 +Ethernet9 10 +Ethernet10 11 +Ethernet11 12 +Ethernet12 21 +Ethernet13 22 +Ethernet14 23 +Ethernet15 24 +Ethernet16 33 +Ethernet17 34 +Ethernet18 35 +Ethernet19 36 +Ethernet20 37 +Ethernet21 38 +Ethernet22 39 +Ethernet23 40 +Ethernet24 41 +Ethernet25 42 +Ethernet26 43 +Ethernet27 44 +Ethernet28 49 +Ethernet29 50 +Ethernet30 51 +Ethernet31 52 +Ethernet32 53 +Ethernet33 54 +Ethernet34 55 +Ethernet35 56 +Ethernet36 65 +Ethernet37 66 +Ethernet38 67 +Ethernet39 68 +Ethernet40 69 +Ethernet41 70 +Ethernet42 71 +Ethernet43 72 +Ethernet44 81 +Ethernet45 82 +Ethernet46 83 +Ethernet47 84 +Ethernet48 85,86,87,88 +Ethernet52 97,98,99,100 +Ethernet56 101,102,103,104 +Ethernet60 105,106,107,108 +Ethernet64 109,110,111,112 +Ethernet68 117,118,119,120 diff --git a/device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/INGRASYS-S8900-54XC/sai.profile b/device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/INGRASYS-S8900-54XC/sai.profile new file mode 100644 index 0000000000..6f07b4605c --- /dev/null +++ b/device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/INGRASYS-S8900-54XC/sai.profile @@ -0,0 +1 @@ +SAI_INIT_CONFIG_FILE=/etc/bcm/th-s8900-48x25G+6x100G.config.bcm diff --git a/device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/fancontrol b/device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/fancontrol new file mode 100644 index 0000000000..05a71e8d99 --- /dev/null +++ b/device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/fancontrol @@ -0,0 +1,12 @@ +# Configuration file generated by pwmconfig, changes will be lost +INTERVAL=10 +DEVPATH=hwmon2=devices/pci0000:00/0000:00:1f.3/i2c-0/0-002f +DEVNAME=hwmon2=w83795adg +FCTEMPS=hwmon2/device/pwm2=hwmon2/device/temp2_input hwmon2/device/pwm1=hwmon2/device/temp2_input +#FCFANS=hwmon2/device/pwm2=hwmon2/device/fan8_input+hwmon2/device/fan7_input+hwmon2/device/fan6_input+hwmon2/device/fan5_input hwmon2/device/pwm1=hwmon2/device/fan4_input+hwmon2/device/fan3_input+hwmon2/device/fan2_input+hwmon2/device/fan1_input +FCFANS=hwmon2/device/pwm2=hwmon2/device/fan8_input hwmon2/device/pwm2=hwmon2/device/fan7_input hwmon2/device/pwm2=hwmon2/device/fan6_input hwmon2/device/pwm2=hwmon2/device/fan5_input hwmon2/device/pwm1=hwmon2/device/fan4_input hwmon2/device/pwm1=hwmon2/device/fan3_input hwmon2/device/pwm1=hwmon2/device/fan2_input hwmon2/device/pwm1=hwmon2/device/fan1_input +MINTEMP=hwmon2/device/pwm2=20 hwmon2/device/pwm1=20 +MAXTEMP=hwmon2/device/pwm2=60 hwmon2/device/pwm1=60 +MINSTART=hwmon2/device/pwm2=75 hwmon2/device/pwm1=75 +MINSTOP=hwmon2/device/pwm2=22 hwmon2/device/pwm1=22 + diff --git a/device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/installer.conf b/device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/installer.conf new file mode 100644 index 0000000000..14404194ef --- /dev/null +++ b/device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/installer.conf @@ -0,0 +1,3 @@ +CONSOLE_PORT=0x2f8 +CONSOLE_DEV=1 +CONSOLE_SPEED=115200 diff --git a/device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/minigraph.xml b/device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/minigraph.xml new file mode 100644 index 0000000000..470b07922b --- /dev/null +++ b/device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/minigraph.xml @@ -0,0 +1,121 @@ + + + + + + OCPSCH0104001MS + 10.10.1.30 + OCPSCH01040HHLF + 10.10.1.29 + 1 + 10 + 3 + + + OCPSCH0104002MS + 10.10.2.30 + OCPSCH01040HHLF + 10.10.2.29 + 1 + 10 + 3 + + + + + 64536 + OCPSCH01040HHLF + + +
10.10.1.30
+ + +
+ +
10.10.2.30
+ + +
+
+ +
+ + 64542 + OCPSCH0104001MS + + + + 64543 + OCPSCH0104002MS + + +
+
+ + + + + + HostIP + Loopback0 + + 100.0.0.10/32 + + 100.0.0.10/32 + + + + + + + + OCPSCH01040HHLF + + + + + + Ethernet48 + 10.10.1.29/30 + + + + Ethernet52 + 10.10.2.29/30 + + + + + + + + + + + + 40000 + DeviceInterfaceLink + OCPSCH0104001MS + Ethernet48 + OCPSCH01040HHLF + Ethernet48 + + + 40000 + DeviceInterfaceLink + OCPSCH0104002MS + Ethernet0 + OCPSCH01040HHLF + Ethernet52 + + + + + OCPSCH01040HHLF + INGRASYS-S8900-54XC + + + + OCPSCH01040HHLF + INGRASYS-S8900-54XC +
diff --git a/device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/plugins/eeprom.py b/device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/plugins/eeprom.py new file mode 100644 index 0000000000..2013aedddd --- /dev/null +++ b/device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/plugins/eeprom.py @@ -0,0 +1,23 @@ +#!/usr/bin/env python + +############################################################################# +# Dell Z9100 +# +# Platform and model specific eeprom subclass, inherits from the base class, +# and provides the followings: +# - the eeprom format definition +# - specific encoder/decoder if there is special need +############################################################################# + +try: + from sonic_eeprom import eeprom_tlvinfo +except ImportError, e: + raise ImportError (str(e) + "- required module not found") + + +class board(eeprom_tlvinfo.TlvInfoDecoder): + + def __init__(self, name, path, cpld_root, ro): + self.eeprom_path = "/sys/class/i2c-adapter/i2c-17/17-0054/eeprom" + super(board, self).__init__(self.eeprom_path, 0, '', True) + diff --git a/device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/plugins/sfputil.py b/device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/plugins/sfputil.py new file mode 100644 index 0000000000..96fa0fca86 --- /dev/null +++ b/device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/plugins/sfputil.py @@ -0,0 +1,82 @@ +#!/usr/bin/env python + +try: + from sonic_sfp.sfputilbase import sfputilbase +except ImportError, e: + raise ImportError (str(e) + "- required module not found") + + +class sfputil(sfputilbase): + """Platform specific sfputil class""" + + port_start = 0 + port_end = 53 + ports_in_block = 54 + + port_to_eeprom_mapping = {} + port_to_i2c_mapping = { + 0: 18, + 1: 19, + 2: 20, + 3: 21, + 4: 22, + 5: 23, + 6: 24, + 7: 25, + 8: 26, + 9: 27, + 10: 28, + 11: 29, + 12: 30, + 13: 31, + 14: 32, + 15: 33, + 16: 34, + 17: 35, + 18: 36, + 19: 37, + 20: 38, + 21: 39, + 22: 40, + 23: 41, + 24: 42, + 25: 43, + 26: 44, + 27: 45, + 28: 46, + 29: 47, + 30: 48, + 31: 49, + 32: 50, + 33: 51, + 34: 52, + 35: 53, + 36: 54, + 37: 55, + 38: 56, + 39: 57, + 40: 58, + 41: 59, + 42: 60, + 43: 61, + 44: 62, + 45: 63, + 46: 64, + 47: 65, + 48: 66, + 49: 67, + 50: 68, + 51: 69, + 52: 70, + 53: 71 + } + + _qsfp_ports = range(0, ports_in_block + 1) + + def __init__(self, port_num): + # Override port_to_eeprom_mapping for class initialization + eeprom_path = '/sys/class/i2c-adapter/i2c-{0}/{0}-0050/eeprom' + for x in range(self.port_start, self.port_end + 1): + port_eeprom_path = eeprom_path.format(self.port_to_i2c_mapping[x]) + self.port_to_eeprom_mapping[x] = port_eeprom_path + sfputilbase.__init__(self, port_num) diff --git a/device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/sensors.conf b/device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/sensors.conf new file mode 100644 index 0000000000..88a474a067 --- /dev/null +++ b/device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/sensors.conf @@ -0,0 +1,39 @@ +# libsensors configuration file +chip "i350bb-*" + ignore loc1 + +chip "jc42-*" + label temp1 "DIMM Temp" + set temp1_max 50 + set temp1_crit 85 + +chip "w83795adg-*" + label in0 "1.0V" + label in1 "1.0V_ROV" + label in2 "1.25V" + label in3 "1.8V" + ignore in4 + ignore in5 + ignore in6 + ignore in7 + label in12 "+3.3V" + ignore in14 + ignore in15 + ignore in16 + label fan1 "FANTRAY 1-A" + label fan2 "FANTRAY 1-B" + label fan3 "FANTRAY 2-A" + label fan4 "FANTRAY 2-B" + label fan5 "FANTRAY 3-A" + label fan6 "FANTRAY 3-B" + label fan7 "FANTRAY 4-A" + label fan8 "FANTRAY 4-B" + label temp1 "Front MAC Temp" + set temp1_max 70 + set temp1_crit 80 + label temp2 "Rear MAC Temp" + set temp1_max 70 + set temp1_crit 80 + ignore temp3 + ignore temp4 + ignore intrusion0 diff --git a/device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/INGRASYS-S8900-64XC/port_config.ini b/device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/INGRASYS-S8900-64XC/port_config.ini new file mode 100644 index 0000000000..3e5c7be570 --- /dev/null +++ b/device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/INGRASYS-S8900-64XC/port_config.ini @@ -0,0 +1,65 @@ +# name lanes alias +Ethernet0 17 +Ethernet1 18 +Ethernet2 19 +Ethernet3 20 +Ethernet4 24 +Ethernet5 23 +Ethernet6 22 +Ethernet7 21 +Ethernet8 28 +Ethernet9 27 +Ethernet10 26 +Ethernet11 25 +Ethernet12 32 +Ethernet13 31 +Ethernet14 30 +Ethernet15 29 +Ethernet16 1 +Ethernet17 2 +Ethernet18 3 +Ethernet19 4 +Ethernet20 8 +Ethernet21 7 +Ethernet22 6 +Ethernet23 5 +Ethernet24 12 +Ethernet25 11 +Ethernet26 10 +Ethernet27 9 +Ethernet28 13 +Ethernet29 14 +Ethernet30 15 +Ethernet31 16 +Ethernet32 33 +Ethernet33 34 +Ethernet34 35 +Ethernet35 36 +Ethernet36 38 +Ethernet37 39 +Ethernet38 40 +Ethernet39 37 +Ethernet40 41 +Ethernet41 42 +Ethernet42 43 +Ethernet43 44 +Ethernet44 48 +Ethernet45 45 +Ethernet46 46 +Ethernet47 47 +Ethernet48 49,50,51,52 +Ethernet52 53,54,55,56 +Ethernet56 57,58,59,60 +Ethernet60 61,62,63,64 +Ethernet64 65,66,67,68 +Ethernet68 69,70,71,72 +Ethernet72 73,74,75,76 +Ethernet76 77,78,79,80 +Ethernet80 81,82,83,84 +Ethernet84 85,86,87,88 +Ethernet88 89,90,91,92 +Ethernet92 93,94,95,96 +Ethernet96 97,98,99,100 +Ethernet100 101,102,103,104 +Ethernet104 105,106,107,108 +Ethernet108 109,110,111,112 diff --git a/device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/INGRASYS-S8900-64XC/sai.profile b/device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/INGRASYS-S8900-64XC/sai.profile new file mode 100644 index 0000000000..f617b8f3c4 --- /dev/null +++ b/device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/INGRASYS-S8900-64XC/sai.profile @@ -0,0 +1 @@ +SAI_INIT_CONFIG_FILE=/etc/bcm/th-s8900-48x25G+16x100G.config.bcm diff --git a/device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/fancontrol b/device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/fancontrol new file mode 100644 index 0000000000..9384403045 --- /dev/null +++ b/device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/fancontrol @@ -0,0 +1,11 @@ +# Configuration file generated by pwmconfig, changes will be lost +INTERVAL=10 +DEVPATH=hwmon1=devices/pci0000:00/0000:00:1f.3/i2c-0/0-002f +DEVNAME=hwmon1=w83795adg +FCTEMPS=hwmon1/device/pwm1=hwmon1/device/temp2_input hwmon1/device/pwm2=hwmon1/device/temp2_input +FCFANS=hwmon1/device/pwm2=hwmon1/device/fan10_input hwmon1/device/pwm2=hwmon1/device/fan9_input hwmon1/device/pwm2=hwmon1/device/fan8_input hwmon1/device/pwm2=hwmon1/device/fan7_input hwmon1/device/pwm2=hwmon1/device/fan6_input hwmon1/device/pwm2=hwmon1/device/fan5_input hwmon1/device/pwm1=hwmon1/device/fan4_input hwmon1/device/pwm1=hwmon1/device/fan3_input hwmon1/device/pwm1=hwmon1/device/fan2_input hwmon1/device/pwm1=hwmon1/device/fan1_input +MINTEMP=hwmon1/device/pwm1=20 hwmon1/device/pwm2=20 +MAXTEMP=hwmon1/device/pwm1=60 hwmon1/device/pwm2=60 +MINSTART=hwmon1/device/pwm1=150 hwmon1/device/pwm2=150 +MINSTOP=hwmon1/device/pwm1=0 hwmon1/device/pwm2=0 + diff --git a/device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/installer.conf b/device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/installer.conf new file mode 100644 index 0000000000..14404194ef --- /dev/null +++ b/device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/installer.conf @@ -0,0 +1,3 @@ +CONSOLE_PORT=0x2f8 +CONSOLE_DEV=1 +CONSOLE_SPEED=115200 diff --git a/device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/minigraph.xml b/device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/minigraph.xml new file mode 100644 index 0000000000..fe96dc87ac --- /dev/null +++ b/device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/minigraph.xml @@ -0,0 +1,359 @@ + + + + + + BGPSession + OCPSCH0104001MS + 10.10.1.2 + OCPSCH01040AALF + 10.10.1.1 + 1 + 10 + 3 + + + BGPSession + OCPSCH0104001MS + 10.10.1.6 + OCPSCH01040BBLF + 10.10.1.5 + 1 + 10 + 3 + + + BGPSession + OCPSCH0104001MS + 10.10.1.10 + OCPSCH01040CCLF + 10.10.1.9 + 1 + 10 + 3 + + + BGPSession + OCPSCH0104001MS + 10.10.1.14 + OCPSCH01040DDLF + 10.10.1.13 + 1 + 10 + 3 + + + BGPSession + OCPSCH0104001MS + 10.10.1.18 + OCPSCH01040EELF + 10.10.1.17 + 1 + 10 + 3 + + + BGPSession + OCPSCH0104001MS + 10.10.1.22 + OCPSCH01040FFLF + 10.10.1.21 + 1 + 10 + 3 + + + BGPSession + OCPSCH0104001MS + 10.10.1.26 + OCPSCH01040GGLF + 10.10.1.25 + 1 + 10 + 3 + + + BGPSession + OCPSCH0104001MS + 10.10.1.30 + OCPSCH01040HHLF + 10.10.1.29 + 1 + 10 + 3 + + + + + 64542 + OCPSCH0104001MS + + + BGPPeer +
10.10.1.2
+ + +
+ + BGPPeer +
10.10.1.6
+ + +
+ + BGPPeer +
10.10.1.10
+ + +
+ + BGPPeer +
10.10.1.14
+ + +
+ + BGPPeer +
10.10.1.18
+ + +
+ + BGPPeer +
10.10.1.22
+ + +
+ + BGPPeer +
10.10.1.26
+ + +
+ + BGPPeer +
10.10.1.30
+ + +
+
+ +
+ + 64536 + OCPSCH01040AALF + + + + 64536 + OCPSCH01040BBLF + + + + 64536 + OCPSCH01040CCLF + + + + 64536 + OCPSCH01040DDLF + + + + 64536 + OCPSCH01040EELF + + + + 64536 + OCPSCH01040FFLF + + + + 64536 + OCPSCH01040GGLF + + + + 64536 + OCPSCH01040HHLF + + +
+
+ + + + + + LoopbackInterface + HostIP + Loopback0 + + 100.0.0.1/32 + + 100.0.0.1/32 + + + + + + + + OCPSCH0104001MS + + + + VlanInterface + Vlan851 + Ethernet0;Ethernet1;Ethernet2;Ethernet3;Ethernet96;Ethernet100;Ethernet104;Ethernet108 + False + 0.0.0.0/0 + + 851 + 10.20.1.0/24 + + + + + IPInterface + + Vlan851 + 10.20.1.1/24 + + + IPInterface + + Ethernet48 + 10.10.1.2/30 + + + IPInterface + + Ethernet52 + 10.10.1.6/30 + + + IPInterface + + Ethernet56 + 10.10.1.10/30 + + + IPInterface + + Ethernet60 + 10.10.1.14/30 + + + IPInterface + + Ethernet64 + 10.10.1.18/30 + + + IPInterface + + Ethernet68 + 10.10.1.22/30 + + + IPInterface + + Ethernet72 + 10.10.1.26/30 + + + IPInterface + + Ethernet76 + 10.10.1.30/30 + + + + + + + + + + + + 40000 + DeviceInterfaceLink + OCPSCH0104001MS + Ethernet48 + OCPSCH01040AALF + Ethernet0 + + + 40000 + DeviceInterfaceLink + OCPSCH0104001MS + Ethernet52 + OCPSCH01040BBLF + Ethernet0 + + + 40000 + DeviceInterfaceLink + OCPSCH0104001MS + Ethernet56 + OCPSCH01040CCLF + Ethernet0 + + + 40000 + DeviceInterfaceLink + OCPSCH0104001MS + Ethernet60 + OCPSCH01040DDLF + Ethernet0 + + + 40000 + DeviceInterfaceLink + OCPSCH0104001MS + Ethernet64 + OCPSCH01040EELF + Ethernet0 + + + 40000 + DeviceInterfaceLink + OCPSCH0104001MS + Ethernet68 + OCPSCH01040FFLF + Ethernet0 + + + 40000 + DeviceInterfaceLink + OCPSCH0104001MS + Ethernet72 + OCPSCH01040GGLF + Ethernet0 + + + 40000 + DeviceInterfaceLink + OCPSCH0104001MS + Ethernet76 + OCPSCH01040HHLF + Ethernet48 + + + + + OCPSCH0104001MS + INGRASYS-S8900-64XC + + + + + + + + OCPSCH0104001MS + INGRASYS-S8900-64XC +
diff --git a/device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/plugins/eeprom.py b/device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/plugins/eeprom.py new file mode 100644 index 0000000000..c23edf5e77 --- /dev/null +++ b/device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/plugins/eeprom.py @@ -0,0 +1,23 @@ +#!/usr/bin/env python + +############################################################################# +# Ingrasys S8900-64XC +# +# Platform and model specific eeprom subclass, inherits from the base class, +# and provides the followings: +# - the eeprom format definition +# - specific encoder/decoder if there is special need +############################################################################# + +try: + from sonic_eeprom import eeprom_tlvinfo +except ImportError, e: + raise ImportError (str(e) + "- required module not found") + + +class board(eeprom_tlvinfo.TlvInfoDecoder): + + def __init__(self, name, path, cpld_root, ro): + self.eeprom_path = "/sys/class/i2c-adapter/i2c-7/7-0054/eeprom" + super(board, self).__init__(self.eeprom_path, 0, '', True) + diff --git a/device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/plugins/sfputil.py b/device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/plugins/sfputil.py new file mode 100644 index 0000000000..d6573d20d7 --- /dev/null +++ b/device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/plugins/sfputil.py @@ -0,0 +1,107 @@ +#!/usr/bin/env python + +import subprocess + +try: + from sonic_sfp.sfputilbase import sfputilbase +except ImportError, e: + raise ImportError (str(e) + "- required module not found") + +i2c_set = 'i2cset' +cpld_addr = '0x33' +mux_reg = '0x4A' + +class sfputil(sfputilbase): + """Platform specific sfputil class""" + + port_start = 0 + port_end = 63 + ports_in_block = 64 + + port_to_eeprom_mapping = {} + port_to_i2c_mapping = { + 0: [2,1], + 1: [2,2], + 2: [2,3], + 3: [2,4], + 4: [2,5], + 5: [2,6], + 6: [2,7], + 7: [2,8], + 8: [2,9], + 9: [2,10], + 10: [2,11], + 11: [2,12], + 12: [2,13], + 13: [2,14], + 14: [2,15], + 15: [2,16], + 16: [2,17], + 17: [2,18], + 18: [2,19], + 19: [2,20], + 20: [2,21], + 21: [2,22], + 22: [2,23], + 23: [2,24], + 24: [3,1], + 25: [3,2], + 26: [3,3], + 27: [3,4], + 28: [3,5], + 29: [3,6], + 30: [3,7], + 31: [3,8], + 32: [3,9], + 33: [3,10], + 34: [3,11], + 35: [3,12], + 36: [3,13], + 37: [3,14], + 38: [3,15], + 39: [3,16], + 40: [3,17], + 41: [3,18], + 42: [3,19], + 43: [3,20], + 44: [3,21], + 45: [3,22], + 46: [3,23], + 47: [3,24], + 48: [4,1], + 49: [4,2], + 50: [4,3], + 51: [4,4], + 52: [4,5], + 53: [4,6], + 54: [4,7], + 55: [4,8], + 56: [4,9], + 57: [4,10], + 58: [4,11], + 59: [4,12], + 60: [4,13], + 61: [4,14], + 62: [4,15], + 63: [4,16] + } + + + _qsfp_ports = range(0, ports_in_block + 1) + + def __init__(self, port_num): + # Override port_to_eeprom_mapping for class initialization + i2c_bus = self.port_to_i2c_mapping[port_num][0] + sfp_idx = self.port_to_i2c_mapping[port_num][1] + proc = subprocess.Popen([i2c_set, '-y', str(i2c_bus), cpld_addr, mux_reg, str(sfp_idx)], + stdout=subprocess.PIPE, + shell=False, + stderr=subprocess.STDOUT) + stdout = proc.communicate()[0] + proc.wait() + + eeprom_path = '/sys/class/i2c-adapter/i2c-{0[0]}/{0[0]}-0050/eeprom' + for x in range(self.port_start, self.port_end + 1): + port_eeprom_path = eeprom_path.format(self.port_to_i2c_mapping[x]) + self.port_to_eeprom_mapping[x] = port_eeprom_path + sfputilbase.__init__(self, port_num) diff --git a/device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/sensors.conf b/device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/sensors.conf new file mode 100644 index 0000000000..d4b5a7bd0c --- /dev/null +++ b/device/ingrasys/x86_64-ingrasys_s8900_64xc-r0/sensors.conf @@ -0,0 +1,56 @@ +# libsensors configuration file +chip "i350bb-*" + ignore loc1 + +chip "jc42-*" + label temp1 "DIMM Temp" + set temp1_max 50 + set temp1_crit 85 + +chip "w83795adg-*" + label in0 "1.0V" + label in1 "1.0V_ROV" + label in2 "1.25V" + label in3 "1.8V" + ignore in4 + ignore in5 + ignore in6 + ignore in7 + label in12 "+3.3V" + ignore in14 + ignore in15 + ignore in16 + label fan1 "FANTRAY 1-A" + label fan2 "FANTRAY 1-B" + label fan3 "FANTRAY 2-A" + label fan4 "FANTRAY 2-B" + label fan5 "FANTRAY 3-A" + label fan6 "FANTRAY 3-B" + label fan7 "FANTRAY 4-A" + label fan8 "FANTRAY 4-B" + label fan9 "FANTRAY 5-A" + label fan10 "FANTRAY 5-B" + label temp1 "Front MAC Temp" + set temp1_max 60 + set temp1_crit 65 + label temp2 "Rear MAC Temp" + set temp2_max 60 + set temp2_crit 65 + label temp3 "Near Port 15" + set temp3_max 50 + set temp3_crit 70 + label temp4 "Near Port 56" + set temp4_max 50 + set temp4_crit 70 + ignore intrusion0 + +bus "i2c-5" "i2c-1-switch (chan_id 3)" +chip "tmp75-i2c-*-48" + label temp1 "FAN Temp1" + set temp1_max 50 + set temp1_crit 70 +chip "tmp75-i2c-*-49" + label temp1 "FAN Temp2" + set temp1_max 50 + set temp1_crit 70 + diff --git a/device/ingrasys/x86_64-ingrasys_s9100-r0/INGRASYS-S9100-C32/port_config.ini b/device/ingrasys/x86_64-ingrasys_s9100-r0/INGRASYS-S9100-C32/port_config.ini index d2b36ebf5e..d70c717fe4 100644 --- a/device/ingrasys/x86_64-ingrasys_s9100-r0/INGRASYS-S9100-C32/port_config.ini +++ b/device/ingrasys/x86_64-ingrasys_s9100-r0/INGRASYS-S9100-C32/port_config.ini @@ -1,33 +1,33 @@ # name lanes alias -Ethernet0 5,6,7,8 Ethernet0 -Ethernet4 1,2,3,4 Ethernet4 -Ethernet8 13,14,15,16 Ethernet8 -Ethernet12 9,10,11,12 Ethernet12 -Ethernet16 21,22,23,24 Ethernet16 -Ethernet20 17,18,19,20 Ethernet20 -Ethernet24 29,30,31,32 Ethernet24 -Ethernet28 25,26,27,28 Ethernet28 -Ethernet32 37,38,39,40 Ethernet32 -Ethernet36 33,34,35,36 Ethernet36 -Ethernet40 45,46,47,48 Ethernet40 -Ethernet44 41,42,43,44 Ethernet44 -Ethernet48 53,54,55,56 Ethernet48 -Ethernet52 49,50,51,52 Ethernet52 -Ethernet56 61,62,63,64 Ethernet56 -Ethernet60 57,58,59,60 Ethernet60 -Ethernet64 69,70,71,72 Ethernet64 -Ethernet68 65,66,67,68 Ethernet68 -Ethernet72 77,78,79,80 Ethernet72 -Ethernet76 73,74,75,76 Ethernet76 -Ethernet80 85,86,87,88 Ethernet80 -Ethernet84 81,82,83,84 Ethernet84 -Ethernet88 93,94,95,96 Ethernet88 -Ethernet92 89,90,91,92 Ethernet92 -Ethernet96 101,102,103,104 Ethernet96 -Ethernet100 97,98,99,100 Ethernet100 -Ethernet104 109,110,111,112 Ethernet104 -Ethernet108 105,106,107,108 Ethernet108 -Ethernet112 117,118,119,120 Ethernet112 -Ethernet116 113,114,115,116 Ethernet116 -Ethernet120 125,126,127,128 Ethernet120 -Ethernet124 121,122,123,124 Ethernet124 +Ethernet0 5,6,7,8 +Ethernet4 1,2,3,4 +Ethernet8 13,14,15,16 +Ethernet12 9,10,11,12 +Ethernet16 21,22,23,24 +Ethernet20 17,18,19,20 +Ethernet24 29,30,31,32 +Ethernet28 25,26,27,28 +Ethernet32 37,38,39,40 +Ethernet36 33,34,35,36 +Ethernet40 45,46,47,48 +Ethernet44 41,42,43,44 +Ethernet48 53,54,55,56 +Ethernet52 49,50,51,52 +Ethernet56 61,62,63,64 +Ethernet60 57,58,59,60 +Ethernet64 69,70,71,72 +Ethernet68 65,66,67,68 +Ethernet72 77,78,79,80 +Ethernet76 73,74,75,76 +Ethernet80 85,86,87,88 +Ethernet84 81,82,83,84 +Ethernet88 93,94,95,96 +Ethernet92 89,90,91,92 +Ethernet96 101,102,103,104 +Ethernet100 97,98,99,100 +Ethernet104 109,110,111,112 +Ethernet108 105,106,107,108 +Ethernet112 117,118,119,120 +Ethernet116 113,114,115,116 +Ethernet120 125,126,127,128 +Ethernet124 121,122,123,124 diff --git a/device/ingrasys/x86_64-ingrasys_s9100-r0/fancontrol b/device/ingrasys/x86_64-ingrasys_s9100-r0/fancontrol new file mode 100644 index 0000000000..05a71e8d99 --- /dev/null +++ b/device/ingrasys/x86_64-ingrasys_s9100-r0/fancontrol @@ -0,0 +1,12 @@ +# Configuration file generated by pwmconfig, changes will be lost +INTERVAL=10 +DEVPATH=hwmon2=devices/pci0000:00/0000:00:1f.3/i2c-0/0-002f +DEVNAME=hwmon2=w83795adg +FCTEMPS=hwmon2/device/pwm2=hwmon2/device/temp2_input hwmon2/device/pwm1=hwmon2/device/temp2_input +#FCFANS=hwmon2/device/pwm2=hwmon2/device/fan8_input+hwmon2/device/fan7_input+hwmon2/device/fan6_input+hwmon2/device/fan5_input hwmon2/device/pwm1=hwmon2/device/fan4_input+hwmon2/device/fan3_input+hwmon2/device/fan2_input+hwmon2/device/fan1_input +FCFANS=hwmon2/device/pwm2=hwmon2/device/fan8_input hwmon2/device/pwm2=hwmon2/device/fan7_input hwmon2/device/pwm2=hwmon2/device/fan6_input hwmon2/device/pwm2=hwmon2/device/fan5_input hwmon2/device/pwm1=hwmon2/device/fan4_input hwmon2/device/pwm1=hwmon2/device/fan3_input hwmon2/device/pwm1=hwmon2/device/fan2_input hwmon2/device/pwm1=hwmon2/device/fan1_input +MINTEMP=hwmon2/device/pwm2=20 hwmon2/device/pwm1=20 +MAXTEMP=hwmon2/device/pwm2=60 hwmon2/device/pwm1=60 +MINSTART=hwmon2/device/pwm2=75 hwmon2/device/pwm1=75 +MINSTOP=hwmon2/device/pwm2=22 hwmon2/device/pwm1=22 + diff --git a/device/ingrasys/x86_64-ingrasys_s9100-r0/sensors.conf b/device/ingrasys/x86_64-ingrasys_s9100-r0/sensors.conf index 44eedb4b11..c55f5c764e 100644 --- a/device/ingrasys/x86_64-ingrasys_s9100-r0/sensors.conf +++ b/device/ingrasys/x86_64-ingrasys_s9100-r0/sensors.conf @@ -29,7 +29,11 @@ chip "w83795adg-*" label fan7 "FANTRAY 4-A" label fan8 "FANTRAY 4-B" label temp1 "Front MAC Temp" + set temp1_max 70 + set temp1_crit 80 label temp2 "Rear MAC Temp" + set temp2_max 70 + set temp2_crit 80 ignore temp3 ignore temp4 ignore intrusion0 diff --git a/dockers/docker-orchagent/orchagent.sh b/dockers/docker-orchagent/orchagent.sh index 15eb2c7e17..a9330826d5 100755 --- a/dockers/docker-orchagent/orchagent.sh +++ b/dockers/docker-orchagent/orchagent.sh @@ -22,6 +22,10 @@ elif [ "$HWSKU" == "AS7512" ]; then ORCHAGENT_ARGS+="-m $MAC_ADDRESS" elif [ "$HWSKU" == "INGRASYS-S9100-C32" ]; then ORCHAGENT_ARGS+="-m $MAC_ADDRESS" +elif [ "$HWSKU" == "INGRASYS-S8900-54XC" ]; then + ORCHAGENT_ARGS+="-m $MAC_ADDRESS" +elif [ "$HWSKU" == "INGRASYS-S8900-64XC" ]; then + ORCHAGENT_ARGS+="-m $MAC_ADDRESS" fi exec /usr/bin/orchagent ${ORCHAGENT_ARGS} diff --git a/platform/broadcom/one-image.mk b/platform/broadcom/one-image.mk index e7e20a9eb7..3af81b325d 100644 --- a/platform/broadcom/one-image.mk +++ b/platform/broadcom/one-image.mk @@ -7,6 +7,8 @@ $(SONIC_ONE_IMAGE)_DEPENDS += $(BRCM_OPENNSL_KERNEL) $(SONIC_ONE_IMAGE)_INSTALLS += $(DELL_S6000_PLATFORM_MODULE) \ $(DELL_Z9100_PLATFORM_MODULE) \ $(DELL_S6100_PLATFORM_MODULE) \ + $(INGRASYS_S8900_54XC_PLATFORM_MODULE) \ + $(INGRASYS_S8900_64XC_PLATFORM_MODULE) \ $(INGRASYS_S9100_PLATFORM_MODULE) $(SONIC_ONE_IMAGE)_DOCKERS += $(SONIC_INSTALL_DOCKER_IMAGES) SONIC_INSTALLERS += $(SONIC_ONE_IMAGE) diff --git a/platform/broadcom/platform-modules-ingrasys-s9100.mk b/platform/broadcom/platform-modules-ingrasys-s9100.mk deleted file mode 100755 index 7c7df7b1cf..0000000000 --- a/platform/broadcom/platform-modules-ingrasys-s9100.mk +++ /dev/null @@ -1,11 +0,0 @@ -# Ingrasys S9100 Platform modules - -INGRASYS_S9100_PLATFORM_MODULE_VERSION = 1.0.0 - -export INGRASYS_S9100_PLATFORM_MODULE_VERSION - -INGRASYS_S9100_PLATFORM_MODULE = sonic-platform-ingrasys-s9100_$(INGRASYS_S9100_PLATFORM_MODULE_VERSION)_amd64.deb -$(INGRASYS_S9100_PLATFORM_MODULE)_SRC_PATH = $(PLATFORM_PATH)/sonic-platform-modules-ingrasys-s9100 -$(INGRASYS_S9100_PLATFORM_MODULE)_DEPENDS += $(LINUX_HEADERS) $(LINUX_HEADERS_COMMON) -$(INGRASYS_S9100_PLATFORM_MODULE)_PLATFORM = x86_64-ingrasys_s9100-r0 -SONIC_DPKG_DEBS += $(INGRASYS_S9100_PLATFORM_MODULE) diff --git a/platform/broadcom/platform-modules-ingrasys.mk b/platform/broadcom/platform-modules-ingrasys.mk new file mode 100644 index 0000000000..95009102dd --- /dev/null +++ b/platform/broadcom/platform-modules-ingrasys.mk @@ -0,0 +1,24 @@ +# Ingrasys S9100, S8900-64XC and S8900-54XC Platform modules + +INGRASYS_S9100_PLATFORM_MODULE_VERSION = 1.1.0 +INGRASYS_S8900_64XC_PLATFORM_MODULE_VERSION = 1.1.0 +INGRASYS_S8900_54XC_PLATFORM_MODULE_VERSION = 1.1.0 + +export INGRASYS_S9100_PLATFORM_MODULE_VERSION +export INGRASYS_S8900_64XC_PLATFORM_MODULE_VERSION +export INGRASYS_S8900_54XC_PLATFORM_MODULE_VERSION + +INGRASYS_S9100_PLATFORM_MODULE = sonic-platform-ingrasys-s9100_$(INGRASYS_S9100_PLATFORM_MODULE_VERSION)_amd64.deb +$(INGRASYS_S9100_PLATFORM_MODULE)_SRC_PATH = $(PLATFORM_PATH)/sonic-platform-modules-ingrasys +$(INGRASYS_S9100_PLATFORM_MODULE)_DEPENDS += $(LINUX_HEADERS) $(LINUX_HEADERS_COMMON) +$(INGRASYS_S9100_PLATFORM_MODULE)_PLATFORM = x86_64-ingrasys_s9100-r0 +SONIC_DPKG_DEBS += $(INGRASYS_S9100_PLATFORM_MODULE) + +INGRASYS_S8900_64XC_PLATFORM_MODULE = sonic-platform-ingrasys-s8900-64xc_$(INGRASYS_S8900_64XC_PLATFORM_MODULE_VERSION)_amd64.deb +$(INGRASYS_S8900_64XC_PLATFORM_MODULE)_PLATFORM = x86_64-ingrasys_s8900_64xc-r0 + +INGRASYS_S8900_54XC_PLATFORM_MODULE = sonic-platform-ingrasys-s8900-54xc_$(INGRASYS_S8900_54XC_PLATFORM_MODULE_VERSION)_amd64.deb +$(INGRASYS_S8900_54XC_PLATFORM_MODULE)_PLATFORM = x86_64-ingrasys_s8900_54xc-r0 + +$(eval $(call add_extra_package,$(INGRASYS_S9100_PLATFORM_MODULE),$(INGRASYS_S8900_64XC_PLATFORM_MODULE))) +$(eval $(call add_extra_package,$(INGRASYS_S9100_PLATFORM_MODULE),$(INGRASYS_S8900_54XC_PLATFORM_MODULE))) diff --git a/platform/broadcom/rules.mk b/platform/broadcom/rules.mk index d2eb4482e9..7f55ccd034 100755 --- a/platform/broadcom/rules.mk +++ b/platform/broadcom/rules.mk @@ -3,7 +3,7 @@ include $(PLATFORM_PATH)/sai.mk include $(PLATFORM_PATH)/platform-modules-s6000.mk include $(PLATFORM_PATH)/platform-modules-dell.mk include $(PLATFORM_PATH)/platform-modules-arista.mk -include $(PLATFORM_PATH)/platform-modules-ingrasys-s9100.mk +include $(PLATFORM_PATH)/platform-modules-ingrasys.mk include $(PLATFORM_PATH)/docker-orchagent-brcm.mk include $(PLATFORM_PATH)/docker-syncd-brcm.mk include $(PLATFORM_PATH)/docker-syncd-brcm-rpc.mk diff --git a/platform/broadcom/sonic-platform-modules-ingrasys b/platform/broadcom/sonic-platform-modules-ingrasys new file mode 160000 index 0000000000..46f1b3303f --- /dev/null +++ b/platform/broadcom/sonic-platform-modules-ingrasys @@ -0,0 +1 @@ +Subproject commit 46f1b3303fecf728b66b88941fa162e91520cc32 diff --git a/platform/broadcom/sonic-platform-modules-ingrasys-s9100 b/platform/broadcom/sonic-platform-modules-ingrasys-s9100 deleted file mode 160000 index 83d62823d2..0000000000 --- a/platform/broadcom/sonic-platform-modules-ingrasys-s9100 +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 83d62823d26a6b572bbe11272d00775f8123c199