History log of /openbmc/phosphor-fan-presence/control/json/event.hpp (Results 1 – 19 of 19)
Revision Date Author Comments
# 4fa67aa1 03-Feb-2025 Patrick Williams <patrick@stwcx.xyz>

clang-format: update latest spec and reformat

Copy the latest format file from the docs repository and apply.

Change-Id: If152304b21dd2daaa2f79255a4f98218615efb05
Signed-off-by: Patrick Williams <p

clang-format: update latest spec and reformat

Copy the latest format file from the docs repository and apply.

Change-Id: If152304b21dd2daaa2f79255a4f98218615efb05
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>

show more ...


# cb356d48 22-Jul-2022 Patrick Williams <patrick@stwcx.xyz>

sdbusplus: use shorter type aliases

The sdbusplus headers provide shortened aliases for many types.
Switch to using them to provide better code clarity and shorter
lines. Possible replacements are

sdbusplus: use shorter type aliases

The sdbusplus headers provide shortened aliases for many types.
Switch to using them to provide better code clarity and shorter
lines. Possible replacements are for:
* bus_t
* exception_t
* manager_t
* match_t
* message_t
* object_t
* slot_t

Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: I9029cc722e7712633c15436bd3868d8c3209f567

show more ...


# c3eb7b3c 25-Apr-2022 Matt Spinler <spinler@us.ibm.com>

control: Add 'events' section to dump

Add an events section to the fan control dump that contains all of the
configured events with their contained action and group names.

Signed-off-by: Matt Spinl

control: Add 'events' section to dump

Add an events section to the fan control dump that contains all of the
configured events with their contained action and group names.

Signed-off-by: Matt Spinler <spinler@us.ibm.com>
Change-Id: I8e9fa9ce975ac30837b0842908faeb63ddc31e2a

show more ...


# d1f97f43 29-Oct-2021 Matt Spinler <spinler@us.ibm.com>

control: Add power on/off triggers

Add two new classes of triggers: powerOn and powerOff. They are only
called during the power on and power off state changes, respectively.

They behave the same a

control: Add power on/off triggers

Add two new classes of triggers: powerOn and powerOff. They are only
called during the power on and power off state changes, respectively.

They behave the same as the existing init trigger.

Signed-off-by: Matt Spinler <spinler@us.ibm.com>
Change-Id: I9d39210843192b9c343c7838c604fcce7c8d3f3d

show more ...


# 3695ac30 06-Oct-2021 Matthew Barth <msbarth@us.ibm.com>

control: Correct reloading groups.json thru SIGHUP

When providing a SIGHUP, the groups.json was not getting reloaded due to
being a pure static method. This changes that method to load the
groups.js

control: Correct reloading groups.json thru SIGHUP

When providing a SIGHUP, the groups.json was not getting reloaded due to
being a pure static method. This changes that method to load the
groups.json if not already loaded and requested to load the groups.json
which is the default.

All of available groups are now saved off during a SIGHUP and restored
if the groups.json or events.json fail to be reloaded. If there are no
failures in reloading neither the groups.json nor the events.json, the
newly loaded groups.json is used instead.

Change-Id: I44870e796530fdb325e0821429a203969ae05018
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>

show more ...


# e386fbb2 30-Jun-2021 Matthew Barth <msbarth@us.ibm.com>

control: Make setting groups public and static

There could be a need for actions to determine a list of groups to use,
so make setting the groups available for actions to use. For example,
the timer

control: Make setting groups public and static

There could be a need for actions to determine a list of groups to use,
so make setting the groups available for actions to use. For example,
the timer_based_actions action could have groups configured on the list
of actions that it runs when its timer expires. These groups need to be
checked against the active profiles and set on the list of actions.

Change-Id: I5b00f16af12bd15e56a65cb3a82a294860ab6d8d
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>

show more ...


# 54b5a24f 21-May-2021 Matthew Barth <msbarth@us.ibm.com>

control: Store/use trigger enable functions on events

Create and store trigger enablement functions on the events based on the
trigger's configuration so that they can be enabled separately from whe

control: Store/use trigger enable functions on events

Create and store trigger enablement functions on the events based on the
trigger's configuration so that they can be enabled separately from when
the event is created. This will allow actions that load events to be
able to be parsed and then enabled when the action determines that the
events should be enabled. It also supports the use of SIGHUP to reload
the event configuration since the events JSON configuration must
successfully be loaded before the newly created events can be enabled in
place of the currently enabled events.

Change-Id: I31871ee1691d5e6b26fe16cde2a829c426ad6504
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>

show more ...


# 152cc4f7 20-May-2021 Matthew Barth <msbarth@us.ibm.com>

control: Remove event `getActions()`

There is currently no need to get the actions of an event.

Change-Id: Ide23cfc9d30559bf7eb8df6a1a2c453ff37c3627
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>


# 619dc0f2 20-May-2021 Matthew Barth <msbarth@us.ibm.com>

control: Remove JSON event precondition support

Event preconditions are essentially specialized actions that load events
after a certain condition is met. JSON configured fan control will just
utili

control: Remove JSON event precondition support

Event preconditions are essentially specialized actions that load events
after a certain condition is met. JSON configured fan control will just
utilize actions that are configured & created to enable or disable
events based on some state.

Change-Id: I8e8faf3c137062943ffaa9b3adc20d93da3a123c
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>

show more ...


# c8bde4aa 19-May-2021 Matthew Barth <msbarth@us.ibm.com>

control: Optimize loading/configuring event groups

The available groups configured can statically be loaded within the
event object since each event instance will configure its specific set
of group

control: Optimize loading/configuring event groups

The available groups configured can statically be loaded within the
event object since each event instance will configure its specific set
of groups from what's available.

Event actions use groups configured on the event or include groups
configured on the action directly with those configured on the event.
This can be done in a single function to setup the groups.

Change-Id: I87cb2949f803ca63c66658a944fe4d9eeabb7a3f
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>

show more ...


# 9403a217 17-May-2021 Matthew Barth <msbarth@us.ibm.com>

control: Switch to using static instance of bus

Update main to use the static reference of the bus from
util::SDBusPlus.getBus() and have each object that needs the bus call
that same util::SDBusPlu

control: Switch to using static instance of bus

Update main to use the static reference of the bus from
util::SDBusPlus.getBus() and have each object that needs the bus call
that same util::SDBusPlus.getBus() function to retrieve the same static
reference.

Change-Id: Icd5a0e61819bf1bec8b46daae05443fdcc542b05
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>

show more ...


# d4bd0ae5 14-Apr-2021 Matthew Barth <msbarth@us.ibm.com>

control: Provide pointer to manager object to events

To setup triggers on events, a pointer to the manager where service and
property states are stored is needed.

Change-Id: Ic6e2ca81c83f4cfacf01b9

control: Provide pointer to manager object to events

To setup triggers on events, a pointer to the manager where service and
property states are stored is needed.

Change-Id: Ic6e2ca81c83f4cfacf01b9cb09b08c9f50f35cb6
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>

show more ...


# 46b34485 06-Apr-2021 Matthew Barth <msbarth@us.ibm.com>

control: Set groups & zones on event actions

Configure and set the groups to be used per action of an event along
with setting the list of zones the action should be run against. Groups
configured o

control: Set groups & zones on event actions

Configure and set the groups to be used per action of an event along
with setting the list of zones the action should be run against. Groups
configured on an action are appended to the event's configured groups.
This is intended to allow a shared set of groups across all actions of
an event and then include additional groups specific to the action.
Also, zones configured on an action result in only those zones being
used by the action whereas when no zones are configured on the action,
all of the available zones to the event are used.

Change-Id: I5986398eec4c6cf5ac88f5725f2b877bd2551fc7
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>

show more ...


# 9f1632e5 31-Mar-2021 Matthew Barth <msbarth@us.ibm.com>

control: Provide zones to the events

The event actions need the zone(s) to run the event's configured
action(s) against. The YAML based configs did not support configuring
which zone(s) to run any p

control: Provide zones to the events

The event actions need the zone(s) to run the event's configured
action(s) against. The YAML based configs did not support configuring
which zone(s) to run any particular action within an event against.
A follow up commit will package the zone(s) an action should run against
and provide that directly to the action, eliminating the need to store
that for the trigger callbacks.

Change-Id: I1d0de02a61c9a906f932487231b46add92e8b1d5
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>

show more ...


# e5578602 30-Mar-2021 Matthew Barth <msbarth@us.ibm.com>

control: Use Group objects in events

Use the generated Group objects in configured events. Group objects are
temporarily generated from the `groups.json` configuration and passed to
each event. When

control: Use Group objects in events

Use the generated Group objects in configured events. Group objects are
temporarily generated from the `groups.json` configuration and passed to
each event. When the event is generated from its JSON configuration, the
group(s) its configured to use in the event are first copied from the
list of Group objects and then populated with the remaining details for
the group configuration that's provided in the event. Groups to be used
in the event must either have no profiles restricting their use or have
a profile that matches the event's profile where that profile is also
active.

Change-Id: Ifda7493ab256fa2fbf869e984609888c418b1f9b
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>

show more ...


# 44ab7693 26-Mar-2021 Matthew Barth <msbarth@us.ibm.com>

control: Load JSON configured groups and events

Load the JSON configured groups and events, removing the remaining
references to the YAML based groups, triggers, and actions types. JSON
configured g

control: Load JSON configured groups and events

Load the JSON configured groups and events, removing the remaining
references to the YAML based groups, triggers, and actions types. JSON
configured groups are loaded and provided to each event so that they can
eventually be copied and updated for the specifics of the event.

Change-Id: If713809b2865b5fe84b7bbb5a086cd49ba7fe55c
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>

show more ...


# 12bae961 15-Jan-2021 Matthew Barth <msbarth@us.ibm.com>

control: Construct events' groups

For each event, using the available groups, construct the groups
configured for the event. Groups with the same profiles configured as an
event can be used and even

control: Construct events' groups

For each event, using the available groups, construct the groups
configured for the event. Groups with the same profiles configured as an
event can be used and events with no profiles configured, can also use
groups with no profiles configured.

*Note: Profiles are ways to keep specific configuration entries from
being used under specified details given within the `profiles.json`
configuration.

Change-Id: I47ce125ebb68e7075efc1c095d525bc9c96630e7
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>

show more ...


# 391ade08 15-Jan-2021 Matthew Barth <msbarth@us.ibm.com>

control: Add creating config object without a dbus object

For those configuration objects that do not need a dbus object, create
them using a similar method without requiring a dbus object to be giv

control: Add creating config object without a dbus object

For those configuration objects that do not need a dbus object, create
them using a similar method without requiring a dbus object to be given.
Updated each object to correctly reflect their current need of a dbus
object which was driven by moving the creation of the available group
objects to within the event.

Change-Id: I8ce4ea7baf4cfd1ad86268b760a334fcf0a4f25e
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>

show more ...


# 3174e72b 15-Sep-2020 Matthew Barth <msbarth@us.ibm.com>

control: Add event configuration class framework

The event class will contain the configuration for each event that
results in altering how fan control functions. Events continue to be
optional, whe

control: Add event configuration class framework

The event class will contain the configuration for each event that
results in altering how fan control functions. Events continue to be
optional, where no events configured result in no fan speed changes.
Events are made up of groups of sensors, triggers from those sensors,
and actions to be run when a trigger occurs. Events may also have a
precondition that must exist before the event is loaded into fan
control. The triggers, actions, and preconditions configured must be
available within the fan control application.

Tested:
Event JSON configuration able to be loaded
Event objects created, each with the name configured
Required event base attributes exist otherwise throw exception

Change-Id: I8a3d116522c78fafa3b3e9a37a63bb8262802a98
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>

show more ...