Using a struct[enum] as an sdbusplus D-Bus method arg?

Matt Spinler mspinler at linux.ibm.com
Thu Jan 30 02:08:28 AEDT 2020



On 1/28/2020 9:07 PM, Patrick Williams wrote:
> On Tue, Jan 14, 2020 at 11:41:17AM -0600, Patrick Williams wrote:
>> On Mon, Jan 13, 2020 at 12:59:26PM -0600, Matt Spinler wrote:
>> This needs a pretty simple refactoring to rename the
>> convert<enum>FromString function to a template function.
>>
>> -- 
>> Patrick Williams
> This probably wasn't as simple as I lead on with this previous email,
> but patches are up for sdbusplus ending with this change:
>      Ib142482de90572e1bda2f3658f6aeec201c043de
>
> https://gerrit.openbmc-project.xyz/c/openbmc/sdbusplus/+/28859
>
> With this commit sequence you should be able to read / write any
> container with sdbusplus-enums in it with the message::read / append
> functions, which as a side-effect means the generated classes no
> longer need all the conversion hoops they use to jump through.
>

Thanks!
I tried to build a flash (wspoon) image, and in the server.hpp generated 
for my interface,
https://gerrit.openbmc-project.xyz/c/openbmc/phosphor-dbus-interfaces/+/26544, 
it had:

#include <std/vector<std/message/tuple<FFDCFormat, uint8_t, uint8_t, 
sdbusplus.hpp>




More information about the openbmc mailing list