summaryrefslogtreecommitdiffstats
path: root/storagehandler.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Handle SdBusError exception in SEL commandsTom Joseph2018-09-121-11/+41
| | | | | Change-Id: Ia79b3e2ea4ca8783c912c9864be32107d170d561 Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
* add .clang-formatPatrick Venture2018-09-071-138/+133
| | | | | Change-Id: I7c2a527b4751a560703a61fcbe9638b150546af5 Signed-off-by: Patrick Venture <venture@google.com>
* Standardize use of filesystemVernon Mauery2018-08-081-1/+11
| | | | | | | | | 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>
* Fix Host time is not getting printed to journalNagaraju Goruganti2018-05-081-2/+4
| | | | | | | | | | | | log<level::DEBUG> is not putting Host time into journal, instead it is putting it in the metadata. Made fix for it. Testing: ipmitool sel time get # Host time:xxx XXX x xx:xx:xx xxxx will be # printed in into journal Change-Id: I0ba72a871469a30c605ee3ec91a07787959d5ae3 Signed-off-by: Nagaraju Goruganti <ngorugan@in.ibm.com>
* Check the offset length in the Read FRU commandTom Joseph2018-05-081-0/+5
| | | | | | | | | | The offset length is validated against the size of the FRU area, before proceeding with populating the response of the Read FRU command. Resolves openbmc/openbmc#3132 Change-Id: I2bc660b7e389f5c85bac0acc8068dd53ab328a65 Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
* Check if the FRU Id is valid for FRU commandsTom Joseph2018-04-231-2/+16
| | | | | | | | | | | Validate FRU Id before proceesing with the command handling. Do not report error log for any FRU command failure, since IPMI is an external interface. Resolves openbmc/openbmc#3016 Change-Id: I9e2af3ce50285662f1b8f9600222e9ff3057a7e3 Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
* Reducing IPMI logging footprintAditya Saripalli2018-04-181-28/+2
| | | | | | | | | | | | -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>
* Fixed broken "fru read" commandNagaraju Goruganti2018-03-271-15/+14
| | | | | | | | | | | | | | | | Fixed below given two issues: 1.We are getting seg-fault due to incorrect format specifiers for log-entry. 2.When requested data count plus offset exceeds fruArea size, we through error, instead we can return remaining bytes. Tested: 1.Verified using below given command. ipmitool -I lanplus -C 3 -P 0penBmc -H <BMP_IP> fru read <fru_id> fru_file Resolves openbmc/openbmc#2893 Change-Id: Iecfe80ed7230b936eca86fd16208582ee7b4e09c Signed-off-by: Nagaraju Goruganti <ngorugan@in.ibm.com>
* Implement Get SDR and Reserve SDR repository commandTom Joseph2018-03-011-0/+11
| | | | | | | | | | | Both Get SDR and Reserve SDR repository command is same as Get Device SDR and Reserve Device SDR command respectively. So the same implementation is shared. Resolves openbmc/openbmc#2615 Change-Id: I64e37837bc5a616bed41a3ceff7d63033d88455c Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
* Add Get Repository Info CommandDhruvaraj Subhashchandran2018-02-161-0/+31
| | | | | | | | | | Adding support for Get Repository Info command, which returns information about the SDR repository. resolves openbmc/openbmc#2614 Change-Id: Id1219de8021b5403a775ad6e8577dbc8edfc60cb Signed-off-by: Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>
* FRU: Fix response for Read FRU Data CommandRatan Gupta2018-02-131-3/+11
| | | | | | | | 1) Add the count field as part of read fru command response. 2) Fix in copying the data from the offset. Change-Id: I2eaa76e82179ad65ba3af0f1795aeec40e68a0fc Signed-off-by: Ratan Gupta <ratagupt@in.ibm.com>
* Commit a MaintenanceProcedure log entry on a 0xDE SEL recordTom Joseph2017-11-031-1/+13
| | | | | | | | | | | | In the case of a procedure callout, HB sends a eSEL of 0xDF type. It is followed by a Add SEL record with OEM record type 0xDE and byte 11 in the record indicate the procedure associated with the eSEL. Resolves openbmc/openbmc#2368 Change-Id: Ia57f423c9d533cd8968b613d7522b409a9820198 Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
* Update Journal Variable NamesGunnar Mills2017-10-191-2/+3
| | | | | | | | | Journal entry variable names should be uppercase. https://www.freedesktop.org/software/systemd/man/sd_journal_print.html Also, fixed indentation. Change-Id: I2c838332ab7811ccc9a2c99f5b1f558c48f25f76 Signed-off-by: Gunnar Mills <gmills@us.ibm.com>
* storagehandler: Use new phosphor-timemanager interfaceLei YU2017-10-191-89/+84
| | | | | | | | Update SEL-Time handlers to use sdbusplus and new phosphor-timemanager interface. Change-Id: Ib931a6bedc14037fc1a0a7c25698f67272520bb5 Signed-off-by: Lei YU <mine260309@gmail.com>
* storagehandler: sort include filesLei YU2017-10-171-11/+14
| | | | | Change-Id: Iaf49ed787a2e077af27f28d22507456e8efa2b41 Signed-off-by: Lei YU <mine260309@gmail.com>
* cater for property change signal to invalidate fru dataMarri Devender Rao2017-07-261-0/+1
| | | | | | | Resolves openbmc/openbmc#1560 Change-Id: I90897959dab76181a6006c372c4b60cc1bdd0c0c Signed-off-by: Marri Devender Rao <devenrao@in.ibm.com>
* cater for fru read callback functionsMarri Devender Rao2017-07-251-3/+64
| | | | | Change-Id: I2fdaef98faa6adc19efce0ede93b4ee728b9404c Signed-off-by: Marri Devender Rao <devenrao@in.ibm.com>
* register call back functions for FRU read commandsMarri Devender Rao2017-07-251-1/+32
| | | | | Change-Id: Idb0230ea173940deb17314dc09c4a562b97ede20 Signed-off-by: Marri Devender Rao <devenrao@in.ibm.com>
* Add Clear SEL commandTom Joseph2017-07-191-0/+104
| | | | | Change-Id: I35b07e0bf1012d4b660d10cf17a47318f3c4e6e2 Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
* Add Delete SEL entry commandTom Joseph2017-07-191-0/+92
| | | | | Change-Id: Iabeaca4b5057ef1bae44cb6d30704de3ce2f1269 Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
* Add Get SEL entry commandTom Joseph2017-07-191-0/+120
| | | | | Change-Id: I09983a127c7c2817a0ebb6d64ffb2a9585dcd235 Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
* Add Get SEL Info commandTom Joseph2017-07-191-28/+71
| | | | | Change-Id: I8caa38ee461d6c570a6d7ab73376eb6aea701391 Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
* Add privilege level for each IPMI commandTom2017-01-171-6/+18
| | | | | Change-Id: I07f160c6ea83dc91f46e21f263c4cf994aff081d Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
* Modify GET_SEL_TIME and SET_SEL_TIME to use TimeManager APIsVishwanatha Subbanna2016-11-111-29/+114
| | | | | | | | | GET_SEL_TIME and SET_SEL_TIME command handlers are using gettimeofday and settimeofday respectively. This patch will change the mechanism to use APIs that are provided by org.openbmc.TimeManager daemon istead of POSIX calls. Change-Id: I4890f4a2c27131d902e7417db023eb4cdd7d8626 Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.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>
* Modify respond of un-supported IPMI commandNan Li2016-09-091-1/+1
| | | | | | | | | | | A number of callbacks are registered for 'WILDCARD' types, which currently do nothing except respond with CC_OK(00h). Change complete codes to CC_INVALID(C1h). Resolves openbmc/openbmc#469. Change-Id: I91ea5ee1a23284a4159ff1c1867342e89c6fa444 Signed-off-by: Nan Li <william.bjlinan@hotmail.com>
* Allow out-of-tree buildsPatrick Williams2016-09-061-1/+1
| | | | | Change-Id: If4b97e65f63c3abbf23140dd97b9febe00b3be0d Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
* Switch C++ source files to .cpp extensionMatthew Barth2016-08-081-0/+171
Change-Id: I495186b4afd58ec1e5d9d5c6472394f96541d17d Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
OpenPOWER on IntegriCloud