History log of /openbmc/phosphor-host-ipmid/dcmihandler.cpp (Results 1 – 25 of 72)
Revision Date Author Comments
# 69b4c281 03-Mar-2025 Patrick Williams <patrick@stwcx.xyz>

clang-format: update latest spec and reformat

Copy the latest format file from the docs repository and apply.

Change-Id: Ic23653be3ed404980fd0e723d9ed8354e2b32579
Signed-off-by: Patrick Williams <p

clang-format: update latest spec and reformat

Copy the latest format file from the docs repository and apply.

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

show more ...


# 5087b075 11-Mar-2025 George Liu <liuxiwei@ieisystem.com>

Update the registered IPMI method name

Update registered IPMI method names to use `Lower Camel Case`.

Change-Id: I5539771c4ba8567f6cdb22aa3c8df58db5e883f2
Signed-off-by: George Liu <liuxiwei@ieisys

Update the registered IPMI method name

Update registered IPMI method names to use `Lower Camel Case`.

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

show more ...


# 1318a5ed 16-Aug-2024 Patrick Williams <patrick@stwcx.xyz>

clang-format: re-format for clang-18

clang-format-18 isn't compatible with the clang-format-17 output, so we
need to reformat the code with the latest version. The way clang-18
handles lambda forma

clang-format: re-format for clang-18

clang-format-18 isn't compatible with the clang-format-17 output, so we
need to reformat the code with the latest version. The way clang-18
handles lambda formatting also changed, so we have made changes to the
organization default style format to better handle lambda formatting.

See I5e08687e696dd240402a2780158664b7113def0e for updated style.
See Iea0776aaa7edd483fa395e23de25ebf5a6288f71 for clang-18 enablement.

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

show more ...


# 7fa2871d 17-Jul-2024 George Liu <liuxiwei@ieisystem.com>

convert dcmihandler.cpp to use lg2

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


# cfd7fa83 21-Jan-2024 George Liu <liuxiwei@ieisystem.com>

dcmi: Flexible support for dhcp dbus path

Since dhcp4 and dhcp6 configurations will be added in the future [1],
when calling ipmitool's dcmi get/set conf param command, all dhcp
paths should be flex

dcmi: Flexible support for dhcp dbus path

Since dhcp4 and dhcp6 configurations will be added in the future [1],
when calling ipmitool's dcmi get/set conf param command, all dhcp
paths should be flexibly supported instead of hard-coding the dhcp
dbus path.

[1] https://gerrit.openbmc.org/c/openbmc/phosphor-networkd/+/63124

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

show more ...


# af762de5 17-Dec-2023 Thang Tran <thuutran@amperecomputing.com>

dcmi: correct return data of Get Configuration Parameter command

When users call "ipmitool dcmi get_conf_param" command, ipmitool shows
paramters are disabled or 0.
```
DHCP Discovery method

dcmi: correct return data of Get Configuration Parameter command

When users call "ipmitool dcmi get_conf_param" command, ipmitool shows
paramters are disabled or 0.
```
DHCP Discovery method :
Management Controller ID String is disabled
Vendor class identifier DCMI IANA and Vendor class-specific \
Informationa are disabled
Initial timeout interval : 0 seconds
Server contact timeout interval : 0 seconds
Server contact retry interval : 0 seconds
```

Those information are incorrect. The root cause of this issue due to the
Get DCMI Configuration Command only returns success value w/o parameter
data.

This commit adds parameter data to the response message.

Tested:
1. Get DCMI Configuration Parameter
$ipmitool dcmi get_conf_param
2. Data are shown as below
```
DHCP Discovery method :
Management Controller ID String is enabled
Vendor class identifier DCMI IANA and Vendor class-specific
Informationa are disabled
Initial timeout interval : 4 seconds
Server contact timeout interval : 120 seconds
Server contact retry interval : 64 seconds
```

Change-Id: I0089993062c3c30792786b8e7f0f39f9507f93c3
Signed-off-by: Thang Tran <thuutran@amperecomputing.com>

show more ...


# 3dad826b 17-Aug-2023 Thang Tran <thuutran@amperecomputing.com>

dbus-sdr: support Get Temperature Readings command

This commit support Get Temperature Readings command in the
dynamicsensor library.

The design follows teps:
- Get the list of sensors based on Ent

dbus-sdr: support Get Temperature Readings command

This commit support Get Temperature Readings command in the
dynamicsensor library.

The design follows teps:
- Get the list of sensors based on Entity Id
- Sort the list of sensors.
- Loop all of sensors in the list, if its Entity Instance is greater
than the Instance Start then read the temperature via object path.

Tested:
1. Request to read Temperature of sensors
"ipmitool dcmi get_temp_reading"
2. Display Entity Id, Entity Instance, Temperature of sensors

Change-Id: Iaa7d65a763dacb50c1488d2a161b180fed49899b
Signed-off-by: Thang Tran <thuutran@amperecomputing.com>

show more ...


# 68d9d405 09-Nov-2023 Matt Simmering <matthew.simmering@intel.com>

Update terminology used within repo

Update the terms to more inclusive language. This change if only for
variables used in the repo.

Change-Id: I5151c9c2efab707b5dbc707e55333a3cb8c4e32b
Signed-off-

Update terminology used within repo

Update the terms to more inclusive language. This change if only for
variables used in the repo.

Change-Id: I5151c9c2efab707b5dbc707e55333a3cb8c4e32b
Signed-off-by: Matt Simmering <matthew.simmering@intel.com>

show more ...


# 5ea83fad 16-Oct-2023 Thang Tran <thuutran@amperecomputing.com>

dcmi: fix Get Sensor Info command

Issue: if users request to Get Sensors Info via "ipmitool dcmi sensors"
command, the Record ID of sensors always are 0x0000.

Root Cause: In the loop of scanning th

dcmi: fix Get Sensor Info command

Issue: if users request to Get Sensors Info via "ipmitool dcmi sensors"
command, the Record ID of sensors always are 0x0000.

Root Cause: In the loop of scanning the configuration file to get the
record ID, it is using the "config" variable instead of the "reading"
variable. It makes the record ID always is 0x0000.

Solution: Replace the "config" variable with the "reading" variable.

Tested:
1. Request to Get Sensors Info.
$ipmitool dcmi sensors
2. The list of sensors and temperature are shown.

Change-Id: If2b03b6b8a077a4e9239403ec9ecd640f645cbc0
Signed-off-by: Thang Tran <thuutran@amperecomputing.com>

show more ...


# 523e2d1b 05-Sep-2023 Willy Tu <wltu@google.com>

ipmid: Update sdbuspp namespaces

Fixed all errors when we remove
`SDBUSPP_REMOVE_DEPRECATED_NAMESPACE` in sdbusplus.

Change-Id: I5607585b2709faa7aee347d26e458ef769ca1626
Signed-off-by: Willy Tu <wl

ipmid: Update sdbuspp namespaces

Fixed all errors when we remove
`SDBUSPP_REMOVE_DEPRECATED_NAMESPACE` in sdbusplus.

Change-Id: I5607585b2709faa7aee347d26e458ef769ca1626
Signed-off-by: Willy Tu <wltu@google.com>

show more ...


# fd9c3617 19-Sep-2023 Thang Tran <thuutran@amperecomputing.com>

dcmi: fix Get/Set Power Limit issues

Get Power Limit command:
Issue: The completion code byte always is 0x00
Root cause: In the getPowerLimit function, it is checking "pcapEnable"
is valid or

dcmi: fix Get/Set Power Limit issues

Get Power Limit command:
Issue: The completion code byte always is 0x00
Root cause: In the getPowerLimit function, it is checking "pcapEnable"
is valid or not instead checking the value of "pcapEnable".
Solution: checking the value of "pcapEnable" is true or false.

Set Power Limit command:
Issue: The length of command always false.
Root cause: the first reserved parameter is 3 bytes, not 2 bytes.
Solution: Add one more reserved byte.

Tested:
IPMI dcmi set/get power limit commands work well.

Change-Id: I3c97411d9e9c39498c0db64d37e6ca4458161b43
Signed-off-by: Thang Tran <thuutran@amperecomputing.com>

show more ...


# 6475b5c9 27-Jul-2023 Vernon Mauery <vernon.mauery@linux.intel.com>

Update DCMI Get/Set Config Parameters commands

DCMI Configuration Parameters commands were still using the old
IPMI API and blocking dbus calls. This updates them to use the new API
and yielding dbu

Update DCMI Get/Set Config Parameters commands

DCMI Configuration Parameters commands were still using the old
IPMI API and blocking dbus calls. This updates them to use the new API
and yielding dbus calls.

Tested: 'ipmitool dcmi get_conf_param' and
'ipmitool dcmi set_conf_param' work the same as before

Change-Id: Ib50118c2dd515c134c3206ee128be2d3e7ea7c81
Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>

show more ...


# 53d0cf1d 27-Jul-2023 Vernon Mauery <vernon.mauery@linux.intel.com>

Update DCMI Get Sensor Reading command

DCMI Get Sensor Reading command was still using the old IPMI API and
blocking dbus calls. This updates it to use the new API and yielding
dbus calls.

Tested:

Update DCMI Get Sensor Reading command

DCMI Get Sensor Reading command was still using the old IPMI API and
blocking dbus calls. This updates it to use the new API and yielding
dbus calls.

Tested: 'ipmitool dcmi sensors' works the same as before

Change-Id: I0aef54ec581dcc98d536e7dfa31c473f16e82754
Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>

show more ...


# 056fab1a 27-Jul-2023 Vernon Mauery <vernon.mauery@linux.intel.com>

update DCMI Get Power Reading command

DCMI Get Power Reading command was still using the old IPMI API and
blocking dbus calls. This updates it to use the new API and yielding
dbus calls.

Tested: 'i

update DCMI Get Power Reading command

DCMI Get Power Reading command was still using the old IPMI API and
blocking dbus calls. This updates it to use the new API and yielding
dbus calls.

Tested: 'ipmitool dcmi power reading' works the same as before

Change-Id: Id8b732bd6ebf2a4d7087fa6fb47edcf35f20fee8
Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>

show more ...


# cce9ffd9 27-Jul-2023 Vernon Mauery <vernon.mauery@linux.intel.com>

update DCMI Read Temperatures command

DCMI Read Temperatures command was still using the old IPMI API and
blocking dbus calls. This updates it to use the new API and yielding
dbus calls.

Tested: 'i

update DCMI Read Temperatures command

DCMI Read Temperatures command was still using the old IPMI API and
blocking dbus calls. This updates it to use the new API and yielding
dbus calls.

Tested: 'ipmitool dcmi get_temp_reading' works the same as before

Change-Id: If5d9fb190173c3ba864030aec4067708fc70eb08
Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>

show more ...


# f038dc09 27-Jul-2023 Vernon Mauery <vernon.mauery@linux.intel.com>

Update DCMI Get Capabilities command

DCMI Get Capabilities command was still using the old IPMI API and
blocking dbus calls. This updates it to use the new API and yielding
dbus calls.

Tested: 'ipm

Update DCMI Get Capabilities command

DCMI Get Capabilities command was still using the old IPMI API and
blocking dbus calls. This updates it to use the new API and yielding
dbus calls.

Tested: 'ipmitool dcmi discover' works the same as before

Change-Id: I8360fc8f6a5ec69031d219f55a1b5b37593b185c
Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>

show more ...


# efb5ae55 27-Jul-2023 Vernon Mauery <vernon.mauery@linux.intel.com>

update DCMI management ctrl ID str commands

DCMI management controller ID string commands were still using the old
IPMI API and blocking dbus calls. This updates them to use the new API
and yielding

update DCMI management ctrl ID str commands

DCMI management controller ID string commands were still using the old
IPMI API and blocking dbus calls. This updates them to use the new API
and yielding dbus calls.

Tested: 'ipmitool dcmi get_mc_id_string' and
'ipmitool dcmi set_mc_id_string' work the same as before

Change-Id: I6bd6284e8f346e4a80d744c6824c5f2f914cd7f3
Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>

show more ...


# dca4720f 27-Jul-2023 Vernon Mauery <vernon.mauery@linux.intel.com>

Update DCMI asset tag commands

DCMI asset tag commands were still using the old IPMI API and
blocking dbus calls. This updates them to use the new API and
yielding dbus calls.

Tested: 'ipmitool dcm

Update DCMI asset tag commands

DCMI asset tag commands were still using the old IPMI API and
blocking dbus calls. This updates them to use the new API and
yielding dbus calls.

Tested: 'ipmitool dcmi asset_tag' and ipmitool dcmi set_asset_tag'
work the same as before

Change-Id: I0f6486fc3d9494628db12ddfe0afbd6afd967a91
Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>

show more ...


# d4222fd3 27-Jul-2023 Vernon Mauery <vernon.mauery@linux.intel.com>

Update DCMI power limit commands

DCMI power limit commands were still using the old IPMI API and
blocking dbus calls. This updates them to use the new API and yielding
dbus calls.

Tested: ipmitool

Update DCMI power limit commands

DCMI power limit commands were still using the old IPMI API and
blocking dbus calls. This updates them to use the new API and yielding
dbus calls.

Tested: ipmitool power get_limit works the same as before

Change-Id: Ib71afac7dd840b7a413813ee050c5fa238716af5
Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>

show more ...


# f4eb35d0 27-Jul-2023 Vernon Mauery <vernon.mauery@linux.intel.com>

make isDCMIPowerMgmtSupported cache response

isDCMIPowerMgmtSupported is called a lot if any of the DCMI commands
are used, so it makes sense to cache the value rather than constantly
re-parsing the

make isDCMIPowerMgmtSupported cache response

isDCMIPowerMgmtSupported is called a lot if any of the DCMI commands
are used, so it makes sense to cache the value rather than constantly
re-parsing the JSON file, especially since it won't change except for
on a fw update.

Tested: DCMI power management commands continue to work as before.

Change-Id: Id0deb40c4a5332d5f96d7dda6d958f20925c01a9
Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>

show more ...


# 3e3cc35b 26-Jul-2023 George Liu <liuxiwei@inspur.com>

Remove is_method_error method

Remove the usage of is_method_error()[1], and add try-catch to handle
D-Bus exceptions around mapper call.

[1]https://github.com/openbmc/sdbusplus/commit/079fb85a398d9

Remove is_method_error method

Remove the usage of is_method_error()[1], and add try-catch to handle
D-Bus exceptions around mapper call.

[1]https://github.com/openbmc/sdbusplus/commit/079fb85a398d90800935e3985bb1266a7530a26e#diff-945669e8bd9cab4ecc83a574a732921281b2c79eb8bba65efff11736ad18f92bR237-R240

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

show more ...


# d74df5f2 25-May-2023 Chau Ly <chaul@amperecomputing.com>

Change Get DCMI sensor info privilege to OPERATOR

This commit changes the privilege to execute the command get DCMI sensor
info (command 0x07) from USER to OPERATOR to match with Table 6.1 of
DCMI s

Change Get DCMI sensor info privilege to OPERATOR

This commit changes the privilege to execute the command get DCMI sensor
info (command 0x07) from USER to OPERATOR to match with Table 6.1 of
DCMI specification.

Tested:
1. Create a user with USER/READONLY privilege
2. $ipmitool -H ${BMC_IP} -U root -P 0penBmc -C 17 -I lanplus \
-L USER raw 0x2c 0x07 0xdc 0x01 0x41 0x00 0x00
Result: Unable to send RAW command
(channel=0x0 netfn=0x2c lun=0x0 cmd=0x7 rsp=0xd4):
Insufficient privilege level
3. Change the user privilege to OPERATOR or ADMIN:
$ipmitool -H ${BMC_IP} -U root -P 0penBmc -C 17 -I lanplus \
user priv <user id> 0x3/0x4
4. Can successfully get the result from step 2.

Signed-off-by: Chau Ly <chaul@amperecomputing.com>
Change-Id: Id841fe94a79dcbf389249209b27ad6b08f39d119

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 ...


# 55cbf552 31-Jan-2023 Thang Tran <thuutran@amperecomputing.com>

update return type of getDHCPEnabled function

In the phosphor-dbus-interfaces, the DHCPEnabled property has been
changed from bool to enum type. Therefore, the getDHCPEnabled function
has to be upda

update return type of getDHCPEnabled function

In the phosphor-dbus-interfaces, the DHCPEnabled property has been
changed from bool to enum type. Therefore, the getDHCPEnabled function
has to be updated to adapt to phosphor-dbus-interfaces.

Tested:
1. Request to active dhcp successfully
$ipmitool dcmi set_conf_param activate_dhcp

Change-Id: I0cd2ce3ab78c3e4d2f376a99ab1ebf33b0ea39d3
Signed-off-by: Thang Tran <thuutran@amperecomputing.com>

show more ...


# 042e9db4 15-Sep-2022 adarshgrami <adarshgr@ami.com>

DCMI Commands: Support Get DCMI Sensor Info Dynamically

When Dynamic SDR Feature is enabled the sensor record id should be get dynamically for DCMI Sensors.

Tested:

Case 1:Get inlet sensor informa

DCMI Commands: Support Get DCMI Sensor Info Dynamically

When Dynamic SDR Feature is enabled the sensor record id should be get dynamically for DCMI Sensors.

Tested:

Case 1:Get inlet sensor information

$ipmitool raw 0x2c 0x07 0xdc 0x01 0x40 0x00 0x00

dc 01 01 1a 00

Case 2:Get Baseboard sensor information

ipmitool raw 0x2c 0x07 0xdc 0x01 0x41 0x00 0x00

dc 02 02 18 00 19 00

Case 3:Get CPU sensor information

ipmitool raw 0x2c 0x07 0xdc 0x01 0x42 0x00 0x00

dc 01 01 1b 00

Case 4: Give a invalid sensor instance number

$ipmitool raw 0x2c 0x07 0xdc 0x01 0x41 0x05 0x00

Unable to send RAW command (channel=0x0 netfn=0x2c lun=0x0 cmd=0x7 rsp=0xff): Unspecified error

Result : The command should throw error

Case 5:Get a specific sensor details by giving instance parameter 2 of CPU sensors

$ipmitool raw 0x2c 0x07 0xdc 0x01 0x41 0x02 0x00

dc 02 01 19 00

Signed-off-by: adarshgrami <adarshgr@ami.com>
Change-Id: Ib2099a49ecaebc16b5fae29a4c18ca3e788aabf1

show more ...


123