[Skiboot] [PATCH] IPMI: Only log events that needs attention

Ananth N Mavinakayanahalli ananth at in.ibm.com
Mon Aug 10 17:03:01 AEST 2015


On Mon, Aug 10, 2015 at 10:52:48AM +0530, Vasant Hegde wrote:
> Presently we are logging all the events to service processor (FSP/BMC).
> But on BMC machines we should only log events that requires attention.
> 
> As per PEL spec, we should log events with severity >= 0x22 and "service
> action flag" is "on". But in our case, all logs OPAL originagted logs
> are makred as report externally.
> 
> So lets log all events that are originated from OAPL (presently all logs
> as payload is not logging any PEL event) and  severity >= 0x22.
> 
> Signed-off-by: Vasant Hegde <hegdevasant at linux.vnet.ibm.com>

Acked-by: Ananth N Mavinakayanahalli <ananth at in.ibm.com>

> Cc: Alistair Popple <alistair at popple.id.au>
> Cc: Jeremy Kerr <jk at ozlabs.org>
> ---
>  hw/ipmi/ipmi-sel.c | 5 +++++
>  1 file changed, 5 insertions(+)
> 
> diff --git a/hw/ipmi/ipmi-sel.c b/hw/ipmi/ipmi-sel.c
> index f03f19e..2842a0a 100644
> --- a/hw/ipmi/ipmi-sel.c
> +++ b/hw/ipmi/ipmi-sel.c
> @@ -268,6 +268,11 @@ int ipmi_elog_commit(struct errorlog *elog_buf)
>  {
>  	struct ipmi_msg *msg;
> 
> +	/* Only log events that needs attention */
> +	if (elog_buf->event_severity < OPAL_PREDICTIVE_ERR_FAULT_RECTIFY_REBOOT ||
> +	    elog_buf->elog_origin != ORG_SAPPHIRE)
> +		return 0;
> +
>  	/* We pass a large request size in to mkmsg so that we have a
>  	 * large enough allocation to reuse the message to pass the
>  	 * PEL data via a series of partial add commands.  */
> -- 
> 2.1.0



More information about the Skiboot mailing list