summaryrefslogtreecommitdiffstats
path: root/apphandler.cpp
Commit message (Collapse)AuthorAgeFilesLines
* 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>
* apphandler: channel: split out commandsPatrick Venture2017-10-261-395/+2
| | | | | | | | | | | | | | I split out the channel commands into their own subordinate file from the apphandler.cpp. There are three commands in apphandler for the channel information. There are other commands in the transporthandler that correlate. Moving this is step one in a larger task to enable multiple channels. Change-Id: I2e434a1da942325fc420079415edb39622f4e346 Signed-off-by: Patrick Venture <venture@google.com>
* watchdog: split out commandsPatrick Venture2017-10-251-169/+1
| | | | | | | | | | I split out the watchdog command handlers into their own subordinate file from the apphandler. This reduces the size of the contents of the apphandler file, and logically cuts out code into its own files. Change-Id: Idc70acad6c93c12456cc7092786715643c9c1ffb Signed-off-by: Patrick Venture <venture@google.com>
* Don't set/get zeroconfig address if other IP address is presentNagaraju Goruganti2017-10-111-2/+5
| | | | | | | Resolves openbmc/openbmc#2265 Change-Id: I65b54358f13231c78b3c6488a59b94bc9323484c Signed-off-by: Nagaraju Goruganti <ngorugan@in.ibm.com>
* Independently set the watchdog Interval when setPatrick Venture2017-09-121-6/+6
| | | | | | | | When we receive a set watchdog command, this will now set the Interval value directly. Change-Id: I34b82507cbad95f2ad56932d03a48a80b2dfc11d Signed-off-by: Patrick Venture <venture@google.com>
* SetLan: Make changes in set channel access to support ipsrc paramRatan Gupta2017-09-081-88/+215
| | | | | | | Resolves openbmc/openbmc#2138 Change-Id: I4b4b8e915bcfea6ed5f913ede5f714290483e4f9 Signed-off-by: Ratan Gupta <ratagupt@in.ibm.com>
* Implement Get channel access commandTom Joseph2017-08-161-0/+50
| | | | | | | | | | | | | | | | | | | The get channel access command is implemented to support the set channel access command. The set channel access command is used to apply the network settings. Before the set channel access is issued ipmitool issues get channel access command to get all the fields and then copy into the buffer for set channel access. This would enable the following ipmitool command. ipmitool lan set 1 access on There is no backend support for these settings and values are hardcoded in the command implementation. Resolves openbmc/openbmc#1565 Change-Id: I6c7b2ca7971155b90914ab5b68ab3038bfaba185 Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
* Handle an action byte value of 0 in the set watchdog timer commandPatrick Venture2017-08-151-0/+10
| | | | | | | | | | | | | | | | | There are multiple options for the action field of the command. This change only addresses one, where the caller wants there to be no action taken when the timer expires. Because the implementation of the watchdog doesn't support multiple actions in precisely that arrangement, it makes sense to simply disable the timer. The default behaviour on x86 of the ipmi_watchdog driver is to first set the watchdog to 10s and an action of "none" and then set it to 10s with an action of "hard reset." This change is necessary to stop the watchdog from resetting the host when it receives the initial setting with the action of "none." Change-Id: I1a541824d2bd0d7a0c33ec5759c7c959cc2ae5ee Signed-off-by: Patrick Venture <venture@google.com>
* Add support for vlan(set lan command)Ratan Gupta2017-08-131-5/+42
| | | | | | | Resolves openbmc/openbmc#1899 Change-Id: I3c436045676bc96e5d91fd9420509bc991549a13 Signed-off-by: Ratan Gupta <ratagupt@in.ibm.com>
* Move LAN handling commands to the new xyz interfacesRatan Gupta2017-08-131-88/+133
| | | | | Change-Id: I4631c79c171883e5f0d531cfb5957a09496e4b3a Signed-off-by: Ratan Gupta <ratagupt@in.ibm.com>
* apphandler: Fix version string leak in ipmi_app_get_device_idXo Wang2017-07-201-0/+1
| | | | | Signed-off-by: Xo Wang <xow@google.com> Change-Id: If64a9897f29e5d8dd267afdd2507b3165114bd98
* Update watchdog command handler to use new watchdog daemonVishwanatha Subbanna2017-06-151-33/+67
| | | | | | | | | | Below IPMI commands in NetFn:0x06 are implemented and they need to use the services from new refactored watchdog daemon Command:0x22 and 0x24. Change-Id: I2f7b89aa8b35d08033ecab30b59440c023520390 Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* Add privilege level for each IPMI commandTom2017-01-171-10/+29
| | | | | Change-Id: I07f160c6ea83dc91f46e21f263c4cf994aff081d Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
* Create library for System Interface Commands.Tom2017-01-171-98/+0
| | | | | | | | | | There are IPMI commands like Read Event Message Buffer, Set BMC Global Enables and Get Message Flags which is to be executed from host interface only. So creating a separate library for these commands which would be used only by phosphor-host-ipmid. Change-Id: I14cb4019b9ab19c84e463e5a7820010f57f1c5eb Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
* ipmid: Fix Get BT Interface Capabilities responseAdriana Kobylak2016-12-131-1/+3
| | | | | | | | | | Per the IPMI 2.0 spec, the input and output buffer size must be maximum buffer size minus one byte to allocate space for the length byte. Change-Id: Ie1768b9c6844275f7897fbf8056ce2a19b1c11c3 Fixes: openbmc/openbmc#847 Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
* Add transaction support to Set Lan Cmd and Set Channel Access CmdNan Li2016-11-231-0/+121
| | | | | | | | | | | | | * Ipmid will cache single setting to memory by Set Lan cmd * Add Set Channel Access cmd to ipmid * Set Channel Access cmd is used to apply the previous cached settings TODO: parse the request data of Set Channel Access cmd if needed. Resolves openbmc/openbmc#444 Change-Id: Ia7ac57a551731920ffe69dad5c69c995521fed02 Signed-off-by: Nan Li <william.bjlinan@hotmail.com>
* Add IPMI Get Self Test Results supportNan Li2016-11-221-0/+42
| | | | | | | | | | | As discussed in design meeting, before the whole ipmi stack is implemented, we don't plan to support "self test". So just respond with self test function not implemented in this controller. Resolves openbmc/openbmc#436 Change-Id: Icd72e07674ce857f98ac036df2b7d6f6b93f1914 Signed-off-by: Nan Li <william.bjlinan@hotmail.com>
* Print failing object path after failed bus lookupBrad Bishop2016-10-061-4/+8
| | | | | Change-Id: I599d8297b4d2fd45831443685ea5b7d53f1515b6 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Ensure all tools are building with -Wall and -WerrorMatthew Barth2016-09-211-2/+0
| | | | | | | | Corrected resulting compiler errors from correctly adding -Wall & -Werror within configure.ac. Change-Id: Ia7aaafa83103322ad4b50171d62144624dd71e42 Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
OpenPOWER on IntegriCloud