History log of /openbmc/libpldm/src/oem/ (Results 1 – 12 of 12)
Revision Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
c8df31c121-May-2024 Andrew Jeffery <andrew@codeconstruct.com.au>

msgbuf: Add error code personalities

libpldm is in a bit of a transitional period with respect to returned
error codes. A historical choice was to return PLDM completion codes
from the library API t

msgbuf: Add error code personalities

libpldm is in a bit of a transitional period with respect to returned
error codes. A historical choice was to return PLDM completion codes
from the library API to indicate errors. This is unfortunate because
we're now constrained to errors that are specified by the PLDM protocol,
which is much less expressive than the set of errors that might be
produced by a run-time environment for the library.

The choice going forward is to return C's errno codes. However at this
point we step on another rake in the libpldm design, which is that some
internal data structures are very much the wire format of corresponding
PLDM messages (such as the PDR repository implementation). Working with
wire-format buffers is most safely done via the msgbuf APIs, however we
then hit the conflict of different error code styles in various parts of
the API surface.

Do a bit of surgery to provide different error code personalities for
msgbuf, such that the caller can pick the style of error code they need
it to return to maintain consistency.

Note that like the previous patch marking all msgbuf APIs as
__attribute__((always_inline)), the rework here makes another small
impact on the argument register allocation of several stable APIs. The
ABI dump is updated accordingly.

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

show more ...

66c7723a23-Apr-2024 Andrew Jeffery <andrew@codeconstruct.com.au>

msgbuf: Enable pldm_msgbuf_extract() into packed members

`pldm_msgbuf_extract()` should work correctly regardless of whether the
`dst` argument is a member of a packed or padded struct.

To get ther

msgbuf: Enable pldm_msgbuf_extract() into packed members

`pldm_msgbuf_extract()` should work correctly regardless of whether the
`dst` argument is a member of a packed or padded struct.

To get there while still achieving type safety we have to jump through
some hoops. Commentary in the patch hopefully captures many of them, but
a side-effect of the hoop-jumping is a couple of changes to ergonomics
of the msgbuf API:

1. `pldm_msgbuf_extract()` no-longer requires that the `dst`
argument be a pointer. Instead, it must be an lvalue, removing all
the `&<lvalue>` noise from the call-sites.

2. However, unfortunately the generic extraction macro has been split in
two. We now have:

2.1 `pldm_msgbuf_extract()`, and
2.2 `pldm_msgbuf_extract_p()`, for when the reference we already have
for the `dst` object is a pointer and not an lvalue.

The split was necessary because I couldn't get GCC and Clang to play
nice with differences required in the assignment expression for lvalue
and pointer type-names in the one macro. Whilst it causes a bunch of
churn it isn't a great concern as the APIs are purely internal to the
library implementation.

Change-Id: Ifc5440a5b838a48bb84c881ec334d9e145365edb
Signed-off-by: Andrew Jeffery <andrew@codeconstruct.com.au>
Signed-off-by: Thu Nguyen <thu@os.amperecomputing.com>

show more ...

a98814fc29-Nov-2023 Andrew Jeffery <andrew@codeconstruct.com.au>

oem: meta: stabilise decode_oem_meta_file_io_req()

Use of decode_oem_meta_file_io_req() is demonstrated in:

67050: Support OEM-META write file request for post code history
https://gerrit.openbmc.o

oem: meta: stabilise decode_oem_meta_file_io_req()

Use of decode_oem_meta_file_io_req() is demonstrated in:

67050: Support OEM-META write file request for post code history
https://gerrit.openbmc.org/c/openbmc/pldm/+/67050

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

show more ...

22fad39526-Oct-2023 Delphine CC Chiu <Delphine_CC_Chiu@wiwynn.com>

oem: meta: Add decode_oem_meta_file_io_req()

Support decode_oem_meta_file_io_req() cmd to decode the incoming post
code.

PLDM OEM Meta Write File IO cmd:
Example:
Request:
Byte 0: 0x3F (OEM c

oem: meta: Add decode_oem_meta_file_io_req()

Support decode_oem_meta_file_io_req() cmd to decode the incoming post
code.

PLDM OEM Meta Write File IO cmd:
Example:
Request:
Byte 0: 0x3F (OEM cmd)
Byte 1: 0x02 (FILE IO)
Byte 2: 0x00 (File io type : POST CODE)
Byte 3-6: 0x04 (Data length)
Byte 7-10: 0x93 0xE0 0x00 0xEA (post code)

Response:
Byte 0: 0x00 (success)

Tested:
- Unit Tests passed.

Change-Id: I85437698642dd3cbe6084acf1feada842d206eac
Signed-off-by: Delphine CC Chiu <Delphine_CC_Chiu@wiwynn.com>

show more ...


/openbmc/libpldm/CHANGELOG.md
/openbmc/libpldm/abi/x86_64/gcc.dump
/openbmc/libpldm/include/libpldm/base.h
/openbmc/libpldm/include/libpldm/bios_table.h
/openbmc/libpldm/include/libpldm/firmware_update.h
/openbmc/libpldm/include/libpldm/fru.h
/openbmc/libpldm/include/libpldm/instance-id.h
/openbmc/libpldm/include/libpldm/meson.build
/openbmc/libpldm/include/libpldm/oem/meta/file_io.h
/openbmc/libpldm/include/libpldm/platform.h
/openbmc/libpldm/include/libpldm/pldm.h
/openbmc/libpldm/include/libpldm/states.h
/openbmc/libpldm/include/libpldm/transport.h
/openbmc/libpldm/include/libpldm/transport/af-mctp.h
/openbmc/libpldm/include/libpldm/transport/mctp-demux.h
/openbmc/libpldm/include/libpldm/utils.h
/openbmc/libpldm/meson.build
/openbmc/libpldm/meson.options
/openbmc/libpldm/src/meson.build
meta/file_io.c
meta/meson.build
/openbmc/libpldm/src/pdr.c
/openbmc/libpldm/src/requester/instance-id.c
/openbmc/libpldm/src/requester/pldm.c
/openbmc/libpldm/src/responder.c
/openbmc/libpldm/src/transport/test.h
/openbmc/libpldm/src/transport/transport.c
/openbmc/libpldm/src/transport/transport.h
/openbmc/libpldm/tests/instance-id.cpp
/openbmc/libpldm/tests/libpldm_bios_table_test.cpp
/openbmc/libpldm/tests/libpldm_bios_test.cpp
/openbmc/libpldm/tests/libpldm_pdr_test.cpp
/openbmc/libpldm/tests/meson.build
/openbmc/libpldm/tests/oem/meta/libpldm_fileio_test.cpp
/openbmc/libpldm/tests/transport.cpp
/openbmc/libpldm/tests/transport/send_recv_one.cpp
/openbmc/libpldm/tests/transport/send_recv_timeout.cpp
/openbmc/libpldm/tests/transport/send_recv_unwanted.cpp
/openbmc/libpldm/tests/transport/send_recv_wrong_command_code.cpp
/openbmc/libpldm/tests/transport/send_recv_wrong_pldm_type.cpp
a7989cd630-Oct-2023 Pavithra Barithaya <pavithra.b@ibm.com>

meson: Fix for OEM header collision issue

It needs to be possible to build libpldm with any number of oem features
enabled simultaneously. If the header files are same then the earlier
implementatio

meson: Fix for OEM header collision issue

It needs to be possible to build libpldm with any number of oem features
enabled simultaneously. If the header files are same then the earlier
implementation will not work.

Install the header file in a way that doesn't break any oem portions.
Also the symlinks are generated to the older location until we migrate
the applications using the files to new location.

Tested: The headers are installed in the new location
and symlinks are generated.

Change-Id: I1455d52ff4b0c7f74b49d136bf582182537592d1
Signed-off-by: Pavithra Barithaya <pavithra.b@ibm.com>
Signed-off-by: Andrew Jeffery <andrew@codeconstruct.com.au>

show more ...

b0c1d20a07-Nov-2023 Andrew Jeffery <andrew@codeconstruct.com.au>

libpldm: Fix header use

The headers need to work whether we're building libpldm in the repo or
we're building another project depending on the headers in the system
include directory.

Tidy up the p

libpldm: Fix header use

The headers need to work whether we're building libpldm in the repo or
we're building another project depending on the headers in the system
include directory.

Tidy up the paths involved and switch to defining the public headers as
system headers for the purpose of the build.

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

show more ...

691668fe01-Nov-2023 Patrick Williams <patrick@stwcx.xyz>

license: add spdx identifier to all files

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


/openbmc/libpldm/.clang-format
/openbmc/libpldm/CHANGELOG.md
/openbmc/libpldm/OWNERS
/openbmc/libpldm/README.md
/openbmc/libpldm/abi/x86_64/gcc.dump
/openbmc/libpldm/include/libpldm/base.h
/openbmc/libpldm/include/libpldm/bios.h
/openbmc/libpldm/include/libpldm/bios_table.h
/openbmc/libpldm/include/libpldm/entity.h
/openbmc/libpldm/include/libpldm/firmware_update.h
/openbmc/libpldm/include/libpldm/fru.h
/openbmc/libpldm/include/libpldm/instance-id.h
/openbmc/libpldm/include/libpldm/oem/ibm/libpldm/entity_oem_ibm.h
/openbmc/libpldm/include/libpldm/oem/ibm/libpldm/file_io.h
/openbmc/libpldm/include/libpldm/oem/ibm/libpldm/fru_oem_ibm.h
/openbmc/libpldm/include/libpldm/oem/ibm/libpldm/host.h
/openbmc/libpldm/include/libpldm/oem/ibm/libpldm/platform_oem_ibm.h
/openbmc/libpldm/include/libpldm/oem/ibm/libpldm/state_set_oem_ibm.h
/openbmc/libpldm/include/libpldm/pdr.h
/openbmc/libpldm/include/libpldm/platform.h
/openbmc/libpldm/include/libpldm/pldm_types.h
/openbmc/libpldm/include/libpldm/requester/pldm.h
/openbmc/libpldm/include/libpldm/state_set.h
/openbmc/libpldm/include/libpldm/states.h
/openbmc/libpldm/include/libpldm/transport.h
/openbmc/libpldm/include/libpldm/transport/af-mctp.h
/openbmc/libpldm/include/libpldm/transport/mctp-demux.h
/openbmc/libpldm/include/libpldm/utils.h
/openbmc/libpldm/meson.build
/openbmc/libpldm/meson.options
/openbmc/libpldm/src/array.h
/openbmc/libpldm/src/base.c
/openbmc/libpldm/src/bios.c
/openbmc/libpldm/src/bios_table.c
/openbmc/libpldm/src/firmware_update.c
/openbmc/libpldm/src/fru.c
/openbmc/libpldm/src/mctp-defines.h
/openbmc/libpldm/src/meson.build
/openbmc/libpldm/src/msgbuf.h
/openbmc/libpldm/src/msgbuf/platform.h
ibm/file_io.c
ibm/host.c
ibm/platform.c
/openbmc/libpldm/src/pdr.c
/openbmc/libpldm/src/platform.c
/openbmc/libpldm/src/requester/instance-id.c
/openbmc/libpldm/src/requester/pldm.c
/openbmc/libpldm/src/responder.c
/openbmc/libpldm/src/responder.h
/openbmc/libpldm/src/transport/af-mctp.c
/openbmc/libpldm/src/transport/container-of.h
/openbmc/libpldm/src/transport/mctp-demux.c
/openbmc/libpldm/src/transport/meson.build
/openbmc/libpldm/src/transport/socket.c
/openbmc/libpldm/src/transport/socket.h
/openbmc/libpldm/src/transport/test.c
/openbmc/libpldm/src/transport/test.h
/openbmc/libpldm/src/transport/transport.c
/openbmc/libpldm/src/transport/transport.h
/openbmc/libpldm/src/utils.c
/openbmc/libpldm/tests/bios_table_iter.c
/openbmc/libpldm/tests/libpldm_base_test.cpp
/openbmc/libpldm/tests/libpldm_bios_table_test.cpp
/openbmc/libpldm/tests/libpldm_pdr_test.cpp
/openbmc/libpldm/tests/meson.build
/openbmc/libpldm/tests/msgbuf_generic.c
/openbmc/libpldm/tests/responder.cpp
/openbmc/libpldm/tests/transport.cpp
/openbmc/libpldm/tests/transport/send_recv_one.cpp
/openbmc/libpldm/tests/transport/send_recv_timeout.cpp
/openbmc/libpldm/tests/transport/send_recv_unwanted.cpp
/openbmc/libpldm/tests/transport/send_recv_wrong_command_code.cpp
/openbmc/libpldm/tests/transport/send_recv_wrong_pldm_type.cpp
f89befe315-Jun-2023 Andrew Jeffery <andrew@aj.id.au>

meson: Force inclusion of config.h via `-include`

Make sure there's no ambiguity about which config.h is used for includes
in the event that libpldm acquires subprojects, or is used as a
subproject

meson: Force inclusion of config.h via `-include`

Make sure there's no ambiguity about which config.h is used for includes
in the event that libpldm acquires subprojects, or is used as a
subproject itself.

Tested: `meson compile -C build` succeeds

Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
Change-Id: I08c3bdc807cc268d2401e06f0bfaee07f89ba534

show more ...

9d2a1c6a04-Jun-2023 Andrew Jeffery <andrew@aj.id.au>

libpldm: Explicit deprecated, stable and testing ABI classes

Experimenting with new APIs is important, but ABI stability of the
library is also important. We wish to have the freedom to add APIs
wit

libpldm: Explicit deprecated, stable and testing ABI classes

Experimenting with new APIs is important, but ABI stability of the
library is also important. We wish to have the freedom to add APIs
without being burdened by them being immediately set in stone.

We implement this wish by introducing three classes of ABI:

1. deprecated
2. stable
3. testing

These are enforced by corresponding function attributes:

1. LIBPLDM_ABI_DEPRECATED
2. LIBPLDM_ABI_STABLE
3. LIBPLDM_ABI_TESTING

Symbol visibility in the library is flipped to 'hidden' by default, so
one of these annotations must be used for the symbol to be exposed.

With these classes in place there are now clear points in time at which
we update the ABI dumps captured under the abi/ directory: When an API
is migrated from the 'testing' class to the 'stable' class, or when
removed from the 'deprecated' class.

Which classes of functions are exposed by the build is controlled by the
new 'abi' meson option. The option is of array type which contains the
list of ABI classes the build should consider. It defaults to enabling
all classes to provide test coverage in CI. The classes used should be
constrained to deprecated and stable (and not test) in any dependent
projects.

Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
Change-Id: I25402e20c7be9c9f264f9ccd7ac36b384823734c

show more ...

37dd6a3d12-May-2023 Andrew Jeffery <andrew@aj.id.au>

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[1] and reformat
the repository.

[1] https://gerrit.openbmc.org/c/openbmc/docs/+/63441

Further, shift the fixup for C's `_Static_assert` into src/msgbuf.h to
prevent a clang-tidy-16 error:

```
/data0/jenkins/workspace/ci-repository/openbmc/libpldm/src/msgbuf.h:315:2: error: '_Static_assert' is a C11 extension [clang-diagnostic-c11-extensions,-warnings-as-errors]
_Static_assert(sizeof(*dst) == sizeof(ldst),
^
```

And fix up the function prototype in the definition of `pldm_open()`:

```
../src/requester/pldm.c:128:16: error: a function declaration without a prototype is deprecated in all versions of C [clang-diagnostic-strict-prototypes,-warnings-as-errors]
void pldm_close()
^
void
```

Change-Id: I57b53f51914e39237e733d024e62ab41b3d306c1
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>

show more ...


/openbmc/libpldm/.clang-format
/openbmc/libpldm/.clang-tidy
/openbmc/libpldm/CHANGELOG.md
/openbmc/libpldm/OWNERS
/openbmc/libpldm/README.md
/openbmc/libpldm/include/libpldm/base.h
/openbmc/libpldm/include/libpldm/bios.h
/openbmc/libpldm/include/libpldm/bios_table.h
/openbmc/libpldm/include/libpldm/firmware_update.h
/openbmc/libpldm/include/libpldm/fru.h
/openbmc/libpldm/include/libpldm/instance-id.h
/openbmc/libpldm/include/libpldm/meson.build
/openbmc/libpldm/include/libpldm/oem/ibm/libpldm/file_io.h
/openbmc/libpldm/include/libpldm/pdr.h
/openbmc/libpldm/include/libpldm/platform.h
/openbmc/libpldm/include/libpldm/requester/pldm.h
/openbmc/libpldm/include/libpldm/state_set.h
/openbmc/libpldm/include/libpldm/transport.h
/openbmc/libpldm/include/libpldm/transport/af-mctp.h
/openbmc/libpldm/include/libpldm/transport/mctp-demux.h
/openbmc/libpldm/include/libpldm/utils.h
/openbmc/libpldm/instance-db/default
/openbmc/libpldm/meson.build
/openbmc/libpldm/src/base.c
/openbmc/libpldm/src/bios.c
/openbmc/libpldm/src/bios_table.c
/openbmc/libpldm/src/firmware_update.c
/openbmc/libpldm/src/fru.c
/openbmc/libpldm/src/mctp-defines.h
/openbmc/libpldm/src/meson.build
/openbmc/libpldm/src/msgbuf.h
/openbmc/libpldm/src/msgbuf/platform.h
ibm/file_io.c
ibm/host.c
ibm/platform.c
/openbmc/libpldm/src/pdr.c
/openbmc/libpldm/src/platform.c
/openbmc/libpldm/src/requester/instance-id.c
/openbmc/libpldm/src/requester/meson.build
/openbmc/libpldm/src/requester/pldm.c
/openbmc/libpldm/src/transport/af-mctp.c
/openbmc/libpldm/src/transport/container-of.h
/openbmc/libpldm/src/transport/mctp-demux.c
/openbmc/libpldm/src/transport/meson.build
/openbmc/libpldm/src/transport/transport.c
/openbmc/libpldm/src/transport/transport.h
/openbmc/libpldm/src/utils.c
/openbmc/libpldm/tests/instance-id.cpp
/openbmc/libpldm/tests/libpldm_bios_table_test.cpp
/openbmc/libpldm/tests/libpldm_bios_test.cpp
/openbmc/libpldm/tests/libpldm_pdr_test.cpp
/openbmc/libpldm/tests/libpldm_platform_test.cpp
/openbmc/libpldm/tests/libpldm_utils_test.cpp
/openbmc/libpldm/tests/meson.build
/openbmc/libpldm/tests/msgbuf.cpp
/openbmc/libpldm/tests/msgbuf_generic.c
/openbmc/libpldm/tests/oem/ibm/libpldm_fileio_test.cpp
/openbmc/libpldm/tests/oem/ibm/libpldm_host_test.cpp
9a8e497528-Nov-2022 Manojkiran Eda <manojkiran.eda@gmail.com>

Fix includes using iwyu tool

These changes are done by running iwyu manually under clang14.

IWYU can increase readability, make maintenance easier, and avoid errors
in some cases. See details in
``

Fix includes using iwyu tool

These changes are done by running iwyu manually under clang14.

IWYU can increase readability, make maintenance easier, and avoid errors
in some cases. See details in
```
https: //github.com/include-what-you-use/include-what-you-use/blob/master/docs/WhyIWYU.md.
```
Signed-off-by: Manojkiran Eda <manojkiran.eda@gmail.com>
Change-Id: Idaaeffd78c9ad7db2b41a057d40f889ade297c55

show more ...

9c76679210-Aug-2022 Andrew Jeffery <andrew@aj.id.au>

libpldm: Migrate to subproject

Organize files in libpldm to make it a subproject

In the current state, libpldm is not readily consumable
as a subproject.This commit does all the necessary re-organi

libpldm: Migrate to subproject

Organize files in libpldm to make it a subproject

In the current state, libpldm is not readily consumable
as a subproject.This commit does all the necessary re-organisation
of the source code to make it work as a subproject.

There are no .c/.h files changes in this commit, only meson
changes and re-organising the code structure.

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

show more ...


/openbmc/libpldm/.clang-format
/openbmc/libpldm/LICENSE
/openbmc/libpldm/include/libpldm/base.h
/openbmc/libpldm/include/libpldm/bios.h
/openbmc/libpldm/include/libpldm/bios_table.h
/openbmc/libpldm/include/libpldm/entity.h
/openbmc/libpldm/include/libpldm/firmware_update.h
/openbmc/libpldm/include/libpldm/fru.h
/openbmc/libpldm/include/libpldm/meson.build
/openbmc/libpldm/include/libpldm/oem/ibm/libpldm/entity_oem_ibm.h
/openbmc/libpldm/include/libpldm/oem/ibm/libpldm/file_io.h
/openbmc/libpldm/include/libpldm/oem/ibm/libpldm/fru_oem_ibm.h
/openbmc/libpldm/include/libpldm/oem/ibm/libpldm/host.h
/openbmc/libpldm/include/libpldm/oem/ibm/libpldm/platform_oem_ibm.h
/openbmc/libpldm/include/libpldm/oem/ibm/libpldm/state_set_oem_ibm.h
/openbmc/libpldm/include/libpldm/pdr.h
/openbmc/libpldm/include/libpldm/platform.h
/openbmc/libpldm/include/libpldm/pldm.h
/openbmc/libpldm/include/libpldm/pldm_types.h
/openbmc/libpldm/include/libpldm/requester/pldm.h
/openbmc/libpldm/include/libpldm/state_set.h
/openbmc/libpldm/include/libpldm/states.h
/openbmc/libpldm/include/libpldm/utils.h
/openbmc/libpldm/libpldm.pc.in
/openbmc/libpldm/meson.build
/openbmc/libpldm/meson_options.txt
/openbmc/libpldm/src/base.c
/openbmc/libpldm/src/bios.c
/openbmc/libpldm/src/bios_table.c
/openbmc/libpldm/src/firmware_update.c
/openbmc/libpldm/src/fru.c
/openbmc/libpldm/src/meson.build
ibm/file_io.c
ibm/host.c
ibm/meson.build
ibm/platform.c
/openbmc/libpldm/src/pdr.c
/openbmc/libpldm/src/platform.c
/openbmc/libpldm/src/requester/meson.build
/openbmc/libpldm/src/requester/pldm.c
/openbmc/libpldm/src/utils.c
/openbmc/libpldm/subprojects/googletest.wrap
/openbmc/libpldm/tests/.clang-format
/openbmc/libpldm/tests/libpldm_base_test.cpp
/openbmc/libpldm/tests/libpldm_bios_table_test.cpp
/openbmc/libpldm/tests/libpldm_bios_test.cpp
/openbmc/libpldm/tests/libpldm_firmware_update_test.cpp
/openbmc/libpldm/tests/libpldm_fru_test.cpp
/openbmc/libpldm/tests/libpldm_pdr_test.cpp
/openbmc/libpldm/tests/libpldm_platform_test.cpp
/openbmc/libpldm/tests/libpldm_utils_test.cpp
/openbmc/libpldm/tests/meson.build
/openbmc/libpldm/tests/oem/ibm/libpldm_fileio_test.cpp
/openbmc/libpldm/tests/oem/ibm/libpldm_host_test.cpp