The entityID and entityInstance always be 0.1.

Paul Fertser fercerpav at gmail.com
Thu Aug 18 21:38:57 AEST 2022


Hi,

On Fri, Feb 26, 2021 at 02:39:51AM +0000, Scron Chang (張仲延) wrote:
> In my case, the BMC uses intel-ipmi-oem, entity-manager, and dbus-sensors to manage the motherboard's sensors.
> I intend to retrieve entityID and entityInstance via IPMI command, e.g., ipmitool sensor get <sensor name>.
> However, intel-ipmi-oem always tries to find the sensor's "entityID" and "entityInstance" from its entity-manager entry. 
> (please refer to
> https://github.com/openbmc/intel-ipmi-oem/blob/09701efa93f2e9b25b19c4560db60c1878ef8a9c/include/sdrutils.hpp#L438 and
> https://github.com/openbmc/intel-ipmi-oem/blob/09701efa93f2e9b25b19c4560db60c1878ef8a9c/include/sdrutils.hpp#L470) 
> 
> It seems like the entity-manager should create these two attributes consumed by intel-ipmi-oem, but schema doesn't include them.
> Besides, entity-manager doesn't create "entityID" and "entityInstance" by itself.
> I'm curious how initially entity-manager or intel-ipmi-oem plans to implement this feature.

If you add the needed interface to your board json file EM will
automatically create it on D-Bus and intel-ipmi-oem will be able to
find it via the associations, e.g. add

        "xyz.openbmc_project.Inventory.Decorator.Ipmi": {
            "EntityId": 7,
            "EntityInstance": 1
        }

to the main Exposes section and you'll be able to observe it with

busctl introspect xyz.openbmc_project.EntityManager /xyz/openbmc_project/inventory/system/board/<your board>

If there exists /xyz/openbmc_project/inventory/system/board/<your board>/<sensorname>
then its first xyz.openbmc_project.Configuration.* interface is
checked and if it contains EntityId or EntityInstance that'll be
preferred. You can simply add them to a specific sensor's json
section, however this is going to work only if <sensorname> matches
exactly, so if more than one sensor is created from a single entry the
override won't happen (e.g. "C3_P12V_IOUT" won't use the value for
"C3_P12V").

-- 
Be free, use free (http://www.gnu.org/philosophy/free-sw.html) software!
mailto:fercerpav at gmail.com


More information about the openbmc mailing list