From 5ee37c3a6c861520cc7e3e558c3b758b2813d1d4 Mon Sep 17 00:00:00 2001 From: dzarista Date: Thu, 21 May 2026 18:49:25 +0000 Subject: [PATCH] SaintPaul: Add BSP platform mapping --- fboss/lib/bsp/BUCK | 1 + fboss/lib/bsp/bspmapping/Main.cpp | 2 + fboss/lib/bsp/bspmapping/Parser.h | 2 + .../bspmapping/input/Saintpaul_BspMapping.csv | 35 + fboss/lib/bsp/bspmapping/test/ParserTest.cpp | 4 + fboss/lib/bsp/saintpaul/BUCK | 19 + .../saintpaul/SaintpaulBspPlatformMapping.cpp | 1436 +++++++++++++++++ .../saintpaul/SaintpaulBspPlatformMapping.h | 17 + 8 files changed, 1516 insertions(+) create mode 100644 fboss/lib/bsp/bspmapping/input/Saintpaul_BspMapping.csv create mode 100644 fboss/lib/bsp/saintpaul/BUCK create mode 100644 fboss/lib/bsp/saintpaul/SaintpaulBspPlatformMapping.cpp create mode 100644 fboss/lib/bsp/saintpaul/SaintpaulBspPlatformMapping.h diff --git a/fboss/lib/bsp/BUCK b/fboss/lib/bsp/BUCK index 16c76ffd359da..972515ed67dd0 100644 --- a/fboss/lib/bsp/BUCK +++ b/fboss/lib/bsp/BUCK @@ -125,6 +125,7 @@ cpp_library( "//fboss/lib/bsp/tahansb800bc:tahansb800bc_bsp", "//fboss/lib/bsp/wedge800bact:wedge800bact_bsp", "//fboss/lib/bsp/wedge800cact:wedge800cact_bsp", + "//fboss/lib/bsp/saintpaul:saintpaul_bsp", "//fboss/lib/fpga:fpga_device", "//fboss/lib/fpga:multi_pim_container", "//fboss/lib/i2c:i2c_controller_stats-cpp2-types", diff --git a/fboss/lib/bsp/bspmapping/Main.cpp b/fboss/lib/bsp/bspmapping/Main.cpp index dcfd8c2e50d12..814a63e921bc3 100644 --- a/fboss/lib/bsp/bspmapping/Main.cpp +++ b/fboss/lib/bsp/bspmapping/Main.cpp @@ -53,6 +53,8 @@ const std::map kHardwareNameMap = { kPortMappingLadakh800bclsCsv}, {facebook::fboss::PlatformType::PLATFORM_ICECUBE800BANW, kPortMappingIcecube800banwCsv}, + {facebook::fboss::PlatformType::PLATFORM_SAINTPAUL, + kPortMappingSaintpaulCsv}, }; // Helper function to generate PHY CSV filename from regular CSV filename diff --git a/fboss/lib/bsp/bspmapping/Parser.h b/fboss/lib/bsp/bspmapping/Parser.h index 954be202011aa..9abdb201276b6 100644 --- a/fboss/lib/bsp/bspmapping/Parser.h +++ b/fboss/lib/bsp/bspmapping/Parser.h @@ -43,6 +43,8 @@ inline constexpr folly::StringPiece kPortMappingLadakh800bclsCsv{ "Ladakh800bcls_BspMapping.csv"}; inline constexpr folly::StringPiece kPortMappingIcecube800banwCsv{ "Icecube800banw_BspMapping.csv"}; +inline constexpr folly::StringPiece kPortMappingSaintpaulCsv{ + "Saintpaul_BspMapping.csv"}; class Parser { public: diff --git a/fboss/lib/bsp/bspmapping/input/Saintpaul_BspMapping.csv b/fboss/lib/bsp/bspmapping/input/Saintpaul_BspMapping.csv new file mode 100644 index 0000000000000..e764cb8cb1d8b --- /dev/null +++ b/fboss/lib/bsp/bspmapping/input/Saintpaul_BspMapping.csv @@ -0,0 +1,35 @@ +TcvrId,TcvrLaneIdList,PimId,AccessControllerId,AccessControlType,ResetPath,ResetMask,ResetHoldHi,PresentPath,PresentMask,PresentHoldHi,IoControllerId,IoControlType,IoPath,LedId,LedBluePath,LedYellowPath +1,1 2 3 4 5 6 7 8,1,1,CPLD,/run/devmap/xcvrs/xcvr_ctrl_1/xcvr_reset_1,1,1,/run/devmap/xcvrs/xcvr_ctrl_1/xcvr_present_1,1,0,1,I2C,/run/devmap/xcvrs/xcvr_io_1,1,/sys/class/leds/port1_led1:blue:status,/sys/class/leds/port1_led1:amber:status +2,1 2 3 4 5 6 7 8,1,2,CPLD,/run/devmap/xcvrs/xcvr_ctrl_2/xcvr_reset_2,1,1,/run/devmap/xcvrs/xcvr_ctrl_2/xcvr_present_2,1,0,2,I2C,/run/devmap/xcvrs/xcvr_io_2,2,/sys/class/leds/port2_led1:blue:status,/sys/class/leds/port2_led1:amber:status +3,1 2 3 4 5 6 7 8,1,3,CPLD,/run/devmap/xcvrs/xcvr_ctrl_3/xcvr_reset_3,1,1,/run/devmap/xcvrs/xcvr_ctrl_3/xcvr_present_3,1,0,3,I2C,/run/devmap/xcvrs/xcvr_io_3,3,/sys/class/leds/port3_led1:blue:status,/sys/class/leds/port3_led1:amber:status +4,1 2 3 4 5 6 7 8,1,4,CPLD,/run/devmap/xcvrs/xcvr_ctrl_4/xcvr_reset_4,1,1,/run/devmap/xcvrs/xcvr_ctrl_4/xcvr_present_4,1,0,4,I2C,/run/devmap/xcvrs/xcvr_io_4,4,/sys/class/leds/port4_led1:blue:status,/sys/class/leds/port4_led1:amber:status +5,1 2 3 4 5 6 7 8,1,5,CPLD,/run/devmap/xcvrs/xcvr_ctrl_5/xcvr_reset_5,1,1,/run/devmap/xcvrs/xcvr_ctrl_5/xcvr_present_5,1,0,5,I2C,/run/devmap/xcvrs/xcvr_io_5,5,/sys/class/leds/port5_led1:blue:status,/sys/class/leds/port5_led1:amber:status +6,1 2 3 4 5 6 7 8,1,6,CPLD,/run/devmap/xcvrs/xcvr_ctrl_6/xcvr_reset_6,1,1,/run/devmap/xcvrs/xcvr_ctrl_6/xcvr_present_6,1,0,6,I2C,/run/devmap/xcvrs/xcvr_io_6,6,/sys/class/leds/port6_led1:blue:status,/sys/class/leds/port6_led1:amber:status +7,1 2 3 4 5 6 7 8,1,7,CPLD,/run/devmap/xcvrs/xcvr_ctrl_7/xcvr_reset_7,1,1,/run/devmap/xcvrs/xcvr_ctrl_7/xcvr_present_7,1,0,7,I2C,/run/devmap/xcvrs/xcvr_io_7,7,/sys/class/leds/port7_led1:blue:status,/sys/class/leds/port7_led1:amber:status +8,1 2 3 4 5 6 7 8,1,8,CPLD,/run/devmap/xcvrs/xcvr_ctrl_8/xcvr_reset_8,1,1,/run/devmap/xcvrs/xcvr_ctrl_8/xcvr_present_8,1,0,8,I2C,/run/devmap/xcvrs/xcvr_io_8,8,/sys/class/leds/port8_led1:blue:status,/sys/class/leds/port8_led1:amber:status +9,1 2 3 4 5 6 7 8,1,9,CPLD,/run/devmap/xcvrs/xcvr_ctrl_9/xcvr_reset_9,1,1,/run/devmap/xcvrs/xcvr_ctrl_9/xcvr_present_9,1,0,9,I2C,/run/devmap/xcvrs/xcvr_io_9,9,/sys/class/leds/port9_led1:blue:status,/sys/class/leds/port9_led1:amber:status +10,1 2 3 4 5 6 7 8,1,10,CPLD,/run/devmap/xcvrs/xcvr_ctrl_10/xcvr_reset_10,1,1,/run/devmap/xcvrs/xcvr_ctrl_10/xcvr_present_10,1,0,10,I2C,/run/devmap/xcvrs/xcvr_io_10,10,/sys/class/leds/port10_led1:blue:status,/sys/class/leds/port10_led1:amber:status +11,1 2 3 4 5 6 7 8,1,11,CPLD,/run/devmap/xcvrs/xcvr_ctrl_11/xcvr_reset_11,1,1,/run/devmap/xcvrs/xcvr_ctrl_11/xcvr_present_11,1,0,11,I2C,/run/devmap/xcvrs/xcvr_io_11,11,/sys/class/leds/port11_led1:blue:status,/sys/class/leds/port11_led1:amber:status +12,1 2 3 4 5 6 7 8,1,12,CPLD,/run/devmap/xcvrs/xcvr_ctrl_12/xcvr_reset_12,1,1,/run/devmap/xcvrs/xcvr_ctrl_12/xcvr_present_12,1,0,12,I2C,/run/devmap/xcvrs/xcvr_io_12,12,/sys/class/leds/port12_led1:blue:status,/sys/class/leds/port12_led1:amber:status +13,1 2 3 4 5 6 7 8,1,13,CPLD,/run/devmap/xcvrs/xcvr_ctrl_13/xcvr_reset_13,1,1,/run/devmap/xcvrs/xcvr_ctrl_13/xcvr_present_13,1,0,13,I2C,/run/devmap/xcvrs/xcvr_io_13,13,/sys/class/leds/port13_led1:blue:status,/sys/class/leds/port13_led1:amber:status +14,1 2 3 4 5 6 7 8,1,14,CPLD,/run/devmap/xcvrs/xcvr_ctrl_14/xcvr_reset_14,1,1,/run/devmap/xcvrs/xcvr_ctrl_14/xcvr_present_14,1,0,14,I2C,/run/devmap/xcvrs/xcvr_io_14,14,/sys/class/leds/port14_led1:blue:status,/sys/class/leds/port14_led1:amber:status +15,1 2 3 4 5 6 7 8,1,15,CPLD,/run/devmap/xcvrs/xcvr_ctrl_15/xcvr_reset_15,1,1,/run/devmap/xcvrs/xcvr_ctrl_15/xcvr_present_15,1,0,15,I2C,/run/devmap/xcvrs/xcvr_io_15,15,/sys/class/leds/port15_led1:blue:status,/sys/class/leds/port15_led1:amber:status +16,1 2 3 4 5 6 7 8,1,16,CPLD,/run/devmap/xcvrs/xcvr_ctrl_16/xcvr_reset_16,1,1,/run/devmap/xcvrs/xcvr_ctrl_16/xcvr_present_16,1,0,16,I2C,/run/devmap/xcvrs/xcvr_io_16,16,/sys/class/leds/port16_led1:blue:status,/sys/class/leds/port16_led1:amber:status +17,1 2 3 4 5 6 7 8,1,17,CPLD,/run/devmap/xcvrs/xcvr_ctrl_17/xcvr_reset_17,1,1,/run/devmap/xcvrs/xcvr_ctrl_17/xcvr_present_17,1,0,17,I2C,/run/devmap/xcvrs/xcvr_io_17,17,/sys/class/leds/port17_led1:blue:status,/sys/class/leds/port17_led1:amber:status +18,1 2 3 4 5 6 7 8,1,18,CPLD,/run/devmap/xcvrs/xcvr_ctrl_18/xcvr_reset_18,1,1,/run/devmap/xcvrs/xcvr_ctrl_18/xcvr_present_18,1,0,18,I2C,/run/devmap/xcvrs/xcvr_io_18,18,/sys/class/leds/port18_led1:blue:status,/sys/class/leds/port18_led1:amber:status +19,1 2 3 4 5 6 7 8,1,19,CPLD,/run/devmap/xcvrs/xcvr_ctrl_19/xcvr_reset_19,1,1,/run/devmap/xcvrs/xcvr_ctrl_19/xcvr_present_19,1,0,19,I2C,/run/devmap/xcvrs/xcvr_io_19,19,/sys/class/leds/port19_led1:blue:status,/sys/class/leds/port19_led1:amber:status +20,1 2 3 4 5 6 7 8,1,20,CPLD,/run/devmap/xcvrs/xcvr_ctrl_20/xcvr_reset_20,1,1,/run/devmap/xcvrs/xcvr_ctrl_20/xcvr_present_20,1,0,20,I2C,/run/devmap/xcvrs/xcvr_io_20,20,/sys/class/leds/port20_led1:blue:status,/sys/class/leds/port20_led1:amber:status +21,1 2 3 4 5 6 7 8,1,21,CPLD,/run/devmap/xcvrs/xcvr_ctrl_21/xcvr_reset_21,1,1,/run/devmap/xcvrs/xcvr_ctrl_21/xcvr_present_21,1,0,21,I2C,/run/devmap/xcvrs/xcvr_io_21,21,/sys/class/leds/port21_led1:blue:status,/sys/class/leds/port21_led1:amber:status +22,1 2 3 4 5 6 7 8,1,22,CPLD,/run/devmap/xcvrs/xcvr_ctrl_22/xcvr_reset_22,1,1,/run/devmap/xcvrs/xcvr_ctrl_22/xcvr_present_22,1,0,22,I2C,/run/devmap/xcvrs/xcvr_io_22,22,/sys/class/leds/port22_led1:blue:status,/sys/class/leds/port22_led1:amber:status +23,1 2 3 4 5 6 7 8,1,23,CPLD,/run/devmap/xcvrs/xcvr_ctrl_23/xcvr_reset_23,1,1,/run/devmap/xcvrs/xcvr_ctrl_23/xcvr_present_23,1,0,23,I2C,/run/devmap/xcvrs/xcvr_io_23,23,/sys/class/leds/port23_led1:blue:status,/sys/class/leds/port23_led1:amber:status +24,1 2 3 4 5 6 7 8,1,24,CPLD,/run/devmap/xcvrs/xcvr_ctrl_24/xcvr_reset_24,1,1,/run/devmap/xcvrs/xcvr_ctrl_24/xcvr_present_24,1,0,24,I2C,/run/devmap/xcvrs/xcvr_io_24,24,/sys/class/leds/port24_led1:blue:status,/sys/class/leds/port24_led1:amber:status +25,1 2 3 4 5 6 7 8,1,25,CPLD,/run/devmap/xcvrs/xcvr_ctrl_25/xcvr_reset_25,1,1,/run/devmap/xcvrs/xcvr_ctrl_25/xcvr_present_25,1,0,25,I2C,/run/devmap/xcvrs/xcvr_io_25,25,/sys/class/leds/port25_led1:blue:status,/sys/class/leds/port25_led1:amber:status +26,1 2 3 4 5 6 7 8,1,26,CPLD,/run/devmap/xcvrs/xcvr_ctrl_26/xcvr_reset_26,1,1,/run/devmap/xcvrs/xcvr_ctrl_26/xcvr_present_26,1,0,26,I2C,/run/devmap/xcvrs/xcvr_io_26,26,/sys/class/leds/port26_led1:blue:status,/sys/class/leds/port26_led1:amber:status +27,1 2 3 4 5 6 7 8,1,27,CPLD,/run/devmap/xcvrs/xcvr_ctrl_27/xcvr_reset_27,1,1,/run/devmap/xcvrs/xcvr_ctrl_27/xcvr_present_27,1,0,27,I2C,/run/devmap/xcvrs/xcvr_io_27,27,/sys/class/leds/port27_led1:blue:status,/sys/class/leds/port27_led1:amber:status +28,1 2 3 4 5 6 7 8,1,28,CPLD,/run/devmap/xcvrs/xcvr_ctrl_28/xcvr_reset_28,1,1,/run/devmap/xcvrs/xcvr_ctrl_28/xcvr_present_28,1,0,28,I2C,/run/devmap/xcvrs/xcvr_io_28,28,/sys/class/leds/port28_led1:blue:status,/sys/class/leds/port28_led1:amber:status +29,1 2 3 4 5 6 7 8,1,29,CPLD,/run/devmap/xcvrs/xcvr_ctrl_29/xcvr_reset_29,1,1,/run/devmap/xcvrs/xcvr_ctrl_29/xcvr_present_29,1,0,29,I2C,/run/devmap/xcvrs/xcvr_io_29,29,/sys/class/leds/port29_led1:blue:status,/sys/class/leds/port29_led1:amber:status +30,1 2 3 4 5 6 7 8,1,30,CPLD,/run/devmap/xcvrs/xcvr_ctrl_30/xcvr_reset_30,1,1,/run/devmap/xcvrs/xcvr_ctrl_30/xcvr_present_30,1,0,30,I2C,/run/devmap/xcvrs/xcvr_io_30,30,/sys/class/leds/port30_led1:blue:status,/sys/class/leds/port30_led1:amber:status +31,1 2 3 4 5 6 7 8,1,31,CPLD,/run/devmap/xcvrs/xcvr_ctrl_31/xcvr_reset_31,1,1,/run/devmap/xcvrs/xcvr_ctrl_31/xcvr_present_31,1,0,31,I2C,/run/devmap/xcvrs/xcvr_io_31,31,/sys/class/leds/port31_led1:blue:status,/sys/class/leds/port31_led1:amber:status +32,1 2 3 4 5 6 7 8,1,32,CPLD,/run/devmap/xcvrs/xcvr_ctrl_32/xcvr_reset_32,1,1,/run/devmap/xcvrs/xcvr_ctrl_32/xcvr_present_32,1,0,32,I2C,/run/devmap/xcvrs/xcvr_io_32,32,/sys/class/leds/port32_led1:blue:status,/sys/class/leds/port32_led1:amber:status +33,1 2 3 4,1,33,CPLD,/run/devmap/xcvrs/xcvr_ctrl_33/xcvr_reset_33,1,1,/run/devmap/xcvrs/xcvr_ctrl_33/xcvr_present_33,1,0,33,I2C,/run/devmap/xcvrs/xcvr_io_33,33,/sys/class/leds/port33_led1:blue:status,/sys/class/leds/port33_led1:amber:status +34,1 2 3 4,1,34,CPLD,/run/devmap/xcvrs/xcvr_ctrl_34/xcvr_reset_34,1,1,/run/devmap/xcvrs/xcvr_ctrl_34/xcvr_present_34,1,0,34,I2C,/run/devmap/xcvrs/xcvr_io_34,34,/sys/class/leds/port34_led1:blue:status,/sys/class/leds/port34_led1:amber:status diff --git a/fboss/lib/bsp/bspmapping/test/ParserTest.cpp b/fboss/lib/bsp/bspmapping/test/ParserTest.cpp index 4504e3153a5e2..7f3605c0d75a6 100644 --- a/fboss/lib/bsp/bspmapping/test/ParserTest.cpp +++ b/fboss/lib/bsp/bspmapping/test/ParserTest.cpp @@ -76,6 +76,10 @@ TEST(ParserTest, GetNameForTests) { facebook::fboss::Parser::getNameFor( facebook::fboss::PlatformType::PLATFORM_ICECUBE800BANW), "icecube800banw"); + EXPECT_EQ( + facebook::fboss::Parser::getNameFor( + facebook::fboss::PlatformType::PLATFORM_SAINTPAUL), + "saintpaul"); } TEST(ParserTest, GetTransceiverConfigRowFromCsvLine) { diff --git a/fboss/lib/bsp/saintpaul/BUCK b/fboss/lib/bsp/saintpaul/BUCK new file mode 100644 index 0000000000000..72612c5ee5d60 --- /dev/null +++ b/fboss/lib/bsp/saintpaul/BUCK @@ -0,0 +1,19 @@ +# @autodeps +load("@fbcode_macros//build_defs:cpp_library.bzl", "cpp_library") + +oncall("fboss_optics_phy") + +cpp_library( + name = "saintpaul_bsp", + srcs = [ + "SaintpaulBspPlatformMapping.cpp", + ], + headers = [ + "SaintpaulBspPlatformMapping.h", + ], + exported_deps = [ + "//fboss/lib/bsp:bsp_platform_mapping-cpp2-types", + "//fboss/lib/bsp:bsp_platform_mapping_lib", + "//thrift/lib/cpp2/protocol:protocol", + ], +) diff --git a/fboss/lib/bsp/saintpaul/SaintpaulBspPlatformMapping.cpp b/fboss/lib/bsp/saintpaul/SaintpaulBspPlatformMapping.cpp new file mode 100644 index 0000000000000..7ed59737c1387 --- /dev/null +++ b/fboss/lib/bsp/saintpaul/SaintpaulBspPlatformMapping.cpp @@ -0,0 +1,1436 @@ +// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary. + +#include "fboss/lib/bsp/saintpaul/SaintpaulBspPlatformMapping.h" +#include +#include "fboss/lib/bsp/BspPlatformMapping.h" +#include "fboss/lib/bsp/gen-cpp2/bsp_platform_mapping_types.h" + +using namespace facebook::fboss; + +namespace { + +// This is generated from the csv under fboss/lib/bsp/bspmapping/input +// To regenerate: build and run fboss/lib/bsp/bspmapping:bspmapping_main, +// then copy the saintpaul.json output here. +constexpr auto kJsonBspPlatformMappingStr = R"( +{ + "pimMapping": { + "1": { + "pimID": 1, + "tcvrMapping": { + "1": { + "tcvrId": 1, + "accessControl": { + "controllerId": "1", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_1/xcvr_reset_1", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_1/xcvr_present_1", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "1", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_1" + }, + "tcvrLaneToLedId": { + "1": 1, + "2": 1, + "3": 1, + "4": 1, + "5": 1, + "6": 1, + "7": 1, + "8": 1 + } + }, + "2": { + "tcvrId": 2, + "accessControl": { + "controllerId": "2", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_2/xcvr_reset_2", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_2/xcvr_present_2", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "2", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_2" + }, + "tcvrLaneToLedId": { + "1": 2, + "2": 2, + "3": 2, + "4": 2, + "5": 2, + "6": 2, + "7": 2, + "8": 2 + } + }, + "3": { + "tcvrId": 3, + "accessControl": { + "controllerId": "3", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_3/xcvr_reset_3", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_3/xcvr_present_3", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "3", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_3" + }, + "tcvrLaneToLedId": { + "1": 3, + "2": 3, + "3": 3, + "4": 3, + "5": 3, + "6": 3, + "7": 3, + "8": 3 + } + }, + "4": { + "tcvrId": 4, + "accessControl": { + "controllerId": "4", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_4/xcvr_reset_4", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_4/xcvr_present_4", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "4", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_4" + }, + "tcvrLaneToLedId": { + "1": 4, + "2": 4, + "3": 4, + "4": 4, + "5": 4, + "6": 4, + "7": 4, + "8": 4 + } + }, + "5": { + "tcvrId": 5, + "accessControl": { + "controllerId": "5", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_5/xcvr_reset_5", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_5/xcvr_present_5", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "5", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_5" + }, + "tcvrLaneToLedId": { + "1": 5, + "2": 5, + "3": 5, + "4": 5, + "5": 5, + "6": 5, + "7": 5, + "8": 5 + } + }, + "6": { + "tcvrId": 6, + "accessControl": { + "controllerId": "6", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_6/xcvr_reset_6", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_6/xcvr_present_6", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "6", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_6" + }, + "tcvrLaneToLedId": { + "1": 6, + "2": 6, + "3": 6, + "4": 6, + "5": 6, + "6": 6, + "7": 6, + "8": 6 + } + }, + "7": { + "tcvrId": 7, + "accessControl": { + "controllerId": "7", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_7/xcvr_reset_7", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_7/xcvr_present_7", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "7", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_7" + }, + "tcvrLaneToLedId": { + "1": 7, + "2": 7, + "3": 7, + "4": 7, + "5": 7, + "6": 7, + "7": 7, + "8": 7 + } + }, + "8": { + "tcvrId": 8, + "accessControl": { + "controllerId": "8", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_8/xcvr_reset_8", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_8/xcvr_present_8", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "8", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_8" + }, + "tcvrLaneToLedId": { + "1": 8, + "2": 8, + "3": 8, + "4": 8, + "5": 8, + "6": 8, + "7": 8, + "8": 8 + } + }, + "9": { + "tcvrId": 9, + "accessControl": { + "controllerId": "9", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_9/xcvr_reset_9", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_9/xcvr_present_9", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "9", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_9" + }, + "tcvrLaneToLedId": { + "1": 9, + "2": 9, + "3": 9, + "4": 9, + "5": 9, + "6": 9, + "7": 9, + "8": 9 + } + }, + "10": { + "tcvrId": 10, + "accessControl": { + "controllerId": "10", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_10/xcvr_reset_10", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_10/xcvr_present_10", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "10", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_10" + }, + "tcvrLaneToLedId": { + "1": 10, + "2": 10, + "3": 10, + "4": 10, + "5": 10, + "6": 10, + "7": 10, + "8": 10 + } + }, + "11": { + "tcvrId": 11, + "accessControl": { + "controllerId": "11", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_11/xcvr_reset_11", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_11/xcvr_present_11", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "11", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_11" + }, + "tcvrLaneToLedId": { + "1": 11, + "2": 11, + "3": 11, + "4": 11, + "5": 11, + "6": 11, + "7": 11, + "8": 11 + } + }, + "12": { + "tcvrId": 12, + "accessControl": { + "controllerId": "12", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_12/xcvr_reset_12", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_12/xcvr_present_12", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "12", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_12" + }, + "tcvrLaneToLedId": { + "1": 12, + "2": 12, + "3": 12, + "4": 12, + "5": 12, + "6": 12, + "7": 12, + "8": 12 + } + }, + "13": { + "tcvrId": 13, + "accessControl": { + "controllerId": "13", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_13/xcvr_reset_13", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_13/xcvr_present_13", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "13", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_13" + }, + "tcvrLaneToLedId": { + "1": 13, + "2": 13, + "3": 13, + "4": 13, + "5": 13, + "6": 13, + "7": 13, + "8": 13 + } + }, + "14": { + "tcvrId": 14, + "accessControl": { + "controllerId": "14", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_14/xcvr_reset_14", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_14/xcvr_present_14", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "14", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_14" + }, + "tcvrLaneToLedId": { + "1": 14, + "2": 14, + "3": 14, + "4": 14, + "5": 14, + "6": 14, + "7": 14, + "8": 14 + } + }, + "15": { + "tcvrId": 15, + "accessControl": { + "controllerId": "15", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_15/xcvr_reset_15", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_15/xcvr_present_15", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "15", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_15" + }, + "tcvrLaneToLedId": { + "1": 15, + "2": 15, + "3": 15, + "4": 15, + "5": 15, + "6": 15, + "7": 15, + "8": 15 + } + }, + "16": { + "tcvrId": 16, + "accessControl": { + "controllerId": "16", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_16/xcvr_reset_16", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_16/xcvr_present_16", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "16", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_16" + }, + "tcvrLaneToLedId": { + "1": 16, + "2": 16, + "3": 16, + "4": 16, + "5": 16, + "6": 16, + "7": 16, + "8": 16 + } + }, + "17": { + "tcvrId": 17, + "accessControl": { + "controllerId": "17", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_17/xcvr_reset_17", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_17/xcvr_present_17", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "17", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_17" + }, + "tcvrLaneToLedId": { + "1": 17, + "2": 17, + "3": 17, + "4": 17, + "5": 17, + "6": 17, + "7": 17, + "8": 17 + } + }, + "18": { + "tcvrId": 18, + "accessControl": { + "controllerId": "18", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_18/xcvr_reset_18", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_18/xcvr_present_18", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "18", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_18" + }, + "tcvrLaneToLedId": { + "1": 18, + "2": 18, + "3": 18, + "4": 18, + "5": 18, + "6": 18, + "7": 18, + "8": 18 + } + }, + "19": { + "tcvrId": 19, + "accessControl": { + "controllerId": "19", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_19/xcvr_reset_19", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_19/xcvr_present_19", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "19", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_19" + }, + "tcvrLaneToLedId": { + "1": 19, + "2": 19, + "3": 19, + "4": 19, + "5": 19, + "6": 19, + "7": 19, + "8": 19 + } + }, + "20": { + "tcvrId": 20, + "accessControl": { + "controllerId": "20", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_20/xcvr_reset_20", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_20/xcvr_present_20", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "20", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_20" + }, + "tcvrLaneToLedId": { + "1": 20, + "2": 20, + "3": 20, + "4": 20, + "5": 20, + "6": 20, + "7": 20, + "8": 20 + } + }, + "21": { + "tcvrId": 21, + "accessControl": { + "controllerId": "21", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_21/xcvr_reset_21", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_21/xcvr_present_21", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "21", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_21" + }, + "tcvrLaneToLedId": { + "1": 21, + "2": 21, + "3": 21, + "4": 21, + "5": 21, + "6": 21, + "7": 21, + "8": 21 + } + }, + "22": { + "tcvrId": 22, + "accessControl": { + "controllerId": "22", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_22/xcvr_reset_22", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_22/xcvr_present_22", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "22", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_22" + }, + "tcvrLaneToLedId": { + "1": 22, + "2": 22, + "3": 22, + "4": 22, + "5": 22, + "6": 22, + "7": 22, + "8": 22 + } + }, + "23": { + "tcvrId": 23, + "accessControl": { + "controllerId": "23", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_23/xcvr_reset_23", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_23/xcvr_present_23", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "23", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_23" + }, + "tcvrLaneToLedId": { + "1": 23, + "2": 23, + "3": 23, + "4": 23, + "5": 23, + "6": 23, + "7": 23, + "8": 23 + } + }, + "24": { + "tcvrId": 24, + "accessControl": { + "controllerId": "24", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_24/xcvr_reset_24", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_24/xcvr_present_24", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "24", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_24" + }, + "tcvrLaneToLedId": { + "1": 24, + "2": 24, + "3": 24, + "4": 24, + "5": 24, + "6": 24, + "7": 24, + "8": 24 + } + }, + "25": { + "tcvrId": 25, + "accessControl": { + "controllerId": "25", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_25/xcvr_reset_25", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_25/xcvr_present_25", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "25", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_25" + }, + "tcvrLaneToLedId": { + "1": 25, + "2": 25, + "3": 25, + "4": 25, + "5": 25, + "6": 25, + "7": 25, + "8": 25 + } + }, + "26": { + "tcvrId": 26, + "accessControl": { + "controllerId": "26", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_26/xcvr_reset_26", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_26/xcvr_present_26", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "26", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_26" + }, + "tcvrLaneToLedId": { + "1": 26, + "2": 26, + "3": 26, + "4": 26, + "5": 26, + "6": 26, + "7": 26, + "8": 26 + } + }, + "27": { + "tcvrId": 27, + "accessControl": { + "controllerId": "27", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_27/xcvr_reset_27", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_27/xcvr_present_27", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "27", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_27" + }, + "tcvrLaneToLedId": { + "1": 27, + "2": 27, + "3": 27, + "4": 27, + "5": 27, + "6": 27, + "7": 27, + "8": 27 + } + }, + "28": { + "tcvrId": 28, + "accessControl": { + "controllerId": "28", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_28/xcvr_reset_28", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_28/xcvr_present_28", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "28", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_28" + }, + "tcvrLaneToLedId": { + "1": 28, + "2": 28, + "3": 28, + "4": 28, + "5": 28, + "6": 28, + "7": 28, + "8": 28 + } + }, + "29": { + "tcvrId": 29, + "accessControl": { + "controllerId": "29", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_29/xcvr_reset_29", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_29/xcvr_present_29", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "29", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_29" + }, + "tcvrLaneToLedId": { + "1": 29, + "2": 29, + "3": 29, + "4": 29, + "5": 29, + "6": 29, + "7": 29, + "8": 29 + } + }, + "30": { + "tcvrId": 30, + "accessControl": { + "controllerId": "30", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_30/xcvr_reset_30", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_30/xcvr_present_30", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "30", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_30" + }, + "tcvrLaneToLedId": { + "1": 30, + "2": 30, + "3": 30, + "4": 30, + "5": 30, + "6": 30, + "7": 30, + "8": 30 + } + }, + "31": { + "tcvrId": 31, + "accessControl": { + "controllerId": "31", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_31/xcvr_reset_31", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_31/xcvr_present_31", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "31", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_31" + }, + "tcvrLaneToLedId": { + "1": 31, + "2": 31, + "3": 31, + "4": 31, + "5": 31, + "6": 31, + "7": 31, + "8": 31 + } + }, + "32": { + "tcvrId": 32, + "accessControl": { + "controllerId": "32", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_32/xcvr_reset_32", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_32/xcvr_present_32", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "32", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_32" + }, + "tcvrLaneToLedId": { + "1": 32, + "2": 32, + "3": 32, + "4": 32, + "5": 32, + "6": 32, + "7": 32, + "8": 32 + } + }, + "33": { + "tcvrId": 33, + "accessControl": { + "controllerId": "33", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_33/xcvr_reset_33", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_33/xcvr_present_33", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "33", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_33" + }, + "tcvrLaneToLedId": { + "1": 33, + "2": 33, + "3": 33, + "4": 33 + } + }, + "34": { + "tcvrId": 34, + "accessControl": { + "controllerId": "34", + "type": 1, + "reset": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_34/xcvr_reset_34", + "mask": 1, + "gpioOffset": 0, + "resetHoldHi": 1 + }, + "presence": { + "sysfsPath": "/run/devmap/xcvrs/xcvr_ctrl_34/xcvr_present_34", + "mask": 1, + "gpioOffset": 0, + "presentHoldHi": 0 + }, + "gpioChip": "" + }, + "io": { + "controllerId": "34", + "type": 1, + "devicePath": "/run/devmap/xcvrs/xcvr_io_34" + }, + "tcvrLaneToLedId": { + "1": 34, + "2": 34, + "3": 34, + "4": 34 + } + } + }, + "phyMapping": {}, + "phyIOControllers": {}, + "ledMapping": { + "1": { + "id": 1, + "bluePath": "/sys/class/leds/port1_led1:blue:status", + "yellowPath": "/sys/class/leds/port1_led1:amber:status", + "transceiverId": 1 + }, + "2": { + "id": 2, + "bluePath": "/sys/class/leds/port2_led1:blue:status", + "yellowPath": "/sys/class/leds/port2_led1:amber:status", + "transceiverId": 2 + }, + "3": { + "id": 3, + "bluePath": "/sys/class/leds/port3_led1:blue:status", + "yellowPath": "/sys/class/leds/port3_led1:amber:status", + "transceiverId": 3 + }, + "4": { + "id": 4, + "bluePath": "/sys/class/leds/port4_led1:blue:status", + "yellowPath": "/sys/class/leds/port4_led1:amber:status", + "transceiverId": 4 + }, + "5": { + "id": 5, + "bluePath": "/sys/class/leds/port5_led1:blue:status", + "yellowPath": "/sys/class/leds/port5_led1:amber:status", + "transceiverId": 5 + }, + "6": { + "id": 6, + "bluePath": "/sys/class/leds/port6_led1:blue:status", + "yellowPath": "/sys/class/leds/port6_led1:amber:status", + "transceiverId": 6 + }, + "7": { + "id": 7, + "bluePath": "/sys/class/leds/port7_led1:blue:status", + "yellowPath": "/sys/class/leds/port7_led1:amber:status", + "transceiverId": 7 + }, + "8": { + "id": 8, + "bluePath": "/sys/class/leds/port8_led1:blue:status", + "yellowPath": "/sys/class/leds/port8_led1:amber:status", + "transceiverId": 8 + }, + "9": { + "id": 9, + "bluePath": "/sys/class/leds/port9_led1:blue:status", + "yellowPath": "/sys/class/leds/port9_led1:amber:status", + "transceiverId": 9 + }, + "10": { + "id": 10, + "bluePath": "/sys/class/leds/port10_led1:blue:status", + "yellowPath": "/sys/class/leds/port10_led1:amber:status", + "transceiverId": 10 + }, + "11": { + "id": 11, + "bluePath": "/sys/class/leds/port11_led1:blue:status", + "yellowPath": "/sys/class/leds/port11_led1:amber:status", + "transceiverId": 11 + }, + "12": { + "id": 12, + "bluePath": "/sys/class/leds/port12_led1:blue:status", + "yellowPath": "/sys/class/leds/port12_led1:amber:status", + "transceiverId": 12 + }, + "13": { + "id": 13, + "bluePath": "/sys/class/leds/port13_led1:blue:status", + "yellowPath": "/sys/class/leds/port13_led1:amber:status", + "transceiverId": 13 + }, + "14": { + "id": 14, + "bluePath": "/sys/class/leds/port14_led1:blue:status", + "yellowPath": "/sys/class/leds/port14_led1:amber:status", + "transceiverId": 14 + }, + "15": { + "id": 15, + "bluePath": "/sys/class/leds/port15_led1:blue:status", + "yellowPath": "/sys/class/leds/port15_led1:amber:status", + "transceiverId": 15 + }, + "16": { + "id": 16, + "bluePath": "/sys/class/leds/port16_led1:blue:status", + "yellowPath": "/sys/class/leds/port16_led1:amber:status", + "transceiverId": 16 + }, + "17": { + "id": 17, + "bluePath": "/sys/class/leds/port17_led1:blue:status", + "yellowPath": "/sys/class/leds/port17_led1:amber:status", + "transceiverId": 17 + }, + "18": { + "id": 18, + "bluePath": "/sys/class/leds/port18_led1:blue:status", + "yellowPath": "/sys/class/leds/port18_led1:amber:status", + "transceiverId": 18 + }, + "19": { + "id": 19, + "bluePath": "/sys/class/leds/port19_led1:blue:status", + "yellowPath": "/sys/class/leds/port19_led1:amber:status", + "transceiverId": 19 + }, + "20": { + "id": 20, + "bluePath": "/sys/class/leds/port20_led1:blue:status", + "yellowPath": "/sys/class/leds/port20_led1:amber:status", + "transceiverId": 20 + }, + "21": { + "id": 21, + "bluePath": "/sys/class/leds/port21_led1:blue:status", + "yellowPath": "/sys/class/leds/port21_led1:amber:status", + "transceiverId": 21 + }, + "22": { + "id": 22, + "bluePath": "/sys/class/leds/port22_led1:blue:status", + "yellowPath": "/sys/class/leds/port22_led1:amber:status", + "transceiverId": 22 + }, + "23": { + "id": 23, + "bluePath": "/sys/class/leds/port23_led1:blue:status", + "yellowPath": "/sys/class/leds/port23_led1:amber:status", + "transceiverId": 23 + }, + "24": { + "id": 24, + "bluePath": "/sys/class/leds/port24_led1:blue:status", + "yellowPath": "/sys/class/leds/port24_led1:amber:status", + "transceiverId": 24 + }, + "25": { + "id": 25, + "bluePath": "/sys/class/leds/port25_led1:blue:status", + "yellowPath": "/sys/class/leds/port25_led1:amber:status", + "transceiverId": 25 + }, + "26": { + "id": 26, + "bluePath": "/sys/class/leds/port26_led1:blue:status", + "yellowPath": "/sys/class/leds/port26_led1:amber:status", + "transceiverId": 26 + }, + "27": { + "id": 27, + "bluePath": "/sys/class/leds/port27_led1:blue:status", + "yellowPath": "/sys/class/leds/port27_led1:amber:status", + "transceiverId": 27 + }, + "28": { + "id": 28, + "bluePath": "/sys/class/leds/port28_led1:blue:status", + "yellowPath": "/sys/class/leds/port28_led1:amber:status", + "transceiverId": 28 + }, + "29": { + "id": 29, + "bluePath": "/sys/class/leds/port29_led1:blue:status", + "yellowPath": "/sys/class/leds/port29_led1:amber:status", + "transceiverId": 29 + }, + "30": { + "id": 30, + "bluePath": "/sys/class/leds/port30_led1:blue:status", + "yellowPath": "/sys/class/leds/port30_led1:amber:status", + "transceiverId": 30 + }, + "31": { + "id": 31, + "bluePath": "/sys/class/leds/port31_led1:blue:status", + "yellowPath": "/sys/class/leds/port31_led1:amber:status", + "transceiverId": 31 + }, + "32": { + "id": 32, + "bluePath": "/sys/class/leds/port32_led1:blue:status", + "yellowPath": "/sys/class/leds/port32_led1:amber:status", + "transceiverId": 32 + }, + "33": { + "id": 33, + "bluePath": "/sys/class/leds/port33_led1:blue:status", + "yellowPath": "/sys/class/leds/port33_led1:amber:status", + "transceiverId": 33 + }, + "34": { + "id": 34, + "bluePath": "/sys/class/leds/port34_led1:blue:status", + "yellowPath": "/sys/class/leds/port34_led1:amber:status", + "transceiverId": 34 + } + } + } + } +})"; + +BspPlatformMappingThrift buildSaintpaulPlatformMapping( + const std::string& platformMappingStr) { + return apache::thrift::SimpleJSONSerializer::deserialize< + BspPlatformMappingThrift>(platformMappingStr); +} + +} // namespace + +namespace facebook { +namespace fboss { + +SaintpaulBspPlatformMapping::SaintpaulBspPlatformMapping() + : BspPlatformMapping( + buildSaintpaulPlatformMapping(kJsonBspPlatformMappingStr)) {} + +SaintpaulBspPlatformMapping::SaintpaulBspPlatformMapping( + const std::string& platformMappingStr) + : BspPlatformMapping(buildSaintpaulPlatformMapping(platformMappingStr)) {} + +} // namespace fboss +} // namespace facebook diff --git a/fboss/lib/bsp/saintpaul/SaintpaulBspPlatformMapping.h b/fboss/lib/bsp/saintpaul/SaintpaulBspPlatformMapping.h new file mode 100644 index 0000000000000..346fdb927b889 --- /dev/null +++ b/fboss/lib/bsp/saintpaul/SaintpaulBspPlatformMapping.h @@ -0,0 +1,17 @@ +// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary. + +#pragma once + +#include "fboss/lib/bsp/BspPlatformMapping.h" + +namespace facebook { +namespace fboss { + +class SaintpaulBspPlatformMapping : public BspPlatformMapping { + public: + SaintpaulBspPlatformMapping(); + explicit SaintpaulBspPlatformMapping(const std::string& platformMappingStr); +}; + +} // namespace fboss +} // namespace facebook