summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* Use a std::literal for dbus wait durationBrad Bishop2017-01-161-1/+4
| | | | | Change-Id: Iad1cf94b7665253fd25d0049af737c46b7f97796 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Use std::thread in favor of direct pthread accessBrad Bishop2017-01-162-15/+7
| | | | | Change-Id: I7f2927deee84701f3ed7bec86ec97171a5daabb8 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Add volatile keyword on shutdownBrad Bishop2017-01-131-1/+1
| | | | | Change-Id: I7448507cf8f18036be6c25bf4ba9d5dd8c2ba768 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Remove decltype where unnecessaryBrad Bishop2017-01-122-2/+2
| | | | | Change-Id: I0d1b9107810a3aaac1f52517b3ff220fdf567ee3 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Run astyleBrad Bishop2017-01-127-401/+427
| | | | | Change-Id: Iec4802e9837465a7deb1fd7fd57a2068cc18c50d Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Fix broken usage of emplaceBrad Bishop2017-01-121-10/+5
| | | | | | | No need to construct a temporary when using emplace. Change-Id: I224054855d0098e128973b8bea23ac000e7231f6 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Add a testcase for setPropertyBrad Bishop2017-01-122-3/+62
| | | | | Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com> Change-Id: Ifade8963ebc8d18dbdca46ece16800cf8ea8a6ad
* pimgen: Add support for setPropertyBrad Bishop2017-01-122-4/+48
| | | | | | | Add code generation support for setProperty actions. Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com> Change-Id: Id367f6da075035824c8f2ae6302505ef625a629a
* Add setProperty actionBrad Bishop2017-01-122-0/+64
| | | | | | | | The setProperty action sets a property to a predefined value when a match occurs. Change-Id: Ibd3cbb0da86a99e823b9cc00cc0240772d895f7f Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Add interface exposing utility functionsBrad Bishop2017-01-123-0/+79
| | | | | | | | Add utility functions enabling easy method calls on sdbusplus interface binding objects. Change-Id: Ie1d01f82604406705869fea0ec19d84c95d90474 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Add a testcase for destroyObjectBrad Bishop2017-01-122-7/+124
| | | | | | | | | | Validate that: -Dbus signal callbacks are established. -The propertyChangedTo filter works correctly. -The destroyObject action works correctly. Change-Id: I0981fed76aa26ff275a401ae81fd230833dfc4cc Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Fix a bug with property change filterBrad Bishop2017-01-121-2/+5
| | | | | | | | | | With strings, propertyChangedTo is instantiated with const char* resulting in the typical pointer x == y comparison bug. Fix by first converting to std::string. Change-Id: I51fe5f3746b8dd8ca094e4662103d41f75e2972f Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Rewrite pimgen in the image of sdbus++Brad Bishop2017-01-124-158/+364
| | | | | | | | | | | Almost complete rewrite of pimgen and the mako template. Adopt the sdbus++ application structure. The hope is that this will encourage additional sdbusplus features deemed general purpose enough for reuse with other applications. Change-Id: I007ff9f5fc9a64f0465159bd1301475ada139d55 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Allow arrays of dbus eventsBrad Bishop2017-01-123-34/+54
| | | | | | | | The current event <-> action relationship is one to many. Allow a many to many relationship to be expressed. Change-Id: Ibfb995cbf677b21757864dc62d9a3818af6c2aa3 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Add event frameworkBrad Bishop2017-01-114-11/+68
| | | | | | | | Introduce the concept of events, where the existing Dbus signal match event is one of many possible event classes. Change-Id: I9b0c6ca12daaa109f8ceb537a5fb0cc6b5f7181b Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Use a vector for eventsBrad Bishop2016-12-153-4/+3
| | | | | | | | | The events structure is never inserted into, searched and the keys aren't used. This was a poor choice of data structure. Change-Id: I46135e9128b3380712234e86674e53af10b37053 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Move filters.hpp to events.hppBrad Bishop2016-12-152-1/+1
| | | | | | | | | Prepare for a more generalized event description framework enabling event classes other than DBus signal matches. Filters become a sub-concept within that framework so rename the file. Change-Id: I0be9f9997239aad6e798ca16055aedc3e1233994 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Enable multiple actions per eventBrad Bishop2016-12-153-6/+8
| | | | | | | | Reduce the number of dbus signal callbacks by enabling multiple actions for a single event. Change-Id: I944eea6ac450c2ea9a201e724765edbef4e677b4 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Enhance notify testcaseBrad Bishop2016-12-151-17/+115
| | | | | | | | | Validate signal content rather than doing explicit property lookups. This avoids race conditions and additionally validates that a signal is sent with the correct values. Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com> Change-Id: Iaf13b1dfd68eeaf8ab7e8dc3bf045f824c3c803a
* Removed duplicated Holder adaptersBrad Bishop2016-12-156-246/+219
| | | | | | | | Refactor copy/pasted action/filter/interface object adapter types into a single templated framework. Change-Id: Iafbd814572a7db13fddc5314617e310fe5f0a062 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Use sdbusplus object wrapperBrad Bishop2016-11-223-3/+11
| | | | | | | | | | | Use sdbusplus::server::object::object to wrap interfaces. This is the preferred way to ensure created objects emit freedesktop ObjectManager signals. Resolves openbmc/openbmc#756 Change-Id: Ia57057e0227ed92bef77f28e42942194f5e802f3 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* React to sdbus++ updatesBrad Bishop2016-11-223-4/+9
| | | | | | | | Update example interfaces to use non language specific type specifiers. React to namespace shuffling in sdbusplus 7aa8a1e2e. Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com> Change-Id: Ib0688056d6fcfbe298d8a24ae9df604cd05fa620
* Add gitignoreBrad Bishop2016-11-222-0/+32
| | | | | Change-Id: Id6bf8564ea4b99dbd80d0326359e2c3ad8e3ab7d Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* build: Fix out of tree build issuesBrad Bishop2016-11-212-2/+2
| | | | | | | | Eventually server.hpp will come from an external shared library. Until then, iquote it while it lives in-tree. Change-Id: If0f7da8e2c951443fea0d623ad03a7c54a5a5ee9 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* build: Makefile.am refactoringBrad Bishop2016-11-211-4/+3
| | | | | | | Formatting only. No functional change. Change-Id: I01271bff8a5018326251ab60d49524537c1a7a8d Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* build: Add targets for generated filesBrad Bishop2016-11-212-10/+31
| | | | | | | | | | | Add a target for generated.cpp. Add targets for extra interfaces. Remove example configure option - this is now driven by the input yaml filesystem. Add YAML_PATH autoconf variable. Change-Id: Ieff734948088d3252e346a8dcc0e1dd6caf83333 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* pimgen: Add list-interfaces command optionBrad Bishop2016-11-211-11/+23
| | | | | | | | list-interfaces simply prints out all the interfaces found in interfaces.d. This intended user is configure. Change-Id: I5e2c6b59ae4addb04f2e82b084122a948e46d29f Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* pimgen: Add command positional argumentBrad Bishop2016-11-211-1/+7
| | | | | | | In preparation for enabling additional commands. Change-Id: I16ec80c9b8f7eebcfd1a47c6ab7b7fe0e581123b Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* pimgen: Split argument parsing logicBrad Bishop2016-11-211-16/+20
| | | | | | | | Move the non-argument parsing logic out of the main function, in preparation for enabling additional command options. Change-Id: Ib2cd75e432e11982a85a824e607ddf2568de63a9 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* pimgen: Enable multiple interface filesBrad Bishop2016-11-212-4/+16
| | | | | | | | | Allow more than one interface file and put declared interface yaml files in interfaces.d, to draw attention to the intent is for packages to install their interface requirements there. Change-Id: Iab0d85eca7c5c3370978dc692d6ab8807108a2f7 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* pimgen: Rename interfaces to extra_interfaces.dBrad Bishop2016-11-213-1/+1
| | | | | | | | | | Draw attention to the intent is that other packages install files here. Additionally these are 'extra' in that they are above and beyond the standard OpenBMC interfaces that will eventually be provided by a shared library. Change-Id: I8e50d39a1004ff24b1ea7de63e6534447c05a9d3 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* pimgen: Move events to events.dBrad Bishop2016-11-213-2/+2
| | | | | | | | Draw attention to the intent is that other packages install files here. Change-Id: I0a6fbe86a16f39f4bb71a0bea367ec3508b14369 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* pimgen: Combine make_example and pimgenBrad Bishop2016-11-212-38/+49
| | | | Change-Id: I1c79fad6a4b70e711c8aad15c9dd86a07b54bff9
* pimgen: change -o option to be a directoryBrad Bishop2016-11-121-3/+3
| | | | | | | | Previously this was a single file but pimgen will shortly be emitting multiple files. Change-Id: I72693512aa62f323ce090cf8137dcb1251e05251 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Remove sdbus++ template search workaroundBrad Bishop2016-11-121-26/+3
| | | | | | | sdbus++ was fixed upstream to find its templates automatically. Change-Id: I29020b9d1ea4ae8baaca5fe869625a3d96cd6eaf Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Find examples directory when invoked out of treeBrad Bishop2016-11-121-1/+1
| | | | | Change-Id: I5d5a7024c5145b0acd5961f4b942bbff635e94cb Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Find template automatically in script dirBrad Bishop2016-11-121-5/+4
| | | | | Change-Id: I8ef69ab4ef6f92c55a7393620abe134ac748a93b Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Add brief description to example interfacesBrad Bishop2016-11-121-0/+3
| | | | | Change-Id: I69ab3de21da08e320bccd122d1f194691784e7fd Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Look for interfaces.yaml in --dirBrad Bishop2016-11-121-8/+5
| | | | | | Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com> Change-Id: I08e28c6fdb6073d65e6100fbf20c4ae271d04f4d
* Fix templatedir argumentBrad Bishop2016-11-121-1/+1
| | | | | | | The argument is a single template, not a directory. Change-Id: I7a000d9ed09fd445c9ade3388193d5aa190a7809 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Set AC_LANG to C++Brad Bishop2016-11-091-4/+5
| | | | | | | | | And move compiler configuration prior to test macros, otherwise c++14 header tests fail. Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com> Change-Id: I64a7f3d22bb655c06a8ab845e636f27a9cc17c33
* configure: Add gtest enabling foo to configureBrad Bishop2016-11-081-0/+21
| | | | | Change-Id: I91fd696a58e3ac1efc923ff9fa66c5dd71d7449f Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* test: Use libmanager for integration testcaseBrad Bishop2016-11-081-7/+1
| | | | | Change-Id: I82d781923fc84e79262a5ffd2ff64488e777a076 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Put most objects in a libraryBrad Bishop2016-11-081-5/+8
| | | | | | | For easy sharing with other Makefiles. Change-Id: I74635903be0119afcd13e1835cc4f28183f2c38b Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* test: Remove existing test from make checkBrad Bishop2016-11-081-1/+2
| | | | | | | The existing testcase isn't a unit test. Change-Id: I2325d7e641736c5290c7e95d37ab43313695ae58 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Build toplevel before testBrad Bishop2016-11-081-1/+1
| | | | | Change-Id: I68e2440fd15edb8d560f262660047e7f832f519c Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Switch to generated interface factory methodsBrad Bishop2016-11-084-12/+23
| | | | | | | | Automatically populate the association of interface with an appropriate sdbusplus server side interface binding. Change-Id: Ie46d91cf2e6726b033789be6228c10ca14a76220 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* pimgen: Pass interfaces.yaml to Mako templateBrad Bishop2016-11-081-0/+8
| | | | | | | | | Update pimgen.py to pass interfaces.yaml to the Mako template in prep for generating the interface -> binding factory method associations. Change-Id: Ic053628331ef0e5a1ef4a8a9d50ff6f4e662cf08 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Optionally include generated example bindingsBrad Bishop2016-11-083-0/+14
| | | | | | | | Add an autoconf opttion that includes the example bindings, for use in standalone/testing environments. Change-Id: Id44f02a9bc7adcc8b36c09f0867ee1a663d7e25c Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Add example interfacesBrad Bishop2016-11-085-3/+82
| | | | | | | | Add example interfaces for testing. Add a script that generates sdbusplus bindings for example interfaces. Change-Id: I683ce9dca74d827d226833ed8a56f87243914e04 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
OpenPOWER on IntegriCloud