Al,

For the SEL OEM record type 0xf0, that is something that we first
selected in 2003 as a way to save the full Linux panic string in the
OpenIPMI driver (see CONFIG_IPMI_PANIC_STRING), and was first introduced
as a patch for kernel 2.4.18.  See also
http://ipmiutil.sourceforge.net/kern.htm for history on this.    
It is the same record type and format used by the Intel IPMI driver, and
now even by the Microsoft IPMI driver in Windows, so it has become
common, but is not detailed in the IPMI spec.  It is a specific use case
that was provided for by the IPMI spec, however.  

Because this panic string is an ASCII string, it needs to be displayed
as ASCII rather than raw HEX.  

Andy

-----Original Message-----
From: Al Chu [mailto:ch...@llnl.gov] 
Sent: Friday, February 19, 2010 1:44 PM
To: ipmitool-devel@lists.sourceforge.net
Subject: [Ipmitool-devel] SEL code review nits

Saw these as I was looking through the ipmitool SEL code.

A)

        evt->record_type = 0;
        if (evt->record_type < 0xc0)
        {
          <snip>
        }
        else if (evt->record_type < 0xe0)
        {
          <snip>
        }
        else
        {
          <snip>
        }

The evt->record_type is set to 0, then there is an else if statement
check for the record_type value.  So there's dead code here.  Probably
not what was intended.

B)

if(evt->record_type < 0xdf)

There are several of these in the file. They should be "<=" according to
the IPMI spec.

C)

        if (evt->record_type == 0xf0)
        {
                printf (" Record Type           : "
                        "Linux kernel panic (OEM record %02x)\n",
                        evt->record_type);
                printf (" Panic string          : %.11s\n\n",
                        (char *) evt + 5);
                return;
        }

There are several of these outputs.  They appear to be a completely
arbitrary OEM special case outputs stuck in there.  As far as I can
tell, there is no check for a manufacturer ID or anything to belong to
this OEM specific record.  It probably should be removed unless someone
can figure out what vendor/manufacturer/product it belongs with.  Or if
it belongs to some standard I'm unaware of, then at least a comment
should be added.

Al

-- 
Albert Chu
ch...@llnl.gov
Computer Scientist
High Performance Systems Division
Lawrence Livermore National Laboratory


------------------------------------------------------------------------
------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Ipmitool-devel mailing list
Ipmitool-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ipmitool-devel



------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Ipmitool-devel mailing list
Ipmitool-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ipmitool-devel

Reply via email to