blob: ee9dacf5aa9160dd3525d32de1d8c19cf697e6e0 [file] [log] [blame]
Sivas SRR81037942017-01-26 06:48:20 -06001*** Settings ***
2Documentation This suite is for Verifying BMC device tree.
3
George Keishingd8004f82022-03-29 08:56:11 -05004Resource ../lib/utils.robot
5Resource ../lib/openbmc_ffdc.robot
6Resource ../lib/ipmi_client.robot
Sivas SRR81037942017-01-26 06:48:20 -06007Library String
8
George Keishing06a8ee82023-10-17 15:54:15 +05309Test Setup Open Connection And Log In
10Test Teardown Run Keywords Close All Connections AND FFDC On Test Case Fail
Sivas SRR81037942017-01-26 06:48:20 -060011
12*** Variables ***
13${devicetree_base} /sys/firmware/devicetree/base/
14
15*** Test Cases ***
16Check BMC Model Property Is Set
Sivas SRR81037942017-01-26 06:48:20 -060017 [Documentation] Verify if the BMC Model is populated in the device tree.
18 [Tags] Check_BMC_Model_Property_Is_Set
19 [Template] Template Check Property
20
Sivas SRR81037942017-01-26 06:48:20 -060021 #Property
George Keishing5abfe602018-07-05 11:54:37 -050022 model
23
24
George Keishing5abfe602018-07-05 11:54:37 -050025Check BMC Compatible Property Is Set
Sivas SRR81037942017-01-26 06:48:20 -060026 [Documentation] Verify if the BMC compatible property is populated.
27 [Tags] Check_BMC_Compatible_Property_Is_Set
28 [Template] Template Check Property
29
Sivas SRR81037942017-01-26 06:48:20 -060030 #Property
George Keishing5abfe602018-07-05 11:54:37 -050031 compatible
32
33
34Check BMC CPU Name Property Is Set
Sivas SRR81037942017-01-26 06:48:20 -060035 [Documentation] Verify if the BMC CPU name property is populated.
36 [Tags] Check_BMC_CPU_Name_Property_Is_Set
37 [Template] Template Check Property
38
Sivas SRR81037942017-01-26 06:48:20 -060039 #Property
George Keishing5abfe602018-07-05 11:54:37 -050040 cpus/name
41
42
43Check BMC CPU Compatible Property Is Set
Sivas SRR81037942017-01-26 06:48:20 -060044 [Documentation] Verify if the BMC CPU compatible property is populated.
45 [Tags] Check_BMC_CPU_Compatible_Property_Is_Set
46 [Template] Template Check Property
47
Sivas SRR81037942017-01-26 06:48:20 -060048 #Property
George Keishing5abfe602018-07-05 11:54:37 -050049 cpus/cpu@0/compatible
50
51
52Check BMC Memory Name Property Is Set
Sivas SRR81037942017-01-26 06:48:20 -060053 [Documentation] Verify if the BMC Memory name property is populated.
54 [Tags] Check_BMC_Memory_Name_Property_Is_Set
55 [Template] Template Check Property
56
Sivas SRR81037942017-01-26 06:48:20 -060057 #Property
Sivas SRRd3b515b2019-01-15 23:31:35 -060058 memory@80000000/name
George Keishing5abfe602018-07-05 11:54:37 -050059
60
61Check BMC Memory Device Type Property Is Set
Sivas SRR81037942017-01-26 06:48:20 -060062 [Documentation] Verify if the BMC Memory Device Type property is
63 ... populated.
64 [Tags] Check_BMC_Memory_Device_Type_Property_Is_Set
65 [Template] Template Check Property
66
Sivas SRR81037942017-01-26 06:48:20 -060067 #Property
Sivas SRRd3b515b2019-01-15 23:31:35 -060068 memory@80000000/device_type
George Keishing5abfe602018-07-05 11:54:37 -050069
70
71Check BMC FSI Name Property Is Set
Sivas SRR81037942017-01-26 06:48:20 -060072 [Documentation] Verify if the BMC FSI name property is populated.
73 [Tags] Check_BMC_FSI_Name_Property_Is_Set
74 [Template] Template Check Property
75
Sivas SRR81037942017-01-26 06:48:20 -060076 #Property
Sivas SRR37f93112019-06-19 03:18:07 -050077 gpio-fsi/name
George Keishing5abfe602018-07-05 11:54:37 -050078
79
80Check BMC FSI Compatible Property Is Set
Sivas SRR81037942017-01-26 06:48:20 -060081 [Documentation] Verify if the BMC FSI compatible property is populated.
82 [Tags] Check_BMC_FSI_Compatible_Property_Is_Set
83 [Template] Template Check Property
84
Sivas SRR01c7dc32017-06-24 02:24:23 -050085 #Property
Sivas SRR37f93112019-06-19 03:18:07 -050086 gpio-fsi/compatible
George Keishing5abfe602018-07-05 11:54:37 -050087
88
George Keishing5236ec52022-01-31 12:07:58 -060089Check BMC GPIO FSI Name Property Is Set
Sivas SRR01c7dc32017-06-24 02:24:23 -050090 [Documentation] Verify if the BMC GPIO-FSI name property is populated.
91 [Tags] Check_BMC_GPIO_FSI_Name_Property_Is_Set
92 [Template] Template Check Property
93
Sivas SRR01c7dc32017-06-24 02:24:23 -050094 #Property
George Keishing5abfe602018-07-05 11:54:37 -050095 gpio-fsi/name
96
97
George Keishing5236ec52022-01-31 12:07:58 -060098Check BMC GPIO FSI Compatible Property Is Set
Sivas SRR01c7dc32017-06-24 02:24:23 -050099 [Documentation] Verify if the BMC GPIO-FSI compatible property is populated.
100 [Tags] Check_BMC_GPIO_FSI_Compatible_Property_Is_Set
101 [Template] Template Check Property
102
Sivas SRRfbe34dd2017-06-29 11:03:12 -0500103 #Property
George Keishing5abfe602018-07-05 11:54:37 -0500104 gpio-fsi/compatible
105
106
George Keishing5236ec52022-01-31 12:07:58 -0600107Check BMC GPIO Keys Name Property Is Set
Sivas SRRfbe34dd2017-06-29 11:03:12 -0500108 [Documentation] Verify if the BMC GPIO-keys name property is
109 ... populated.
George Keishing5236ec52022-01-31 12:07:58 -0600110 [Tags] Check_BMC_GPIO_Keys_Name_Property_Is_Set
Sivas SRRfbe34dd2017-06-29 11:03:12 -0500111 [Template] Template Check Property
112
Sivas SRRfbe34dd2017-06-29 11:03:12 -0500113 #Property
George Keishing5abfe602018-07-05 11:54:37 -0500114 gpio-keys/name
115
116
George Keishing5236ec52022-01-31 12:07:58 -0600117Check BMC GPIO Keys Compatible Property Is Set
Sivas SRRfbe34dd2017-06-29 11:03:12 -0500118 [Documentation] Verify if the BMC GPIO-keys compatible property is
119 ... populated.
George Keishing5236ec52022-01-31 12:07:58 -0600120 [Tags] Check_BMC_GPIO_Keys_Compatible_Property_Is_Set
Sivas SRRfbe34dd2017-06-29 11:03:12 -0500121 [Template] Template Check Property
122
Sivas SRRfbe34dd2017-06-29 11:03:12 -0500123 #Property
George Keishing5abfe602018-07-05 11:54:37 -0500124 gpio-keys/compatible
125
126
127Check BMC IIO-HWMON Name Property Is Set
Sivas SRRf4f533b2017-07-30 11:42:12 -0500128 [Documentation] Verify if the BMC IIO-HWMON-DPS310 name property is
Sivas SRRfbe34dd2017-06-29 11:03:12 -0500129 ... populated.
130 [Tags] Check_BMC_IIO-HWMON_Name_Property_Is_Set
131 [Template] Template Check Property
132
Sivas SRRfbe34dd2017-06-29 11:03:12 -0500133 #Property
George Keishing5abfe602018-07-05 11:54:37 -0500134 iio-hwmon-dps310/name
135
136
137Check BMC IIO-HWMON Compatible Property Is Set
Sivas SRRf4f533b2017-07-30 11:42:12 -0500138 [Documentation] Verify if the BMC IIO-HWMON-DPS310 compatible property is
Sivas SRRfbe34dd2017-06-29 11:03:12 -0500139 ... populated.
140 [Tags] Check_BMC_IIO-HWMON_Compatible_Property_Is_Set
141 [Template] Template Check Property
142
Sivas SRR81037942017-01-26 06:48:20 -0600143 #Property
George Keishing5abfe602018-07-05 11:54:37 -0500144 iio-hwmon-dps310/compatible
145
146
147Check BMC LED Name Property Is Set
Sivas SRR81037942017-01-26 06:48:20 -0600148 [Documentation] Verify if the BMC LED name property is populated.
149 [Tags] Check_BMC_LED_Name_Property_Is_Set
150 [Template] Template Check Property
151
Sivas SRR81037942017-01-26 06:48:20 -0600152 #Property
George Keishing5abfe602018-07-05 11:54:37 -0500153 leds/name
154
155
156Check BMC LED Compatible Property Is Set
Sivas SRR81037942017-01-26 06:48:20 -0600157 [Documentation] Verify if the BMC LED compatible property is populated.
158 [Tags] Check_BMC_LED_Compatible_Property_Is_Set
159 [Template] Template Check Property
160
Sivas SRR81037942017-01-26 06:48:20 -0600161 #Property
George Keishing5abfe602018-07-05 11:54:37 -0500162 leds/compatible
163
164
Sivas SRR81037942017-01-26 06:48:20 -0600165*** Keywords ***
166
167Template Check Property
168 [Documentation] Check for the existence of a property in the device tree.
169 [Arguments] ${property}
170 #property: Value of Property
171
172 ${devicetree_path}= Catenate SEPARATOR=
173 ... ${devicetree_base} ${property}
174 ${output} ${stderr}= Execute Command cat ${devicetree_path}
175 ... return_stderr=True
176 Should Be Empty ${stderr}
177 ${length}= Get Length ${output}
178 Should Be True ${length} > 1
Rahul Maheshwari06174f22017-03-06 03:17:09 -0600179