History log of /openbmc/openpower-occ-control/occ_events.hpp (Results 1 – 3 of 3)
Revision Date Author Comments
# f3a4a69f 27-Dec-2021 George Liu <liuxiwei@inspur.com>

Fix some warnings by cppcheck

Warning message:
../../../occ_events.hpp:16:9: warning: Value stored to 'event' is never read [deadcode.DeadStores]
event = sd_event_unref(event);
^

Fix some warnings by cppcheck

Warning message:
../../../occ_events.hpp:16:9: warning: Value stored to 'event' is never read [deadcode.DeadStores]
event = sd_event_unref(event);
^ ~~~~~~~~~~~~~~~~~~~~~
../../../occ_events.hpp:26:9: warning: Value stored to 'eventSource' is never read [deadcode.DeadStores]
eventSource = sd_event_source_unref(eventSource);

occ_dbus.cpp:34:47: performance: Searching before insertion is not necessary. [stlFindInsert]
path, std::make_unique<SensorIntf>(utils::getBus(), path.c_str()));
^
occ_dbus.cpp:61:47: performance: Searching before insertion is not necessary. [stlFindInsert]
path, std::make_unique<SensorIntf>(utils::getBus(), path.c_str()));
^
occ_dbus.cpp:88:47: performance: Searching before insertion is not necessary. [stlFindInsert]
path, std::make_unique<SensorIntf>(utils::getBus(), path.c_str()));
^
occ_dbus.cpp:115:47: performance: Searching before insertion is not necessary. [stlFindInsert]
path, std::make_unique<SensorIntf>(utils::getBus(), path.c_str()));
^
occ_dbus.cpp:158:80: performance: Searching before insertion is not necessary. [stlFindInsert]
operationalStatus.emplace(path, std::make_unique<OperationalStatusIntf>(
^
occ_pass_through.hpp:42:5: style: Class 'PassThrough' has a constructor with 1 argument that is not explicit. [noExplicitConstructor]
PassThrough(const char* path);
^
powercap.hpp:41:5: style: Class 'PowerCap' has a constructor with 1 argument that is not explicit. [noExplicitConstructor]
PowerCap(Status& occStatus,
^
occ_manager.hpp:77:5: style: Struct 'Manager' has a constructor with 1 argument that is not explicit. [noExplicitConstructor]
Manager(EventPtr& event) :
^
occ_status.hpp:307:26: style: Local variable 'path' shadows outer variable [shadowVariable]
auto path = fs::path(estimatedPath);
^
occ_status.hpp:207:17: note: Shadowed declaration
std::string path;
^
occ_status.hpp:307:26: note: Shadow variable
auto path = fs::path(estimatedPath);
^
pldm.hpp:55:14: warning: Member variable 'Interface::OCCSensorOffset' is not initialized in the constructor. [uninitMemberVar]
explicit Interface(
^
pldm.hpp:55:14: warning: Member variable 'Interface::SBESensorOffset' is not initialized in the constructor. [uninitMemberVar]
explicit Interface(
^
powermode.hpp:60:5: style: Class 'PowerMode' has a constructor with 1 argument that is not explicit. [noExplicitConstructor]
PowerMode(Status& occStatus) :
^
powermode.hpp:96:5: style: Class 'PowerIPS' has a constructor with 1 argument that is not explicit. [noExplicitConstructor]
PowerIPS(Status& occStatus) :
^
occ_manager.cpp:321:24: style: The scope of the variable 'path' can be reduced. [variableScope]
constexpr auto path = "/org/openpower/dump";
^
occ_manager.cpp:322:24: style: The scope of the variable 'interface' can be reduced. [variableScope]
constexpr auto interface = "xyz.openbmc_project.Dump.Create";
^
occ_manager.cpp:323:24: style: The scope of the variable 'function' can be reduced. [variableScope]
constexpr auto function = "CreateDump";
^
pldm.cpp:78:16: style: Local variable 'pdr' shadows outer variable [shadowVariable]
for (auto& pdr : pdrs)
^
pldm.cpp:48:10: note: Shadowed declaration
auto pdr =
^
pldm.cpp:78:16: note: Shadow variable
for (auto& pdr : pdrs)
^
pldm.cpp:248:16: style: Local variable 'pdr' shadows outer variable [shadowVariable]
for (auto& pdr : pdrs)
^
pldm.cpp:221:10: note: Shadowed declaration
auto pdr =
^
pldm.cpp:248:16: note: Shadow variable
for (auto& pdr : pdrs)
^
powermode.cpp:28:22: style: Variable 'pmode' is assigned a value that is never used. [unreadVariable]
SysPwrMode pmode = SysPwrMode::NO_CHANGE;

Tested: Use cppcheck to build successfully and eliminate the above
warning message.

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

show more ...


# 7db89e36 18-Oct-2018 Brad Bishop <bradleyb@fuzziesquirrel.com>

events: Add missing memory header include

Include memory so we don't require a specific include ordering.

Change-Id: I2f5d195b07191963cb194de100ddf3523c295b93
Signed-off-by: Bra

events: Add missing memory header include

Include memory so we don't require a specific include ordering.

Change-Id: I2f5d195b07191963cb194de100ddf3523c295b93
Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>

show more ...


# ee4d83df 29-Jun-2017 Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>

Add support to watch for OCC errors

Change-Id: I98d95020a2d01e281e5c8efa825d6b4bd4c6c160
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>