summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--meta-openbmc-machines/meta-openpower/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-events-config-native.bbappend1
-rw-r--r--meta-openbmc-machines/meta-openpower/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-events-config/events.yaml53
-rw-r--r--meta-phosphor/common/recipes-phosphor/fans/phosphor-fan-control-events-config-native.bb15
-rw-r--r--meta-phosphor/common/recipes-phosphor/fans/phosphor-fan-control-events-config/events.yaml2
-rw-r--r--meta-phosphor/common/recipes-phosphor/fans/phosphor-fan.bb2
5 files changed, 73 insertions, 0 deletions
diff --git a/meta-openbmc-machines/meta-openpower/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-events-config-native.bbappend b/meta-openbmc-machines/meta-openpower/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-events-config-native.bbappend
new file mode 100644
index 000000000..db65e0916
--- /dev/null
+++ b/meta-openbmc-machines/meta-openpower/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-events-config-native.bbappend
@@ -0,0 +1 @@
+FILESEXTRAPATHS_prepend := "${THISDIR}/phosphor-fan-control-events-config:"
diff --git a/meta-openbmc-machines/meta-openpower/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-events-config/events.yaml b/meta-openbmc-machines/meta-openpower/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-events-config/events.yaml
new file mode 100644
index 000000000..94e55bb88
--- /dev/null
+++ b/meta-openbmc-machines/meta-openpower/meta-ibm/meta-witherspoon/recipes-phosphor/fans/phosphor-fan-control-events-config/events.yaml
@@ -0,0 +1,53 @@
+groups:
+ - name: zone0_fans
+ description: Group of fan inventory objects for zone 0
+ type: inventory
+ members:
+ - /system/chassis/motherboard/fan0
+ - /system/chassis/motherboard/fan1
+ - /system/chassis/motherboard/fan2
+ - /system/chassis/motherboard/fan3
+
+actions:
+ - name: count_state_before_speed
+ description: Set the speed when a number of properties at a state
+ parameters:
+ - count
+ - property
+ - speed
+
+events:
+ - name: missing_before_high_speed
+ zone_conditions:
+ - name: air_cooled_chassis
+ zones:
+ - 0
+ group: zone0_fans
+ interface: xyz.openbmc_project.Inventory.Item
+ property:
+ name: Present
+ type: bool
+ action:
+ name: count_state_before_speed
+ count: 1
+ property: false
+ speed:
+ value: 10500
+ type: uint64_t
+ - name: fails_before_high_speed
+ zone_conditions:
+ - name: air_cooled_chassis
+ zones:
+ - 0
+ group: zone0_fans
+ interface: xyz.openbmc_project.State.Decorator.OperationalStatus
+ property:
+ name: Functional
+ type: bool
+ action:
+ name: count_state_before_speed
+ count: 1
+ property: false
+ speed:
+ value: 10500
+ type: uint64_t
diff --git a/meta-phosphor/common/recipes-phosphor/fans/phosphor-fan-control-events-config-native.bb b/meta-phosphor/common/recipes-phosphor/fans/phosphor-fan-control-events-config-native.bb
new file mode 100644
index 000000000..740b194ad
--- /dev/null
+++ b/meta-phosphor/common/recipes-phosphor/fans/phosphor-fan-control-events-config-native.bb
@@ -0,0 +1,15 @@
+SUMMARY = "Phosphor zone events definition default data"
+PR = "r1"
+
+inherit native
+inherit obmc-phosphor-license
+inherit phosphor-fan
+
+SRC_URI += "file://events.yaml"
+
+S = "${WORKDIR}"
+
+do_install() {
+ DEST=${D}${control_datadir}
+ install -D events.yaml ${DEST}/events.yaml
+}
diff --git a/meta-phosphor/common/recipes-phosphor/fans/phosphor-fan-control-events-config/events.yaml b/meta-phosphor/common/recipes-phosphor/fans/phosphor-fan-control-events-config/events.yaml
new file mode 100644
index 000000000..b89d1dca7
--- /dev/null
+++ b/meta-phosphor/common/recipes-phosphor/fans/phosphor-fan-control-events-config/events.yaml
@@ -0,0 +1,2 @@
+#Default zone events definition YAML - empty.
+#For format, see documentation in fan control code repository example yaml.
diff --git a/meta-phosphor/common/recipes-phosphor/fans/phosphor-fan.bb b/meta-phosphor/common/recipes-phosphor/fans/phosphor-fan.bb
index 04413e94d..e7a6d7eca 100644
--- a/meta-phosphor/common/recipes-phosphor/fans/phosphor-fan.bb
+++ b/meta-phosphor/common/recipes-phosphor/fans/phosphor-fan.bb
@@ -58,10 +58,12 @@ SYSTEMD_LINK_${PN}-presence-tach += "${@compose_list(d, 'FMT_TACH', 'OBMC_CHASSI
PACKAGECONFIG[control] = "--enable-control \
FAN_DEF_YAML_FILE=${STAGING_DIR_NATIVE}${control_datadir}/fans.yaml \
FAN_ZONE_YAML_FILE=${STAGING_DIR_NATIVE}${control_datadir}/zones.yaml \
+ ZONE_EVENTS_YAML_FILE=${STAGING_DIR_NATIVE}${control_datadir}/events.yaml \
FAN_ZONE_OUTPUT_DIR=${S}/control, \
--disable-control, \
virtual/phosphor-fan-control-fan-config \
phosphor-fan-control-zone-config-native \
+ phosphor-fan-control-events-config-native \
, \
"
OpenPOWER on IntegriCloud