George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 1 | #! /usr/bin/python |
| 2 | |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 3 | ## System states |
| 4 | ## state can change to next state in 2 ways: |
| 5 | ## - a process emits a GotoSystemState signal with state name to goto |
| 6 | ## - objects specified in EXIT_STATE_DEPEND have started |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 7 | SYSTEM_STATES = [ |
| 8 | 'BASE_APPS', |
| 9 | 'BMC_STARTING', |
| 10 | 'BMC_READY', |
| 11 | 'HOST_POWERING_ON', |
| 12 | 'HOST_POWERED_ON', |
| 13 | 'HOST_BOOTING', |
| 14 | 'HOST_BOOTED', |
| 15 | 'HOST_POWERED_OFF', |
| 16 | ] |
| 17 | |
| 18 | EXIT_STATE_DEPEND = { |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 19 | 'BASE_APPS' : { |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 20 | '/org/openbmc/sensors': 0, |
| 21 | }, |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 22 | 'BMC_STARTING' : { |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 23 | '/org/openbmc/control/chassis0': 0, |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 24 | '/org/openbmc/control/power0' : 0, |
| 25 | '/org/openbmc/control/flash/bios' : 0, |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 26 | }, |
| 27 | } |
| 28 | |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 29 | FRU_INSTANCES = { |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 30 | '<inventory_root>/system' : { 'fru_type' : 'SYSTEM','is_fru' : True, 'present' : "True" }, |
| 31 | '<inventory_root>/system/bios' : { 'fru_type' : 'SYSTEM','is_fru' : True, 'present' : "True" }, |
| 32 | '<inventory_root>/system/misc' : { 'fru_type' : 'SYSTEM','is_fru' : False, }, |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 33 | |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 34 | '<inventory_root>/system/chassis' : { 'fru_type' : 'SYSTEM','is_fru' : True, 'present' : "True" }, |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 35 | |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 36 | '<inventory_root>/system/chassis/motherboard' : { 'fru_type' : 'MAIN_PLANAR','is_fru' : True, }, |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 37 | |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 38 | '<inventory_root>/system/systemevent' : { 'fru_type' : 'SYSTEM_EVENT', 'is_fru' : False, }, |
| 39 | '<inventory_root>/system/chassis/motherboard/refclock' : { 'fru_type' : 'MAIN_PLANAR', 'is_fru' : False, }, |
| 40 | '<inventory_root>/system/chassis/motherboard/pcieclock': { 'fru_type' : 'MAIN_PLANAR', 'is_fru' : False, }, |
| 41 | '<inventory_root>/system/chassis/motherboard/todclock' : { 'fru_type' : 'MAIN_PLANAR', 'is_fru' : False, }, |
| 42 | '<inventory_root>/system/chassis/motherboard/apss' : { 'fru_type' : 'MAIN_PLANAR', 'is_fru' : False, }, |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 43 | |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 44 | '<inventory_root>/system/chassis/fan0' : { 'fru_type' : 'FAN','is_fru' : True, }, |
| 45 | '<inventory_root>/system/chassis/fan1' : { 'fru_type' : 'FAN','is_fru' : True, }, |
| 46 | '<inventory_root>/system/chassis/fan2' : { 'fru_type' : 'FAN','is_fru' : True, }, |
| 47 | '<inventory_root>/system/chassis/fan3' : { 'fru_type' : 'FAN','is_fru' : True, }, |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 48 | |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 49 | '<inventory_root>/system/chassis/motherboard/bmc' : { 'fru_type' : 'BMC','is_fru' : False, 'manufacturer' : 'ASPEED' }, |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 50 | |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 51 | '<inventory_root>/system/chassis/motherboard/cpu0' : { 'fru_type' : 'CPU', 'is_fru' : True, }, |
| 52 | '<inventory_root>/system/chassis/motherboard/cpu1' : { 'fru_type' : 'CPU', 'is_fru' : True, }, |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 53 | |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 54 | '<inventory_root>/system/chassis/motherboard/cpu0/core0' : { 'fru_type' : 'CORE', 'is_fru' : False, }, |
| 55 | '<inventory_root>/system/chassis/motherboard/cpu0/core1' : { 'fru_type' : 'CORE', 'is_fru' : False, }, |
| 56 | '<inventory_root>/system/chassis/motherboard/cpu0/core2' : { 'fru_type' : 'CORE', 'is_fru' : False, }, |
| 57 | '<inventory_root>/system/chassis/motherboard/cpu0/core3' : { 'fru_type' : 'CORE', 'is_fru' : False, }, |
| 58 | '<inventory_root>/system/chassis/motherboard/cpu0/core4' : { 'fru_type' : 'CORE', 'is_fru' : False, }, |
| 59 | '<inventory_root>/system/chassis/motherboard/cpu0/core5' : { 'fru_type' : 'CORE', 'is_fru' : False, }, |
| 60 | '<inventory_root>/system/chassis/motherboard/cpu0/core6' : { 'fru_type' : 'CORE', 'is_fru' : False, }, |
| 61 | '<inventory_root>/system/chassis/motherboard/cpu0/core7' : { 'fru_type' : 'CORE', 'is_fru' : False, }, |
| 62 | '<inventory_root>/system/chassis/motherboard/cpu0/core8' : { 'fru_type' : 'CORE', 'is_fru' : False, }, |
| 63 | '<inventory_root>/system/chassis/motherboard/cpu0/core9' : { 'fru_type' : 'CORE', 'is_fru' : False, }, |
| 64 | '<inventory_root>/system/chassis/motherboard/cpu0/core10': { 'fru_type' : 'CORE', 'is_fru' : False, }, |
| 65 | '<inventory_root>/system/chassis/motherboard/cpu0/core11': { 'fru_type' : 'CORE', 'is_fru' : False, }, |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 66 | |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 67 | '<inventory_root>/system/chassis/motherboard/cpu1/core0' : { 'fru_type' : 'CORE', 'is_fru' : False, }, |
| 68 | '<inventory_root>/system/chassis/motherboard/cpu1/core1' : { 'fru_type' : 'CORE', 'is_fru' : False, }, |
| 69 | '<inventory_root>/system/chassis/motherboard/cpu1/core2' : { 'fru_type' : 'CORE', 'is_fru' : False, }, |
| 70 | '<inventory_root>/system/chassis/motherboard/cpu1/core3' : { 'fru_type' : 'CORE', 'is_fru' : False, }, |
| 71 | '<inventory_root>/system/chassis/motherboard/cpu1/core4' : { 'fru_type' : 'CORE', 'is_fru' : False, }, |
| 72 | '<inventory_root>/system/chassis/motherboard/cpu1/core5' : { 'fru_type' : 'CORE', 'is_fru' : False, }, |
| 73 | '<inventory_root>/system/chassis/motherboard/cpu1/core6' : { 'fru_type' : 'CORE', 'is_fru' : False, }, |
| 74 | '<inventory_root>/system/chassis/motherboard/cpu1/core7' : { 'fru_type' : 'CORE', 'is_fru' : False, }, |
| 75 | '<inventory_root>/system/chassis/motherboard/cpu1/core8' : { 'fru_type' : 'CORE', 'is_fru' : False, }, |
| 76 | '<inventory_root>/system/chassis/motherboard/cpu1/core9' : { 'fru_type' : 'CORE', 'is_fru' : False, }, |
| 77 | '<inventory_root>/system/chassis/motherboard/cpu1/core10' : { 'fru_type' : 'CORE', 'is_fru' : False, }, |
| 78 | '<inventory_root>/system/chassis/motherboard/cpu1/core11' : { 'fru_type' : 'CORE', 'is_fru' : False, }, |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 79 | |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 80 | '<inventory_root>/system/chassis/motherboard/membuf0' : { 'fru_type' : 'MEMORY_BUFFER', 'is_fru' : False, }, |
| 81 | '<inventory_root>/system/chassis/motherboard/membuf1' : { 'fru_type' : 'MEMORY_BUFFER', 'is_fru' : False, }, |
| 82 | '<inventory_root>/system/chassis/motherboard/membuf2' : { 'fru_type' : 'MEMORY_BUFFER', 'is_fru' : False, }, |
| 83 | '<inventory_root>/system/chassis/motherboard/membuf3' : { 'fru_type' : 'MEMORY_BUFFER', 'is_fru' : False, }, |
| 84 | '<inventory_root>/system/chassis/motherboard/membuf4' : { 'fru_type' : 'MEMORY_BUFFER', 'is_fru' : False, }, |
| 85 | '<inventory_root>/system/chassis/motherboard/membuf5' : { 'fru_type' : 'MEMORY_BUFFER', 'is_fru' : False, }, |
| 86 | '<inventory_root>/system/chassis/motherboard/membuf6' : { 'fru_type' : 'MEMORY_BUFFER', 'is_fru' : False, }, |
| 87 | '<inventory_root>/system/chassis/motherboard/membuf7' : { 'fru_type' : 'MEMORY_BUFFER', 'is_fru' : False, }, |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 88 | |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 89 | '<inventory_root>/system/chassis/motherboard/dimm0' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 90 | '<inventory_root>/system/chassis/motherboard/dimm1' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 91 | '<inventory_root>/system/chassis/motherboard/dimm2' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 92 | '<inventory_root>/system/chassis/motherboard/dimm3' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 93 | '<inventory_root>/system/chassis/motherboard/dimm4' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 94 | '<inventory_root>/system/chassis/motherboard/dimm5' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 95 | '<inventory_root>/system/chassis/motherboard/dimm6' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 96 | '<inventory_root>/system/chassis/motherboard/dimm7' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 97 | '<inventory_root>/system/chassis/motherboard/dimm8' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 98 | '<inventory_root>/system/chassis/motherboard/dimm9' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 99 | '<inventory_root>/system/chassis/motherboard/dimm10' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 100 | '<inventory_root>/system/chassis/motherboard/dimm11' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 101 | '<inventory_root>/system/chassis/motherboard/dimm12' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 102 | '<inventory_root>/system/chassis/motherboard/dimm13' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 103 | '<inventory_root>/system/chassis/motherboard/dimm14' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 104 | '<inventory_root>/system/chassis/motherboard/dimm15' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 105 | '<inventory_root>/system/chassis/motherboard/dimm16' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 106 | '<inventory_root>/system/chassis/motherboard/dimm17' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 107 | '<inventory_root>/system/chassis/motherboard/dimm18' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 108 | '<inventory_root>/system/chassis/motherboard/dimm19' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 109 | '<inventory_root>/system/chassis/motherboard/dimm20' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 110 | '<inventory_root>/system/chassis/motherboard/dimm21' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 111 | '<inventory_root>/system/chassis/motherboard/dimm22' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 112 | '<inventory_root>/system/chassis/motherboard/dimm23' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 113 | '<inventory_root>/system/chassis/motherboard/dimm24' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 114 | '<inventory_root>/system/chassis/motherboard/dimm25' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 115 | '<inventory_root>/system/chassis/motherboard/dimm26' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 116 | '<inventory_root>/system/chassis/motherboard/dimm27' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 117 | '<inventory_root>/system/chassis/motherboard/dimm28' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 118 | '<inventory_root>/system/chassis/motherboard/dimm29' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 119 | '<inventory_root>/system/chassis/motherboard/dimm30' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
| 120 | '<inventory_root>/system/chassis/motherboard/dimm31' : { 'fru_type' : 'DIMM', 'is_fru' : True,}, |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 121 | } |
| 122 | |
| 123 | ID_LOOKUP = { |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 124 | 'FRU' : { |
| 125 | 0x01 : '<inventory_root>/system/chassis/motherboard/cpu0', |
| 126 | 0x02 : '<inventory_root>/system/chassis/motherboard/cpu1', |
| 127 | 0x03 : '<inventory_root>/system/chassis/motherboard', |
| 128 | 0x04 : '<inventory_root>/system/chassis/motherboard/membuf0', |
| 129 | 0x05 : '<inventory_root>/system/chassis/motherboard/membuf1', |
| 130 | 0x06 : '<inventory_root>/system/chassis/motherboard/membuf2', |
| 131 | 0x07 : '<inventory_root>/system/chassis/motherboard/membuf3', |
| 132 | 0x08 : '<inventory_root>/system/chassis/motherboard/membuf4', |
| 133 | 0x09 : '<inventory_root>/system/chassis/motherboard/membuf5', |
| 134 | 0x0c : '<inventory_root>/system/chassis/motherboard/dimm0', |
| 135 | 0x0d : '<inventory_root>/system/chassis/motherboard/dimm1', |
| 136 | 0x0e : '<inventory_root>/system/chassis/motherboard/dimm2', |
| 137 | 0x0f : '<inventory_root>/system/chassis/motherboard/dimm3', |
| 138 | 0x10 : '<inventory_root>/system/chassis/motherboard/dimm4', |
| 139 | 0x11 : '<inventory_root>/system/chassis/motherboard/dimm5', |
| 140 | 0x12 : '<inventory_root>/system/chassis/motherboard/dimm6', |
| 141 | 0x13 : '<inventory_root>/system/chassis/motherboard/dimm7', |
| 142 | 0x14 : '<inventory_root>/system/chassis/motherboard/dimm8', |
| 143 | 0x15 : '<inventory_root>/system/chassis/motherboard/dimm9', |
| 144 | 0x16 : '<inventory_root>/system/chassis/motherboard/dimm10', |
| 145 | 0x17 : '<inventory_root>/system/chassis/motherboard/dimm11', |
| 146 | 0x18 : '<inventory_root>/system/chassis/motherboard/dimm12', |
| 147 | 0x19 : '<inventory_root>/system/chassis/motherboard/dimm13', |
| 148 | 0x1a : '<inventory_root>/system/chassis/motherboard/dimm14', |
| 149 | 0x1b : '<inventory_root>/system/chassis/motherboard/dimm15', |
| 150 | 0x1c : '<inventory_root>/system/chassis/motherboard/dimm16', |
| 151 | 0x1d : '<inventory_root>/system/chassis/motherboard/dimm17', |
| 152 | 0x1e : '<inventory_root>/system/chassis/motherboard/dimm18', |
| 153 | 0x1f : '<inventory_root>/system/chassis/motherboard/dimm19', |
| 154 | 0x20 : '<inventory_root>/system/chassis/motherboard/dimm20', |
| 155 | 0x21 : '<inventory_root>/system/chassis/motherboard/dimm21', |
| 156 | 0x22 : '<inventory_root>/system/chassis/motherboard/dimm22', |
| 157 | 0x23 : '<inventory_root>/system/chassis/motherboard/dimm23', |
| 158 | 0x24 : '<inventory_root>/system/chassis/motherboard/dimm24', |
| 159 | 0x25 : '<inventory_root>/system/chassis/motherboard/dimm25', |
| 160 | 0x26 : '<inventory_root>/system/chassis/motherboard/dimm26', |
| 161 | 0x27 : '<inventory_root>/system/chassis/motherboard/dimm27', |
| 162 | 0x28 : '<inventory_root>/system/chassis/motherboard/dimm28', |
| 163 | 0x29 : '<inventory_root>/system/chassis/motherboard/dimm29', |
| 164 | 0x2a : '<inventory_root>/system/chassis/motherboard/dimm30', |
| 165 | 0x2b : '<inventory_root>/system/chassis/motherboard/dimm31', |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 166 | }, |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 167 | 'FRU_STR' : { |
| 168 | 'PRODUCT_0' : '<inventory_root>/system/bios', |
| 169 | 'BOARD_1' : '<inventory_root>/system/chassis/motherboard/cpu0', |
| 170 | 'BOARD_2' : '<inventory_root>/system/chassis/motherboard/cpu1', |
| 171 | 'CHASSIS_3' : '<inventory_root>/system/chassis/motherboard', |
| 172 | 'BOARD_3' : '<inventory_root>/system/misc', |
| 173 | 'BOARD_4' : '<inventory_root>/system/chassis/motherboard/membuf0', |
| 174 | 'BOARD_5' : '<inventory_root>/system/chassis/motherboard/membuf1', |
| 175 | 'BOARD_6' : '<inventory_root>/system/chassis/motherboard/membuf2', |
| 176 | 'BOARD_7' : '<inventory_root>/system/chassis/motherboard/membuf3', |
| 177 | 'BOARD_8' : '<inventory_root>/system/chassis/motherboard/membuf4', |
| 178 | 'BOARD_9' : '<inventory_root>/system/chassis/motherboard/membuf5', |
| 179 | 'BOARD_10' : '<inventory_root>/system/chassis/motherboard/membuf6', |
| 180 | 'BOARD_11' : '<inventory_root>/system/chassis/motherboard/membuf7', |
| 181 | 'PRODUCT_12' : '<inventory_root>/system/chassis/motherboard/dimm0', |
| 182 | 'PRODUCT_13' : '<inventory_root>/system/chassis/motherboard/dimm1', |
| 183 | 'PRODUCT_14' : '<inventory_root>/system/chassis/motherboard/dimm2', |
| 184 | 'PRODUCT_15' : '<inventory_root>/system/chassis/motherboard/dimm3', |
| 185 | 'PRODUCT_16' : '<inventory_root>/system/chassis/motherboard/dimm4', |
| 186 | 'PRODUCT_17' : '<inventory_root>/system/chassis/motherboard/dimm5', |
| 187 | 'PRODUCT_18' : '<inventory_root>/system/chassis/motherboard/dimm6', |
| 188 | 'PRODUCT_19' : '<inventory_root>/system/chassis/motherboard/dimm7', |
| 189 | 'PRODUCT_20' : '<inventory_root>/system/chassis/motherboard/dimm8', |
| 190 | 'PRODUCT_21' : '<inventory_root>/system/chassis/motherboard/dimm9', |
| 191 | 'PRODUCT_22' : '<inventory_root>/system/chassis/motherboard/dimm10', |
| 192 | 'PRODUCT_23' : '<inventory_root>/system/chassis/motherboard/dimm11', |
| 193 | 'PRODUCT_24' : '<inventory_root>/system/chassis/motherboard/dimm12', |
| 194 | 'PRODUCT_25' : '<inventory_root>/system/chassis/motherboard/dimm13', |
| 195 | 'PRODUCT_26' : '<inventory_root>/system/chassis/motherboard/dimm14', |
| 196 | 'PRODUCT_27' : '<inventory_root>/system/chassis/motherboard/dimm15', |
| 197 | 'PRODUCT_28' : '<inventory_root>/system/chassis/motherboard/dimm16', |
| 198 | 'PRODUCT_29' : '<inventory_root>/system/chassis/motherboard/dimm17', |
| 199 | 'PRODUCT_30' : '<inventory_root>/system/chassis/motherboard/dimm18', |
| 200 | 'PRODUCT_31' : '<inventory_root>/system/chassis/motherboard/dimm19', |
| 201 | 'PRODUCT_32' : '<inventory_root>/system/chassis/motherboard/dimm20', |
| 202 | 'PRODUCT_33' : '<inventory_root>/system/chassis/motherboard/dimm21', |
| 203 | 'PRODUCT_34' : '<inventory_root>/system/chassis/motherboard/dimm22', |
| 204 | 'PRODUCT_35' : '<inventory_root>/system/chassis/motherboard/dimm23', |
| 205 | 'PRODUCT_36' : '<inventory_root>/system/chassis/motherboard/dimm24', |
| 206 | 'PRODUCT_37' : '<inventory_root>/system/chassis/motherboard/dimm25', |
| 207 | 'PRODUCT_38' : '<inventory_root>/system/chassis/motherboard/dimm26', |
| 208 | 'PRODUCT_39' : '<inventory_root>/system/chassis/motherboard/dimm27', |
| 209 | 'PRODUCT_40' : '<inventory_root>/system/chassis/motherboard/dimm28', |
| 210 | 'PRODUCT_41' : '<inventory_root>/system/chassis/motherboard/dimm29', |
| 211 | 'PRODUCT_42' : '<inventory_root>/system/chassis/motherboard/dimm30', |
| 212 | 'PRODUCT_43' : '<inventory_root>/system/chassis/motherboard/dimm31', |
| 213 | 'PRODUCT_47' : '<inventory_root>/system/misc', |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 214 | }, |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 215 | 'SENSOR' : { |
| 216 | 0x02 : '/org/openbmc/sensors/host/HostStatus', |
| 217 | 0x03 : '/org/openbmc/sensors/host/BootProgress', |
| 218 | 0x5a : '<inventory_root>/system/chassis/motherboard/cpu0', |
| 219 | 0xa4 : '<inventory_root>/system/chassis/motherboard/cpu1', |
| 220 | 0x1e : '<inventory_root>/system/chassis/motherboard/dimm3', |
| 221 | 0x1f : '<inventory_root>/system/chassis/motherboard/dimm2', |
| 222 | 0x20 : '<inventory_root>/system/chassis/motherboard/dimm1', |
| 223 | 0x21 : '<inventory_root>/system/chassis/motherboard/dimm0', |
| 224 | 0x22 : '<inventory_root>/system/chassis/motherboard/dimm7', |
| 225 | 0x23 : '<inventory_root>/system/chassis/motherboard/dimm6', |
| 226 | 0x24 : '<inventory_root>/system/chassis/motherboard/dimm5', |
| 227 | 0x25 : '<inventory_root>/system/chassis/motherboard/dimm4', |
| 228 | 0x26 : '<inventory_root>/system/chassis/motherboard/dimm11', |
| 229 | 0x27 : '<inventory_root>/system/chassis/motherboard/dimm10', |
| 230 | 0x28 : '<inventory_root>/system/chassis/motherboard/dimm9', |
| 231 | 0x29 : '<inventory_root>/system/chassis/motherboard/dimm8', |
| 232 | 0x2a : '<inventory_root>/system/chassis/motherboard/dimm15', |
| 233 | 0x2b : '<inventory_root>/system/chassis/motherboard/dimm14', |
| 234 | 0x2c : '<inventory_root>/system/chassis/motherboard/dimm13', |
| 235 | 0x2d : '<inventory_root>/system/chassis/motherboard/dimm12', |
| 236 | 0x2e : '<inventory_root>/system/chassis/motherboard/dimm19', |
| 237 | 0x2f : '<inventory_root>/system/chassis/motherboard/dimm18', |
| 238 | 0x30 : '<inventory_root>/system/chassis/motherboard/dimm17', |
| 239 | 0x31 : '<inventory_root>/system/chassis/motherboard/dimm16', |
| 240 | 0x32 : '<inventory_root>/system/chassis/motherboard/dimm23', |
| 241 | 0x33 : '<inventory_root>/system/chassis/motherboard/dimm22', |
| 242 | 0x34 : '<inventory_root>/system/chassis/motherboard/dimm21', |
| 243 | 0x35 : '<inventory_root>/system/chassis/motherboard/dimm20', |
| 244 | 0x36 : '<inventory_root>/system/chassis/motherboard/dimm27', |
| 245 | 0x37 : '<inventory_root>/system/chassis/motherboard/dimm26', |
| 246 | 0x38 : '<inventory_root>/system/chassis/motherboard/dimm25', |
| 247 | 0x39 : '<inventory_root>/system/chassis/motherboard/dimm24', |
| 248 | 0x3a : '<inventory_root>/system/chassis/motherboard/dimm31', |
| 249 | 0x3b : '<inventory_root>/system/chassis/motherboard/dimm30', |
| 250 | 0x3c : '<inventory_root>/system/chassis/motherboard/dimm29', |
| 251 | 0x3d : '<inventory_root>/system/chassis/motherboard/dimm28', |
| 252 | 0x3e : '<inventory_root>/system/chassis/motherboard/cpu0/core0', |
| 253 | 0x3f : '<inventory_root>/system/chassis/motherboard/cpu0/core1', |
| 254 | 0x40 : '<inventory_root>/system/chassis/motherboard/cpu0/core2', |
| 255 | 0x41 : '<inventory_root>/system/chassis/motherboard/cpu0/core3', |
| 256 | 0x42 : '<inventory_root>/system/chassis/motherboard/cpu0/core4', |
| 257 | 0x43 : '<inventory_root>/system/chassis/motherboard/cpu0/core5', |
| 258 | 0x44 : '<inventory_root>/system/chassis/motherboard/cpu0/core6', |
| 259 | 0x45 : '<inventory_root>/system/chassis/motherboard/cpu0/core7', |
| 260 | 0x46 : '<inventory_root>/system/chassis/motherboard/cpu0/core8', |
| 261 | 0x47 : '<inventory_root>/system/chassis/motherboard/cpu0/core9', |
| 262 | 0x48 : '<inventory_root>/system/chassis/motherboard/cpu0/core10', |
| 263 | 0x49 : '<inventory_root>/system/chassis/motherboard/cpu0/core11', |
| 264 | 0x4a : '<inventory_root>/system/chassis/motherboard/cpu1/core0', |
| 265 | 0x4b : '<inventory_root>/system/chassis/motherboard/cpu1/core1', |
| 266 | 0x4c : '<inventory_root>/system/chassis/motherboard/cpu1/core2', |
| 267 | 0x4d : '<inventory_root>/system/chassis/motherboard/cpu1/core3', |
| 268 | 0x4e : '<inventory_root>/system/chassis/motherboard/cpu1/core4', |
| 269 | 0x4f : '<inventory_root>/system/chassis/motherboard/cpu1/core5', |
| 270 | 0x50 : '<inventory_root>/system/chassis/motherboard/cpu1/core6', |
| 271 | 0x51 : '<inventory_root>/system/chassis/motherboard/cpu1/core7', |
| 272 | 0x52 : '<inventory_root>/system/chassis/motherboard/cpu1/core8', |
| 273 | 0x53 : '<inventory_root>/system/chassis/motherboard/cpu1/core9', |
| 274 | 0x54 : '<inventory_root>/system/chassis/motherboard/cpu1/core10', |
| 275 | 0x55 : '<inventory_root>/system/chassis/motherboard/cpu1/core11', |
| 276 | 0x56 : '<inventory_root>/system/chassis/motherboard/membuf0', |
| 277 | 0x57 : '<inventory_root>/system/chassis/motherboard/membuf1', |
| 278 | 0x58 : '<inventory_root>/system/chassis/motherboard/membuf2', |
| 279 | 0x59 : '<inventory_root>/system/chassis/motherboard/membuf3', |
| 280 | 0x5a : '<inventory_root>/system/chassis/motherboard/membuf4', |
| 281 | 0x5b : '<inventory_root>/system/chassis/motherboard/membuf5', |
| 282 | 0x5c : '<inventory_root>/system/chassis/motherboard/membuf6', |
| 283 | 0x5d : '<inventory_root>/system/chassis/motherboard/membuf7', |
| 284 | 0x07 : '/org/openbmc/sensors/host/BootCount', |
| 285 | 0x0c : '<inventory_root>/system/chassis/motherboard', |
| 286 | 0x01 : '<inventory_root>/system/systemevent', |
| 287 | 0x08 : '<inventory_root>/system/powerlimit', |
| 288 | 0x0d : '<inventory_root>/system/chassis/motherboard/refclock', |
| 289 | 0x0e : '<inventory_root>/system/chassis/motherboard/pcieclock', |
| 290 | 0x0f : '<inventory_root>/system/chassis/motherboard/todclock', |
| 291 | 0x10 : '<inventory_root>/system/chassis/motherboard/apss', |
| 292 | 0x02 : '/org/openbmc/sensors/host/OperatingSystemStatus', |
| 293 | 0x04 : '<inventory_root>/system/chassis/motherboard/pcielink', |
| 294 | 0x0b : '/xyz/openbmc_project/sensors/chassis/PowerSupplyRedundancy', |
| 295 | 0xda : '/org/openbmc/sensors/host/TurboAllowed', |
| 296 | 0xD8 : '/org/openbmc/sensors/host/PowerSupplyDerating', |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 297 | }, |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 298 | 'GPIO_PRESENT' : {} |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 299 | } |
| 300 | |
| 301 | GPIO_CONFIG = {} |
| 302 | GPIO_CONFIG['BMC_POWER_UP'] = \ |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 303 | {'gpio_pin': 'D1', 'direction': 'out'} |
| 304 | GPIO_CONFIG['SOFTWARE_PGOOD'] = \ |
| 305 | {'gpio_pin': 'R1', 'direction': 'out'} |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 306 | GPIO_CONFIG['SYS_PWROK_BUFF'] = \ |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 307 | {'gpio_pin': 'D2', 'direction': 'in'} |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 308 | |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 309 | # PV_CP_MD_JTAG_ATTENTION_N |
| 310 | GPIO_CONFIG['CHECKSTOP'] = \ |
| 311 | {'gpio_pin': 'J2', 'direction': 'falling'} |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 312 | |
| 313 | GPIO_CONFIG['BMC_CP0_RESET_N'] = \ |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 314 | {'gpio_pin': 'A1', 'direction': 'out'} |
| 315 | # pcie switch reset |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 316 | GPIO_CONFIG['BMC_VS1_PERST_N'] = \ |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 317 | {'gpio_pin': 'B7', 'direction': 'out'} |
| 318 | # pcie slots reset - not connected? |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 319 | GPIO_CONFIG['BMC_CP0_PERST_ENABLE_R'] = \ |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 320 | {'gpio_pin': 'A3', 'direction': 'out'} |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 321 | |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 322 | # SOFT_FSI_DAT |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 323 | GPIO_CONFIG['FSI_DATA'] = \ |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 324 | {'gpio_pin': 'E0', 'direction': 'out'} |
| 325 | # SOFT_FSI_CLK |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 326 | GPIO_CONFIG['FSI_CLK'] = \ |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 327 | {'gpio_pin': 'AA0', 'direction': 'out'} |
| 328 | # BMC_FSI_IN_ENA |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 329 | GPIO_CONFIG['FSI_ENABLE'] = \ |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 330 | {'gpio_pin': 'D0', 'direction': 'out'} |
| 331 | # FSI_JMFG0_PRSNT_N |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 332 | GPIO_CONFIG['CRONUS_SEL'] = \ |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 333 | {'gpio_pin': 'A6', 'direction': 'out'} |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 334 | |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 335 | # FP_PWR_BTN_N |
| 336 | GPIO_CONFIG['POWER_BUTTON'] = \ |
| 337 | {'gpio_pin': 'I3', 'direction': 'both'} |
| 338 | # BMC_NMIBTN_IN_N |
| 339 | GPIO_CONFIG['RESET_BUTTON'] = \ |
| 340 | {'gpio_pin': 'J1', 'direction': 'both'} |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 341 | |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 342 | # FIXME: needed for Witherspoon? |
| 343 | # Tracked by openbmc/openbmc#814 |
| 344 | # FP_ID_BTN_N |
Gunnar Mills | dca3579 | 2018-03-26 10:05:38 -0500 | [diff] [blame] | 345 | GPIO_CONFIG['IDBTN'] = \ |
| 346 | {'gpio_pin': 'Q7', 'direction': 'out'} |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 347 | |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 348 | # TODO openbmc/openbmc#2288 - Determine if any pci resets needed |
| 349 | GPIO_CONFIGS = { |
| 350 | 'power_config' : { |
| 351 | 'power_good_in' : 'SYS_PWROK_BUFF', |
| 352 | 'power_up_outs' : [ |
| 353 | ('SOFTWARE_PGOOD', True), |
| 354 | ('BMC_POWER_UP', True), |
| 355 | ], |
| 356 | 'reset_outs' : [ |
| 357 | ('BMC_CP0_RESET_N', False), |
| 358 | ], |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 359 | }, |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 360 | 'hostctl_config' : { |
| 361 | 'fsi_data' : 'FSI_DATA', |
| 362 | 'fsi_clk' : 'FSI_CLK', |
| 363 | 'fsi_enable' : 'FSI_ENABLE', |
| 364 | 'cronus_sel' : 'CRONUS_SEL', |
| 365 | 'optionals' : [ |
| 366 | ], |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 367 | }, |
| 368 | } |
| 369 | |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 370 | |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 371 | # Miscellaneous non-poll sensor with system specific properties. |
| 372 | # The sensor id is the same as those defined in ID_LOOKUP['SENSOR']. |
| 373 | MISC_SENSORS = { |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 374 | 0x07 : { 'class' : 'BootCountSensor' }, |
| 375 | 0x03 : { 'class' : 'BootProgressSensor' }, |
| 376 | 0x02 : { 'class' : 'OperatingSystemStatusSensor' }, |
| 377 | # Garrison value is used, Not in P9 XML yet. |
| 378 | 0x0b : { 'class' : 'PowerSupplyRedundancySensor'}, |
| 379 | 0xda : { 'class' : 'TurboAllowedSensor' }, |
| 380 | 0xD8 : { 'class' : 'PowerSupplyDeratingSensor' }, |
George Keishing | 3bd8cf2 | 2016-09-01 00:04:19 -0500 | [diff] [blame] | 381 | } |
George Keishing | 301e7ac | 2018-06-01 12:06:33 -0500 | [diff] [blame] | 382 | |
| 383 | # vim: tabstop=8 expandtab shiftwidth=4 softtabstop=4 |