| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
| |
loggingPath is not populated after args are parsed.
Tested: with -l, swampd correctly generated logs
Resolves: openbmc/phosphor-pid-control#12
Signed-off-by: Kun Yi <kunyi731@gmail.com>
Change-Id: Ic103879f6b65d4e89c49e8d9700c5d71b9549f4d
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Now that asio is being used instead of threads, we can
reload the fan configuration without having to restart the
application. This moves the ownership of the passive and host
bus outside of the SensorManager so that it can be recreated
each reload.
Tested: Watched logs and saw full fan config get reloaded
after changing fan configuration
Tested: Ran on json configured system and it behaved as
expected.
Change-Id: I00e6b27f75384fd41de2017b723f159c9691ae97
Signed-off-by: James Feist <james.feist@linux.intel.com>
|
|
|
|
|
|
|
|
| |
Verify the logging parameter is explicitly a directory. Treat the path
as a directory for creating the logging files.
Signed-off-by: Patrick Venture <venture@google.com>
Change-Id: I84d6be79780df3f52deeb1ff1b7a50de6175c055
|
|
|
|
|
|
|
|
|
| |
add a flag to enable/disable tuning: default off
add an option for specifying a folder for outputting logs.
Closes: #10
Signed-off-by: Patrick Venture <venture@google.com>
Change-Id: I43864768f1dee8672f13288d3cf5a0c87c373aed
|
|
|
|
|
|
|
| |
Remove check that the log file path exists.
Signed-off-by: Patrick Venture <venture@google.com>
Change-Id: I8324ea847fd57de54ab1a9d252fd12a3ddafc4d8
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This converts phosphor-pid-control into an async
single threaded application. The reason for doing this
is on our systems phosphor-pid-control had the largest
VSZ when viewed under top. Before this patch the VSZ
was at 50720, after it is at 7760.
Tested-by: Could still interact with all interfaces
under rest-dbus and sensor override worked to ramp fans
when changing cpu temps.
Change-Id: Ie0a837bdf0d1b1df61dc7aff87e5d503b9e0e875
Signed-off-by: James Feist <james.feist@linux.intel.com>
|
|
|
|
|
|
|
| |
Swap out getopt for cli11 for parsing parameters.
Change-Id: If6845c359dafc28b545925faa4701d401c7b8dd2
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
|
|
|
|
| |
Add a variable that when set, enables tuning logging. This variable is
set to false.
Tuning can be enabled via "-t" "--tuning" on the command line.
With a parameter is the path where to write the logging information.
Change-Id: I6eb8035d56cc3301face21e9375c02fc9fcc5b31
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
|
|
| |
Put rest of conf.hpp in the conf namespace. This is
largely a sed replace, and wrapping from_json in
conf namespace as it failed to build.
Change-Id: I9fe5c7b2fface44618c43af2367035afc39bcb64
Signed-off-by: James Feist <james.feist@linux.intel.com>
|
|
|
|
|
|
|
|
| |
phosphor-pid-control now only supports json configurations and no longer
builds from a YAML configuration.
Change-Id: I25fa7766399a1345dca89aac20e7b49caa46797e
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
| |
Override the yaml built objects if there is a configuration file.
Change-Id: Id7b21fa171f5f133b2d888b4095047551b3d65b9
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
|
| |
If swampd is compiled to check for its configuration at run-time, it
will check one specific path.
Change-Id: I5c37ccbb2229db742c0f43b3d9ee0c368df19479
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
| |
Parse the configuration file as json and not libconfig++.
Change-Id: Ic3e71cc810195387617b545566cf757c61c71942
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
new_default now returns a reference to a single bus,
phosphor-pid-control uses multiple busses so we do not
want that. This was the way it was implemented prior to
https://github.com/openbmc/sdbusplus/commit/8ca6025eed193c252149b2908c3d5e37b00b0107
Tested-by: swampd ran normally
These errors go away:
Jan 28 18:28:45 swampd[1760]: terminate called after throwing an instance of 'sdbusplus::exception::SdBusError'
Jan 28 18:28:45 swampd[1760]: what(): sd_bus_request_name: org.freedesktop.DBus.Error.InconsistentMessage: Bad message
Change-Id: I708cd5e6c45509f27d4fe783c0b0cfb52ff10336
Signed-off-by: James Feist <james.feist@linux.intel.com>
|
|
|
|
|
|
|
|
|
| |
Drop unused headers from main.cpp:
- experimental/any
- mutex
Change-Id: I1bd0180e8582bc9c80e67bbb5e3bb5d040c218cc
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
| |
Miscellaneous camel casing.
Change-Id: I90f7ab36448ad7c6a8e22677345d9d15591a64d5
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
| |
Rename the main global variables per openbmc style.
Change-Id: I9de8cf841304f24238ae0275b6904f4926a6892d
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
| |
Fix function names to be lower camel.
Change-Id: I145e1f4c03d7740bc1525dcffbdce2f78fd61075
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
| |
Fixup naming of structures to UpperCamel.
Change-Id: I6a9bf0b954298089c85d3362e86cd95b3fc5b944
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
| |
Apply const to read-only iterators to indicate intent more clearly.
Change-Id: Ic14304c69361da203d3d3a900180bd54346acc87
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
| |
Various things caught by cppcheck that are non-critical.
Change-Id: I495453c84bc15788b85036a163ee36b0ac601fa1
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
|
|
|
| |
The external references to the configurations are provided by the
dbusconfiguration.cpp. Make including this configured.
Tested: Now platform without dbus configuration properly configures
zone.
Change-Id: I97646141aa5672afaadd5346152dfbb07557b2d9
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
| |
Change-Id: I6627b5569c2e0f730be7331403218b823a2c622f
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This allows configuration of PID control from dbus using
entity manager. Sample configuration will be pushed to
entity-manager repo shortly.
Tested-by: Used yaml configuration and dbus / entity-manager
based configuration and pid seemed to work the same.
Verified printout of configuration matched generated
cpp files.
Change-Id: Ia7b016e53262791ffcccdb9b21c1ccddae2926bc
Signed-off-by: James Feist <james.feist@linux.intel.com>
|
|
|
|
|
|
|
|
|
|
| |
To enable unit-testing, split the builders into their own
object files.
Tested: Ran on quanta-q71l board and it behaved as expected.
Change-Id: I92168ec9ae4946d12328e9c0b94a36bb89d0f718
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Enabled unit-tests in general for the project, and more
specifically started with a benign construction test for
the SensorManager object.
Tested: Verified continues to build and link, and unit-test
passes.
Tested: Ran on quanta-q71l board and it behaved as expected.
Change-Id: I4ad9a0c57efd0b9ccc37d26faa0cc1b82026b8d7
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
To increase testability, split out the building of sensors
from the sensor manager. And this further splits out building
from a configuration file.
Tested: Verified code continued to build and link.
Tested: Ran on quanta-q71l board and it behaved as expected.
Change-Id: Ib63a11e1107b1864c3c370bba2bd9ef2effa42f3
Signed-off-by: Patrick Venture <venture@google.com>
|
|
|
|
|
|
|
|
|
| |
Spelling errors found using github.com/lucasdemarchi/codespell
A tool to fix common misspellings.
This tool is licensed under GNU General Public License, version 2.
Change-Id: I1de3fdd00d0c132987b1eeb78b2945f30d3ab538
Signed-off-by: Gunnar Mills <gmills@us.ibm.com>
|
|
This includes the scripts for the YAML parsing and the
main execution point.
Change-Id: If42154c621353b23370b63d4e58f6c75bca8b356
Signed-off-by: Patrick Venture <venture@google.com>
|