#
06f265f6 |
| 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: I4f63258febea27dae710c252033b9151e02be7e8 Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
show more ...
|
#
9d8ba947 |
| 13-Jul-2023 |
William A. Kennington III <wak@google.com> |
bus: Consistently leverage mock
We have some project generating matches that are using the mock. Previously, we never checked the return value of this function and it allowed our match creations to
bus: Consistently leverage mock
We have some project generating matches that are using the mock. Previously, we never checked the return value of this function and it allowed our match creations to silently fail. With error checking added, this was breaking unit tests.
This change makes sure that all users of slot generating functions have their calls properly mocked.
Change-Id: I5dab3e3ae73e8516db21c928fc39bc00d4218c82 Signed-off-by: William A. Kennington III <wak@google.com>
show more ...
|
#
66492215 |
| 19-Nov-2021 |
Patrick Williams <patrick@stwcx.xyz> |
bus: reduce forward declaration for friendship
Generally we do not want users to be able to get the underlying `sd_bus` pointer held by the `bus_t`, but there are a number of classes inside sdbusplu
bus: reduce forward declaration for friendship
Generally we do not want users to be able to get the underlying `sd_bus` pointer held by the `bus_t`, but there are a number of classes inside sdbusplus that do need the bus so that they can make appropriate sd_bus call. Previously, we've required every one of these classes to be forward declared inside `bus.hpp`, which is clutter. Create a new class, with a simple static function, which can be inherited by any internal class and allows access to the underlying `sd_bus*`.
Refactor classes which were previously friends to now inherit from this class.
Signed-off-by: Patrick Williams <patrick@stwcx.xyz> Change-Id: Ide0e7147801d01dc45b255261ba2cafefabddbb1
show more ...
|
#
a7ac313c |
| 19-Nov-2021 |
Patrick Williams <patrick@stwcx.xyz> |
slot: explicitly transfer pointer
The slot class is intended to be an RAII wrapper around the C-style `sd_bus_slot*`. As part of the constructor it gets the pointer it is assuming ownership for.
T
slot: explicitly transfer pointer
The slot class is intended to be an RAII wrapper around the C-style `sd_bus_slot*`. As part of the constructor it gets the pointer it is assuming ownership for.
The previous constructor took the `sd_bus_slot*` by value so it was possible that the caller still kept the slot rather than fully transferring ownership. Switch the constructor to an r-value reference so that the caller's pointer can be erased as part of the ownership transfer.
Also, add an assignment operator to simplify the syntax when a slot is first initialized with `nullptr` and then later given ownership of a newly constructed slot.
While this is an incompatible constructor change, it is not expected to affect any current users. The only example of referencing a `slot::slot` I could see in the current OpenBMC org calls the constructor with a `nullptr`, which will seamlessly call the new r-value variant.
Signed-off-by: Patrick Williams <patrick@stwcx.xyz> Change-Id: I577de2e10e4d5ccae6337c763b848ea4cf2121dd
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 ...
|
#
0f282c48 |
| 19-Nov-2021 |
Patrick Williams <patrick@stwcx.xyz> |
bus: shorten bus type
Create an alias `sdbusplus::bus_t` to `sdbusplus::bus::bus` to reduce duplication.
Signed-off-by: Patrick Williams <patrick@stwcx.xyz> Change-Id: I9f17892eed5112d4946949861488
bus: shorten bus type
Create an alias `sdbusplus::bus_t` to `sdbusplus::bus::bus` to reduce duplication.
Signed-off-by: Patrick Williams <patrick@stwcx.xyz> Change-Id: I9f17892eed5112d49469498614884c02bba86011
show more ...
|
#
32ffb03d |
| 12-Oct-2020 |
Patrick Williams <patrick@stwcx.xyz> |
server: un-inline various large functions
Save approximiately 70k (ARM32) of size from the generated library of libphosphor-dbus.so by un-inlining various large functions.
Signed-off-by: Patrick Wi
server: un-inline various large functions
Save approximiately 70k (ARM32) of size from the generated library of libphosphor-dbus.so by un-inlining various large functions.
Signed-off-by: Patrick Williams <patrick@stwcx.xyz> Change-Id: Ie238ca7807960bf1577dcbb272226f197de84b01
show more ...
|