History log of /openbmc/phosphor-led-manager/fault-monitor/fru-fault-monitor.cpp (Results 1 – 25 of 30)
Revision Date Author Comments
# 1f0b715a 17-Jul-2023 George Liu <liuxiwei@inspur.com>

Use the lower camel case of the C++ standard

Signed-off-by: George Liu <liuxiwei@inspur.com>
Change-Id: Ied901f0cc7cc6606e199dad0e31a35f838c32ab9


# b4c82cf4 03-Jan-2023 George Liu <liuxiwei@inspur.com>

support sdbusplus::message::object_path

Since lg2 already supports sdbusplus::message::object_path,
it needs to be updated synchronously.

Signed-off-by: George Liu <liuxiwei@inspur.com>
Change-Id:

support sdbusplus::message::object_path

Since lg2 already supports sdbusplus::message::object_path,
it needs to be updated synchronously.

Signed-off-by: George Liu <liuxiwei@inspur.com>
Change-Id: I4d81fac0d0acaf069381099e541ce2ac578d632e

show more ...


# 3e073ba6 22-Jul-2022 Patrick Williams <patrick@stwcx.xyz>

sdbusplus: use shorter type aliases

The sdbusplus headers provide shortened aliases for many types.
Switch to using them to provide better code clarity and shorter
lines. Possible replacements are

sdbusplus: use shorter type aliases

The sdbusplus headers provide shortened aliases for many types.
Switch to using them to provide better code clarity and shorter
lines. Possible replacements are for:
* bus_t
* exception_t
* manager_t
* match_t
* message_t
* object_t
* slot_t

Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: I223d58649a21565678bd7ef78d955b30d3fd6d84

show more ...


# f2044037 17-Mar-2022 Patrick Williams <patrick@stwcx.xyz>

switch map to unordered_map

Generally, unordered_maps should be preferred over map because they have
faster access times (O(1)) and tend to allocate less dynamic memory. We
do not rely on ordered i

switch map to unordered_map

Generally, unordered_maps should be preferred over map because they have
faster access times (O(1)) and tend to allocate less dynamic memory. We
do not rely on ordered iteration in any current use of maps, so it is
safe to do a full replace.

Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: Ieaa28ac7f70f9913d13d25142fea9861d49bb23f

show more ...


# 9bd334ff 16-Mar-2022 Patrick Williams <patrick@stwcx.xyz>

fault-monitor: remove locally generated errors

Switch fault-monitor to use Common.Errors instead of locally defined
ones. This greatly simplifies the build structure and follows the
expected phosph

fault-monitor: remove locally generated errors

Switch fault-monitor to use Common.Errors instead of locally defined
ones. This greatly simplifies the build structure and follows the
expected phosphor-logging patterns better.

Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: Idb3473989c86b3a505f3c0a238735db6f3a4349e

show more ...


# c5e0f31c 27-Dec-2021 George Liu <liuxiwei@inspur.com>

Fix some warnings by cppcheck

Signed-off-by: George Liu <liuxiwei@inspur.com>
Change-Id: Icee0abe2e3130aa225db776efdcd47200eb38f8d


# fb56fde0 06-Oct-2021 Patrick Williams <patrick@stwcx.xyz>

catch exceptions as const

Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: Id11e5c601ff495cd61abd3c35e6558e446e8a7d1


# e9fb5c6a 01-Jul-2021 George Liu <liuxiwei@inspur.com>

logging: switch to lg2

After switching to C++20, it is recommended to use `phosphor::lg2`
to format log, and the correct `CODE_LINE` and `CODE_FUNC` values
can be used in log trackin

logging: switch to lg2

After switching to C++20, it is recommended to use `phosphor::lg2`
to format log, and the correct `CODE_LINE` and `CODE_FUNC` values
can be used in log tracking.

Tested: built ledManager successfully and Unit Test passes.

Before: The file does not exist or is empty
After: The file does not exist or is empty, FILE_PATH = /usr/share/phosphor-led-manager/lamp-test-led-overrides.json

MESSAGE=File does not exist, FILE_PATH = /var/lib/phosphor-led-manager/savedGroups
LOG2_FMTMSG=File does not exist, FILE_PATH = {PATH}
CODE_FILE=../../../../../../fp5280g2-workspace/sources/phosphor-led-manager/serialize.cpp
CODE_LINE=63
CODE_FUNC=void phosphor::led::Serialize::restoreGroups()
PATH=/var/lib/phosphor-led-manager/savedGroups
SYSLOG_IDENTIFIER=phosphor-ledmanager
_PID=298
_COMM=phosphor-ledman
_EXE=/usr/bin/phosphor-ledmanager
_CMDLINE=phosphor-ledmanager
_SYSTEMD_CGROUP=/system.slice/xyz.openbmc_project.LED.GroupManager.service
_SYSTEMD_UNIT=xyz.openbmc_project.LED.GroupManager.service
_SYSTEMD_INVOCATION_ID=5ddd4960a3b04fe29c34e4ce03b6be06

Signed-off-by: George Liu <liuxiwei@inspur.com>
Change-Id: I5ec8530e0b539bcf8d7d211c802430698aebd343

show more ...


# d78de14d 23-Aug-2021 George Liu <liuxiwei@inspur.com>

Handle D-Bus exceptions

Remove the usage of is_method_error()[1].

Also, add try-catch to handle D-Bus exceptions around mapper call.

[1]https://github.com/openbmc/sdbusplus

Handle D-Bus exceptions

Remove the usage of is_method_error()[1].

Also, add try-catch to handle D-Bus exceptions around mapper call.

[1]https://github.com/openbmc/sdbusplus/blob/master/include/sdbusplus/bus.hpp#L282-L286

Signed-off-by: George Liu <liuxiwei@inspur.com>
Change-Id: Id2b5234009e62e6c003f24a25c726317646b582b

show more ...


# 7152edcf 02-Sep-2021 Patrick Williams <patrick@stwcx.xyz>

exception: switch to public sdbus exception

SdBusError was intended to be a private error type inside sdbusplus.
Switch all catch locations to use the general sdbusplus::exception type.

exception: switch to public sdbus exception

SdBusError was intended to be a private error type inside sdbusplus.
Switch all catch locations to use the general sdbusplus::exception type.

Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: I411acc5238da0ad3d14a963c0d1a3bb4791f23ff

show more ...


# 4b062010 13-Oct-2020 George Liu <liuxiwei@inspur.com>

Add meson build

This commit is to add meson build.
And later, we will remove Autotools and replace it with meson build.

In addition, fixed Layout::LedAction construct parameter

Add meson build

This commit is to add meson build.
And later, we will remove Autotools and replace it with meson build.

In addition, fixed Layout::LedAction construct parameter error in test
file.

Signed-off-by: George Liu <liuxiwei@inspur.com>
Change-Id: I58c9a2c9de928db288e77ca2d6aa807d36e70144

show more ...


# a41d282a 13-May-2020 Patrick Williams <patrick@stwcx.xyz>

sdbusplus: replace message::variant with std::variant

Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: I7b04e16b91dbb6eb229cb2d0d528c56f6b2ea0ba


# 5ebebeff 13-May-2020 Patrick Williams <patrick@stwcx.xyz>

sdbusplus: remove deprecated variant_ns

Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: Ia4b7b6bd27bdcb68cb4ef6399f97966372bf4c2e


# a6e48929 06-Nov-2019 Andrew Geissler <geissonator@yahoo.com>

Change to use new association interface

The phosphor-logging code moved from implementing
org.openbmc.Associations to now implementing
xyz.openbmc_project.Association.Definitions. Th

Change to use new association interface

The phosphor-logging code moved from implementing
org.openbmc.Associations to now implementing
xyz.openbmc_project.Association.Definitions. The property name was also
changed from associations to Associations.

Tested:
Put on a system with existing error log and verified application did not
fail on start up

Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
Change-Id: I046244039dd8fe663185b981bce875691769a0d8

show more ...


# 555a279e 06-Nov-2018 William A. Kennington III <wak@google.com>

Fix std::variant usage

We need to conform to the std::variant interface for sdbusplus to
eventually switch away from mapbox. The .get() interface is only
provided by mapbox and needs

Fix std::variant usage

We need to conform to the std::variant interface for sdbusplus to
eventually switch away from mapbox. The .get() interface is only
provided by mapbox and needs to be converted.

Change-Id: Ia41808d6bab73b097fc631fd9eff549be9a22415
Signed-off-by: William A. Kennington III <wak@google.com>

show more ...


# 91ac8d3a 01-Nov-2018 Patrick Venture <venture@google.com>

Add clang-format to repo

Add clang-format to repo.

Change-Id: Ib3f81524b66414df3e6c93d8a6df6e22c43841e0
Signed-off-by: Patrick Venture <venture@google.com>


# 91122927 24-Sep-2018 Matt Spinler <spinler@us.ibm.com>

fault-monitor: Catch GetSubTree exceptions

The C++ implementation of the mapper will throw an exception
if the passed in interface was not found on any paths, which
is expected to h

fault-monitor: Catch GetSubTree exceptions

The C++ implementation of the mapper will throw an exception
if the passed in interface was not found on any paths, which
is expected to happen when fru-fault-monitor checks for error
logs on startup and there aren't any. Catch that exception
and just continue on the path of there being no error logs.

Note this is made slightly more complicated by the fact that the
default constructor for sdbusplus::message is deleted, so one
cannot just do:

sdbusplus::message reply;
try
{
auto method = bus.new_method_call(...);
reply = bus.call(method);
}
...
reply.read(...);

Change-Id: Ic15c7112cbfe0f3df974748f90828f12255ec29a
Signed-off-by: Matt Spinler <spinler@us.ibm.com>

show more ...


# e77b8345 12-Sep-2018 Matt Spinler <spinler@us.ibm.com>

Remove trailing slash on path in GetObject call

The upcoming C++ mapper implementation needs it this way.

Tested: With the new mapper and this fix, the call works.

Change-

Remove trailing slash on path in GetObject call

The upcoming C++ mapper implementation needs it this way.

Tested: With the new mapper and this fix, the call works.

Change-Id: I9b65cb8e12ff0369517ab82dca0be0fae5ae281c
Signed-off-by: Matt Spinler <spinler@us.ibm.com>

show more ...


# 08d613e7 18-Jul-2018 Adriana Kobylak <anoo@us.ibm.com>

Romulus: Handle SdBusError Exceptions

Handle exceptions from the sdbusplus method call_noreply API.

The phosphor-fru-fault-monitor app would fail with the following
message on R

Romulus: Handle SdBusError Exceptions

Handle exceptions from the sdbusplus method call_noreply API.

The phosphor-fru-fault-monitor app would fail with the following
message on Romulus with the latest sdbusplus changes:
sd_bus_call noreply: org.freedesktop.DBus.Error.UnknownObject:
Unknown object '/xyz/openbmc_project/led/groups/core1_fault'.
Add error handling.

Tested: The phosphor-fru-fault-monitor does not core dump on Romulus.

Change-Id: I2bec59c0e0f483e8bfc0cb20a343cb05670212b7
Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>

show more ...


# 44bb6683 21-Jun-2018 Matt Spinler <spinler@us.ibm.com>

Removed unused header files

Will cause symbol collisions when this repository's local
error yaml is copied out during building so phosphor-logging
includes it in its elog-errors.hpp.

Removed unused header files

Will cause symbol collisions when this repository's local
error yaml is copied out during building so phosphor-logging
includes it in its elog-errors.hpp.

Change-Id: Ic467418106d45b6b49b6cabec304c4ae64a3d76b
Signed-off-by: Matt Spinler <spinler@us.ibm.com>

show more ...


# b2f253b7 13-Jun-2018 Matt Spinler <spinler@us.ibm.com>

Fix fault-monitor interfacesAdded msg parsing

With the latest sdbusplus exception handling changes,
an exception was being thrown when trying to read a pair
out of the interfacesAdde

Fix fault-monitor interfacesAdded msg parsing

With the latest sdbusplus exception handling changes,
an exception was being thrown when trying to read a pair
out of the interfacesAdded signal message.

Change the code to read the path and map separately.

Also modified the name of the data structures to match
what the message actually returned.

Tested: The exception journal entries went away and LEDs
will turn on and off again.

Change-Id: I2c72000e0da365743715da966a0c9e571efd33d5
Signed-off-by: Matt Spinler <spinler@us.ibm.com>

show more ...


# 151122aa 15-May-2018 William A. Kennington III <wak@google.com>

Add error handling to message parsing

Some of the messages we try and parse are not structured in the
format we expect when parsing. When error logging is enabled in
sdbusplus this c

Add error handling to message parsing

Some of the messages we try and parse are not structured in the
format we expect when parsing. When error logging is enabled in
sdbusplus this causes the phosphor-fru-fault-manager to crash. Fix
this crashing by logging errors and ignoring the bad signals and
message responses.

Change-Id: Ie817beaae96961b33a343aabf1dbba9f31606d4b
Signed-off-by: William A. Kennington III <wak@google.com>

show more ...


# 3d2b0d62 29-Mar-2018 Matt Spinler <spinler@us.ibm.com>

Move down error entry trace

It's possible that multiple services can provide the
/xyz/openbmc_project/logging paths, which means the
interfaces added handler can get multiple callbac

Move down error entry trace

It's possible that multiple services can provide the
/xyz/openbmc_project/logging paths, which means the
interfaces added handler can get multiple callbacks
for a single error.

That being the case, move down the trace that shows
the new error log object path until after the code
checks that the association interface is present, as
that interface will only be present on one object.

Another option would have been to remove the trace
completely, but it is fairly useful for debug.

Change-Id: I98659562ef024455762110e20109bf3079b96cbe
Signed-off-by: Matt Spinler <spinler@us.ibm.com>

show more ...


# 9f782246 06-Nov-2017 Matt Spinler <spinler@us.ibm.com>

Use interfaces-removed for association removes

The mapper will no longer emit properties-changed signals
when the last endpoints property is removed from the fault
association object

Use interfaces-removed for association removes

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>

show more ...


# fc30e0c1 19-Sep-2017 Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>

Remove incorrect error log when no errors present.

An error was logged while starting the fru fault monitor
with no existing error logs, which is not correct.

Resolves openbmc/o

Remove incorrect error log when no errors present.

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>

show more ...


12