blob: b883086266fc1026bde331c756222d2cad75d18f [file] [log] [blame]
George Keishinge7e91712021-09-03 11:28:44 -05001#!/usr/bin/env python3
Rahul Maheshwaria17a3392020-03-02 04:51:52 -06002
3r"""
4Contains PEL related constants.
5"""
6
7PEL_DETAILS = {
Patrick Williams20f38712022-12-08 06:18:26 -06008 "CreatorID": "BMC",
9 "CompID": "0x1000",
10 "Subsystem": "Platform Firmware",
11 "Message": "This is a test error",
12 "SRC": "BD8D1002",
13 "Sev": "Unrecoverable Error",
14}
Rahul Maheshwarib8580dd2021-05-10 00:57:33 -050015
Patrick Williams20f38712022-12-08 06:18:26 -060016ERROR_LOG_CREATE_BASE_CMD = (
17 "busctl call xyz.openbmc_project.Logging /xyz/openbmc_project/logging "
18 " xyz.openbmc_project.Logging.Create Create ssa{ss} "
19)
Rahul Maheshwarib8580dd2021-05-10 00:57:33 -050020
Patrick Williams20f38712022-12-08 06:18:26 -060021CMD_INTERNAL_FAILURE = (
22 ERROR_LOG_CREATE_BASE_CMD
23 + "xyz.openbmc_project.Common.Error.InternalFailure "
24 " xyz.openbmc_project.Logging.Entry.Level.Error 0"
25)
Rahul Maheshwarib8580dd2021-05-10 00:57:33 -050026
Patrick Williams20f38712022-12-08 06:18:26 -060027CMD_FRU_CALLOUT = (
28 ERROR_LOG_CREATE_BASE_CMD
29 + "xyz.openbmc_project.Sensor.Device.Error.ReadFailure "
30 ' xyz.openbmc_project.Logging.Entry.Level.Error 2 "TIMEOUT_IN_MSEC" "5"'
31 ' "CALLOUT_INVENTORY_PATH" '
32 ' "/xyz/openbmc_project/inventory/system/chassis/motherboard"'
33)
Rahul Maheshwarib8580dd2021-05-10 00:57:33 -050034
Patrick Williams20f38712022-12-08 06:18:26 -060035CMD_PROCEDURAL_SYMBOLIC_FRU_CALLOUT = (
George Keishing7899a452023-02-15 02:46:54 -060036 ERROR_LOG_CREATE_BASE_CMD + "org.open_power.Logging.Error.TestError1 "
Patrick Williams20f38712022-12-08 06:18:26 -060037 " xyz.openbmc_project.Logging.Entry.Level.Error 0"
38)
Rahul Maheshwarib8580dd2021-05-10 00:57:33 -050039
Patrick Williams20f38712022-12-08 06:18:26 -060040CMD_INFORMATIONAL_ERROR = (
41 ERROR_LOG_CREATE_BASE_CMD
42 + "xyz.openbmc_project.Common.Error.TestError2 "
43 " xyz.openbmc_project.Logging.Entry.Level.Informational 0"
44)
Rahul Maheshwarib8580dd2021-05-10 00:57:33 -050045
Patrick Williams20f38712022-12-08 06:18:26 -060046CMD_INVENTORY_PREFIX = (
47 "busctl get-property xyz.openbmc_project.Inventory.Manager "
48 " /xyz/openbmc_project/inventory/system/chassis/motherboard"
49)
Rahul Maheshwarib8580dd2021-05-10 00:57:33 -050050
Patrick Williams20f38712022-12-08 06:18:26 -060051CMD_UNRECOVERABLE_ERROR = (
George Keishing7899a452023-02-15 02:46:54 -060052 ERROR_LOG_CREATE_BASE_CMD + "org.open_power.Logging.Error.TestError1 "
Patrick Williams20f38712022-12-08 06:18:26 -060053 " xyz.openbmc_project.Logging.Entry.Level.Error 0"
54)
Rahul Maheshwarib8580dd2021-05-10 00:57:33 -050055
Patrick Williams20f38712022-12-08 06:18:26 -060056CMD_PREDICTIVE_ERROR = (
57 ERROR_LOG_CREATE_BASE_CMD
58 + "xyz.openbmc_project.Sensor.Threshold.Error.TemperatureWarningLow "
59 " xyz.openbmc_project.Logging.Entry.Level.Warning 0"
60)
Rahul Maheshwarib8580dd2021-05-10 00:57:33 -050061
Patrick Williams20f38712022-12-08 06:18:26 -060062CMD_UNRECOVERABLE_HOST_ERROR = (
George Keishing7899a452023-02-15 02:46:54 -060063 ERROR_LOG_CREATE_BASE_CMD + "xyz.openbmc_project.Host.Error.Event "
Patrick Williams20f38712022-12-08 06:18:26 -060064 " xyz.openbmc_project.Logging.Entry.Level.Error 1 RAWPEL"
65 " /tmp/FILE_NBMC_UNRECOVERABLE"
66)
manashsarma4baa6a72020-12-16 07:13:37 -060067
Patrick Williams20f38712022-12-08 06:18:26 -060068CMD_INFORMATIONAL_HOST_ERROR = (
George Keishing7899a452023-02-15 02:46:54 -060069 ERROR_LOG_CREATE_BASE_CMD + "xyz.openbmc_project.Host.Error.Event "
Patrick Williams20f38712022-12-08 06:18:26 -060070 " xyz.openbmc_project.Logging.Entry.Level.Error 1 RAWPEL"
71 " /tmp/FILE_HOST_INFORMATIONAL"
72)