Skip to content

Commit

Permalink
meta-ampere: mtmitchell: handle fan fault
Browse files Browse the repository at this point in the history
Handle FAN fault check using phosphor-led-manager which monitors the
xyz.openbmc_project.State.Decorator.OperationalStatus interface and
assert the configured LED group.

Tested:
1. Unplug the fan and verify that both `Fan Fault Led` and `Fault Led`
   are turned on.
2. Plug the fan and verify that both `Fan Fault Led` and `Fault Led` are
   turned off.

Signed-off-by: Hieu Huynh <[email protected]>
Signed-off-by: HuyLe <[email protected]>
  • Loading branch information
hieuhuynh-ampere authored and thangqn-ampere committed Jan 31, 2024
1 parent e8cc60d commit 6236c94
Show file tree
Hide file tree
Showing 2 changed files with 156 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,15 @@
"/xyz/openbmc_project/sensors/fan_tach/FAN0_R"
]
},
{
"types": {
"rType": "fault_identified_by",
"fType": "fault_identifying"
},
"paths": [
"/xyz/openbmc_project/led/groups/fan0_fault"
]
},
{
"types":
{
Expand Down Expand Up @@ -190,6 +199,15 @@
"/xyz/openbmc_project/sensors/fan_tach/FAN1_R"
]
},
{
"types": {
"rType": "fault_identified_by",
"fType": "fault_identifying"
},
"paths": [
"/xyz/openbmc_project/led/groups/fan1_fault"
]
},
{
"types":
{
Expand Down Expand Up @@ -219,6 +237,15 @@
"/xyz/openbmc_project/sensors/fan_tach/FAN2_R"
]
},
{
"types": {
"rType": "fault_identified_by",
"fType": "fault_identifying"
},
"paths": [
"/xyz/openbmc_project/led/groups/fan2_fault"
]
},
{
"types":
{
Expand Down Expand Up @@ -248,6 +275,15 @@
"/xyz/openbmc_project/sensors/fan_tach/FAN3_R"
]
},
{
"types": {
"rType": "fault_identified_by",
"fType": "fault_identifying"
},
"paths": [
"/xyz/openbmc_project/led/groups/fan3_fault"
]
},
{
"types":
{
Expand Down Expand Up @@ -277,6 +313,15 @@
"/xyz/openbmc_project/sensors/fan_tach/FAN4_R"
]
},
{
"types": {
"rType": "fault_identified_by",
"fType": "fault_identifying"
},
"paths": [
"/xyz/openbmc_project/led/groups/fan4_fault"
]
},
{
"types":
{
Expand Down Expand Up @@ -306,6 +351,15 @@
"/xyz/openbmc_project/sensors/fan_tach/FAN5_R"
]
},
{
"types": {
"rType": "fault_identified_by",
"fType": "fault_identifying"
},
"paths": [
"/xyz/openbmc_project/led/groups/fan5_fault"
]
},
{
"types":
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,108 @@
}
]
},
{
"group": "fan0_fault",
"members": [
{
"Name": "fan_fault",
"Action": "On",
"DutyOn": 50,
"Period": 1000
},
{
"Name": "fault",
"Action": "On",
"DutyOn": 50,
"Period": 1000
}
]
},
{
"group": "fan1_fault",
"members": [
{
"Name": "fan_fault",
"Action": "On",
"DutyOn": 50,
"Period": 1000
},
{
"Name": "fault",
"Action": "On",
"DutyOn": 50,
"Period": 1000
}
]
},
{
"group": "fan2_fault",
"members": [
{
"Name": "fan_fault",
"Action": "On",
"DutyOn": 50,
"Period": 1000
},
{
"Name": "fault",
"Action": "On",
"DutyOn": 50,
"Period": 1000
}
]
},
{
"group": "fan3_fault",
"members": [
{
"Name": "fan_fault",
"Action": "On",
"DutyOn": 50,
"Period": 1000
},
{
"Name": "fault",
"Action": "On",
"DutyOn": 50,
"Period": 1000
}
]
},
{
"group": "fan4_fault",
"members": [
{
"Name": "fan_fault",
"Action": "On",
"DutyOn": 50,
"Period": 1000
},
{
"Name": "fault",
"Action": "On",
"DutyOn": 50,
"Period": 1000
}
]
},
{
"group": "fan5_fault",
"members": [
{
"Name": "fan_fault",
"Action": "On",
"DutyOn": 50,
"Period": 1000
},
{
"Name": "fault",
"Action": "On",
"DutyOn": 50,
"Period": 1000
}
]
},
{
"group": "psu_fault",
"members": [
Expand Down

0 comments on commit 6236c94

Please sign in to comment.