summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Add .gitignoreGunnar Mills2018-04-081-0/+49
| | | | | | | | Took a .gitignore from another repo and added a few repo specific items. Change-Id: I221f6af5662828be73fa1bbab9b9aa8ae24f2085 Signed-off-by: Gunnar Mills <gmills@us.ibm.com>
* Use interfaces-removed for association removesMatt Spinler2017-12-052-28/+3
| | | | | | | | | | | The mapper will no longer emit properties-changed signals when the last endpoints property is removed from the fault association object. It will only emit an interfaces-removed signal in that case, so change the code to subscribe to the interfaces-removed signal instead. Change-Id: I225376e550d21b82473015324cd9a261e16fe6db Signed-off-by: Matt Spinler <spinler@us.ibm.com>
* Spelling fixesGunnar Mills2017-10-251-1/+1
| | | | | | | | | 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: I30fd1f3678a2e0fa1c24f6d5b2c0970903db4596 Signed-off-by: Gunnar Mills <gmills@us.ibm.com>
* Fix a bug in handling LED priorityVishwanatha Subbanna2017-09-281-1/+0
| | | | | Change-Id: Idbc2808136f1589e7e4340c336613ece2d069da1 Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* Remove incorrect error log when no errors present.Dhruvaraj Subhashchandran2017-09-191-6/+1
| | | | | | | | | | An error was logged while starting the fru fault monitor with no existing error logs, which is not correct. Resolves openbmc/openbmc#2330 Change-Id: I6b222b45dd99b653443c58d9982d6576f8af0bfa Signed-off-by: Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>
* Assert LEDs for existing callouts while service startsDhruvaraj Subhashchandran2017-09-072-2/+92
| | | | | | | Resolves openbmc/openbmc#1631 Change-Id: I1639c84cbb180dfe7f6494b5e80ca45514a3e730 Signed-off-by: Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>
* Fix for mapper errors during logging service restartDhruvaraj Subhashchandran2017-07-264-133/+19
| | | | | | | | | | | There was a race condition while calling mapper from led monitoring after error logs started persisting, to avoid such errors the callout information is now extracted from the message received as part of interface added signal. Resolves openbmc/openbmc#1853 Change-Id: Ie913992bdcb3b1cb93677d64331db34202f8ae72 Signed-off-by: Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>
* Throw error if priority of any LED is not same across all groupsVishwanatha Subbanna2017-06-191-4/+20
| | | | | | | | | | | | An LED can be part of any number of groups. It is a requirement that the priority of that particular LED is same in all the groups where that LED is a member. If the input yaml file does not conform to this requirement, compilation should fail. Change-Id: I187730e835521d14564495cbe52eb139fc1bd264 Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* LEDS: Provide support to override the default Blink priorityVishwanatha Subbanna2017-06-198-367/+1341
| | | | | | | | In some cases, it is needed that the Solid-ON action over rules Blink and this patch adds that support. Change-Id: Ib0a88b11142ccef3e39ef0a7c6eb3a037c878bc2 Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* parse_led.py: python3 fixesPatrick Williams2017-06-051-13/+8
| | | | | | | | | * iteritems / iterkeys does not exist in python3, use items / keys directly. * Order of dicts cannot be relied on. Change-Id: Ieaf5f58115d4015070d812814d98ca1e58d92ae2 Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
* use new sdbusplus match constructorsPatrick Williams2017-06-012-54/+39
| | | | | Change-Id: Id833073b9e45fae24d6bd0e7f9310ef0ba8658de Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
* Implement led assert and deassert based on faultsDhruvaraj Subhashchandran2017-05-238-2/+671
| | | | | Change-Id: I28378b155da15282b1b5bf0403075b55bda5b70d Signed-off-by: Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>
* Add class and stub for fru fault monitor applicationDhruvaraj Subhashchandran2017-05-236-2/+220
| | | | | | | | | This application waits for new fault entries and resolution of exiting faults to assert or deassert LED for the corresponding FRUs, respectively. Change-Id: I92ead0c8d3132dd7a6740b536231d6588ac42471 Signed-off-by: Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>
* Fix LED action priority inconsistencyVishwanatha Subbanna2017-05-033-7/+136
| | | | | | | | | | When certain LED is first set to "Blink" and is set to "ON" again, LED needs to stay "Blink" as opposed to turning "ON". This is the default behavior needed on all systems unless overridden. Change-Id: Ied52bb60c538516802b05eb72c139a31499178f5 Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* LEDS: Handle empty groupVishwanatha Subbanna2017-03-301-0/+5
| | | | | | | | | | | | | | | | | | LED group consists of name and the associated LEDs that need to be actioned on when the group is asserted or de-asserted. However, its not a hard requirement that all the groups must have the associated LEDs if the system does not have the usecase. For example, it is required from the firmware standpoint that the groups "bmc_booted" and "power_on" be present but not all systems may have a mapping LED. So in those cases, the group itself can be in asserted state but without doing anything underneath. Providing this support will make sure that addition of LEDs into those groups if needed in the future are handled seamlessly. Change-Id: I345886a3edbabf11f1e9f5c9de4b9cf28a7c33f6 Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* LEDS: Add default LED groupsVishwanatha Subbanna2017-03-291-0/+10
| | | | | | | | | | | | | | | | | | Regardless of the machine type, there needs to be standard set of LED groups that would get asserted / de-asserted under these conditions: 1) BMC booted 2) Power On 3) Power Off This makes sense on hardwares that have physical LEDs. However, QEMU does not have physical LEDs associated with the groups but the groups themselves can be in asserted state so that if physical LEDs are implemented in future, they can be used. Change-Id: Ie66f5ac59fcdbecb7ba79c4dbcbdc8fceaace42f Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* LEDS: Convert group and led names to lower_case_underscoreVishwanatha Subbanna2017-03-281-2/+4
| | | | | | | | | | | | This converts the LED group names and LED names from all formats to lower_case_underscore. Example : fan0IdentifyTest will become fan0_identify_test Fixes openbmc/openbmc#1312 Change-Id: Iffa458d593239eb1cb6be0bcda749260cb01c80d Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* LEDS: Get the service names for all physical LED dbus paths at onceVishwanatha Subbanna2017-03-272-41/+58
| | | | | | | | | | | | | Previous code made a call to get the service name for every physical LED and that was a little costly. This patch changes it to get the service names of all the physical LED dbus paths and uses it. This is done everytime a group of LEDs are to be manipulated. Fixes openbmc/phosphor-led-manager#4 Change-Id: I5ce455f683a38eae7f9b383013f5729ec7dd7fae Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* Use physical LED actions from generated codeVishwanatha Subbanna2017-03-243-8/+12
| | | | | | | | | | Today's code returned a hardcoded string for physical LED action and this patch uses the generated string for the passed in action enum Fixes openbmc/phosphor-led-manager#2 Change-Id: I960e2d4346966caee526e1a0e8713e18d34b428a Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* Move object_mapper per dbus path conventions.Leonel Gonzalez2017-03-201-1/+1
| | | | | | | Partial fix for openbmc/openbmc#1112. Change-Id: Ie1995bd0a1d0fe32891ab814a7fe3c0e2aa47db0 Signed-off-by: Leonel Gonzalez <lgonzalez@us.ibm.com>
* Link to dbus interfaces library for using generated codeVishwanatha Subbanna2017-03-135-199/+9
| | | | | Change-Id: I7db65c8bea0bc111e9b0810ffdc33a8ffc924f5e Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* Check for needed package modules than individual header filesVishwanatha Subbanna2017-03-132-8/+4
| | | | | Change-Id: I582caca53aa84ba7037a61f7a2a947ca0b313cc2 Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* Update example led.yaml with appropriate dataVishwanatha Subbanna2017-03-101-90/+12
| | | | | | | | Moved from hyphen to underscore, changed to all lowercase and removed some groups Change-Id: I0e3137230003153c9a898f0afb9f4db63ee46936 Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* Drive physical LED when a LED group is actioned onVishwanatha Subbanna2017-03-077-36/+195
| | | | | Change-Id: I3107c1d961c459379b77548a738533567eccf693 Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* Adhere to freedesktop naming convention for service and object pathVishwanatha Subbanna2017-02-162-5/+5
| | | | | | | Fixes openbmc/openbmc#1039 Change-Id: I995168828a187671072f761668c873c2b1936874 Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* led_gen: Add an outputdir cmdline optionBrad Bishop2017-02-092-5/+12
| | | | | | | | | The output is currently placed in the same directory as the script. Default instead to cwd, and allow the user to specify so out of tree builds can work. Change-Id: Ia7b94f509e0239f7697634d7a52f22e38d7efc6a Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* led_gen: Run pep8Brad Bishop2017-02-091-5/+14
| | | | | Change-Id: Ifce2040d750254227ebee7af4e46fca029820c83 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Fix build issuesBrad Bishop2017-02-012-1/+2
| | | | | | | | Somewhere along the line the repo stopped building. Fix a couple minor build issues. Change-Id: I17e24a6f7f1a9946b5c6b5b6544a0f6f172a585f Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Update configure and Makefile to refer to a config pathVishwanatha Subbanna2017-01-252-1/+6
| | | | | | | Define a variable in configure having the information about config files Change-Id: Ic68c02189a07d7198a4ea1ba858ec90aca9126ae Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* Update parse_led.py to accept command line argumentsVishwanatha Subbanna2017-01-251-1/+17
| | | | | | | | | | | Existing parse_led.py had a hardcoded reference to the current directory and the file name 'led.yaml'. This patch introduces changes through which an arbitrary directory and filename can be passed. What would still remain the older way is the generation of led-gen.hpp into the current source directorty Change-Id: I352dadd6aa99ef80192dfca3071357917d4593b8 Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* Update led manager to consume DutyOn and Period valuesVishwanatha Subbanna2017-01-253-122/+135
| | | | | | | | | Previous code only considered the Name and Action for the LED but then DutyOn and Period are also the properties that are associated with LED and this patchset handles that. Change-Id: Ifb57719ed3bcf01a4704618089d9ce676e4b951c Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* Enable gtest for testing LED set operationsVishwanatha Subbanna2017-01-1711-90/+1187
| | | | | | | | This patchset enables gtest to allow different combinations of LED set operations to be verified at build time. Change-Id: I9c2ddf82c2e23be911233b23037ee44e3ce301db Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* Use python from toolchain instead of local copyVishwanatha Subbanna2017-01-121-2/+1
| | | | | | | | | Previous commit used /usr/bin/python to parse a yaml file and that resulted in CI failures and this patch corrects that by using the one in toolchain. Change-Id: I0f3efcab0c0f620a6ddb7b3500aca5694351fe10 Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* Add performance improvement to LED group assertionsVishwanatha Subbanna2016-12-201-23/+30
| | | | | | | | | | | | | | | | | | | | | | | | | Consider the below scenario: 1) User turns on Identify_Fan_1, which results in Fan_1's LED to blink 2) Fan_1 is faulted resulting in Fan_1, EncFaultFront and EncFaultBack to be asserted. 3) User turuns off Identify_Fan_1. This should result in Fan_1 going back to SolidOn state since the Fan_1 is still faulted. Current implementation handles #3 by first turning off Fan_1 LED and then turning it back on. So this was adding extra dbus calls to the actual LED manager and also this would mean that Group manager would know the underlying LED implementation. With this patch, Group Manager tells the physical manager to move to SolidOn state directly from Blink and physical LED manager now has the job of doing the actual turn off followed by turn on and thus hiding the implementation locally. Fixes openbmc/phosphor-led-manager#3 Change-Id: Ic961095d01e59ba39a841ce8b74bbcde8ddec1df Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* Use generated bindings for Led Group managerVishwanatha Subbanna2016-12-1513-377/+559
| | | | | | | | This extends generated sdbusplus interface and provides implementation for handling LED group operations. Change-Id: I9e6f83f2f801de24d33937bc651228b1c0ccdc37 Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* Add methods to driving the LEDsVishwanatha Subbanna2016-12-136-136/+245
| | | | | | | | | | This enables creating custom groups and participating LEDs so that it can later be generated from MRW. For each of the group, a dbus object is created which will announce LED actions. Corresponding groups are asserted / de-asserted based on user input. Change-Id: I7e64bea13767b8d083dd946f4cf3aeb37e62ff17 Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* Add LED grouping supportVishwanatha Subbanna2016-11-218-0/+448
| | | | | | | | | | | This enables creating custom groups and participating LEDs so that it can later be generated from MRW. For each of the group, a dbus object is created which will announce LED actions. Fixes openbmc/openbmc#550 Change-Id: I7a56d08755288dcfce45ee4c6d6b6c5e5aa454f7 Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* Initial commitPatrick Williams2016-10-171-0/+201
OpenPOWER on IntegriCloud