History log of /openbmc/libpldm/abi/ (Results 101 – 106 of 106)
Revision Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
b6c06f1826-Jun-2023 Andrew Jeffery <andrew@aj.id.au>

abi: Update for v0.3.0 tag

This should have been done at the time of the v0.3.0 tag but I
overlooked it. To fix that I've written a blog post on how and when the
ABI dumps should be updated:

https:

abi: Update for v0.3.0 tag

This should have been done at the time of the v0.3.0 tag but I
overlooked it. To fix that I've written a blog post on how and when the
ABI dumps should be updated:

https://amboar.github.io/notes/2023/06/26/managing-the-libpldm-abi-reference-dumps.html

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

show more ...

6409c8a013-Jun-2023 Andrew Jeffery <andrew@aj.id.au>

bios_table: Remove deprecated APIs sanitized by assert()

pldmd has now been reworked to remove its use of the unchecked APIs[1].

[1]: https://gerrit.openbmc.org/c/openbmc/pldm/+/64181

Signed-off-b

bios_table: Remove deprecated APIs sanitized by assert()

pldmd has now been reworked to remove its use of the unchecked APIs[1].

[1]: https://gerrit.openbmc.org/c/openbmc/pldm/+/64181

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

show more ...

8de8e1ec09-Jun-2023 Andrew Jeffery <andrew@aj.id.au>

meson: Reduce strength of oem-ibm requirements from enabled to allowed

If it's not expressly disabled, do what's necessary to build the oem-ibm
pieces of the code-base. Capture the newly-enabled API

meson: Reduce strength of oem-ibm requirements from enabled to allowed

If it's not expressly disabled, do what's necessary to build the oem-ibm
pieces of the code-base. Capture the newly-enabled APIs in the ABI
dumps.

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

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

33e21a2228-May-2023 Andrew Jeffery <andrew@aj.id.au>

abi: Differentiate on architectures and compilers

aarch64 and x86_64 have different stack orderings for parameters to
decode_get_date_time_resp() and
decode_get_fru_record_table_metadata_resp(). Thi

abi: Differentiate on architectures and compilers

aarch64 and x86_64 have different stack orderings for parameters to
decode_get_date_time_resp() and
decode_get_fru_record_table_metadata_resp(). This triggers a false ABI
break warning from abi-compliance-checker, as we weren't differentiating
on architecture.

Rearrange the compliance check to support multiple architectures and
compilers.

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

show more ...

953bc8c122-May-2023 Andrew Jeffery <andrew@aj.id.au>

libpldm: Enable API/ABI compliance checks

This catches breaks to the API and ABI of the library at compile time,
providing feedback to developers that they should probably not be doing
whatever it i

libpldm: Enable API/ABI compliance checks

This catches breaks to the API and ABI of the library at compile time,
providing feedback to developers that they should probably not be doing
whatever it is they have done.

abi-compliance-checker is only enabled if tests are enabled and the
necessary external programs can be found. The check can be forcefully
disabled with `-Dabi-compliance-check=disabled`.

A further constraint is that compliance is only checked with GCC. There
are some minor issues with abi-compliance-checker if the new dump is
generated with a different compiler (e.g. clang) to the reference dump.
The GCC limitation will remain until I can find a comfortable way
forward.

Below is an example of a detected violation where an existing API is
changed:

```
$ git diff
diff --git a/include/libpldm/platform.h b/include/libpldm/platform.h
index ead3421af4f9..44654bc6f0c3 100644
--- a/include/libpldm/platform.h
+++ b/include/libpldm/platform.h
@@ -1385,7 +1385,7 @@ int encode_get_pdr_repository_info_resp(
const uint8_t *update_time, const uint8_t *oem_update_time,
uint32_t record_count, uint32_t repository_size,
uint32_t largest_record_size, uint8_t data_transfer_handle_timeout,
- struct pldm_msg *msg);
+ struct pldm_msg *msg, int test);

/** @brief Decode GetPDRRepositoryInfo response data
*
diff --git a/src/platform.c b/src/platform.c
index 5da538cfa36e..69e5f87b0e41 100644
--- a/src/platform.c
+++ b/src/platform.c
@@ -366,7 +366,7 @@ int encode_get_pdr_repository_info_resp(
const uint8_t *update_time, const uint8_t *oem_update_time,
uint32_t record_count, uint32_t repository_size,
uint32_t largest_record_size, uint8_t data_transfer_handle_timeout,
- struct pldm_msg *msg)
+ struct pldm_msg *msg, int test __attribute__((unused)))
{
if (msg == NULL) {
return PLDM_ERROR_INVALID_DATA;
diff --git a/tests/libpldm_platform_test.cpp b/tests/libpldm_platform_test.cpp
index 0b3370dec60e..6fc1dd005535 100644
--- a/tests/libpldm_platform_test.cpp
+++ b/tests/libpldm_platform_test.cpp
@@ -405,7 +405,7 @@ TEST(GetPDRRepositoryInfo, testGoodEncodeResponse)
auto rc = encode_get_pdr_repository_info_resp(
0, PLDM_SUCCESS, repositoryState, updateTime, oemUpdateTime,
recordCount, repositorySize, largestRecordSize,
- dataTransferHandleTimeout, response);
+ dataTransferHandleTimeout, response, 1);

EXPECT_EQ(rc, PLDM_SUCCESS);
struct pldm_pdr_repository_info_resp* resp =
@@ -436,7 +436,7 @@ TEST(GetPDRRepositoryInfo, testBadEncodeResponse)
auto rc = encode_get_pdr_repository_info_resp(
0, PLDM_SUCCESS, repositoryState, updateTime, oemUpdateTime,
recordCount, repositorySize, largestRecordSize,
- dataTransferHandleTimeout, nullptr);
+ dataTransferHandleTimeout, nullptr, 1);
EXPECT_EQ(rc, PLDM_ERROR_INVALID_DATA);
}

$ meson compile -C build
INFO: autodetecting backend as ninja
INFO: calculating backend command to run: /usr/bin/ninja -C /mnt/host/andrew/home/andrew/src/openbmc/libpldm/build
ninja: Entering directory `/mnt/host/andrew/home/andrew/src/openbmc/libpldm/build'
[9/10] Generating abi-dump with a custom command
Detect public symbols
Reading debug-info
WARNING: a "Struct" type with no attributes detected in the DWARF dump (192)
ERROR: invalid debug_loc section of object, please fix your elf utils
ERROR: missed type id 13275
ERROR: missed type id 13632
ERROR: missed type id 11631
ERROR: missed type id 13540
ERROR: missed type id 702
ERROR: missed type id 60867
ERROR: missed type id 60369
ERROR: missed type id 30341
ERROR: missed type id 3570
ERROR: missed type id 3881
ERROR: missed type id 65373
ERROR: missed type id 66112
ERROR: missed type id 66916
Creating ABI dump

The object ABI has been dumped to:
current.dump
[10/10] Generating abi-compliance with a custom command
FAILED: abi-compliance
/usr/bin/abi-compliance-checker -l libpldm -old /mnt/host/andrew/home/andrew/src/openbmc/libpldm/abi/baseline.dump -new current.dump
Preparing, please wait ...
Comparing ABIs ...
Comparing APIs ...
Creating compatibility report ...
Binary compatibility: 99.8%
Source compatibility: 99.8%
Total binary compatibility problems: 1, warnings: 0
Total source compatibility problems: 1, warnings: 0
Report: compat_reports/libpldm/0.2.0_to_0.2.0/compat_report.html
ninja: build stopped: subcommand failed.
```

Change-Id: I72981ce48420eee970c3917059fbcbd350b00da9
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/LICENSE
/openbmc/libpldm/OWNERS
/openbmc/libpldm/README.md
baseline.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/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/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/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/mctp-defines.h
/openbmc/libpldm/src/meson.build
/openbmc/libpldm/src/msgbuf.h
/openbmc/libpldm/src/msgbuf/platform.h
/openbmc/libpldm/src/oem/ibm/file_io.c
/openbmc/libpldm/src/oem/ibm/host.c
/openbmc/libpldm/src/oem/ibm/meson.build
/openbmc/libpldm/src/oem/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/subprojects/googletest.wrap
/openbmc/libpldm/tests/.clang-format
/openbmc/libpldm/tests/instance-id.cpp
/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/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

12345