Skip to content

Commit

Permalink
[Platform] Accton as7712 32x support oom (#1327)
Browse files Browse the repository at this point in the history
* Update sonic-platform-modules-accton to lastest

Signed-off-by: roylee123 <roy_lee@accton.com>

* [platform] accton as7712_32x supports OOM SFP eerpom driver.
Signed-off-by: roylee123 <roy_lee@accton.com>

* [platform] update for as7712-32x to remove local optoe.c file and Makefile.
Signed-off-by: roy_lee <roy_lee@accton.com>
  • Loading branch information
roylee123 authored and lguohan committed Feb 13, 2018
1 parent d844acc commit 02e0fad
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
12 changes: 6 additions & 6 deletions device/accton/x86_64-accton_as7712_32x-r0/plugins/sfputil.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ class SfpUtil(SfpUtilBase):
_qsfp_ports = range(0, ports_in_block + 1)

def __init__(self):
eeprom_path = '/sys/bus/i2c/devices/{0}-0050/sfp_eeprom'
eeprom_path = '/sys/bus/i2c/devices/{0}-0050/eeprom'
for x in range(0, self._port_end + 1):
port_eeprom_path = eeprom_path.format(self.port_to_i2c_mapping[x+1])
self._port_to_eeprom_mapping[x] = port_eeprom_path
Expand All @@ -64,9 +64,9 @@ def reset(self, port_num):
if port_num < self._port_start or port_num > self._port_end:
return False

path = "/sys/bus/i2c/devices/{0}-0050/sfp_port_reset"
port_ps = path.format(self.port_to_i2c_mapping[port_num+1])
path = "/sys/bus/i2c/devices/4-0060/module_reset_{0}"
port_ps = path.format(port_num+1)

try:
reg_file = open(port_ps, 'w')
except IOError as e:
Expand All @@ -93,8 +93,8 @@ def get_presence(self, port_num):
if port_num < self._port_start or port_num > self._port_end:
return False

path = "/sys/bus/i2c/devices/{0}-0050/sfp_is_present"
port_ps = path.format(self.port_to_i2c_mapping[port_num+1])
path = "/sys/bus/i2c/devices/4-0060/module_present_{0}"
port_ps = path.format(port_num+1)


try:
Expand Down

0 comments on commit 02e0fad

Please sign in to comment.