summaryrefslogtreecommitdiffstats
path: root/apphandler.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Modify Get Device ID to use Context::busVernon Mauery2019-06-051-17/+30
| | | | | | | | | | | | Now that a bus pointer is available via the Context for every IPMI command handler, make use of it for Get Device ID. Tested-by: run Get Device ID and verify results: ipmitool raw 6 1 23 00 00 00 02 bf 57 01 00 7b 00 00 00 00 00 Change-Id: I2ae5f59623767c7ae059340758a8d042acfb00e9 Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
* rewrite Get Device GUID to use new provider APIVernon Mauery2019-05-201-97/+53
| | | | | | | | | | | | | | | Modify to use the new provider API. One by one, change calls to remove any legacy API constructs. Tested-by: ipmitool 6 8 30 ba 05 cd 7e 9d ac 89 4a 4c 52 ef f3 24 2d 5f (with matching change from bmcweb:) curl https://<bmcip>/redfish/v1/Managers/bmc ... "UUID": "5f2d24f3-ef52-4c4a-89ac-9d7ecd05ba30" Change-Id: I4cd3b945f76b4fe6c4fcf31d8e1962aaa768828e Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
* apphandler: move get ACPI power state to new APIDeepak Kumar Sahu2019-05-091-21/+21
| | | | | | | | | | | | | | Rewritten "Get ACPI power state" command to use the newly introduced IPMI provider API. Tested: Verified using ipmitool and it is giving same behaviour as before. ipmitool raw 0x06 0x07 05 03 Change-Id: I51f2d5bbb89e445230ffc1363cf413e716116996 Signed-off-by: Deepak Kumar Sahu <deepakx.sahu@intel.com> Signed-off-by: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com>
* apphandler: catch exceptions in getting bmc statePatrick Venture2019-05-071-1/+19
| | | | | | | | | | | | | | | | | | If the xyz.openbmc_project.State.BMC interface is not provided by anything in the inventory, provide a mechanism for specifying a default state with regards to the BMC state. The dev_id.json file now can have a boolean field, availability, that sets the default that the Get Device Id command should use in the event the interface is unavailable or that there is a dbus error. The default value for the state of the BMC is true. Currently, the service in OpenBMC providing the real value via the dbus interface simply checks that a systemd target is Active. The systemd target checked is the one that starts all the OpenBmc default services, including ipmid. Signed-off-by: Patrick Venture <venture@google.com> Change-Id: Iba2c8308544337490905b0b48ba95785e0d775d4
* apphandler: Master write read - whitelist filterRichard Marian Thomaiyar2019-05-071-0/+282
| | | | | | | | | | | | | | | Support added for master write read IPMI command with whitelist filter support. Allows commands which are listed in the whitelist filter. Tested: 1. Verified with filter list and able to execute whitelisted commands as per the mask 2. verified command throws invalid field in request for non whitelisted filters. Change-Id: I8f20808a8a2d9afc10747485a1303492329a6996 Signed-off-by: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com>
* move variant to std namespaceVernon Mauery2019-04-181-13/+12
| | | | | | | | | | | sdbusplus::message::variant_ns has been std for a while now. This moves ipmid away from sdbusplus::message::variant_ns to directly use std::variant. Tested-by: built, compiles, and runs the same as before. Change-Id: I8caa945f31c926c2721319f001b9d7f83fd3f1b7 Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
* rewrite Reset Watchdog Timer command to use new provider APIVernon Mauery2019-04-111-2/+3
| | | | | | | | | | | | Modify to use the new provider API. One by one, change calls to remove any legacy API constructs. Tested-by: ipmitool mc watchdog get ipmitool mc watchdog off ipmitool mc watchdog reset Change-Id: If6cd1d921908dc7f5462e99b0098b4897e743ebb Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
* Fix up Get Device ID to use the new return helpersVernon Mauery2019-04-111-2/+2
| | | | | | | | | | The Get Device ID rewrite went in before some feedback had come along to add helper return functions for more readable error codes. Tested-by: Built and runs Get Device ID as before. Change-Id: I7e31ad3cff75acb11bda5ee06f60429552a61ed5 Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
* Only include ipmid/api.hpp for the new APIVernon Mauery2019-04-081-2/+0
| | | | | | | | | | | | | | After some feedback from users of the new IPMI API, they wanted to see two things: 1) don't require ipmid/api.hpp and ipmid/registration.hpp to be able to write new handlers 2) only require including ipmid/api.hpp (instead of ipmid/api.h) So now, by simply including ipmid/api.hpp instead of ipmid/api.h (deprecated), handlers incorporating the new IPMI API can be written. Change-Id: I446dcce70cff03d4ecc28c658292d052485f77fc Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
* remove app wildcard handlerVernon Mauery2019-04-051-21/+0
| | | | | | | | Tested-by: ipmitool raw 6 0x88 -> returns c1 Change-Id: I1f22a70d135ed0ab39c6b1fbacf41e8d5ff20b65 Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
* rewrite Get BT Capabilities using new provider APIVernon Mauery2019-04-051-21/+13
| | | | | | | | | | | Modify to use the new provider API. One by one, change calls to remove any legacy API constructs. Tested-by: ipmitool raw 6 0x36 01 3f 3f 0a 01 Change-Id: I9be3d21c041ba1d99f6672c4501faafcca117d11 Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
* rewrite Get Self Test Results to use new provider APIVernon Mauery2019-04-051-20/+7
| | | | | | | | | | | Modify to use the new provider API. One by one, change calls to remove any legacy API constructs. Tested-by: ipmitool raw 6 4 56 00 Change-Id: I3cf0a9bd93df6b12584861b4c60b272ff84b7dae Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
* rewrite Get Device ID using new provider APIVernon Mauery2019-04-051-72/+70
| | | | | | | | | | | Modify to use the new provider API. One by one, change calls to remove any legacy API constructs. Tested-by: ipmitool raw 6 1 check for expected output Change-Id: I59688627eb32670559c1defad0b7af8abeb84c75 Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
* update apphandler #include to match styleVernon Mauery2019-04-011-7/+8
| | | | | | | Remove the "" style includes in preference of the <> style Change-Id: I74bfa4dcadeaca7fe2341d5a9221844ebe2653b8 Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
* Remove old channel commandsVernon Mauery2019-04-011-19/+1
| | | | | | | | | New channel commands have been implemented in user_channel/channelcommands.cpp This removes the old, unused command implementation Change-Id: I054ea053d25865e0d4203f2ae294778d31817637 Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
* remove legacy ipmid.cpp and ipmid.hppVernon Mauery2019-04-011-1/+0
| | | | | | | These two files have now been replaced with newer APIs and can be removed. Change-Id: If60227b24188c6796211ca43379169f9a95c9cb3 Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
* Remove experimental filesystem spliceVernon Mauery2019-03-281-13/+1
| | | | | | | | | | In order to be compatible with older versions of GCC that did not have the experimental filesystem moved over to the standard paths, the code would splice the experimental code into the std namespace. This is no longer necessary with yocto 2.6 and the latest versions of GCC. Change-Id: I2db13c52a91456318795819f2d45c3386b4c56d2 Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
* move types.hpp to ipmid/types.hpp for exportVernon Mauery2019-03-251-1/+1
| | | | | | | | | | types.hpp is required by utility.hpp, which is exported, so it needs to be exported as well. This moves it to the include/libipmid directory, changes the Makefile to export it, and changes all the files that include it so it can be found in the right place. Change-Id: I30ec365446e4de466c266ec4faa327478460ec05 Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
* Move util.cpp/util.hpp to libipmidVernon Mauery2019-03-251-1/+1
| | | | | | | | | | | | | | | | These are functions that are used widely by ipmid providers, so it makes sense to put them in libipmi.so (the library that all providers must link against). Tested-by: use nm to inspect the binaries to see that the symbols are in the expected library. arm-openbmc-linux-gnueabi-nm libipmid.so.0.0.0 \ | grep getDbusObject 0001063c T _ZN4ipmi13getDbusObjectERN9sdbusplus.... Change-Id: I1221f807f2711c5301c5574623564ea1ae48a437 Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
* Create libipmid and libipmid-hostWilliam A. Kennington III2019-02-071-1/+1
| | | | | | | | | | | | | | | | | | | This starts a transition to common ipmid libraries that providers can link against. It will allow for a cleaner separation between common ipmid functionality and daemon type specific code. This is needed so we can resolve all of the symbols in the providers at link time instead of discovering bad linkage by building and running a full ipmi daemon. In future commits libraries will be packaged for libipmid and libipmid-host which provide all of the symbols used by the current set of ipmid providers. This is the first step, it just separates and renames the headers. Legacy symlinks are still kept around for compatability. It also adds stub libraries so that external users can start linking as intended. Change-Id: I6bbd7a146362012d26812a7b039d1c4075862cbd Signed-off-by: William A. Kennington III <wak@google.com>
* libipmi: Decouple user commandsWilliam A. Kennington III2018-12-201-4/+0
| | | | | | | | | | | | | This makes them an optional, separate provider like the sysfs cmds. Tested: Ran on real hardware that included libusercmds.so in /usr/lib/host-ipmid and on a machine that did not include it. Ran ipmitool on the host to verify that the user commands were present when expected. Change-Id: I07b3af5ae603c3e5f1ea41f0afc309329f4e185d Signed-off-by: William A. Kennington III <wak@google.com>
* std::variant: Fix new instances of mapbox specific callsWilliam A. Kennington III2018-11-261-2/+2
| | | | | | | | Tested: Build and run through unit tests. Change-Id: I87f2d5441b2f029e1e96ee1b46c4c760b0d82aac Signed-off-by: William A. Kennington III <wak@google.com>
* IPMI Channel commands implementationAppaRao Puli2018-11-201-1/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | IPMI Channel commands implemenation - squashed commit e9a75d8dd6e89d17381f0310c7930586c6b79996 Author: AppaRao Puli <apparao.puli@intel.com> Date: Thu Jul 5 14:47:22 2018 +0530 Channel layer separation De-coupling the channel management from ipmi channel commands implementation. This gives flexibility to load only needed stuff in different modules(host-ipmi or netipmid) Change-Id: Ib334562beb9325f7768ed6a15475cae15af17b19 Signed-off-by: AppaRao Puli <apparao.puli@intel.com> Signed-off-by: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> commit 726ddf2af678ea6773f4b4b918fbd49be8c83e6a Author: AppaRao Puli <apparao.puli@intel.com> Date: Thu May 24 16:45:30 2018 +0530 IPMI Channel commands implementation Following IPMI channel commands are implemented. 1) Set channel access (0x40) 2) Get channel access (0x41) 3) Get channel info (0x42) Also added code supported for LAN configuration parameters 1) Authentication Type Support (selector #1) 2) Authentication Type Enables (selector #2) Change-Id: Ic4156378c7756eca383dc3da52114fd119346ca6 Signed-off-by: AppaRao Puli <apparao.puli@intel.com> Signed-off-by: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> Change-Id: Ic4156378c7756eca383dc3da52114fd119346ca6 Signed-off-by: AppaRao Puli <apparao.puli@intel.com> Signed-off-by: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com>
* Implement IPMI ACPI set/get commandsYong Li2018-11-201-1/+263
| | | | | | | | | | | | | | | | | | | | | | | The IPMI ACPI set/get power state commands are provided to allow system software to tell a controller the present ACPI power state of the system. This is an independent setting that may not necessarily match the actual power state of the system. The commands are used to enable the reporting of the power state, it does not control or change the power state. The ACPI status will be saved into flash by settings manager. Tested By: Set ACPI: ipmitool -H <IP> -P 0penBmc -I lanplus raw 0x06 0x06 0x86 0x83 Get ACPI: ipmitool -H <IP> -P 0penBmc -I lanplus raw 0x06 0x07 Change-Id: I6d00c0aec931b98d6691d7c4a54698e08d317aa4 Signed-off-by: Yong Li <yong.b.li@linux.intel.com>
* Basic IPMI User Management SupportRichard Marian Thomaiyar2018-11-201-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Squashed commit containing Basic User Management implementation Unit Test: 1. Verified both Host & NetIpmid works fine. 2. Verified user related command responses commit b46b869c0a3958a572b976b3bbaf6b5f33673778 Author: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> Date: Tue Aug 7 15:30:32 2018 +0530 Fix static objects to directly link user layer User layer library has to be directly linked with netipmid in order to be used in RAKP commands. Hence user layer library should not initialize the static bus objects in file scope, as ipmid_get_sd_bus_connection() won't be available during this time. Hence moved it under function scope and initialize it later. Unit test: Made sure, with this change it is loaded perfectly under phosphor-ipmi-host & phosphor-ipmi-net and responding to all user commands Change-Id: Id3f2e06580ca41b0347176ca33e011bf7b048c6a Signed-off-by: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> commit dc60516c45234379a30ad8b03b1cbe53978faeae Author: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> Date: Tue Aug 7 15:22:37 2018 +0530 Fix to use proper user index for set user name Fix to use proper user index, instead of bailing out on first empty index. If user creation is requested on random index with previous index empty, then signal handler updates the data in first empty index, instead of traversing the user list fully. Fix added to mark the first free index, and still search for match to skip if found. Unit Test: Verified that user added in random index shows in that index using ipmitool set user name command. Change-Id: I30d9b884a5bae98b243ccf8ba7da194ef81355e6 Signed-off-by: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> commit 0b9a81a1261b08ea13ad8777d0d80dad937e9972 Author: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> Date: Fri Jul 6 15:57:02 2018 +0530 Converting json store to array for user config Addressed comments to convert to array instead of key value pair. Testing: Performed basic testing of user management commands in both host & netipmid, by repeatedly restarting the same. Change-Id: I2e51ded3e2299fa196d868213950d96c72886358 Signed-off-by: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> commit 182c945657b29acaeb13fc44129e0ed929013e59 Author: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> Date: Sat Jun 30 00:07:28 2018 +0530 Fix D-Bus paths for user management Fix D-Bus path as per upstream code in user management Change-Id: Idb22bee4365520f3d58e70ff61b02d6f6512d707 Signed-off-by: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> commit cd5e22b16f8805dda396311b06994a9e021e97e9 Author: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> Date: Thu Jun 28 06:22:27 2018 +0530 Json format to store user config & cleanup Code updated to use json format to store and read the user configuration data. Few basic cleanup's performed. Change-Id: I7005f4f2648ccb8214312982a755ddcc6c33e64d Signed-off-by: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> commit 95ca9a67a4b84df603db0eb6a7024e9e0e5ad342 Author: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> Date: Wed May 30 15:16:47 2018 +0530 Get & Set User Access command implementation Get & Set User access command implementation Change-Id: I4f7a86de95400387c47ae556127baa1f02a703b2 Signed-off-by: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> commit b2dea762362d06b70576dba5f45552d548792cb9 Author: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> Date: Fri May 18 23:46:23 2018 +0530 User layer separation. Separated out user commands from the implementation details, by creating user layers. App Handler library and netipmid will directly rely on this user_layer.so Change-Id: Ie7d4b3a5a934e32da73e066a25da4c27485c59c8 Signed-off-by: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> commit 63e3113e522ecc7ce6e5aa1c85de4dc9b9a65a7b Author: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> Date: Mon May 7 12:00:06 2018 +0530 Updated user management ipmi support 1. Relying on Object Manager & D-Bus properties signal (except user rename, for which still relying on user rename signal) 2. Minor clean-up. Change-Id: I594e7823a2c626bb7c88ec54a3ffa89a60b09c65 Signed-off-by: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> commit 3e7b774c842917743369569790612d74387c755e Author: AppaRao Puli <apparao.puli@intel.com> Date: Tue Apr 24 22:01:15 2018 +0530 Synchronize user manager data during ipmi startup Synchronizing the user information by reading all managed user objects from dbus and checking ipmi user data for any update/delete/add users. Change-Id: I9e1a62ec9dd186a7276d083a57e679606d635e05 Signed-off-by: AppaRao Puli <apparao.puli@intel.com> Signed-off-by: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> commit 92298ac0f591d167b0e26b977316a2b136127778 Author: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> Date: Tue Apr 24 21:34:08 2018 +0530 Minor fix: Read user enabled state in signals Fixed to read user enabled state in signal handlers. Change-Id: I0aa6c4687c16e08d8e304315e85cb65e9dbd346a Signed-off-by: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> commit 8646d2683fc247ce02a0460f9577276eb6e0a581 Author: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> Date: Wed Apr 11 22:18:44 2018 +0530 Signal handler update Support added to handle group, privilege user rename, enable / disable signal, and update the database accordingly. Change-Id: Ia33d063715a35814bbe1f9220e9609b800261e33 Signed-off-by: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> commit fa411b2c4bbef50175b084889a4829206263ebdb Author: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> Date: Mon Mar 12 23:42:34 2018 +0530 Add Basic user manager support - IPMI Add basic user manager support in IPMI Creates user through D-Bus user interface and sets password using pam_chauthok(). Lock & File reload mechanism also implmeneted. UserUpdate signal handler support added to update user in IPMI, when users are updated through different interfaces. Change-Id: I1adc538562615109189d7c19dadae0b6a109f4a5 Signed-off-by: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> Change-Id: I1adc538562615109189d7c19dadae0b6a109f4a5 Signed-off-by: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com>
* Convert variant usage to std interfaceWilliam A. Kennington III2018-10-181-10/+14
| | | | | | | | | | | | | This is just a refactoring to use the c++17 std::variant interfaces instead of the mapbox::variant specific ones. We should be able to use mapbox::variant and std::variant interchangeably now. Tested: Built against sdbusplus with mapbox::variant and sbusplus using std::variant. Both variant compile and test out. Change-Id: I6fbaad3d12dd34968db6a10f3d74a65e07d0f0cc Signed-off-by: William A. Kennington III <wak@google.com>
* apphandler: Fix buffer underflow in ipmi_app_get_device_guidEmily Shaffer2018-10-011-0/+12
| | | | | Change-Id: I7e27130bbe8bfc847f81968d850abacb8914ad78 Signed-off-by: Emily Shaffer <emilyshaffer@google.com>
* add std namespace prefix to common methodsPatrick Venture2018-09-251-8/+8
| | | | | | | | Standard clib methods should be explicitly grabbed from the standard namespace. Change-Id: I8bcfcb260a99180d535ec8102c1a24c318cbc209 Signed-off-by: Patrick Venture <venture@google.com>
* move filesystem inclusion to bottom of listPatrick Venture2018-09-251-15/+14
| | | | | Change-Id: I4aa3c984992236bb5b4a5c62c3d42a33c12d55de Signed-off-by: Patrick Venture <venture@google.com>
* replaced c headers with cpp where applicablePatrick Venture2018-09-251-2/+0
| | | | | Change-Id: I23a70eb540ccde5d2aba467426769feffb07b516 Signed-off-by: Patrick Venture <venture@google.com>
* rename headers to match stylePatrick Venture2018-09-251-3/+3
| | | | | | | | | | | | | | | | | | Moving headers from ".h" to ".hpp" Reworked the header inclusion a bit so that host-ipmid is treated as a library, and local headers aren't. renamed apphandler.h => apphandler.hpp renamed chassishandler.h => chassishandler.hpp renamed globalhandler.h => globalhandler.hpp renamed sensorhandler.h => sensorhandler.hpp renamed storageaddsel.h => storageaddsel.hpp renamed storagehandler.h => storagehandler.hpp renamed systemintfcmds.h => systemintfcmds.hpp Change-Id: I9d4ce3dd57e2e996800f9020a10cc10cdf2c3914 Signed-off-by: Patrick Venture <venture@google.com>
* apphandler: Add "System Name" System Info parameterXo Wang2018-09-251-0/+15
| | | | | | | | | Use the BMC's hostname to respond to requests for the "System Name" parameter. Signed-off-by: Xo Wang <xow@google.com> Change-Id: I23845aab6091a0d003b6f8370d2b67fc11e580e8 Signed-off-by: Patrick Venture <venture@google.com>
* apphandler: Implement Get/Set System Info ParameterXo Wang2018-09-251-8/+176
| | | | | | | | | | | | | | | | Implement Get System Info Parameter using the parameter storage code to back the string-type parameters. Supports up to 255 chunks (known as "sets" in the spec) for those parameters. Currently, iterated reads by chunk of a string parameter will repeatedly invoke that parameter's callback, which can result in chunks being incoherent with each other if the string changes between invocations. This is noted in a TODO comment. Stub out Set System Info Parameter. Full implementation for that is pending support for read-only flags in the parameter storage code. Change-Id: If0a9d807725ccf1f1f62e931010024841575469c Signed-off-by: Xo Wang <xow@google.com> Signed-off-by: Patrick Venture <venture@google.com>
* Get Device ID: Add handling of availability bitAlexander Amelkin2018-09-251-2/+32
| | | | | | | | | | | Make "Device available" bit in Firmware Version 1 field reflect the ready state of BMC as indicated in DBus by CurrentBMCState property of xyz.openbmc_project.State.BMC interface. Change-Id: Ic108507882c68d6cc70b40849668732f7b759ef6 Signed-off-by: Alexander Amelkin <a.amelkin@yadro.com> Signed-off-by: Alexander Filippov <a.filippov@yadro.com>
* Implement Set Channel access commandTom Joseph2018-09-251-0/+4
| | | | | | | | The only option supported is the access mode for disabling or enabling the network IPMI. Change-Id: I2e6b20c317fec19e1e71b3adfc211e6fb847f737 Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
* add .clang-formatPatrick Venture2018-09-071-173/+147
| | | | | Change-Id: I7c2a527b4751a560703a61fcbe9638b150546af5 Signed-off-by: Patrick Venture <venture@google.com>
* Standardize use of filesystemVernon Mauery2018-08-081-2/+12
| | | | | | | | | If <filesystem> exists, use that, if it doesn't, try <experimental/filesystem>. Either way, access it from std via a namespace splice. Change-Id: I5b35ee9f74b88e188cb3ca3fed9abaec64933697 Signed-off-by: Vernon Mauery <vernon.mauery@intel.com>
* Reducing IPMI logging footprintAditya Saripalli2018-04-181-44/+10
| | | | | | | | | | | | -host-ipmid is very noisy in terms of journal logging. A small step towards cleaning that up. -Also converted printfs to phosphor-logging. Partially Resolves openbmc/openbmc#2507 Change-Id: I749c19c18d1cabf6f0216830c8cb0a08ee43d6de Signed-off-by: Aditya Saripalli <aditya0124@gmail.com> Signed-off-by: Nagaraju Goruganti <ngorugan@in.ibm.com>
* Implement Get Channel Cipher Suites commandTom Joseph2018-04-161-0/+7
| | | | | Change-Id: I8c808ce7e2bbd3ae5e225573138d7e04871f1643 Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
* setlan: Remove registration of handler for Set Channel AccessRatan Gupta2018-03-201-10/+0
| | | | | | | | | | | | | Presently through set channel access command we apply the network changes which is not a standard BMC implementation. It was decided that we should apply the network changes with the timer based approach. Timer based implementation would be done in later commits. This commit only removes the registration handler for set channel access command. Change-Id: Ic67c09d0f688d30be0fc7bfcda4f3290f89baf20 Signed-off-by: Ratan Gupta <ratagupt@in.ibm.com>
* Change the byte order for aux firmware revisionTom Joseph2018-03-161-4/+4
| | | | | | | | | | According to the specification, any generic utilities should display each byte as 2-digit hexadecimal numbers, with byte 13 displayed first as the most-significant byte. This patch corrects the byte order so that byte 13 represents the most-significant byte. Change-Id: Ie71d2af6a9e9f14c8d1d12cea7e45a57aa15a3dd Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
* Remove use of legacy inventory interfaceNagaraju Goruganti2018-03-121-35/+111
| | | | | | | | | | | | | | | | | | | Made below given changes: 1.With legacy code we used to read software version info from the system file: /etc/os-release, now with new updates we will read it from the s/w object which is implementing the interface "xyz.openbmc_project.Software.RedundancyPriority" interface. 2.Removed legacy code related to inventory(FRU) for sensors Tested: 1.Verified f/w version info using below given command >ipmitool mc info -I dbus 2.Verified get sensor type info using below given command >ipmitool raw 0x04 0x2f 0x02 -I dbus Resolves openbmc/openbmc#2870 Change-Id: I384bf4aaacd56f4a871833b533b2a8a68c489959 Signed-off-by: Nagaraju Goruganti <ngorugan@in.ibm.com>
* Remove unused variables.Nagaraju Goruganti2018-02-271-4/+0
| | | | | Change-Id: I9c8ea4fbf7421ceef1e509cb78dea7136fd0a94b Signed-off-by: Nagaraju Goruganti <ngorugan@in.ibm.com>
* watchdog: Implements the Watchdog Get CommandWilliam A. Kennington III2018-02-211-0/+7
| | | | | Change-Id: I2ba9fd0eeba4e828cafd1bcf6fe30e2322eaf99e Signed-off-by: William A. Kennington III <wak@google.com>
* watchdog: Reorganize header and function namesWilliam A. Kennington III2018-02-151-2/+2
| | | | | | | | This is a refactoring of names + header cleanup and has no functional change. Change-Id: Ie90fded80b6a26927f56bb342993193530b8b8ef Signed-off-by: William A. Kennington III <wak@google.com>
* apphandler.cpp: fix-up 80 charsPatrick Venture2018-02-091-38/+104
| | | | | | | Cleaned up lines to address lines >80 chars. Change-Id: I2aa8ebb91f4af875275fb00f7444698e89c53b89 Signed-off-by: Patrick Venture <venture@google.com>
* DCMI : Implement Get System GUID commandMarri Devender Rao2018-01-191-0/+74
| | | | | | | | | | | Implemented IPMI Get System GUID command. It reads data from the DBUS object which is in RFC4122(MSB) format and converts to LSB format and returns. Resolves openbmc/openbmc#2620 Change-Id: I95f0aa596695bf1f903b4c2cc1d64df80bdd3de9 Signed-off-by: Marri Devender Rao <devenrao@in.ibm.com>
* Get Device ID - JSONDavid Cobbley2018-01-041-59/+69
| | | | | | | | | | | | | | This reads in all the get device ID parameters via a JSON file in the rootfs. Using a file in the rootfs will give much more flexibility to consumers of openbmc. Each ODM can simply bbappend their dev_id.json with their own specific get device ID info in. Now you can compile in the required info at build time, or modify during run time if needed. It also does not require any additional compilers/scripts to generate a yaml file. Change-Id: I44dfda54fa1762f88973ad709bf7a50bf32e492d Signed-off-by: David Cobbley <david.j.cobbley@linux.intel.com>
* IPMI device ID command mismatch with BMC current side issue fix.Dinesh Chinari2017-12-051-32/+66
| | | | | | | | | | Revisited convert_version sub routine. It should now work for also v1.x.y strings, e.g: ibm-v1.99.10-113-g65edf7d-r3-0-g9e4f715. Resolves: openbmc/openbmc#1480 Signed-off-by: Dinesh Chinari <chinari@us.ibm.com> Change-Id: I5acf028a907af8a1a3bbecd6709bcbac45c877e1
* Spelling fixesGunnar Mills2017-10-311-2/+2
| | | | | | | | | 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: I78e9d126f19fd9fb2e3f2fa9fe8c2404dc505f82 Signed-off-by: Gunnar Mills <gmills@us.ibm.com>
OpenPOWER on IntegriCloud