Skip to content

Commit

Permalink
[Ingrasys] Add Ingrasys S8900 series platform (#569)
Browse files Browse the repository at this point in the history
* 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 <chihen.he@gmail.com>
  • Loading branch information
wadelnn authored and Shuotian Cheng committed May 18, 2017
1 parent 8ebf0b0 commit fb4cd63
Show file tree
Hide file tree
Showing 27 changed files with 1,044 additions and 49 deletions.
7 changes: 3 additions & 4 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -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

Original file line number Diff line number Diff line change
@@ -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
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
SAI_INIT_CONFIG_FILE=/etc/bcm/th-s8900-48x25G+6x100G.config.bcm
12 changes: 12 additions & 0 deletions device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/fancontrol
Original file line number Diff line number Diff line change
@@ -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

3 changes: 3 additions & 0 deletions device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/installer.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
CONSOLE_PORT=0x2f8
CONSOLE_DEV=1
CONSOLE_SPEED=115200
121 changes: 121 additions & 0 deletions device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/minigraph.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,121 @@
<DeviceMiniGraph xmlns="Microsoft.Search.Autopilot.Evolution" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
<CpgDec>
<IsisRouters xmlns:a="http://schemas.datacontract.org/2004/07/Microsoft.Search.Autopilot.Evolution"/>
<PeeringSessions>
<BGPSession>
<StartRouter>OCPSCH0104001MS</StartRouter>
<StartPeer>10.10.1.30</StartPeer>
<EndRouter>OCPSCH01040HHLF</EndRouter>
<EndPeer>10.10.1.29</EndPeer>
<Multihop>1</Multihop>
<HoldTime>10</HoldTime>
<KeepAliveTime>3</KeepAliveTime>
</BGPSession>
<BGPSession>
<StartRouter>OCPSCH0104002MS</StartRouter>
<StartPeer>10.10.2.30</StartPeer>
<EndRouter>OCPSCH01040HHLF</EndRouter>
<EndPeer>10.10.2.29</EndPeer>
<Multihop>1</Multihop>
<HoldTime>10</HoldTime>
<KeepAliveTime>3</KeepAliveTime>
</BGPSession>
</PeeringSessions>
<Routers xmlns:a="http://schemas.datacontract.org/2004/07/Microsoft.Search.Autopilot.Evolution">
<a:BGPRouterDeclaration>
<a:ASN>64536</a:ASN>
<a:Hostname>OCPSCH01040HHLF</a:Hostname>
<a:Peers>
<BGPPeer>
<Address>10.10.1.30</Address>
<RouteMapIn i:nil="true"/>
<RouteMapOut i:nil="true"/>
</BGPPeer>
<BGPPeer>
<Address>10.10.2.30</Address>
<RouteMapIn i:nil="true"/>
<RouteMapOut i:nil="true"/>
</BGPPeer>
</a:Peers>
<a:RouteMaps/>
</a:BGPRouterDeclaration>
<a:BGPRouterDeclaration>
<a:ASN>64542</a:ASN>
<a:Hostname>OCPSCH0104001MS</a:Hostname>
<a:RouteMaps/>
</a:BGPRouterDeclaration>
<a:BGPRouterDeclaration>
<a:ASN>64543</a:ASN>
<a:Hostname>OCPSCH0104002MS</a:Hostname>
<a:RouteMaps/>
</a:BGPRouterDeclaration>
</Routers>
</CpgDec>
<DpgDec>
<DeviceDataPlaneInfo>
<IPSecTunnels/>
<LoopbackIPInterfaces xmlns:a="http://schemas.datacontract.org/2004/07/Microsoft.Search.Autopilot.Evolution">
<a:LoopbackIPInterface>
<Name>HostIP</Name>
<AttachTo>Loopback0</AttachTo>
<a:Prefix xmlns:b="Microsoft.Search.Autopilot.NetMux">
<b:IPPrefix>100.0.0.10/32</b:IPPrefix>
</a:Prefix>
<a:PrefixStr>100.0.0.10/32</a:PrefixStr>
</a:LoopbackIPInterface>
</LoopbackIPInterfaces>
<ManagementIPInterfaces xmlns:a="http://schemas.datacontract.org/2004/07/Microsoft.Search.Autopilot.Evolution">
</ManagementIPInterfaces>
<MplsInterfaces/>
<MplsTeInterfaces/>
<RsvpInterfaces/>
<Hostname>OCPSCH01040HHLF</Hostname>
<PortChannelInterfaces/>
<VlanInterfaces/>
<IPInterfaces>
<IPInterface>
<Name i:nil="true"/>
<AttachTo>Ethernet48</AttachTo>
<Prefix>10.10.1.29/30</Prefix>
</IPInterface>
<IPInterface>
<Name i:nil="true"/>
<AttachTo>Ethernet52</AttachTo>
<Prefix>10.10.2.29/30</Prefix>
</IPInterface>
</IPInterfaces>
<DataAcls/>
<AclInterfaces/>
<DownstreamSummaries/>
<DownstreamSummarySet xmlns:a="http://schemas.datacontract.org/2004/07/Microsoft.Search.Autopilot.Evolution"/>
</DeviceDataPlaneInfo>
</DpgDec>
<PngDec>
<DeviceInterfaceLinks>
<DeviceLinkBase i:type="DeviceInterfaceLink">
<Bandwidth>40000</Bandwidth>
<ElementType>DeviceInterfaceLink</ElementType>
<EndDevice>OCPSCH0104001MS</EndDevice>
<EndPort>Ethernet48</EndPort>
<StartDevice>OCPSCH01040HHLF</StartDevice>
<StartPort>Ethernet48</StartPort>
</DeviceLinkBase>
<DeviceLinkBase i:type="DeviceInterfaceLink">
<Bandwidth>40000</Bandwidth>
<ElementType>DeviceInterfaceLink</ElementType>
<EndDevice>OCPSCH0104002MS</EndDevice>
<EndPort>Ethernet0</EndPort>
<StartDevice>OCPSCH01040HHLF</StartDevice>
<StartPort>Ethernet52</StartPort>
</DeviceLinkBase>
</DeviceInterfaceLinks>
<Devices>
<Device i:type="LeafRouter">
<Hostname>OCPSCH01040HHLF</Hostname>
<HwSku>INGRASYS-S8900-54XC</HwSku>
</Device>
</Devices>
</PngDec>
<Hostname>OCPSCH01040HHLF</Hostname>
<HwSku>INGRASYS-S8900-54XC</HwSku>
</DeviceMiniGraph>
23 changes: 23 additions & 0 deletions device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/plugins/eeprom.py
Original file line number Diff line number Diff line change
@@ -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)

82 changes: 82 additions & 0 deletions device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/plugins/sfputil.py
Original file line number Diff line number Diff line change
@@ -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)
39 changes: 39 additions & 0 deletions device/ingrasys/x86_64-ingrasys_s8900_54xc-r0/sensors.conf
Original file line number Diff line number Diff line change
@@ -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
Loading

0 comments on commit fb4cd63

Please sign in to comment.