summaryrefslogtreecommitdiffstats
path: root/presence/example/example.yaml
blob: aea0139037403abb7de9d9b4da9696491f073301 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
# Phosphor Fan Presence (PFP) example configuration file.
#
# The configuration represents an array of fans the application
# should check for presence.  The name attribute is required
# and is used as the PrettyName attribute for the
# xyz.openbmc_project.Inventory.Item interface.  Path is required
# and is the location where the fan inventory object will be
# created.  Additional configuration directives described below
# in the examples.

- name: Example Fan0
  description: >
    'Example fan with tach feedback detection method.

    Fans without any special presence detection hardware
    can use one or more tach speed sensor feedbacks as
    an indicator of presence.  Listed sensors are expected to
    be found in the /xyz/openbmc_project/sensors/fan_tach
    namespace as required by the OpenBMC DBus API.

    Supported policy types are all_of or any_of.'
  path: /system/chassis/motherboard/fan0
  methods:
    - type: tach
      sensors:
        - fan0

- name: Example Fan1
  description: >
    'Example fan with gpio detection method.

    Fans with dedicated gpios can use the gpio detection
    method.  The gpio detection uses Linux gpio-keys: the
    event number must be provided via the key property.'
  path: /system/chassis/motherboard/fan1
  methods:
    - type: gpio
      key: 123
      physpath: /sys/devices/foo/bar

- name: Example Fan2
  description: >
    'Example fan with fallback redundancy policy.

    Multiple detection methods for a single fan are allowed.
    When multiple detection methods are provided a redundancy
    algorithm must be specified with the rpolicy attribute.

    Note that the redundancy policy algorithm may or may not
    factor the order the detection methods are listed into
    its logic.

    The fallback algorithm falls back to subsequently listed
    detection methods when the first method does not detect
    a fan and the second method does.'
  path: /system/chassis/motherboard/fan2
  methods:
    - type: gpio
      key: 124
      physpath: /sys/devices/foo/bar
    - type: tach
      sensors:
        - fan2
  rpolicy:
    type: fallback

OpenPOWER on IntegriCloud