From 764a7edd83685a2245e436c8ce5e36f407434084 Mon Sep 17 00:00:00 2001 From: Samuel Angebault Date: Tue, 27 Mar 2018 09:32:05 -0700 Subject: [PATCH] [device]: Enable arista drivers for sonic-linux-kernel 4.9 (#21) * Enable arista drivers * Add vfat ascii charset in initramfs * Update boot0.j2 for 4.9 kernel * Fix i2c offsets in sensors.conf * Bump sonic-platform-modules-arista submodule --- .../x86_64-arista_7050_qx32/sensors.conf | 20 +++++++++---------- files/Aboot/boot0.j2 | 6 ++++-- files/initramfs-tools/modules | 1 + platform/broadcom/rules.mk | 2 +- .../broadcom/sonic-platform-modules-arista | 2 +- 5 files changed, 17 insertions(+), 14 deletions(-) diff --git a/device/arista/x86_64-arista_7050_qx32/sensors.conf b/device/arista/x86_64-arista_7050_qx32/sensors.conf index 481c9ec301..8b6ca752fe 100644 --- a/device/arista/x86_64-arista_7050_qx32/sensors.conf +++ b/device/arista/x86_64-arista_7050_qx32/sensors.conf @@ -2,21 +2,21 @@ # ------------------------------------------------ # -bus "i2c-2" "SCD 0000:04:00.0 SMBus master 0 bus 0" -bus "i2c-3" "SCD 0000:04:00.0 SMBus master 0 bus 1" -bus "i2c-5" "SCD 0000:04:00.0 SMBus master 0 bus 3" -bus "i2c-6" "SCD 0000:04:00.0 SMBus master 0 bus 4" -bus "i2c-7" "SCD 0000:04:00.0 SMBus master 0 bus 5" +bus "i2c-5" "SCD 0000:04:00.0 SMBus master 0 bus 0" +bus "i2c-6" "SCD 0000:04:00.0 SMBus master 0 bus 1" +bus "i2c-8" "SCD 0000:04:00.0 SMBus master 0 bus 3" +bus "i2c-9" "SCD 0000:04:00.0 SMBus master 0 bus 4" +bus "i2c-10" "SCD 0000:04:00.0 SMBus master 0 bus 5" chip "k10temp-pci-00c3" label temp1 "Cpu temp sensor" -chip "lm73-i2c-3-48" +chip "lm73-i2c-6-48" label temp1 "Back panel temp sensor" set temp1_max 65 #set temp1_max_alarm 75 # read-only -chip "max6658-i2c-2-4c" +chip "max6658-i2c-5-4c" label temp1 "Board temp sensor" set temp1_max 65 set temp1_crit 75 @@ -26,7 +26,7 @@ chip "max6658-i2c-2-4c" set temp2_crit 75 # disabled because of some eeprom corruption risks -#chip "pmbus-i2c-3-4e" +#chip "pmbus-i2c-6-4e" # label temp1 "Power controller sensor 1" # set temp1_max 60 # set temp1_crit 70 @@ -37,7 +37,7 @@ chip "max6658-i2c-2-4c" # ignore curr1 -chip "dps460-i2c-5-58" +chip "dps460-i2c-8-58" label temp1 "Power supply 1 inlet temp sensor" # maximum and critical thresholds are not supported for this psu set temp1_max 60 @@ -59,7 +59,7 @@ chip "dps460-i2c-5-58" set curr2_max 36 set curr2_crit 37 -chip "dps460-i2c-6-58" +chip "dps460-i2c-9-58" label temp1 "Power supply 2 inlet temp sensor" # maximum and critical thresholds are not supported for this psu set temp1_max 60 diff --git a/files/Aboot/boot0.j2 b/files/Aboot/boot0.j2 index ab2cdedb63..94f9b76035 100644 --- a/files/Aboot/boot0.j2 +++ b/files/Aboot/boot0.j2 @@ -153,12 +153,12 @@ platform_specific() { if [ "$platform" = "raven" ]; then aboot_machine=arista_7050_qx32 flash_size=2000 - echo "modprobe.blacklist=radeon" >>/tmp/append + echo "modprobe.blacklist=radeon,sp5100_tco acpi=off" >>/tmp/append fi if [ "$platform" = "crow" ]; then aboot_machine=arista_7050_qx32s flash_size=3700 - echo "modprobe.blacklist=radeon" >>/tmp/append + echo "modprobe.blacklist=radeon,sp5100_tco" >>/tmp/append fi if [ "$sid" = "Upperlake" ] || [ "$sid" = "UpperlakeES" ]; then aboot_machine=arista_7060_cx32s @@ -191,6 +191,8 @@ platform_specific() { fi echo "varlog_size=$varlog_size" >>/tmp/append + # disable deterministic interface naming + echo "net.ifnames=0" >>/tmp/append } get_uuid_for() { diff --git a/files/initramfs-tools/modules b/files/initramfs-tools/modules index 33f28b98b3..e7fcbef870 100644 --- a/files/initramfs-tools/modules +++ b/files/initramfs-tools/modules @@ -1,5 +1,6 @@ squashfs overlay vfat +nls_ascii nls_cp437 nls_utf8 diff --git a/platform/broadcom/rules.mk b/platform/broadcom/rules.mk index a065506a42..582af46b86 100755 --- a/platform/broadcom/rules.mk +++ b/platform/broadcom/rules.mk @@ -2,7 +2,7 @@ include $(PLATFORM_PATH)/sdk.mk 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-arista.mk include $(PLATFORM_PATH)/platform-modules-ingrasys.mk include $(PLATFORM_PATH)/platform-modules-accton.mk include $(PLATFORM_PATH)/platform-modules-inventec.mk diff --git a/platform/broadcom/sonic-platform-modules-arista b/platform/broadcom/sonic-platform-modules-arista index 8f65ad92c5..a7edec0e19 160000 --- a/platform/broadcom/sonic-platform-modules-arista +++ b/platform/broadcom/sonic-platform-modules-arista @@ -1 +1 @@ -Subproject commit 8f65ad92c5b5dfec24e8faf068cc9d2374244edf +Subproject commit a7edec0e19e63b4ec437d32928a5362a6d0a9bc9