History log of /openbmc/libpldm/include/ (Results 1 – 25 of 262)
Revision Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
ae7410c312-Sep-2025 Kasun Athukorala <kasunath@google.com>

dsp: base: Added encode_pldm_base_negotiate_transfer_params_resp()

This command is based on DSP0240 v1.2.0 section 9.6.2
NegotiateTransferParameters (0x07).

gitlint-ignore: T1
Signed-off-by: Kasun

dsp: base: Added encode_pldm_base_negotiate_transfer_params_resp()

This command is based on DSP0240 v1.2.0 section 9.6.2
NegotiateTransferParameters (0x07).

gitlint-ignore: T1
Signed-off-by: Kasun Athukorala <kasunath@google.com>
Change-Id: I619ca0b356df065b662b16d4a469730fd145f9de

show more ...

cb987c5c18-Jun-2025 Kasun Athukorala <kasunath@google.com>

dsp: base: Added decode_pldm_base_negotiate_transfer_params_req()

This command is based on DSP0240 v1.2.0 section 9.6.2
NegotiateTransferParameters (0x07).

gitlint-ignore: T1
Change-Id: I4fa193444d

dsp: base: Added decode_pldm_base_negotiate_transfer_params_req()

This command is based on DSP0240 v1.2.0 section 9.6.2
NegotiateTransferParameters (0x07).

gitlint-ignore: T1
Change-Id: I4fa193444df9ba5b109ca063163d7f7d109fcbda
Signed-off-by: Kasun Athukorala <kasunath@google.com>

show more ...

d7b9424118-Jun-2025 Kasun Athukorala <kasunath@google.com>

utils: Add an API to calculate cumulative crc32

Change-Id: I6c6fce214b98bc8f7284bc3e58319a9ef659e1b0
Signed-off-by: Kasun Athukorala <kasunath@google.com>

94f7fd6415-Sep-2025 Andrew Jeffery <andrew@codeconstruct.com.au>

include, tests: Address concerns from -Wsign-compare

After switching to Debian Trixie these surfaced as issues when building
locally.

Change-Id: I92a4d19579257e796aa29be8d4fb79fe92466780
Signed-off

include, tests: Address concerns from -Wsign-compare

After switching to Debian Trixie these surfaced as issues when building
locally.

Change-Id: I92a4d19579257e796aa29be8d4fb79fe92466780
Signed-off-by: Andrew Jeffery <andrew@codeconstruct.com.au>

show more ...

b36f9f0718-Jun-2025 Kasun Athukorala <kasunath@google.com>

dsp: base: Add ACKNOWLEDGE_COMPLETION transfer flag

ACKNOWLEDGE_COMPLETION flag is defined in DSP0240 v1.1.0 under
MultipartReceive response data structure definition.

Change-Id: I1bd340ebd2d521759

dsp: base: Add ACKNOWLEDGE_COMPLETION transfer flag

ACKNOWLEDGE_COMPLETION flag is defined in DSP0240 v1.1.0 under
MultipartReceive response data structure definition.

Change-Id: I1bd340ebd2d52175991f2084c1586bf3fe75b6ae
Signed-off-by: Kasun Athukorala <kasunath@google.com>

show more ...

6ae2fd7b17-Jul-2025 Kasun Athukorala <kasunath@google.com>

dsp: platform: Add file PDR descriptor encoding

Change-Id: Ic1627b0ba2a4c87f4a8352e7c63eede0a2513b80
Signed-off-by: Kasun Athukorala <kasunath@google.com>

7efe4f6409-Sep-2025 Kasun Athukorala <kasunath@google.com>

dsp: platform: Updated a macro definition

This patch updates the file descriptor PDR min length macro header
to note the inclusion of common PDR header bytes.

Change-Id: I479bea1f82680ca57f26c5b45b

dsp: platform: Updated a macro definition

This patch updates the file descriptor PDR min length macro header
to note the inclusion of common PDR header bytes.

Change-Id: I479bea1f82680ca57f26c5b45b763669488f2eb6
Signed-off-by: Kasun Athukorala <kasunath@google.com>

show more ...

f308a96408-Sep-2025 John Chung <john.chung@arm.com>

base: Allocating struct pldm_msg with member initialization

Avoid allocating struct pldm_msg without member initialization in
PLDM_MSG_DEFINE_P. Otherwise unit tests may fail with
-Werror=maybe-unin

base: Allocating struct pldm_msg with member initialization

Avoid allocating struct pldm_msg without member initialization in
PLDM_MSG_DEFINE_P. Otherwise unit tests may fail with
-Werror=maybe-uninitialized.

Change-Id: I3d0118a0067e373dc7bd2fd9b28eec2fdf5780e4
Signed-off-by: John Chung <john.chung@arm.com>

show more ...

fdf065b519-Aug-2025 Alexander Hansen <alexander.hansen@9elements.com>

ABI: named bitfield structs in pldm_types.h

Change the bitfield structs in pldm_types.h to be named structs.
This fixes an issue with the abi-dumper mistakenly seeing those as
1 byte wide when compi

ABI: named bitfield structs in pldm_types.h

Change the bitfield structs in pldm_types.h to be named structs.
This fixes an issue with the abi-dumper mistakenly seeing those as
1 byte wide when compiling with the C++ binding.

Change-Id: Ifecc4d62355e9233e88b75baffb4fcf89efe1c06
Signed-off-by: Alexander Hansen <alexander.hansen@9elements.com>

show more ...

cab9f9bb19-Aug-2025 Alexander Hansen <alexander.hansen@9elements.com>

clang-tidy: NOLINT reserved identifiers

fix clang-tidy error in CI. Experienced this error on an unrelated code
change [1]

```
/data0/jenkins/workspace/ci-repository/openbmc/libpldm/include/libpldm

clang-tidy: NOLINT reserved identifiers

fix clang-tidy error in CI. Experienced this error on an unrelated code
change [1]

```
/data0/jenkins/workspace/ci-repository/openbmc/libpldm/include/libpldm/firmware_update.h:2298:8: error: declaration uses identifier 'pldm__package_header_information', which is a reserved identifier [bugprone-reserved-identifier,cert-dcl37-c,cert-dcl51-cpp,-warnings-as-errors]
2298 | struct pldm__package_header_information {
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| pldm_package_header_information
2299 | pldm_uuid package_header_identifier;
2300 | uint8_t package_header_format_revision;
2301 | uint8_t package_release_date_time[PLDM_TIMESTAMP104_SIZE];
2302 | uint16_t component_bitmap_bit_length;
2303 | uint8_t package_version_string_type;
2304 |
2305 | /** A field pointing to the package version string in the provided package data */
2306 | struct variable_field package_version_string;
2307 | };
2308 | /* TODO: Deprecate the other struct pldm_package_header_information, remove, drop typedef */
2309 | typedef struct pldm__package_header_information
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| pldm_package_header_information
```

References:
[1] https://jenkins.openbmc.org/job/ci-repository/115058//console

Change-Id: I3e9dee5e266ee734f86039fc08dc28983d48c267
Signed-off-by: Alexander Hansen <alexander.hansen@9elements.com>

show more ...

72442dea12-Aug-2025 Andrew Jeffery <andrew@codeconstruct.com.au>

dsp: firmware_update: Flags for decode_pldm_firmware_update_package()

Allow influencing the parser behavior down the track.

Change-Id: If63284f5c67b7a8e40d5b3176f5b8367038eb98e
Signed-off-by: Andre

dsp: firmware_update: Flags for decode_pldm_firmware_update_package()

Allow influencing the parser behavior down the track.

Change-Id: If63284f5c67b7a8e40d5b3176f5b8367038eb98e
Signed-off-by: Andrew Jeffery <andrew@codeconstruct.com.au>

show more ...

c53c6fe911-Aug-2025 Andrew Jeffery <andrew@codeconstruct.com.au>

dsp: firmware_update: Run-time state machine for package parsing

Encoding the necessary sequence of calls with an approximation of linear
types is hampered by DSP0267's introduction of entirely new

dsp: firmware_update: Run-time state machine for package parsing

Encoding the necessary sequence of calls with an approximation of linear
types is hampered by DSP0267's introduction of entirely new sections
into the package format across revisions. The existing design enforced a
sequence that precluded _not_ calling the decoder for downstream device
records in the case of pinning to format revision 1. The choice had the
further effect of stunting the API to future expansion of the spec.

Switch from linear types to tracking parse state at runtime based on the
provided pin and the extracted package header.

The state machine implementation is modeled on the TLA+ specification
below, with NR_FORMATS set to 4 in the model:

```tla
---- MODULE pldm_package_parser ----
EXTENDS Integers, Sequences

\* pin and format have non-deterministic init, but are then constant
VARIABLE state, pin, format

vars == << state, pin, format >>

States == {
"Init",
"Header",
"FirmwareDevices",
"DownstreamDevices",
"ComponentImageInfos",
"Complete",
"Unsupported",
"Error"
}

Formats == 1..4

DecodeHeader ==
/\ state = "Init"
/\ state' = IF format <= pin THEN "Header" ELSE "Unsupported"
/\ UNCHANGED << pin, format >>

DecodeFirmwareDevices ==
/\ state = "Header"
/\ state' = "FirmwareDevices"
/\ UNCHANGED << pin, format >>

DecodeDownstreamDevices ==
/\ state = "FirmwareDevices"
/\ state' = IF pin = 1 THEN "Error" ELSE "DownstreamDevices"
/\ UNCHANGED << pin, format >>

DecodeComponentImageInfos ==
/\ \/ /\ state = "FirmwareDevices"
/\ pin = 1
\/ /\ state = "DownstreamDevices"
/\ pin \in ( Formats \ { 1 } )
/\ state' = "Complete"
/\ UNCHANGED << pin, format >>

Done == state \in { "Complete", "Unsupported", "Error" } /\ UNCHANGED vars

Init ==
/\ state = "Init"
/\ pin \in Formats
/\ format \in Formats

Next ==
\/ DecodeHeader
\/ DecodeFirmwareDevices
\/ DecodeDownstreamDevices
\/ DecodeComponentImageInfos
\/ Done

Spec == Init /\ [][Next]_vars /\ WF_state(Next)

TypeInvariant ==
/\ state \in States
/\ pin \in Formats
/\ format \in Formats

Safety ==
/\ TypeInvariant
/\ state \in States \ { "Init", "Unsupported" } => format <= pin

Liveness ==
/\ [][(state \in { "Complete", "Unsupported", "Error" } => UNCHANGED state)]_vars
/\ [][UNCHANGED <<pin, format>>]_vars

====
```

For an introduction to TLA+ see https://www.learntla.com/

Note that the implemented state machine does not exactly replicate that
specified in the model. Specifically:

- No "Unsupported" state is defined. Instead, the APIs return -ENOTSUP
- No "Error" state is defined. Instead, the APIs return -EPROTO

It is expected that callers perform appropriate error handling.

Change-Id: Id8780c1f5f130b77e6eea2519b5d5734aa79040e
Signed-off-by: Andrew Jeffery <andrew@codeconstruct.com.au>

show more ...

530d1a3a15-Aug-2025 Chau Ly <chaul@amperecomputing.com>

dsp: file: Let some encode APIs accept pointer to payload_length

In order to achieve [1], this commit updates some encoding APIs to
accept the length of the message as an in/out parameter (pointer t

dsp: file: Let some encode APIs accept pointer to payload_length

In order to achieve [1], this commit updates some encoding APIs to
accept the length of the message as an in/out parameter (pointer to
size_t). The APIs are then updated to return the encoded payload length
through this parameter.

The unit tests for these APIs are updated accordingly. The change list
includes:

- encode_pldm_file_df_open_req()
- encode_pldm_file_df_close_req()
- encode_pldm_file_df_heartbeat_req()

[1]: https://github.com/openbmc/libpldm/blob/main/CONTRIBUTING.md?plain=1#L270-L272

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

show more ...

e98a72fd14-Aug-2025 Chau Ly <chaul@amperecomputing.com>

dsp: base: Let some encode APIs accept pointer to payload_length

In order to achieve [1], this commit updates some encoding APIs to
accept the length of the message as an in/out parameter (pointer t

dsp: base: Let some encode APIs accept pointer to payload_length

In order to achieve [1], this commit updates some encoding APIs to
accept the length of the message as an in/out parameter (pointer to
size_t). The APIs are then updated to return the encoded payload length
through this parameter.

The unit tests for these APIs are updated accordingly. The change list
includes:

- encode_pldm_base_multipart_receive_req()
- encode_pldm_base_negotiate_transfer_params_req()

[1]: https://github.com/openbmc/libpldm/blob/main/CONTRIBUTING.md?plain=1#L270-L272

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

show more ...

7c65530213-Aug-2025 Chau Ly <chaul@amperecomputing.com>

platform: Reinforce some symbol names

This commit rename some symbol names for base APIs to reinforce API
naming convention defined here [1]. The list of change includes:

1. `struct pldm_file_descr

platform: Reinforce some symbol names

This commit rename some symbol names for base APIs to reinforce API
naming convention defined here [1]. The list of change includes:

1. `struct pldm_file_descriptor_pdr` to
`struct pldm_platform_file_descriptor_pdr`
2. `decode_pldm_file_descriptor_pdr()` to
`decode_pldm_platform_file_descriptor_pdr()`

[1]: https://github.com/openbmc/libpldm/blob/main/docs/checklists/changes.md#adding-a-new-api

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

show more ...

4184623812-Aug-2025 Chau Ly <chaul@amperecomputing.com>

base: Reinforce some symbol names

This commit renames some symbol names for base APIs to reinforce API
naming convention defined here [1]. The list of change includes:

1. `encode_base_multipart_rec

base: Reinforce some symbol names

This commit renames some symbol names for base APIs to reinforce API
naming convention defined here [1]. The list of change includes:

1. `encode_base_multipart_receive_req()` to
`encode_pldm_base_multipart_receive_req()`
2. `decode_base_multipart_receive_resp()` to
`decode_pldm_base_multipart_receive_resp()`
3. `struct pldm_multipart_receive_resp` to
`struct pldm_base_multipart_receive_resp`
4. `struct pldm_multipart_receive_req` to
`struct pldm_base_multipart_receive_req`

This also removes `__attribute__((packed))` from
`struct pldm_base_multipart_receive_req` to adapt [1].

[1]: https://github.com/openbmc/libpldm/blob/main/docs/checklists/changes.md#adding-a-new-api

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

show more ...

21a639d617-Jul-2025 John Chung <john.chung@arm.com>

dsp: base: Add encode resp for MultipartReceive command

Added encode APIs for MultipartReceive command (0x09) that
defined in DSP0240 1.2.0 section 9.6.

Change-Id: I08eb9be3685dd6eb35e7559eb3710160

dsp: base: Add encode resp for MultipartReceive command

Added encode APIs for MultipartReceive command (0x09) that
defined in DSP0240 1.2.0 section 9.6.

Change-Id: I08eb9be3685dd6eb35e7559eb37101604409562f
Signed-off-by: John Chung <john.chung@arm.com>

show more ...

76c9b19209-Jul-2025 John Chung <john.chung@arm.com>

dsp: file: Add decode req & encode resp for DfOpen & DfClose command

Add encode/decode APIs for DfOpen & DfClose command
which are defined in DSP0242 Version 1.0.0 Section 9.2 & 9.3

Change-Id: I249

dsp: file: Add decode req & encode resp for DfOpen & DfClose command

Add encode/decode APIs for DfOpen & DfClose command
which are defined in DSP0242 Version 1.0.0 Section 9.2 & 9.3

Change-Id: I249b3c915b3d0a2c35be31c808a84d0800637b68
Signed-off-by: John Chung <john.chung@arm.com>

show more ...

ea5f737820-Jun-2025 Matt Johnston <matt@codeconstruct.com.au>

dsp: platform: Add sensor enable responder

Add responder definitions and decode routines for
SetStateSensorEnables and SetNumericSensorEnable

Change-Id: Ic93da95f6b3cda4a99951943ebba1b1e20b95d79
Si

dsp: platform: Add sensor enable responder

Add responder definitions and decode routines for
SetStateSensorEnables and SetNumericSensorEnable

Change-Id: Ic93da95f6b3cda4a99951943ebba1b1e20b95d79
Signed-off-by: Matt Johnston <matt@codeconstruct.com.au>
Signed-off-by: Andrew Jeffery <andrew@codeconstruct.com.au>

show more ...

0178274525-Jun-2025 Carter Chen <carter.chen.wiwynn@gmail.com>

firmware_update: Add DSP0267 v1.3.0 version updates

- Added `reference_manifest_data` and `payload_checksum` fields
to relevant data structures.
- Implemented decode functionality for these fields

firmware_update: Add DSP0267 v1.3.0 version updates

- Added `reference_manifest_data` and `payload_checksum` fields
to relevant data structures.
- Implemented decode functionality for these fields to correctly
parse their contents.
- Added unit tests for DSP0267 v1.3.0 to verify the new
decoding functionality.

Change-Id: I4403ab18daffcec5a51247a8ba6cd426072dd764
Signed-off-by: Carter Chen <carter.chen.wiwynn@gmail.com>

show more ...

b87bc7c020-May-2025 Manojkiran Eda <manojkiran.eda@gmail.com>

firmware_update: Add 1.3.0 version updates

Add the newly added commands, completion codes , descriptor types as
part of firmware update spec version 1.3.0.

Change-Id: Idfb3f9deef23039879de6391348b3

firmware_update: Add 1.3.0 version updates

Add the newly added commands, completion codes , descriptor types as
part of firmware update spec version 1.3.0.

Change-Id: Idfb3f9deef23039879de6391348b33a88c89fdf5
Signed-off-by: Manojkiran Eda <manojkiran.eda@gmail.com>

show more ...

f72cf6f624-Jun-2025 Carter Chen <carter.chen.wiwynn@gmail.com>

firmware_update: Add DSP0267 v1.2.0 version updates

- Added `component_opaque_data` fields to relevant data structures.
- Implemented decode functionality for these fields to correctly
parse their

firmware_update: Add DSP0267 v1.2.0 version updates

- Added `component_opaque_data` fields to relevant data structures.
- Implemented decode functionality for these fields to correctly
parse their contents.
- Added unit tests for DSP0267 v1.2.0 to verify the new
decoding functionality.

Change-Id: I47a85b5c9f7cc28da6066e88e27e8dc877cc074b
Signed-off-by: Carter Chen <carter.chen.wiwynn@gmail.com>

show more ...

62b7dad719-May-2025 Manojkiran Eda <manojkiran.eda@gmail.com>

base: Add command specific completion codes

Add command specific completion codes for various base commands.

Change-Id: Iee01b0ec9cd13f5102f1767f7184ac47cfc36c43
Signed-off-by: Manojkiran Eda <mano

base: Add command specific completion codes

Add command specific completion codes for various base commands.

Change-Id: Iee01b0ec9cd13f5102f1767f7184ac47cfc36c43
Signed-off-by: Manojkiran Eda <manojkiran.eda@gmail.com>

show more ...

07264f4812-Jun-2025 Manojkiran Eda <manojkiran.eda@gmail.com>

base: Remove PLDM_INVALID_TRANSFER_OPERATION_FLAG

Remove `PLDM_INVALID_TRANSFER_OPERATION_FLAG` as it is incorrect as per
the base specification.

Change-Id: I89dd7f72d7d9a1bb6e9c981261324298afa0738

base: Remove PLDM_INVALID_TRANSFER_OPERATION_FLAG

Remove `PLDM_INVALID_TRANSFER_OPERATION_FLAG` as it is incorrect as per
the base specification.

Change-Id: I89dd7f72d7d9a1bb6e9c981261324298afa07385
Signed-off-by: Manojkiran Eda <manojkiran.eda@gmail.com>

show more ...

33ff135a22-Jun-2025 Andrew Jeffery <andrew@codeconstruct.com.au>

dsp: firmware_update: Document package format pin metadata

The magic and version fields of the pin struct were some what cryptic
while also being fundamental to the correctness of the implementation

dsp: firmware_update: Document package format pin metadata

The magic and version fields of the pin struct were some what cryptic
while also being fundamental to the correctness of the implementation.
Improve the documentation.

Change-Id: I0c3e1c0169719ee0ad6442e426e533e55fd08d15
Signed-off-by: Andrew Jeffery <andrew@codeconstruct.com.au>

show more ...

1234567891011