diff options
Diffstat (limited to 'meta-ampere')
9 files changed, 779 insertions, 4 deletions
diff --git a/meta-ampere/meta-jade/recipes-phosphor/configuration/dbus-sensors_%.bbappend b/meta-ampere/meta-common/recipes-phosphor/configuration/dbus-sensors_%.bbappend index b3be6438d9..b3be6438d9 100644 --- a/meta-ampere/meta-jade/recipes-phosphor/configuration/dbus-sensors_%.bbappend +++ b/meta-ampere/meta-common/recipes-phosphor/configuration/dbus-sensors_%.bbappend diff --git a/meta-ampere/meta-mitchell/recipes-ampere/platform/ampere-platform-init.bb b/meta-ampere/meta-mitchell/recipes-ampere/platform/ampere-platform-init.bb index 12a5c09a6d..362b4c8e59 100644 --- a/meta-ampere/meta-mitchell/recipes-ampere/platform/ampere-platform-init.bb +++ b/meta-ampere/meta-mitchell/recipes-ampere/platform/ampere-platform-init.bb @@ -17,7 +17,7 @@ SRC_URI = " \ file://ampere-bmc-heartbeat.service \ file://ampere_platform_init.sh \ file://ampere_bmc_heartbeat.sh \ - file://${MACHINE}_platform_gpios_init.sh \ + file://mtmitchell_platform_gpios_init.sh \ file://gpio-lib.sh \ file://ampere_uart_console_setup.sh \ file://ampere_uartmux_ctrl.sh \ @@ -30,7 +30,7 @@ do_install () { install -m 0755 ${WORKDIR}/gpio-lib.sh ${D}${sbindir}/ install -m 0755 ${WORKDIR}/ampere_platform_init.sh ${D}${sbindir}/ install -m 0755 ${WORKDIR}/ampere_bmc_heartbeat.sh ${D}${sbindir}/ - install -m 0755 ${WORKDIR}/${MACHINE}_platform_gpios_init.sh ${D}${sbindir}/platform_gpios_init.sh + install -m 0755 ${WORKDIR}/mtmitchell_platform_gpios_init.sh ${D}${sbindir}/platform_gpios_init.sh install -m 0755 ${WORKDIR}/ampere_uart_console_setup.sh ${D}${sbindir}/ install -m 0755 ${WORKDIR}/ampere_uartmux_ctrl.sh ${D}/${sbindir}/ install -d ${D}${systemd_unitdir}/system/ diff --git a/meta-ampere/meta-mitchell/recipes-phosphor/configuration/mtmitchell-yaml-config.bb b/meta-ampere/meta-mitchell/recipes-phosphor/configuration/mtmitchell-yaml-config.bb new file mode 100644 index 0000000000..c6e0ab604d --- /dev/null +++ b/meta-ampere/meta-mitchell/recipes-phosphor/configuration/mtmitchell-yaml-config.bb @@ -0,0 +1,26 @@ +SUMMARY = "YAML configuration for Mt Mitchell" +PR = "r1" +LICENSE = "Apache-2.0" +LIC_FILES_CHKSUM = "file://${COREBASE}/meta/files/common-licenses/Apache-2.0;md5=89aea4e17d99a7cacdbeed46a0096b10" +inherit allarch + +SRC_URI = " \ + file://mtmitchell-ipmi-sensors.yaml \ + file://mtmitchell-ipmi-fru.yaml \ + " + +S = "${WORKDIR}" + +do_install() { + install -m 0644 -D mtmitchell-ipmi-sensors.yaml \ + ${D}${datadir}/${BPN}/ipmi-sensors.yaml + install -m 0644 -D mtmitchell-ipmi-fru.yaml \ + ${D}${datadir}/${BPN}/ipmi-fru-read.yaml +} + +FILES:${PN}-dev = " \ + ${datadir}/${BPN}/ipmi-sensors.yaml \ + ${datadir}/${BPN}/ipmi-fru-read.yaml \ + " + +ALLOW_EMPTY:${PN} = "1" diff --git a/meta-ampere/meta-mitchell/recipes-phosphor/configuration/mtmitchell-yaml-config/mtmitchell-ipmi-fru.yaml b/meta-ampere/meta-mitchell/recipes-phosphor/configuration/mtmitchell-yaml-config/mtmitchell-ipmi-fru.yaml new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/meta-ampere/meta-mitchell/recipes-phosphor/configuration/mtmitchell-yaml-config/mtmitchell-ipmi-fru.yaml diff --git a/meta-ampere/meta-mitchell/recipes-phosphor/configuration/mtmitchell-yaml-config/mtmitchell-ipmi-sensors.yaml b/meta-ampere/meta-mitchell/recipes-phosphor/configuration/mtmitchell-yaml-config/mtmitchell-ipmi-sensors.yaml new file mode 100644 index 0000000000..d2773ccd20 --- /dev/null +++ b/meta-ampere/meta-mitchell/recipes-phosphor/configuration/mtmitchell-yaml-config/mtmitchell-ipmi-sensors.yaml @@ -0,0 +1,551 @@ +1: &TEMP_DEFAULTS + bExp: 0 + entityID: 0x7 + entityInstance: 1 + interfaces: + xyz.openbmc_project.Sensor.Value: + Value: + Offsets: + 255: + type: double + multiplierM: 1 + mutability: Mutability::Write|Mutability::Read + offsetB: 0 + path: /xyz/openbmc_project/sensors/temperature/OutletTemp + rExp: 0 + readingType: readingData + sensorNamePattern: nameLeaf + sensorReadingType: 1 + sensorType: 1 + serviceInterface: org.freedesktop.DBus.Properties + unit: xyz.openbmc_project.Sensor.Value.Unit.DegreesC +2: + <<: *TEMP_DEFAULTS + entityInstance: 2 + path: /xyz/openbmc_project/sensors/temperature/Psu1InletTemp2 +3: + <<: *TEMP_DEFAULTS + entityInstance: 3 + path: /xyz/openbmc_project/sensors/temperature/PcieZoneTemp1 +4: + <<: *TEMP_DEFAULTS + entityInstance: 4 + path: /xyz/openbmc_project/sensors/temperature/Psu0InletTemp2 +5: + <<: *TEMP_DEFAULTS + entityInstance: 5 + path: /xyz/openbmc_project/sensors/temperature/PcieZoneTemp2 +7: + <<: *TEMP_DEFAULTS + entityID: 0x37 + entityInstance: 1 + path: /xyz/openbmc_project/sensors/temperature/SysCabInletTemp +8: + <<: *TEMP_DEFAULTS + entityID: 0x40 + entityInstance: 1 + path: /xyz/openbmc_project/sensors/temperature/MBInletTemp1 +9: + <<: *TEMP_DEFAULTS + entityID: 0x40 + entityInstance: 2 + path: /xyz/openbmc_project/sensors/temperature/MBInletTemp2 +10: + <<: *TEMP_DEFAULTS + entityID: 0x42 + entityInstance: 1 + path: /xyz/openbmc_project/sensors/temperature/AST2600CPUTemp +11: + <<: *TEMP_DEFAULTS + entityID: 0x1e + entityInstance: 1 + path: /xyz/openbmc_project/sensors/temperature/NVMeM2_MaxTemp +16: + <<: *TEMP_DEFAULTS + entityID: 0x1e + entityInstance: 6 + path: /xyz/openbmc_project/sensors/temperature/OCP_MaxTemp + +17: &FAN_DEFAULTS + entityID: 29 + entityInstance: 1 + sensorType: 4 + path: /xyz/openbmc_project/sensors/fan_tach/FAN0_F + sensorReadingType: 1 + multiplierM: 100 + offsetB: 0 + rExp: 0 + unit: xyz.openbmc_project.Sensor.Value.Unit.RPMS + mutability: Mutability::Write|Mutability::Read + serviceInterface: org.freedesktop.DBus.Properties + readingType: readingData + sensorNamePattern: nameLeaf + interfaces: + xyz.openbmc_project.Sensor.Value: + Value: + Offsets: + 0x0: + type: double +18: + <<: *FAN_DEFAULTS + entityInstance: 2 + path: /xyz/openbmc_project/sensors/fan_tach/FAN0_R +19: + <<: *FAN_DEFAULTS + entityInstance: 3 + path: /xyz/openbmc_project/sensors/fan_tach/FAN1_F +20: + <<: *FAN_DEFAULTS + entityInstance: 4 + path: /xyz/openbmc_project/sensors/fan_tach/FAN1_R +21: + <<: *FAN_DEFAULTS + entityInstance: 5 + path: /xyz/openbmc_project/sensors/fan_tach/FAN2_F +22: + <<: *FAN_DEFAULTS + entityInstance: 6 + path: /xyz/openbmc_project/sensors/fan_tach/FAN2_R +23: + <<: *FAN_DEFAULTS + entityInstance: 7 + path: /xyz/openbmc_project/sensors/fan_tach/FAN3_F +24: + <<: *FAN_DEFAULTS + entityInstance: 8 + path: /xyz/openbmc_project/sensors/fan_tach/FAN3_R +25: + <<: *FAN_DEFAULTS + entityInstance: 9 + path: /xyz/openbmc_project/sensors/fan_tach/FAN4_F +26: + <<: *FAN_DEFAULTS + entityInstance: 10 + path: /xyz/openbmc_project/sensors/fan_tach/FAN4_R +27: + <<: *FAN_DEFAULTS + entityInstance: 11 + path: /xyz/openbmc_project/sensors/fan_tach/FAN5_F +28: + <<: *FAN_DEFAULTS + entityInstance: 12 + path: /xyz/openbmc_project/sensors/fan_tach/FAN5_R + +57: &VOLTAGE_DEFAULTS + entityID: 0x13 + entityInstance: 1 + sensorType: 0x02 + path: /xyz/openbmc_project/sensors/voltage/S0_0V8_D2D + sensorReadingType: 0x01 + multiplierM: 5 + offsetB: 0 + bExp: 0 + unit: xyz.openbmc_project.Sensor.Value.Unit.Volts + rExp: -3 + serviceInterface: org.freedesktop.DBus.Properties + readingType: readingData + interfaces: + xyz.openbmc_project.Sensor.Value: + Value: + Offsets: + 0xFF: + type: double +58: + <<: *VOLTAGE_DEFAULTS + entityInstance: 2 + multiplierM: 5 + path: /xyz/openbmc_project/sensors/voltage/S0_0V85_SOC +59: + <<: *VOLTAGE_DEFAULTS + entityInstance: 3 + multiplierM: 5 + path: /xyz/openbmc_project/sensors/voltage/S0_0V85_RC_DDR0 +60: + <<: *VOLTAGE_DEFAULTS + entityInstance: 4 + multiplierM: 5 + path: /xyz/openbmc_project/sensors/voltage/S0_0V85_RC_DDR1 +61: + <<: *VOLTAGE_DEFAULTS + entityInstance: 5 + multiplierM: 5 + path: /xyz/openbmc_project/sensors/voltage/S0_0V9_RC5A +62: + <<: *VOLTAGE_DEFAULTS + entityInstance: 6 + multiplierM: 10 + path: /xyz/openbmc_project/sensors/voltage/S0_1V8_RC5A +63: + <<: *VOLTAGE_DEFAULTS + entityInstance: 7 + multiplierM: 7 + path: /xyz/openbmc_project/sensors/voltage/S0_0V75_PCP +64: + <<: *VOLTAGE_DEFAULTS + entityInstance: 8 + multiplierM: 6 + path: /xyz/openbmc_project/sensors/voltage/S0_1V1_VDDQ0123 +65: + <<: *VOLTAGE_DEFAULTS + entityInstance: 9 + multiplierM: 6 + path: /xyz/openbmc_project/sensors/voltage/S0_1V1_VDDQ4567 +66: + <<: *VOLTAGE_DEFAULTS + entityInstance: 10 + multiplierM: 10 + path: /xyz/openbmc_project/sensors/voltage/S0_1V8_SOC +67: + <<: *VOLTAGE_DEFAULTS + entityInstance: 11 + multiplierM: 8 + path: /xyz/openbmc_project/sensors/voltage/S0_1V2_SOC +68: + <<: *VOLTAGE_DEFAULTS + entityInstance: 12 + multiplierM: 5 + path: /xyz/openbmc_project/sensors/voltage/S0_EXT_VREF +69: + <<: *VOLTAGE_DEFAULTS + entityInstance: 13 + multiplierM: 5 + path: /xyz/openbmc_project/sensors/voltage/S1_0V8_D2D +70: + <<: *VOLTAGE_DEFAULTS + entityInstance: 14 + multiplierM: 5 + path: /xyz/openbmc_project/sensors/voltage/S1_0V85_SOC +71: + <<: *VOLTAGE_DEFAULTS + entityInstance: 15 + multiplierM: 5 + path: /xyz/openbmc_project/sensors/voltage/S1_0V85_RC_DDR0 +72: + <<: *VOLTAGE_DEFAULTS + entityInstance: 16 + multiplierM: 5 + path: /xyz/openbmc_project/sensors/voltage/S1_0V85_RC_DDR1 +73: + <<: *VOLTAGE_DEFAULTS + entityInstance: 17 + multiplierM: 5 + path: /xyz/openbmc_project/sensors/voltage/S1_0V9_RC5A +74: + <<: *VOLTAGE_DEFAULTS + entityInstance: 18 + multiplierM: 10 + path: /xyz/openbmc_project/sensors/voltage/S1_1V8_RC5A +75: + <<: *VOLTAGE_DEFAULTS + entityInstance: 19 + multiplierM: 7 + path: /xyz/openbmc_project/sensors/voltage/S1_0V75_PCP +76: + <<: *VOLTAGE_DEFAULTS + entityInstance: 20 + multiplierM: 6 + path: /xyz/openbmc_project/sensors/voltage/S1_1V1_VDDQ0123 +77: + <<: *VOLTAGE_DEFAULTS + entityInstance: 21 + multiplierM: 6 + path: /xyz/openbmc_project/sensors/voltage/S1_1V1_VDDQ4567 +78: + <<: *VOLTAGE_DEFAULTS + entityInstance: 22 + multiplierM: 10 + path: /xyz/openbmc_project/sensors/voltage/S1_1V8_SOC +79: + <<: *VOLTAGE_DEFAULTS + entityInstance: 23 + multiplierM: 8 + path: /xyz/openbmc_project/sensors/voltage/S1_1V2_SOC +80: + <<: *VOLTAGE_DEFAULTS + entityInstance: 24 + multiplierM: 5 + path: /xyz/openbmc_project/sensors/voltage/S1_EXT_VREF +81: + <<: *VOLTAGE_DEFAULTS + entityInstance: 25 + multiplierM: 80 + path: /xyz/openbmc_project/sensors/voltage/12V_S0 +82: + <<: *VOLTAGE_DEFAULTS + entityInstance: 26 + multiplierM: 80 + path: /xyz/openbmc_project/sensors/voltage/12V_S1 +83: + <<: *VOLTAGE_DEFAULTS + entityInstance: 27 + multiplierM: 80 + path: /xyz/openbmc_project/sensors/voltage/12V_SB +84: + <<: *VOLTAGE_DEFAULTS + entityInstance: 28 + multiplierM: 18 + path: /xyz/openbmc_project/sensors/voltage/3V3 +85: + <<: *VOLTAGE_DEFAULTS + entityInstance: 29 + multiplierM: 18 + path: /xyz/openbmc_project/sensors/voltage/3V3_SB +86: + <<: *VOLTAGE_DEFAULTS + entityInstance: 30 + multiplierM: 27 + path: /xyz/openbmc_project/sensors/voltage/5V +87: + <<: *VOLTAGE_DEFAULTS + entityInstance: 31 + multiplierM: 27 + path: /xyz/openbmc_project/sensors/voltage/5V_SB +88: + <<: *VOLTAGE_DEFAULTS + entityInstance: 32 + multiplierM: 18 + path: /xyz/openbmc_project/sensors/voltage/VBAT_RTC +89: + <<: *VOLTAGE_DEFAULTS + entityInstance: 33 + multiplierM: 18 + path: /xyz/openbmc_project/sensors/voltage/3V3_OCP0_SB +90: + <<: *VOLTAGE_DEFAULTS + entityInstance: 34 + multiplierM: 18 + path: /xyz/openbmc_project/sensors/voltage/3V3_OCP1_SB +91: + <<: *VOLTAGE_DEFAULTS + entityInstance: 35 + multiplierM: 80 + path: /xyz/openbmc_project/sensors/voltage/12V_OCP0_SB +92: + <<: *VOLTAGE_DEFAULTS + entityInstance: 36 + multiplierM: 80 + path: /xyz/openbmc_project/sensors/voltage/12V_OCP1_SB +93: + <<: *VOLTAGE_DEFAULTS + entityInstance: 37 + multiplierM: 80 + path: /xyz/openbmc_project/sensors/voltage/12V_HDD +94: + <<: *VOLTAGE_DEFAULTS + entityInstance: 38 + multiplierM: 80 + path: /xyz/openbmc_project/sensors/voltage/12V_FAN +95: + <<: *VOLTAGE_DEFAULTS + entityInstance: 39 + multiplierM: 80 + path: /xyz/openbmc_project/sensors/voltage/12V_PCIe +96: + <<: *VOLTAGE_DEFAULTS + entityInstance: 40 + multiplierM: 80 + path: /xyz/openbmc_project/sensors/voltage/12V_NIC_SB +97: + <<: *VOLTAGE_DEFAULTS + entityInstance: 41 + multiplierM: 80 + path: /xyz/openbmc_project/sensors/voltage/12V_GPU0 +98: + <<: *VOLTAGE_DEFAULTS + entityInstance: 42 + multiplierM: 80 + path: /xyz/openbmc_project/sensors/voltage/12V_GPU1 +99: + <<: *VOLTAGE_DEFAULTS + entityInstance: 43 + multiplierM: 80 + path: /xyz/openbmc_project/sensors/voltage/12V_GPU2 +100: + <<: *VOLTAGE_DEFAULTS + entityInstance: 44 + multiplierM: 10 + path: /xyz/openbmc_project/sensors/voltage/1V8_SB +101: + <<: *VOLTAGE_DEFAULTS + entityInstance: 45 + multiplierM: 6 + path: /xyz/openbmc_project/sensors/voltage/1V05_SB +102: + <<: *VOLTAGE_DEFAULTS + entityInstance: 46 + multiplierM: 8 + path: /xyz/openbmc_project/sensors/voltage/1V25_SB +103: + <<: *VOLTAGE_DEFAULTS + entityInstance: 47 + multiplierM: 18 + path: /xyz/openbmc_project/sensors/voltage/3V3_M2 +104: + <<: *VOLTAGE_DEFAULTS + entityInstance: 48 + multiplierM: 10 + path: /xyz/openbmc_project/sensors/voltage/12V_HDD_I +252: + <<: *VOLTAGE_DEFAULTS + entityInstance: 122 + multiplierM: 80 + path: /xyz/openbmc_project/sensors/voltage/12V_SB_BMC +253: + <<: *VOLTAGE_DEFAULTS + entityInstance: 123 + multiplierM: 27 + path: /xyz/openbmc_project/sensors/voltage/5V_SB_BMC +254: + <<: *VOLTAGE_DEFAULTS + entityInstance: 124 + multiplierM: 18 + path: /xyz/openbmc_project/sensors/voltage/3V3_SB_BMC + +122: + <<: *TEMP_DEFAULTS + entityID: 19 + entityInstance: 50 + path: /xyz/openbmc_project/sensors/temperature/S0_PCP_VR_Temp + +123: &power + sensorType: 0x08 + path: /xyz/openbmc_project/sensors/power/S0_PCP_VR_Pwr + entityID: 0x13 + entityInstance: 51 + sensorReadingType: 0x01 + multiplierM: 0x50 + offsetB: 0 + bExp: 0 + unit: xyz.openbmc_project.Sensor.Value.Unit.Watts + rExp: -2 + serviceInterface: org.freedesktop.DBus.Properties + readingType: readingData + interfaces: + xyz.openbmc_project.Sensor.Value: + Value: + Offsets: + 0xFF: + type: double + +129: ¤t + sensorType: 0x03 + path: /xyz/openbmc_project/sensors/current/S0_SOC_VR_Cur + entityID: 0x13 + entityInstance: 57 + sensorReadingType: 0x01 + multiplierM: 0x50 + offsetB: 0 + bExp: 0 + unit: xyz.openbmc_project.Sensor.Value.Unit.Amperes + rExp: -3 + serviceInterface: org.freedesktop.DBus.Properties + readingType: readingData + interfaces: + xyz.openbmc_project.Sensor.Value: + Value: + Offsets: + 0xFF: + type: double + +230: + <<: *VOLTAGE_DEFAULTS + entityInstance: 74 + multiplierM: 20 + rExp: -1 + path: /xyz/openbmc_project/sensors/voltage/PSU0_VINPUT +231: + <<: *VOLTAGE_DEFAULTS + entityInstance: 75 + multiplierM: 20 + rExp: -1 + path: /xyz/openbmc_project/sensors/voltage/PSU1_VINPUT +232: + <<: *VOLTAGE_DEFAULTS + entityInstance: 76 + multiplierM: 20 + rExp: -2 + path: /xyz/openbmc_project/sensors/voltage/PSU0_VOUTPUT +233: + <<: *VOLTAGE_DEFAULTS + entityInstance: 77 + multiplierM: 20 + rExp: -2 + path: /xyz/openbmc_project/sensors/voltage/PSU1_VOUTPUT +234: + <<: *current + entityInstance: 78 + multiplierM: 80 + path: /xyz/openbmc_project/sensors/current/PSU0_IINPUT +235: + <<: *current + entityInstance: 79 + multiplierM: 80 + path: /xyz/openbmc_project/sensors/current/PSU1_IINPUT +236: + <<: *current + entityInstance: 80 + multiplierM: 160 + path: /xyz/openbmc_project/sensors/current/PSU0_IOUTPUT +237: + <<: *current + entityInstance: 81 + multiplierM: 160 + path: /xyz/openbmc_project/sensors/current/PSU1_IOUTPUT +238: + <<: *power + entityInstance: 82 + multiplierM: 80 + rExp: -1 + path: /xyz/openbmc_project/sensors/power/PSU0_PINPUT +239: + <<: *power + entityInstance: 83 + multiplierM: 80 + rExp: -1 + path: /xyz/openbmc_project/sensors/power/PSU1_PINPUT +240: + <<: *power + entityInstance: 84 + multiplierM: 80 + rExp: -1 + path: /xyz/openbmc_project/sensors/power/PSU0_POUTPUT +241: + <<: *power + entityInstance: 85 + multiplierM: 80 + rExp: -1 + path: /xyz/openbmc_project/sensors/power/PSU1_POUTPUT +242: + <<: *power + entityInstance: 57 + multiplierM: 80 + rExp: -1 + path: /xyz/openbmc_project/sensors/power/total_power +243: + <<: *TEMP_DEFAULTS + entityID: 0x1e + entityInstance: 58 + path: /xyz/openbmc_project/sensors/temperature/PSU0_TEMP +244: + <<: *TEMP_DEFAULTS + entityID: 0x1e + entityInstance: 59 + path: /xyz/openbmc_project/sensors/temperature/PSU1_TEMP +245: + <<: *FAN_DEFAULTS + entityInstance: 60 + path: /xyz/openbmc_project/sensors/fan_tach/PSU0_fan1 +246: + <<: *FAN_DEFAULTS + entityInstance: 61 + path: /xyz/openbmc_project/sensors/fan_tach/PSU1_fan1 +250: + <<: *TEMP_DEFAULTS + entityID: 3 + entityInstance: 13 + path: /xyz/openbmc_project/sensors/temperature/S0_THDIODE_Temp +251: + <<: *TEMP_DEFAULTS + entityID: 3 + entityInstance: 14 + path: /xyz/openbmc_project/sensors/temperature/S1_THDIODE_Temp diff --git a/meta-ampere/meta-mitchell/recipes-phosphor/ipmi/phosphor-ipmi-host_%.bbappend b/meta-ampere/meta-mitchell/recipes-phosphor/ipmi/phosphor-ipmi-host_%.bbappend new file mode 100644 index 0000000000..7377e285e6 --- /dev/null +++ b/meta-ampere/meta-mitchell/recipes-phosphor/ipmi/phosphor-ipmi-host_%.bbappend @@ -0,0 +1,8 @@ +FILESEXTRAPATHS:append := "${THISDIR}/${PN}:" + +DEPENDS:append = " mtmitchell-yaml-config" + +EXTRA_OEMESON = " \ + -Dsensor-yaml-gen=${STAGING_DIR_HOST}${datadir}/mtmitchell-yaml-config/ipmi-sensors.yaml \ + -Dfru-yaml-gen=${STAGING_DIR_HOST}${datadir}/mtmitchell-yaml-config/ipmi-fru-read.yaml \ + " diff --git a/meta-ampere/meta-mitchell/recipes-phosphor/sensors/phosphor-virtual-sensor/mtmitchell_virtual_sensor_config.json b/meta-ampere/meta-mitchell/recipes-phosphor/sensors/phosphor-virtual-sensor/mtmitchell_virtual_sensor_config.json new file mode 100644 index 0000000000..c846a9187a --- /dev/null +++ b/meta-ampere/meta-mitchell/recipes-phosphor/sensors/phosphor-virtual-sensor/mtmitchell_virtual_sensor_config.json @@ -0,0 +1,179 @@ +[ + { + "Desc": + { + "Name": "total_power", + "SensorType": "power" + }, + "Threshold" : + { + }, + "Associations": + [ + [ + "chassis", + "all_sensors", + "/xyz/openbmc_project/inventory/system/board/Mt_Mitchell_Motherboard" + ], + [ + "inventory", + "sensors", + "/xyz/openbmc_project/inventory/system/board/Mt_Mitchell_Motherboard" + ] + ], + "Params": + { + "DbusParam": + [ + { + "ParamName": "P0", + "Desc": + { + "Name": "PSU0_POUTPUT", + "SensorType": "power" + } + }, + { + "ParamName": "P1", + "Desc": + { + "Name": "PSU1_POUTPUT", + "SensorType": "power" + } + } + ] + }, + "Expression": "(P0 == P0) ? ((P1 == P1) ? P0+P1 : P0 ) : P1" + }, + { + "Desc": + { + "Name": "OutletTemp", + "SensorType": "temperature" + }, + "Threshold" : + { + "CriticalHigh": 70 + }, + "Associations": + [ + [ + "board", + "all_sensors", + "/xyz/openbmc_project/inventory/system/board/Mt_Mitchell_Motherboard" + ], + [ + "inventory", + "sensors", + "/xyz/openbmc_project/inventory/system/board/Mt_Mitchell_Motherboard" + ] + ], + "Params": + { + "DbusParam": + [ + { + "ParamName": "P0", + "Desc": + { + "Name": "OutletTemp1", + "SensorType": "temperature" + } + }, + { + "ParamName": "P1", + "Desc": + { + "Name": "OutletTemp2", + "SensorType": "temperature" + } + } + ] + }, + "Expression": "(P0 + P1) >= 0 ? (P0 + P1) / 2 : NULL" + }, + { + "Desc":{ + "Name":"NVMeM2_MaxTemp", + "SensorType":"temperature" + }, + "Threshold" : + { + "CriticalHigh": 70 + }, + "Associations": + [ + [ + "chassis", + "all_sensors", + "/xyz/openbmc_project/inventory/system/board/Mt_Mitchell_Motherboard" + ], + [ + "inventory", + "sensors", + "/xyz/openbmc_project/inventory/system/board/Mt_Mitchell_Motherboard" + ] + ], + "Params":{ + "DbusParam": [ + { + "ParamName": "n0", + "Desc": { + "Name": "m2nvme0", + "SensorType": "temperature" + } + }, + { + "ParamName": "n1", + "Desc": { + "Name": "m2nvme1", + "SensorType": "temperature" + } + } + ] + }, + "Expression": "max((n0 == n0) ? n0 : 0,(n1 == n1) ? n1 : 0)" + }, + { + "Desc":{ + "Name":"OCP_MaxTemp", + "SensorType":"temperature" + }, + "Threshold" : + { + "CriticalHigh": 105 + }, + "Associations": + [ + [ + "chassis", + "all_sensors", + "/xyz/openbmc_project/inventory/system/board/Mt_Mitchell_Motherboard" + ], + [ + "inventory", + "sensors", + "/xyz/openbmc_project/inventory/system/board/Mt_Mitchell_Motherboard" + ] + ], + "Params":{ + "DbusParam": [ + { + "ParamName": "n1", + "Desc": { + "Name": "OCP1_Temp", + "SensorType": "temperature" + } + }, + { + "ParamName": "n2", + "Desc": { + "Name": "OCP2_Temp", + "SensorType": "temperature" + } + } + ] + }, + "Expression": "max((n1 == n1) ? n1 : 0,(n2 == n2) ? n2 : 0)" + } +] diff --git a/meta-ampere/meta-mitchell/recipes-phosphor/sensors/phosphor-virtual-sensor_%.bbappend b/meta-ampere/meta-mitchell/recipes-phosphor/sensors/phosphor-virtual-sensor_%.bbappend new file mode 100644 index 0000000000..093b8b11f0 --- /dev/null +++ b/meta-ampere/meta-mitchell/recipes-phosphor/sensors/phosphor-virtual-sensor_%.bbappend @@ -0,0 +1,11 @@ +FILESEXTRAPATHS:prepend := "${THISDIR}/${PN}:" + +SRC_URI:append = " \ + file://mtmitchell_virtual_sensor_config.json \ + " + +do_install:append() { + install -m 0644 ${WORKDIR}/mtmitchell_virtual_sensor_config.json \ + ${D}${datadir}/phosphor-virtual-sensor/virtual_sensor_config.json +} + diff --git a/meta-ampere/meta-mitchell/recipes-phosphor/skeleton/obmc-libobmc-intf_%.bbappend b/meta-ampere/meta-mitchell/recipes-phosphor/skeleton/obmc-libobmc-intf_%.bbappend index 331c244ab4..5973cdf148 100644 --- a/meta-ampere/meta-mitchell/recipes-phosphor/skeleton/obmc-libobmc-intf_%.bbappend +++ b/meta-ampere/meta-mitchell/recipes-phosphor/skeleton/obmc-libobmc-intf_%.bbappend @@ -1,10 +1,10 @@ FILESEXTRAPATHS:append := "${THISDIR}/${PN}:" SRC_URI += "\ - file://${MACHINE}_gpio_defs.json \ + file://mtmitchell_gpio_defs.json \ " do_install:append() { install -d ${D}${sysconfdir}/default/obmc/gpio/ - install -m 0644 ${WORKDIR}/${MACHINE}_gpio_defs.json ${D}/${sysconfdir}/default/obmc/gpio/gpio_defs.json + install -m 0644 ${WORKDIR}/mtmitchell_gpio_defs.json ${D}/${sysconfdir}/default/obmc/gpio/gpio_defs.json } |