All of lore.kernel.org
 help / color / mirror / Atom feed
* Proposal for caching/buffering POST codes list for one boot process.
@ 2018-08-24  7:28 Wang, Kuiying
  2018-08-24 16:12 ` Tanous, Ed
  0 siblings, 1 reply; 16+ messages in thread
From: Wang, Kuiying @ 2018-08-24  7:28 UTC (permalink / raw)
  To: Kun Yi
  Cc: Li, Yong B, openbmc, Tanous, Ed, Feist, James,
	'Andrew Geissler',
	Brad Bishop, Jia, Chunhui, Yang, Cheng C, Xu, Qiang, Mihm, James,
	Nguyen, Hai V

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

Hi Kun,
Current implementation of phosphor-host-postd just publish one POST code to DBus, but no caching/buffering logic.
So other module cannot get a list of POST code for current/previous boot process.
So there is a proposal to do that which could benefit issue debugging and analysis.


1.      Define 2 properties in Raw.interface.yaml (https://github.com/openbmc/phosphor-dbus-interfaces/blob/master/xyz/openbmc_project/State/Boot/Raw.interface.yaml )
properties:
    - name: Value
      type: uint64
      description: >
          The POST code value.
    - name: PrePostCodes
      type: variant[uint32, uint64]
      description: >
          The POST code list of previous boot process.
          The fist uint32 is the time stamp the post code;
          the second uint64 is the post code value.
    - name: CurrPostCodes
      type: variant[uint32, uint64]
      description: >
          The POST code list of current boot process.
          The fist uint32 is the time stamp the post code;
          the second uint64 is the post code value.

2.      Save post code to CurrPostCodes list together w/ timestamp in PostCodeEventHandler function.

https://github.com/openbmc/phosphor-host-postd/blob/master/main.cpp#L99

3.      When detect host power off, copy CurrPostCodes to PrePostCodes and clean CurrPostCodes in host state manager

https://github.com/openbmc/phosphor-state-manager/blob/master/host_state_manager.cpp#L225

BTW: we could implement an IPMI command to get current/previous post codes remotely.

Thanks,
Kuiying.

From: Kun Yi [mailto:kun.yi.731@gmail.com]
Sent: Wednesday, August 22, 2018 12:36 AM
To: Wang, Kuiying <kuiying.wang@intel.com>
Cc: Li, Yong B <yong.b.li@intel.com>
Subject: Re: about post code

Hi Kuiying,

Yes, only the current POST code is published on DBus. The idea of caching/buffering more POST codes on the DBus server side is definitely interesting. It would require some thoughts on the DBus interface. If you have some thoughts, you are welcome to email the openbmc mailing list for a discussion.

With that said, it's not hard to implement a listener client that caches the POST codes received and stream them to log/file/network. The listener can also talk to the host Power control interface to interpret which POST codes these are for.

Thanks,
Kun

On Mon, Aug 20, 2018 at 2:51 AM Wang, Kuiying <kuiying.wang@intel.com<mailto:kuiying.wang@intel.com>> wrote:
Hi Kunyi,
According to the Raw.interface.yaml definition, and existing implementation, only current one post code is posted to dbus, right?
Do you plan to save all the post codes(and the timestamp for each) for previous boot process and current process?


Thanks,
Kuiying.


[-- Attachment #2: Type: text/html, Size: 14518 bytes --]

^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2018-09-05 12:17 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-08-24  7:28 Proposal for caching/buffering POST codes list for one boot process Wang, Kuiying
2018-08-24 16:12 ` Tanous, Ed
2018-08-24 18:07   ` Patrick Venture
2018-08-24 19:33     ` Tanous, Ed
2018-08-27  7:59       ` chunhui.jia
2018-08-27 15:45         ` Tanous, Ed
2018-08-27 23:52           ` Kun Yi
2018-08-27 23:55             ` Kun Yi
2018-08-27 23:58               ` Kun Yi
2018-08-28  6:09                 ` Tanous, Ed
2018-08-29  4:44                   ` Wang, Kuiying
2018-08-29 12:19                     ` Brad Bishop
2018-08-30  7:23                       ` Wang, Kuiying
2018-09-04 20:12                         ` Brad Bishop
2018-09-05  7:25                           ` Wang, Kuiying
2018-09-05 12:17                             ` Brad Bishop

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.