| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
| |
Allows the complete removal of a set speed event from the zone. This is
done when any precondition defined for the event to be active is not
met any longer.
Change-Id: Idbec357f76f0fd7db9107e8c9d3e00461872c528
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
| |
The property state check precondition validates that each given property
matches the defined value. When all the precondition groups' property
states match, the given set speed event is initialized and activated
allowing the zone speeds to be active controlled.
Change-Id: Ic16a0e1fc584c6fa695e354fa80fb1993002ffc7
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Set speed events can not subscribe to InterfaceAdded signals for
properties that are created after fan control initializes the event. Fan
control subscribes to property changed signals for all events upon
startup where any properties that do not exist are unable to be
subscribed to and be notified when their property changes. Therefore,
subscribing to the InterfacesAdded signals for properties as well allows
any property defined within a set speed event that may not exist upon
starting the fan control application get added or updated when the
interface it resides on is added.
When a subscribed InterfacesAdded signal is caught, the same setProperty
handler function will be used to add the property value for the object
path, interface, and property name defined to be subscribed to for
property change signals.
Change-Id: If6fe97288140b83e2e2d735fdf61d52de1ec2e88
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Any defined preconditions for a set speed event must be satisfied prior
to configuring the event parameters for fan control. These preconditions
will accept a list of group entries that include the value the group's
property must be to have the precondition met for that group. Once all
preconditions are met, the set speed event will be initialized and
become active.
Change-Id: Ia5555be55c5937c891af527bea63da1546655b2f
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
| |
Change-Id: I30fdecd3af3dcdc7f954bdb9d535c6bc92edd67a
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Support setting the increase delay time(in seconds) for each zone from
the zone yaml file. Speed increases use a delay type timer where the
amount of time given delays additional increase requests from happening
until the fans within the zone reach the highest net increase in speeds.
Support setting the decrease interval time(in seconds) for each zone
from the zone yaml file. Since decreasing is done on an interval, a
decrease interval time of zero disables the decrease interval timer
causing no decreases in speed to occur. Speed decreases use an interval
type timer to decrease the fan speeds within the zone when no speed
increase requests exist on the given time interval.
Change-Id: I88334a313b6e2820b768fa7e3f1cb65887f29258
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
| |
When the floor speed updates, a request to increase the target speed
should be made when the target is now below the floor speed.
Change-Id: Ib622bc717a952ef0c0703cbff40a4dc14b213416
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
A oneshot timer is started on each target speed increase where the
amount of time configured is how long the fans within the zone are
allowed to reach the new target speed before additional speed increase
requests will be processed. Any speed increase request deltas that are
above the current speed increase delta being processed as the new target
speed will cause the timer to stop and the difference between the deltas
are added onto the target speed.
Change-Id: I064941c4e12c3e44be90880d6f32c6fbcf7ae32d
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
| |
Change-Id: I8a281935368cd705658d489c7c7af59b8dde7e4d
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
|
| |
Create a repeating timer for decreasing fan speeds where the fan speeds
in the zone are decreased when the timer expires and a decrease speed
request exists with no increase request present or active.
Change-Id: I419592f6f50c0ed524f8bf3ebf183854ab5ef2ea
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
A net decrease speed action determines the net decrease delta from each
group member's property value and requests a speed decrease of that
delta from the current target speed.
From all the requests for a speed decrease on a zone, only the lowest
net decrease is used from all the groups subscribed to decrease a zone's
speed. The new target speed is only decreased when no increase requests
exist and the resulting target is above the zone's floor speed,
otherwise the floor speed is set as the new target.
Resolves openbmc/openbmc#1626
Change-Id: Iaefa7b25c3f44691dd3ca4084bfddd3c1a504de9
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
| |
Speed increases are made providing a target speed delta. The increase is
made when the delta is higher than the current increase that may be
occurring. When no increase is currently happening, the increase delta
requested is accepted. All resulting target increases will not go above
a defined ceiling speed.
Change-Id: Ia19c71a023cf5b897d5ba92974ff98451f34d5a3
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
|
| |
The net increase speed action provides the ability to determine what the
net delta the zone's fan speeds should be updated by from their current
target speed.
Change-Id: Ib463e5ed4836bebf906cea27ea5788d826ec9c38
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Set the default ceiling to be what's given as full speed and adjust the
ceiling speed based on an average of a given set of sensor values.
The ceiling is chosen from a given map's key transition values. The map
consists of key, value pairs where each key is the sensor value
transition point and the value is the ceiling speed for when that
transition occurs. The previous key value is needed to determine the
direction in which to chose the appropriate ceiling speed allowing a
buffer zone between ceiling changes if defined to.
Resolves openbmc/openbmc#1628
Change-Id: I7c9c553b5d0c3219c51b563aec7dd5d5f090916b
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
| |
Implemented elog exception for phosphor fan presence,
replacing runtime_errors.
Change-Id: I70465060838b2cbaeadccf84ed5924e222ac59e3
Signed-off-by: Dinesh Chinari <chinari@us.ibm.com>
|
|
|
|
|
|
|
| |
Resolves openbmc/openbmc#940
Change-Id: I238cd4a6ef69c1d54a775ad90ee87e6e327b82bd
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
| |
Given a group of sensor values, the average of those sensor values will
be used in selecting the floor speed for the zone. Each time the speed
is set/updated, any speed requested lower than the current floor will be
overwritten with the floor speed to not allow speeds below the floor.
Change-Id: I4c8e8a2cd66892b9fdc2bc5643e907adddff51f8
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
| |
Change-Id: Id2d3b362e79e7a8c2330181f68ae11e43f84e2fd
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
| |
Allow properties stored for processing events to be of types other than
bool
Change-Id: Ie1dde5aca562c9958bdff6fa3d1b19d3154b2c6d
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
| |
The interface is needed on the properties stored to uniquely identify
each property used in events.
Change-Id: Ia062f25514d7ed04ef1023a02eecad4738711ffb
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
|
| |
Only add events to the zone if the conditions and
zone number are correct.
Resolves openbmc/openbmc#1500
Change-Id: Ia040fcbdd9093d25d4ed1773d5fea0ed8a95ba2b
Signed-off-by: Gunnar Mills <gmills@us.ibm.com>
|
|
|
|
|
|
|
|
| |
An example yaml file for zone conditions to be used to
create the correct fan zones.
Change-Id: I6ca339a3a9f37bc70424cde57f2229a5dcb70cbb
Signed-off-by: Gunnar Mills <gmills@us.ibm.com>
|
|
|
|
|
| |
Change-Id: I8eb215aaf90ef9553a52e8eaa54d3fd1a1a00ca5
Signed-off-by: Gunnar Mills <gmills@us.ibm.com>
|
|
|
|
|
| |
Change-Id: Idb825b27ecf98503ddc2405a0cafc30c644efc71
Signed-off-by: Gunnar Mills <gmills@us.ibm.com>
|
|
|
|
|
|
|
| |
Fixed pep8 warnings in gen-fan-zone-defs.py
Change-Id: I78472a1e9ce1bd6eb14e0352398c6470fa144604
Signed-off-by: Gunnar Mills <gmills@us.ibm.com>
|
|
|
|
|
|
|
| |
Zone conditions are used to determine which zone to use.
Change-Id: I11f0ffa4da12532aeedf88941fb8a2d7fca5d352
Signed-off-by: Gunnar Mills <gmills@us.ibm.com>
|
|
|
|
|
|
|
|
| |
Attach the event handler callback function to the match along with
generating the match string using the new match methods
Change-Id: I7595d65cbc615f29db60e2a65534ee5b635d6f96
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
| |
On start of fan control, check the current event's group members'
property states and envoke the defined action function on the results.
Change-Id: I12509403328d90f85d67b393dbdd97d8710c83ef
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Each zone contains an active state that determines whether the
automatic fan control algorithm is active and controlling the fan speeds
dynamically or not.
This will be used to determine if the fan speeds within the zone are set
dynamically or rather held at another speed for a determined reason.
Change-Id: I2f81de168c5f7d859b3ec917022c4749e1a28d4e
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
| |
Change-Id: Ia6987295a3eb4e23b9d6ae13a383e440386572de
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
| |
Fixed resulting pep8 alignment issues in the generated template
Change-Id: I26d316a86c40896cda729683b26ccf06a3f89d5f
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
| |
Add the list of property(s) associated to a set speed event where the
handler updates the property cached on the zone for the action
Change-Id: Ifac61dda6eb200ca28735ddfaab3d34c9a9df758
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
| |
Adds the set speed event action functions with the associated parameters
in the order required for the function
Change-Id: Ib08f2442d8ff1fb3d49ab5234eacc2db8304a20d
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
| |
Adds the groups for a set speed event for each zone listed within the
event. The groups are for maintaining a cached property value.
Change-Id: I2de9cf62215f9861e8ea2e6807df11e6a04638fb
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
|
| |
An example yaml file to define set speed events based on groups of dbus
object properties and a set of actions that can be performed based on
those property values
Change-Id: I2f713920f9ce25859855cfec783df0adb505f31d
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
| |
Enable an action to be defined that sets the zone to a given speed when
a number of properties are set to a given value
Change-Id: I5252a20a24bdb14dee63080f2c08b080c82ad7e8
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
| |
Enable the control application to handle property changed signals to set
or update a cached set of these properties
Change-Id: Ib84ffe1e801ee7dd85d17fdbb122d124d307dbd3
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
The cooling-type application should use the common
header file for the ArgumentParser class now that one
is available.
Also fixed where a static ArgumentParser constant was
being initialized.
Change-Id: I1fb0dfe3bd0c6e0200ad7c718ef2a3def5476f3f
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
|
|
|
|
|
|
|
| |
initial_speed should be full_speed in example/zones.yaml
Change-Id: I64b4803a26006cf78f6d29859bb8dd43a5cf63b3
Signed-off-by: Gunnar Mills <gmills@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
phosphor-fan-control can behave differently based
on its command line arguments
--init: Set fans to full speed, delay for a
configurable amount of time to allow fans to ramp up,
start the fan control ready target, and then exit.
--control: Start the control algorithm. Never exits.
Will be started as part of the fan control ready target.
Change-Id: I453daf8cc05a5c85a19c098e1cca64cac2ad9520
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Parses arguments for phosphor-fan-control.
The header file is in the base directory of the repository
and can be common to all fan applications. The cpp file
needs to be in the subdirectory of the application that uses
it, in this case control.
Change-Id: I93dba60daf8f78667df970ab47ec018d90a8c14f
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Start running the python script that generates the
fan zone data structures during the build.
If the paths to the 2 yaml files aren't provided during
configure, then the yaml in the example directory will
be used instead.
Change-Id: I9f67c1b94b5302c30ac87b0f80746854c42776b2
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
|
|
|
|
|
|
|
|
|
| |
Using data from the zone and fan definition yaml files,
generate a .cpp file with data structures that define
the fan zones and the fans in those zones for a system.
Change-Id: I5679ee692856e01138750f41bc23eb0cbb7f9464
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
|
|
|
|
|
|
|
|
|
| |
The basics of a python script that will generate the
fan zone data structures for the fan control code
from zone and fan yaml files using a mako template.
Change-Id: I1d92dc55c2b6dd986e5aaae0d3440ef85cbe79c0
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
|
|
|
|
|
|
|
|
| |
Create Zone objects for the fan zones defined in the
definition data that meet all conditions.
Change-Id: I9c29be93716cd137f1c714355a0bd2a1c93271cd
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
|
|
|
|
|
|
|
|
| |
This class represents a fan zone, which is a collection
of fans that are always set to a speed together.
Change-Id: I5646f07b7b136aad216dabded3b5da3e9da0a531
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
| |
This class contains the inventory name of the fan,
and the sensor names representing the rotors.
Calling setSpeed on this object will set the speed
on all contained sensors.
Change-Id: I850e2d69067813005270105618fcf69b04382b03
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
| |
Create the fan manager class.
Check in the fan zone data as a normal file. In a future commit
this will be generated during the compile. It is required now
for review and so everything compiles.
Change-Id: I5733b81db80c5e072abdbffd42e335fa46c61ef8
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
|
|
|
|
|
| |
Change-Id: I9cb2037dc459516f577fc2bff91cccafea539eff
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
|
|
|
|
|
|
|
|
| |
LDFLAGS is for linker flags other than -lfoo:
https://www.gnu.org/software/automake/manual/html_node/Linking.html
Change-Id: I813e093ff8c7b824178d7170ca7c71982e49a53b
Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
|