blob: 3a01fe1ae26d7047872aac56c77984c682384b91 [file] [log] [blame]
Brad Bishop6242f802019-06-09 16:02:49 -04001SUMMARY = "YAML configuration for ACx22 systems"
2PR = "r1"
3LICENSE = "Apache-2.0"
Brad Bishopd77088a2019-09-13 13:06:15 -04004LIC_FILES_CHKSUM = "file://${COREBASE}/meta/files/common-licenses/Apache-2.0;md5=89aea4e17d99a7cacdbeed46a0096b10"
Brad Bishop6242f802019-06-09 16:02:49 -04005
6inherit allarch
7inherit mrw-xml
8
Adriana Kobylakb96c7502021-08-06 16:25:30 +00009SRC_URI:ibm-ac-server = " \
Brad Bishop6242f802019-06-09 16:02:49 -040010 file://acx22-ipmi-fru-bmc.yaml \
11 file://acx22-ipmi-fru-not-sent-by-host.yaml \
12 file://acx22-ipmi-hwmon-sensors.yaml \
13 file://acx22-ipmi-inventory-sensors.yaml \
14 file://acx22-ipmi-occ-sensors.yaml \
15 file://acx22-ipmi-sensors-mrw.yaml \
Brad Bishop6242f802019-06-09 16:02:49 -040016 "
Adriana Kobylakb96c7502021-08-06 16:25:30 +000017SRC_URI:mihawk = " \
Ben_Pai89e65012019-08-21 18:04:55 +080018 file://acx22-ipmi-fru-bmc.yaml \
19 file://acx22-ipmi-hwmon-sensors.yaml \
20 file://acx22-ipmi-inventory-sensors.yaml \
21 file://acx22-ipmi-occ-sensors.yaml \
22 file://acx22-ipmi-sensors-mrw.yaml \
23 "
Brad Bishop6242f802019-06-09 16:02:49 -040024DEPENDS = " \
25 mrw-native \
26 mrw-perl-tools-native \
27 openpower-yaml-config \
28 "
29
30S = "${WORKDIR}"
31
Adriana Kobylakb96c7502021-08-06 16:25:30 +000032ACx22_IPMI_EXTRA_FRU_READ_YAMLS:ibm-ac-server = " \
Brad Bishop6242f802019-06-09 16:02:49 -040033 acx22-ipmi-fru-bmc.yaml \
34 acx22-ipmi-fru-not-sent-by-host.yaml \
35 "
Adriana Kobylakb96c7502021-08-06 16:25:30 +000036ACx22_IPMI_EXTRA_FRU_READ_YAMLS:mihawk = " \
Ben_Pai89e65012019-08-21 18:04:55 +080037 acx22-ipmi-fru-bmc.yaml \
38 "
Brad Bishop6242f802019-06-09 16:02:49 -040039ACx22_IPMI_EXTRA_SENSOR_YAMLS = " \
40 acx22-ipmi-hwmon-sensors.yaml \
41 acx22-ipmi-occ-sensors.yaml \
Brad Bishop6242f802019-06-09 16:02:49 -040042 "
43
44do_install() {
45 perlbin="${STAGING_DIR_NATIVE}${bindir}/perl-native/perl"
46 scriptpath=${STAGING_DIR_NATIVE}${bindir}
47 mrw=${STAGING_DIR_NATIVE}${datadir}/obmc-mrw/${MRW_XML}
48 op_configpath=${STAGING_DIR_HOST}${datadir}/openpower-yaml-config
49
50 # generate extra-properties.yaml from the MRW for ipmi-fru-parser
51 $perlbin $scriptpath/gen_fru_properties.pl -m $mrw \
52 -c $op_configpath/ipmi-fru-properties-mrw.yaml \
Santosh Puranik87d92e52019-10-11 12:54:52 -050053 -o extra-properties.yaml ${EXTRA_MRW_SCRIPT_ARGS}
Brad Bishop6242f802019-06-09 16:02:49 -040054
55 # generate fru-read.yaml from the MRW, for ipmid and ipmi-fru-parser
56 $perlbin $scriptpath/gen_ipmi_fru.pl -i $mrw \
57 -m $op_configpath/ipmi-hostboot-fru-mrw.yaml \
Santosh Puranik87d92e52019-10-11 12:54:52 -050058 -o fru-read-partial.yaml ${EXTRA_MRW_SCRIPT_ARGS}
Brad Bishop6242f802019-06-09 16:02:49 -040059 cat fru-read-partial.yaml ${ACx22_IPMI_EXTRA_FRU_READ_YAMLS} \
60 > fru-read.yaml
61
62 # generate inventory-sensors.yaml from the MRW, for ipmid
63 $perlbin $scriptpath/gen_ipmi_sel.pl -i $mrw \
Santosh Puranik87d92e52019-10-11 12:54:52 -050064 -m acx22-ipmi-inventory-sensors.yaml -o inventory-sensors.yaml \
65 ${EXTRA_MRW_SCRIPT_ARGS}
Brad Bishop6242f802019-06-09 16:02:49 -040066
67 # generate sensors.yaml from the MRW, for ipmid
68 cat acx22-ipmi-sensors-mrw.yaml \
69 $op_configpath/ipmi-hostboot-volatile-sensor-mrw.yaml \
70 $op_configpath/ipmi-occ-active-sensor-mrw.yaml \
71 > sensors-mrw.yaml
72 $perlbin $scriptpath/gen_ipmi_sensor.pl -i $mrw -m sensors-mrw.yaml \
Santosh Puranik87d92e52019-10-11 12:54:52 -050073 -o sensors-partial.yaml ${EXTRA_MRW_SCRIPT_ARGS}
Brad Bishop6242f802019-06-09 16:02:49 -040074 cat sensors-partial.yaml ${ACx22_IPMI_EXTRA_SENSOR_YAMLS} \
75 > sensors.yaml
76
77 install -m 0644 -D extra-properties.yaml \
78 ${D}${datadir}/${BPN}/ipmi-extra-properties.yaml
79 install -m 0644 -D fru-read.yaml ${D}${datadir}/${BPN}/ipmi-fru-read.yaml
80 install -m 0644 -D inventory-sensors.yaml \
81 ${D}${datadir}/${BPN}/ipmi-inventory-sensors.yaml
82 install -m 0644 -D sensors.yaml ${D}${datadir}/${BPN}/ipmi-sensors.yaml
83}
84
Adriana Kobylakb96c7502021-08-06 16:25:30 +000085FILES:${PN}-dev = " \
Brad Bishop6242f802019-06-09 16:02:49 -040086 ${datadir}/${BPN}/ipmi-extra-properties.yaml \
87 ${datadir}/${BPN}/ipmi-fru-read.yaml \
88 ${datadir}/${BPN}/ipmi-inventory-sensors.yaml \
89 ${datadir}/${BPN}/ipmi-sensors.yaml \
90 "
91
Adriana Kobylakb96c7502021-08-06 16:25:30 +000092ALLOW_EMPTY:${PN} = "1"