#
6db88387 |
| 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: I1d7d35c8035993df4c164bfb055d3be476d3ea84 Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
show more ...
|
#
da48d207 |
| 08-Mar-2023 |
Ed Tanous <edtanous@google.com> |
Fix vtable entires for offset callbacks
property_o didn't pass through the callbacks as sd-bus expected, so they can't be used for read-write properties. Add the expected methods.
Change-Id: Iad75
Fix vtable entires for offset callbacks
property_o didn't pass through the callbacks as sd-bus expected, so they can't be used for read-write properties. Add the expected methods.
Change-Id: Iad7592c99a60c22c10e274517ebfcbf8cf293a42 Signed-off-by: Ed Tanous <edtanous@google.com>
show more ...
|
#
1837cd59 |
| 06-Jan-2023 |
Ed Tanous <edtanous@google.com> |
Remove dead code paths
There's a few places where we call return after another return statement, or after a method that doesn't return. These are not required, and can be removed.
Change-Id: I0917
Remove dead code paths
There's a few places where we call return after another return statement, or after a method that doesn't return. These are not required, and can be removed.
Change-Id: I091716bd0eb8ad6aec7a54b66d175b348cbe00e0 Signed-off-by: Ed Tanous <edtanous@google.com>
show more ...
|
#
a735ca5c |
| 19-Nov-2021 |
Patrick Williams <patrick@stwcx.xyz> |
vtable: shorten vtable type
Create an alias `sdbusplus::vtable_t` to `sdbusplus::vtable::vtable_t` to reduce duplication.
Signed-off-by: Patrick Williams <patrick@stwcx.xyz> Change-Id: I0c3a8e40827
vtable: shorten vtable type
Create an alias `sdbusplus::vtable_t` to `sdbusplus::vtable::vtable_t` to reduce duplication.
Signed-off-by: Patrick Williams <patrick@stwcx.xyz> Change-Id: I0c3a8e40827cb011a07d75c99550a371afdefc64
show more ...
|
#
127b8abe |
| 21-May-2020 |
Patrick Williams <patrick@stwcx.xyz> |
clang-format: sync from docs master .clang-format
Signed-off-by: Patrick Williams <patrick@stwcx.xyz> Change-Id: I8077816a5ddf7a067bdf537cb46e4e32f5c4ef65
|
#
d35c8523 |
| 13-Dec-2019 |
Lei YU <mine260309@gmail.com> |
Fix vtable CI error
The CI reports failure in VtableTest.SameContent, where the case is comparing the binary of example vtables constructed from sdbusplus and macros defined in systemd.
The root ca
Fix vtable CI error
The CI reports failure in VtableTest.SameContent, where the case is comparing the binary of example vtables constructed from sdbusplus and macros defined in systemd.
The root cause has two parts.
Part I: When systemd is updated, the members in struct sd_bus_vtable is updated, e.g. * From v239 to v242, sd_bus_vtable.x.start is updated from struct { size_t element_size; } start; to: struct { size_t element_size; uint64_t features; } start; and sd_bus_vtable.x.method is updated from struct { const char *member; const char *signature; const char *result; sd_bus_message_handler_t handler; size_t offset; } method; to: struct { const char *member; const char *signature; const char *result; sd_bus_message_handler_t handler; size_t offset; const char *names; } method; * From v242 to v243, sd_bus_vtable.x.start is updated to struct { size_t element_size; uint64_t features; const unsigned *vtable_format_reference; } start;
The code in vtable.hpp only assign the members in v239, the new members are intialized with 0, so it differs from the vtable constructed from macros defined by systemd.
The fix is to use macros from systemd in vtable.hpp as well, which is suggested by systemd:
> Please do not initialize this structure directly, use the > macros below instead
Part II: The `const char *names` in struct method and signal introduced between systemd v239 and v242 is a pointer to const strings.
By default they are "empty" strings, but there is no guarantee that the compiler will use the same pointer for the same string.
So the test case can not assume the binaries are the same for two vtables even they are constructed with the same parameters.
Update the test case to use real `const char*` and handler/get/set functions and check each member of the struct instead of comparing the binary data by memcmp.
Tested: Verify the CI passes.
Change-Id: I9e94ff16075dd3f12d73e96438c0d864203bdcf4 Signed-off-by: Lei YU <mine260309@gmail.com>
show more ...
|
#
95269dbc |
| 31-Aug-2018 |
Patrick Venture <venture@google.com> |
update .clang-format header inclusion order
Added the header inclusion order to the .clang-format file generated these changes.
Change-Id: Ia31b21d7ea451cac0309828006bc17c27cbd5bd5 Signed-off-by: P
update .clang-format header inclusion order
Added the header inclusion order to the .clang-format file generated these changes.
Change-Id: Ia31b21d7ea451cac0309828006bc17c27cbd5bd5 Signed-off-by: Patrick Venture <venture@google.com>
show more ...
|
#
072da3ea |
| 18-Jan-2018 |
Andrew Geissler <geissonator@yahoo.com> |
Update repo to conform to openbmc code standard
Change-Id: If1d6b1f04514367cc544c2507a845b3e9d6d3435 Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
#
a14167b5 |
| 28-Apr-2017 |
Patrick Williams <patrick@stwcx.xyz> |
test: convert vtable to gtest
Change-Id: Ic54957df1c8d08c5461b262628fd1cc5c27217d7 Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
|
#
9d3ec7fb |
| 27-Sep-2016 |
Patrick Williams <patrick@stwcx.xyz> |
Add vtable support
The sd-bus interfaces for creating a VTABLE require C-only syntax, which prevents them from being used in C++ code. Create constexpr wrappers that emit VTABLE entries so that a V
Add vtable support
The sd-bus interfaces for creating a VTABLE require C-only syntax, which prevents them from being used in C++ code. Create constexpr wrappers that emit VTABLE entries so that a VTABLE can be created in C++ code.
Change-Id: I22892de1e87448ab9dce48034c9f030bc5bab9af Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
show more ...
|