All of lore.kernel.org
 help / color / mirror / Atom feed
From: Patrick Williams <patrick@stwcx.xyz>
To: Deepak Kodihalli <dkodihal@linux.vnet.ibm.com>
Cc: Brad Bishop <bradleyb@fuzziesquirrel.com>,
	James Feist <james.feist@linux.intel.com>,
	"Thomaiyar,
	Richard Marian" <richard.marian.thomaiyar@linux.intel.com>,
	"Bhat, Sumanth" <sumanth.bhat@intel.com>,
	"openbmc@lists.ozlabs.org" <openbmc@lists.ozlabs.org>
Subject: Re: D-Bus interface to provide data to entity manager (was: Processing PLDM FRU information with entity manager)
Date: Thu, 28 May 2020 07:03:31 -0500	[thread overview]
Message-ID: <20200528120331.GC17541@heinlein> (raw)
In-Reply-To: <5fc67500-b0f4-c964-fc9a-d3f5346e47ab@linux.vnet.ibm.com>

[-- Attachment #1: Type: text/plain, Size: 3284 bytes --]

On Tue, May 26, 2020 at 06:26:27PM +0530, Deepak Kodihalli wrote:
> On 19/05/20 9:10 am, Deepak Kodihalli wrote:
> To do a) above, there are 3 options:
> 
> 1) Propose a D-Bus interface in phosphor-dbus-interfaces. This was [2] 
> in my original email above. The concern raised by Patrick here is that 
> this interface is very specific to a protocol (PLDM in this case), 
> whereas the phosphor D-Bus interfaces are mostly abstract and protocol 
> agnostic.
> 
> In my opinion, PLDM is also a data model, so PLDM specific D-Bus 
> interfaces can enable two apps that are PLDM aware (for eg a PLDM 
> requester app talking to the PLDM daemon) to talk to each other. I do 
> see other protocol specific D-Bus interfaces as well (for eg related to 
> SMBIOS). So I don't really understand the concern. The protocol specific 
> interfaces do not preclude other abstract interfaces.

After thinking about it for a bit, I think this is my preference with
the design caveat that these are only consumed by processes which are
"FRU-to-Inventory" transformers.  I would suggest putting these
interfaces under the 'Inventory/' namespace somewhere to hopefully make
this clearer.

We have two implementations of these "FRU-to-Inventory" transformers: EM
and PIM.  Both of them have a form of dbus backdoor in order to get the
information they need to create the Inventory objects they host.  PIM uses
`Inventory/Manager`[1] and EM uses an undocumented `FruDevice` interface
between it and 'fru-device'.  Both of these implementations do
processing on the data they get (though, very minimal in the case of
PIM) and create `Inventory/Item`s as a result.

What I am worried about, and Richard seconded in his response, is the
details of PLDM (or any other protocol) starting to leak into other
processes.  We don't want people to notice that there is some piece of
information that isn't currently exposed via Inventory but happens to be
available in PLDM and start coding towards consuming it.  Hence, my
request that the design document the caveat I listed above.  We want to
limit the scope of applications that need to understand specific
protocols.

My suggestion would be to put these new proposed PLDM interfaces under
`Inventory/Source/PLDM`.  Anything under `Source` becomes one of these
"FRU-to-Inventory" transformational interfaces.

> 2) Propose a generic/abstract 'FRU properties' kind of D-Bus interface. 
> This is something that both the PLDM daemon and FRU device daemon could 
> use to host FRU information on D-Bus, and to provide the same as an 
> intermediate FRU format data to apps like EM. The suggestion on the docs 
> commit above [2] was to have an interface like {Enum[Protocol], 
> array[byte]}. I think instead this could be a dict[string, 
> variant[string, int64]], for a FRU property to value mapping.

I don't like arbitrary string-based properties like this.  They aren't
documented and effectively become a private API between the processes.
In order for someone to make a new implementation they have to reverse
engineer the code.

> Thanks,
> Deepak

1. https://github.com/openbmc/phosphor-dbus-interfaces/blob/master/xyz/openbmc_project/Inventory/Manager.interface.yaml

-- 
Patrick Williams

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

  parent reply	other threads:[~2020-05-28 12:03 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-19  3:40 Processing PLDM FRU information with entity manager Deepak Kodihalli
2020-05-20 16:28 ` Brad Bishop
2020-05-20 16:56   ` James Feist
2020-05-20 17:35     ` Brad Bishop
2020-05-20 17:46       ` James Feist
2020-05-26 12:56 ` D-Bus interface to provide data to entity manager (was: Processing PLDM FRU information with entity manager) Deepak Kodihalli
2020-05-27 13:50   ` D-Bus interface to provide data to entity manager Thomaiyar, Richard Marian
2020-05-27 13:58     ` Deepak Kodihalli
2020-05-27 15:25       ` Thomaiyar, Richard Marian
2020-05-27 15:46         ` Deepak Kodihalli
2020-05-27 17:19           ` Thomaiyar, Richard Marian
2020-05-28 12:09             ` Patrick Williams
2020-05-28 12:03   ` Patrick Williams [this message]
2020-05-28 12:24     ` Deepak Kodihalli
2020-05-28 16:42       ` Thomaiyar, Richard Marian
2020-05-28 18:05         ` Patrick Williams
2020-05-28 18:31           ` James Feist
2020-05-29  5:11             ` Deepak Kodihalli
2020-05-29  5:09           ` Deepak Kodihalli
2020-05-29  7:17             ` Thomaiyar, Richard Marian
2020-05-29  7:31               ` Deepak Kodihalli
2020-05-29  9:03                 ` Thomaiyar, Richard Marian
2020-05-29 10:19                   ` Deepak Kodihalli
2020-05-29 10:30                     ` Deepak Kodihalli
2020-05-29 10:33                       ` Thomaiyar, Richard Marian
2020-05-28 15:43     ` D-Bus interface to provide data to entity manager (was: Processing PLDM FRU information with entity manager) Brad Bishop
2020-05-28 18:21       ` D-Bus interface to provide data to entity manager James Feist

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200528120331.GC17541@heinlein \
    --to=patrick@stwcx.xyz \
    --cc=bradleyb@fuzziesquirrel.com \
    --cc=dkodihal@linux.vnet.ibm.com \
    --cc=james.feist@linux.intel.com \
    --cc=openbmc@lists.ozlabs.org \
    --cc=richard.marian.thomaiyar@linux.intel.com \
    --cc=sumanth.bhat@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.