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

[AS4630-54PE] Fix led drv and i2c bus order #9170

Merged
merged 6 commits into from
Mar 5, 2022
Merged
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
1 change: 1 addition & 0 deletions device/accton/x86_64-accton_as4630_54pe-r0/installer.conf
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
CONSOLE_PORT=0x3f8
CONSOLE_DEV=0
CONSOLE_SPEED=115200
ONIE_PLATFORM_EXTRA_CMDLINE_LINUX="intel_iommu=off modprobe.blacklist=i2c-ismt,i2c_ismt,i2c-i801,i2c_i801"
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,7 @@ static ssize_t set_duty_cycle(struct device *dev, struct device_attribute *da,

static u8 reg_val_to_direction(u8 reg_val, enum fan_id id)
{
u8 mask = (1 << id);
u8 mask = (1 << (id+4));

reg_val &= mask;

Expand Down
Empty file.
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,6 @@ def main():
elif opt in ('-f', '--force'):
FORCE = 1
else:
print("TEST")
logging.info('no option')
for arg in args:
if arg == 'install':
Expand Down Expand Up @@ -167,7 +166,9 @@ def driver_inserted():
kos = [
'depmod -ae',
'modprobe i2c_dev',
'modprobe i2c_mux_pca954x force_deselect_on_exit=1',
'modprobe i2c_i801',
'modprobe i2c_ismt',
'modprobe i2c_mux_pca954x',
'modprobe ym2651y',
'modprobe x86_64_accton_as4630_54pe_cpld',
'modprobe x86_64_accton_as4630_54pe_leds',
Expand All @@ -176,17 +177,7 @@ def driver_inserted():

def driver_install():
global FORCE

ret=log_os_system("lsmod|grep i2c_ismt",1)
my_log("rmmond i2cismt")
log_os_system("rmmod i2c_ismt", 1)
log_os_system("rmmod i2c_i801", 1)
log_os_system("modprobe i2c-i801", 1)
time.sleep(1)
log_os_system("modprobe i2c-ismt", 1)




for i in range(0,len(kos)):
status, output = log_os_system(kos[i], 1)
if status:
Expand Down Expand Up @@ -226,6 +217,13 @@ def device_install():
if FORCE == 0:
return status

# set all pca954x idle_disconnect
cmd = 'echo -2 | tee /sys/bus/i2c/drivers/pca954x/*-00*/idle_state'
status, output = log_os_system(cmd, 1)
if status:
print(output)
if FORCE == 0:
return status
for i in range(0,len(sfp_map)):
if(i < 4):
opt='optoe2'
Expand Down