blob: fe45e7499759298c38d2f5539b376d5763ecbb0c [file] [log] [blame]
Matt Spinler8cca7012016-12-05 10:42:47 -06001SUMMARY = "Set Witherspoon fan default speeds"
2DESCRIPTION = "Sets all fans to a single speed"
3PR = "r1"
4
5inherit allarch
6inherit obmc-phosphor-license
7inherit obmc-phosphor-systemd
8
9RDEPENDS_${PN} += "i2c-tools"
10
11S = "${WORKDIR}"
12SRC_URI += "file://set_fan_speeds.sh"
13
14TMPL = "fan-default-speed@.service"
15INSTFMT = "fan-default-speed@{0}.service"
Josh D. Kingaaf179d2017-04-06 15:56:37 -050016TGTFMT = "obmc-host-start@{0}.target"
Andrew Geissler17100972017-02-08 15:54:25 -060017FMT = "../${TMPL}:${TGTFMT}.requires/${INSTFMT}"
Matt Spinler8cca7012016-12-05 10:42:47 -060018
19SYSTEMD_SERVICE_${PN} += "${TMPL}"
20SYSTEMD_LINK_${PN} += "${@compose_list(d, 'FMT', 'OBMC_CHASSIS_INSTANCES')}"
21
22do_install() {
23 install -d ${D}${bindir}
24 install -m 0755 ${WORKDIR}/set_fan_speeds.sh ${D}${bindir}/set_fan_speeds.sh
25}