#
95655220 |
| 05-Dec-2023 |
Patrick Williams <patrick@stwcx.xyz> |
sdbusplus: avoid deprecated phosphor::Timer
sdbusplus had an older type named `phosphor::Timer` which was recently renamed to `sdbusplus::Timer`. Update the code to use the new type alias.
Change-
sdbusplus: avoid deprecated phosphor::Timer
sdbusplus had an older type named `phosphor::Timer` which was recently renamed to `sdbusplus::Timer`. Update the code to use the new type alias.
Change-Id: If69434b3a3639b8f97ab16cab5da4d70e3379cb2 Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
show more ...
|
#
369824e7 |
| 20-Oct-2023 |
Patrick Williams <patrick@stwcx.xyz> |
clang-format: copy latest and re-format
clang-format-17 has some backwards incompatible changes that require additional settings for best compatibility and re-running the formatter. Copy the latest
clang-format: copy latest and re-format
clang-format-17 has some backwards incompatible changes that require additional settings for best compatibility and re-running the formatter. Copy the latest .clang-format from the docs repository and reformat the repository.
Change-Id: Ic5fd073faa7391d3f0b37787d6a9c7688c9a3253 Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
show more ...
|
#
7197b347 |
| 06-Sep-2023 |
Alexander Hansen <alexander.hansen@9elements.com> |
more debug logs for ipmi OEM commands
- log IANA as unpacked from request - log if the request was filtered - log sucessful / unsucessful registering of OEM Command Handler
Tested: ipmid logs the e
more debug logs for ipmi OEM commands
- log IANA as unpacked from request - log if the request was filtered - log sucessful / unsucessful registering of OEM Command Handler
Tested: ipmid logs the expected messages.
Change-Id: If4387d2d1927768f697e29d2230d9e3491e8ed48 Signed-off-by: Alexander Hansen <alexander.hansen@9elements.com>
show more ...
|
#
82cffccd |
| 27-Jul-2023 |
Vernon Mauery <vernon.mauery@linux.intel.com> |
change to use non-deprecated dcmi group value
All new code should be using the constants from the new API, rather than the old code. This is a minor change to remove usage of the DCMI group value fr
change to use non-deprecated dcmi group value
All new code should be using the constants from the new API, rather than the old code. This is a minor change to remove usage of the DCMI group value from all internal phosphor-ipmi-host code.
Change-Id: Ib4b44bbb4a40945639eeb0f72e817f3dc716903b Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
show more ...
|
#
fbc6c9d7 |
| 10-May-2023 |
Patrick Williams <patrick@stwcx.xyz> |
clang-format: copy latest and re-format
clang-format-16 has some backwards incompatible changes that require additional settings for best compatibility and re-running the formatter. Copy the latest
clang-format: copy latest and re-format
clang-format-16 has some backwards incompatible changes that require additional settings for best compatibility and re-running the formatter. Copy the latest .clang-format from the docs repository and reformat the repository.
Change-Id: I44441096113929ce96eb1439e2932e6ff3c87f27 Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
show more ...
|
#
5e096a28 |
| 01-Jun-2022 |
Vernon Mauery <vernon.mauery@linux.intel.com> |
remove return statement for void function
The function signature shows return type void, the return statement returns a value from a function that is void, so while not really an error right now, co
remove return statement for void function
The function signature shows return type void, the return statement returns a value from a function that is void, so while not really an error right now, could be if the called function signature changed.
Tested: Builds as expected.
Change-Id: If93fcf531c173dfeb7048afbb50e365c538a0b45 Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
show more ...
|
#
5d82f474 |
| 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: Ibd2a0b512bfb7caf65bfab64b271d194da520aac
show more ...
|
#
a2ad2da8 |
| 06-Oct-2021 |
Patrick Williams <patrick@stwcx.xyz> |
catch exceptions as const Signed-off-by: Patrick Williams <patrick@stwcx.xyz> Change-Id: Ic2b49715c7b81ac5bcfc12ff2d3b4c593cd95ce7
|
#
03d7a4be |
| 19-Jan-2021 |
Vernon Mauery <vernon.mauery@linux.intel.com> |
properly handle unexpected exceptions Prior code followed a poorly explained example and then would just re-throw the exception without actually catching it. The new code (while spec
properly handle unexpected exceptions Prior code followed a poorly explained example and then would just re-throw the exception without actually catching it. The new code (while specific to gcc and clang) will log the unexpected exception type so it will not be fatal. Tested: throw an std::string in a handler and see that it is not fatal. MESSAGE=Handler failed to catch exception EXCEPTION=std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > Change-Id: I4734aba8ea6fb02ad8ce54be55e860d2b4c6576c Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
show more ...
|
#
997952af |
| 30-Jul-2021 |
Vernon Mauery <vernon.mauery@linux.intel.com> |
Add a SecureBuffer class SecureBuffer is like SecureString, but a specialization of std::vector<uint8_t> that cleans up after itself Tested: Executed various ipmi commands to se
Add a SecureBuffer class SecureBuffer is like SecureString, but a specialization of std::vector<uint8_t> that cleans up after itself Tested: Executed various ipmi commands to see that they still work Change-Id: Ifd255ef682d6e46d981de6a5a294d12f3666698b Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
show more ...
|
#
55f5d53c |
| 13-Jul-2021 |
Snehalatha Venkatesh <snehalathax.v@intel.com> |
Fix static analysis (uninitialized var) warnings Initialized variables with default value Tested: Build got successful Signed-off-by: Snehalatha Venkatesh <snehalathax.
Fix static analysis (uninitialized var) warnings Initialized variables with default value Tested: Build got successful Signed-off-by: Snehalatha Venkatesh <snehalathax.v@intel.com> Change-Id: Ied1a5e188d49e28d0b64a20ff9f31016735b82c2
show more ...
|
#
be063232 |
| 04-Mar-2021 |
Yong Li <yong.b.li@linux.intel.com> |
Do not insert twice for first filter On the first call, the filter list is empty, the element will be insert two times, just return after the first insert. Tested: Check the
Do not insert twice for first filter On the first call, the filter list is empty, the element will be insert two times, just return after the first insert. Tested: Check the filter callback functions, there is no duplicated call; Signed-off-by: Yong Li <yong.b.li@linux.intel.com> Change-Id: I4e4d5147b5c0466b651700f79afcb34940e6f48a
show more ...
|
#
f7d081f6 |
| 19-Aug-2020 |
Kumar Thangavel <thangavel.k@hcl.com> |
phosphor-host-ipmid : yosemitev2: Add host Identification support Added host Identification support in ipmid. This helps to identify the particular hosts. The channel indexes for hos
phosphor-host-ipmid : yosemitev2: Add host Identification support Added host Identification support in ipmid. This helps to identify the particular hosts. The channel indexes for hosts are getting from ipmb json config and passed from ipmb. TESTED : Built Facebook YosemiteV2 & Tiogapass images and loaded on the target hardware. We are able to see hostId's for all the hosts. Note : This is the follow-up patch for multiple channels support in ipmbbridge. https://gerrit.openbmc-project.xyz/c/openbmc/ipmbbridge/+/34579 Signed-off-by: Kumar Thangavel <thangavel.k@hcl.com> Change-Id: I01f1783f6c95780a62639d5ce9edc0b420d57be9
show more ...
|
#
778418da |
| 18-Aug-2020 |
Ed Tanous <ed@tanous.net> |
Fix includes This patchset tries to fix some of the include problems in phosphor-ipmi-host. First, it relies on io_service, which is deprecated, and will not compile in boost 1.74.
Fix includes This patchset tries to fix some of the include problems in phosphor-ipmi-host. First, it relies on io_service, which is deprecated, and will not compile in boost 1.74. It also relies on the fact that sdbusplus #includes <asio.hpp> as a whole, this patchset makes it add the correct includes, so it can compile on its own, and we can improve compile times by removing asio.hpp from sdbusplus. Signed-off-by: Ed Tanous <ed@tanous.net> Change-Id: I0ab3b202b07a716368711dc6528d984c73bcb9d9
show more ...
|
#
c11cc5c0 |
| 22-Jul-2020 |
Johnathan Mantey <johnathanx.mantey@intel.com> |
Add LUN to the IPMI sensor context structure Systems monitored by BMCs may have more than 255 sensors. This code change provides the necessary piece to allow a BMC to support more th
Add LUN to the IPMI sensor context structure Systems monitored by BMCs may have more than 255 sensors. This code change provides the necessary piece to allow a BMC to support more than 255 sensors. It does this by adding a variable to store a LUN value. This allows LUN 0 to manage 255 sensors, and any overflow may be assigned to LUN 1. Tested: Confirmed the following commands still work: "ipmitool sdr elist" "ipmitool sensor list" "ipmitool raw 4 0x20 0" "ipmitool raw -l 1 4 0x20 0" Change-Id: I92d5205eac33829d8133f2e38ed96bfc5a9bc033 Signed-off-by: Johnathan Mantey <johnathanx.mantey@intel.com>
show more ...
|
#
51f78141 |
| 13-Jan-2020 |
Vernon Mauery <vernon.mauery@linux.intel.com> |
ipmid: allow command not found for filtered commands Filters are executed first and the actual ipmi command handler will not execute if the filter rejects it for any reason. How
ipmid: allow command not found for filtered commands Filters are executed first and the actual ipmi command handler will not execute if the filter rejects it for any reason. However, if a filter returns a value for a command that is not even implemented, the old logic would return that value instead of command not implemented (C1h). This is incorrect behavior. This fix will run the filter and then check to see if the command is registered. If the command is registered AND the filter has returned some error, only then will the filter error get returned. If the command is registered and the filter returns no error, the command is executed. If the command is not registered, C1h is returned, as per the spec. Tested: 1) Add some bogus command definitions to the whitelist filter 2) Run the bogus command 3) See that C1h is returned, not insufficient privilege Change-Id: I069df8f47a169d6b2961460a561bf9cae6ae285c Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
show more ...
|
#
369406e6 |
| 09-Jan-2020 |
Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com> |
[ipmid]: Advertise D-Bus signals, only when ready Requesting the bus name & sending out InterfacesAdded signal earlier causes phosphor-mapper introspect to fail, as ipmi command handler
[ipmid]: Advertise D-Bus signals, only when ready Requesting the bus name & sending out InterfacesAdded signal earlier causes phosphor-mapper introspect to fail, as ipmi command handler registration & initialization was in progress before hitting io->run(). Hence moved the code to advertise about D-Bus signal, once ipmid is done with init & registration. This fixes phosphor-mapper timeout. Tested: 1. Verified that phosphor-mapper timeout doesn't happen, even when there is delay in cmd handler registrations etc. Change-Id: I3bb565c0e39f2604dde30e21b9539ce88b73cb0e Signed-off-by: Richard Marian Thomaiyar <richard.marian.thomaiyar@linux.intel.com>
show more ...
|
#
b0094a72 |
| 26-Nov-2019 |
James Feist <james.feist@linux.intel.com> |
Provide proper exit code for signals Currently ipmid only exits 0, allow it to exit based on the signal captured. Tested: journalctl -u phosphor-pid-control -o json-pre
Provide proper exit code for signals Currently ipmid only exits 0, allow it to exit based on the signal captured. Tested: journalctl -u phosphor-pid-control -o json-pretty { "_SYSTEMD_SLICE" : "-.slice", "_GID" : "0", "_CAP_EFFECTIVE" : "3fffffffff", "MESSAGE" : "phosphor-ipmi-host.service: Main process exited, code=killed, status=9/KILL", "EXIT_STATUS" : "9", "__CURSOR" : "s=cd10fcb9010e4cfdbcdad08709c2265d;i=399;b=2efcc2f735f74bc99588861556589a72;m=7c0ed53;t=592853b62b677;x=1ae3833ab435621e", "__MONOTONIC_TIMESTAMP" : "130084179", "MESSAGE_ID" : "98e322203f7a4ed290d09fe03c09fe15", "_EXE" : "/lib/systemd/systemd", "CODE_LINE" : "5797", "UNIT" : "phosphor-ipmi-host.service", "_SYSTEMD_CGROUP" : "/init.scope", "_SYSTEMD_UNIT" : "init.scope", "SYSLOG_IDENTIFIER" : "systemd", "_COMM" : "systemd", "_UID" : "0", "PRIORITY" : "4", "_HOSTNAME" : "intel-obmc", "SYSLOG_FACILITY" : "3", "CODE_FILE" : "src/core/unit.c", "CODE_FUNC" : "unit_log_process_exit", "_CMDLINE" : "/lib/systemd/systemd", "__REALTIME_TIMESTAMP" : "1568475808183927", "_SOURCE_REALTIME_TIMESTAMP" : "1568475808183827", "COMMAND" : "ExecStart", "INVOCATION_ID" : "67ff87a3ad4b4a4da3fe7e0ff083e2b8", "_TRANSPORT" : "journal", "_MACHINE_ID" : "f7182be05e2147feba2eaceaea0aded3", "_BOOT_ID" : "2efcc2f735f74bc99588861556589a72", "EXIT_CODE" : "killed", "_PID" : "1" } Change-Id: I9f3233546b43a331076d21b73beabbf2aaca9d8b Signed-off-by: James Feist <james.feist@linux.intel.com>
show more ...
|
#
4d22640a |
| 13-Nov-2019 |
Rajashekar Gade Reddy <raja.sekhar.reddy.gade@linux.intel.com> |
Added sessionId context in host-ipmid, used by GetSessionInfo SessionId is now passed to host-ipmid context along with userid and privilege information. This will enable certain commands
Added sessionId context in host-ipmid, used by GetSessionInfo SessionId is now passed to host-ipmid context along with userid and privilege information. This will enable certain commands to know the current sessionid Added option to get current session info in get session info command. With this change, we can get the current session info by passing sessionIndex as zero in get session info command via lan interface and the same via host interface will return an error, beacuse no session will be created for host interface. Tested: ipmitool -I lanplus -U <user> -P <password> -H <lan1_ip> raw 6 0x3d <Zero> Response : gives currents session info ipmitool -I lanplus -U <user> -P <password> -H <lan2_ip> raw 6 0x3d <Zero> Response : gives currents session info //host interface ipmitool raw 6 0x3d 0 Response: 0xCC // invalid field in the request //This command shows info of all sessions, which includes current session info as well. ipmitool -I lanplus -U <user> -P <password> -H <lan1_ip> session info all session handle : 129 slot count : 45 active sessions : 1 user id : 1 privilege level : ADMINISTRATOR session type : IPMIv1.5 channel number : 0x03 console ip : 0.0.0.0 console mac : 00:00:00:00:00:00 console port : 52670 session handle : 0 slot count : 45 active sessions : 1 //This command shows info of all sessions, which includes current session info as well. ipmitool -I lanplus -U <user> -P <password> -H <lan2_ip> session info all session handle : 0 slot count : 45 active sessions : 1 session handle : 1 slot count : 45 active sessions : 1 user id : 1 privilege level : ADMINISTRATOR session type : IPMIv1.5 channel number : 0x01 console ip : 0.0.0.0 console mac : 00:00:00:00:00:00 console port : 57622 //host interface ipmitool session info all session handle : 0 slot count : 45 active sessions : 0 session handle : 0 slot count : 45 active sessions : 0 Tested other postive and negative test cases for get session info command in Lan1, Lan2 and host interfaces. All are working fine. Signed-off-by: Rajashekar Gade Reddy <raja.sekhar.reddy.gade@linux.intel.com> Change-Id: I9fb1ef12693e4c0da3661ffdf21eec248b48b5b4
show more ...
|
#
cb09aa00 |
| 06-Sep-2019 |
James Feist <james.feist@linux.intel.com> |
Change yield from ptr to object The ptr makes for ugly code: i.e. *(ctx->yield) all over the place. Change it to copy as it is just 4 pointers. Tested: ipmitool mc info
Change yield from ptr to object The ptr makes for ugly code: i.e. *(ctx->yield) all over the place. Change it to copy as it is just 4 pointers. Tested: ipmitool mc info still works Change-Id: I30c5bc395849875cd58925fac99bb23c1804cd5b Signed-off-by: James Feist <james.feist@linux.intel.com>
show more ...
|
#
99adf2b5 |
| 20-Aug-2019 |
Tom Joseph <tomjoseph@in.ibm.com> |
Revert "Add system interface as the channel for the legacy interface" This reverts commit 152e98cd339f3df58d5832af5779eff541f0adc5. Change-Id: Ib36cdbb2d140de749335a3ae9cbb279563c33
Revert "Add system interface as the channel for the legacy interface" This reverts commit 152e98cd339f3df58d5832af5779eff541f0adc5. Change-Id: Ib36cdbb2d140de749335a3ae9cbb279563c33a1c
show more ...
|
#
152e98cd |
| 22-Jul-2019 |
Tom Joseph <tomjoseph@in.ibm.com> |
Add system interface as the channel for the legacy interface The legacy interface org.openbmc.HostIpmi is used by the btbridge interface and the channel number was set to 0 which implies
Add system interface as the channel for the legacy interface The legacy interface org.openbmc.HostIpmi is used by the btbridge interface and the channel number was set to 0 which implies the IPMB bridge. This is corrected to use the system interface. Change-Id: I870d8fc6c2461b7fc75a90f9576f08599038f211 Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
show more ...
|
#
33298af1 |
| 13-May-2019 |
Vernon Mauery <vernon.mauery@linux.intel.com> |
Add sdbusplus::asio::connection pointer to ipmi::Context This adds a std::shared_ptr<sdbusplus::asio::connection> to every ipmi::Context in order to facilitate easy transition to yie
Add sdbusplus::asio::connection pointer to ipmi::Context This adds a std::shared_ptr<sdbusplus::asio::connection> to every ipmi::Context in order to facilitate easy transition to yield_method_call over other D-Bus interfaces. This means that a getDbusObjects call could just pass in the ipmi::Context and it will get a yielding call. ipmi::Context is a natural fit because one is created for each of the boost::asio::coroutine contexts. And because a yielding call needs both an async D-Bus connection and a yield_context, this means that we now have one object to rule them all. Tested: Created a handler that uses the new shared_ptr in the context to see the API in action. Change-Id: I429a324180a38bf17845f7fd0544df2226d0300a Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
show more ...
|
#
23b7021c |
| 08-May-2019 |
Vernon Mauery <vernon.mauery@linux.intel.com> |
Legacy D-Bus interface must set yield_context The legacy D-Bus interface was not setting the yield_context pointer in the ipmi::Context struct. This means that a command coming in from
Legacy D-Bus interface must set yield_context The legacy D-Bus interface was not setting the yield_context pointer in the ipmi::Context struct. This means that a command coming in from a legacy D-Bus interface that called a new-provider that uses the yield_method_call function would segfault on a NULL pointer. This change makes the legacy interface behave the same as the new D-Bus interface by creating a new boost::coroutine for each command. Tested-by: running a legacy ipmitool to ensure that the rewritten set chassis power restore policy command worked without a segfault. Change-Id: Ie45fff1fc222b9b949a9d3976bf9d1b2c29bd8f5 Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
show more ...
|
#
da31f9a6 |
| 25-Apr-2019 |
William A. Kennington III <wak@google.com> |
ipmid: Handler should automatically handle OEM / Group We shouldn't require the user to handle these. They are a detail purely at the message layer and weren't provided to handlers in th
ipmid: Handler should automatically handle OEM / Group We shouldn't require the user to handle these. They are a detail purely at the message layer and weren't provided to handlers in the past. Change-Id: I1796eb887c86dfbd66d9c784a99dbae675ceb774 Signed-off-by: William A. Kennington III <wak@google.com>
show more ...
|