Re: [systemd-level]: how to set property to read only in systemd?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




Thank you very much for your help。

thanks,
Byron





At 2020-04-21 20:53:02, "Lennart Poettering" <lennart@xxxxxxxxxxxxxx> wrote: >On Di, 21.04.20 19:54, www (ouyangxuan10@xxxxxxx) wrote: > >> hi Lennart, >> >> >> I mean the DBUS property. >> >> root@demoboard:/# busctl set-property org.freedesktop.DBus /org/freedesktop/DBus org.freedesktop.DBus Features as 1 x >> >> Cannot set read-only property -- the default >> >> >> >> >> root@demoboard:/# busctl set-property com.sugon.sensors.DISCRETE /com/sugon/sensors/HDD/HDD4_Status xyz.openbmc_project.Sensor.DiscreteAll FanDeviceInserted b true -- new add >> >> root@demoboard:/# >> >> >> >> I want the property on Dbus is read only. Just can modify by the >> special method and cannot modify the property directly. How can I >> change it like this? > >Is "com.sugon.sensors.DISCRETE" a service you implemented yourself? >With the sd-bus API? > >In sd-bus you define a writable property in a vtable with the >SD_BUS_WRITABLE_PROPERTY() macro, and a read-only one with >SD_BUS_PROPERTY(). > >But not sure I grok your question properly. > >Lennart > >-- >Lennart Poettering, Berlin


 

_______________________________________________
systemd-devel mailing list
systemd-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/systemd-devel

[Index of Archives]     [LARTC]     [Bugtraq]     [Yosemite Forum]     [Photo]

  Powered by Linux