mirror of
https://github.com/ipmitool/ipmitool.git
synced 2025-05-10 18:47:22 +00:00
Added ekanalyzer command line support (PICMG ekeying analyzer module)
-Display point to point physical connectivity between carriers and AMC modules -Display power supply informations between carrier and AMC modules. -Display only matched results of Ekeying match between an On-Carrier device and an AMC module or between 2 AMC modules. Based on binary fru files supplied as parameter See the updated manpage for details
This commit is contained in:
parent
e6f0e459dd
commit
0b9f0d6a35
@ -204,6 +204,7 @@ Commands:
|
||||
sunoem Manage Sun OEM Extensions
|
||||
exec Run list of commands from file
|
||||
set Set runtime variable for shell and exec
|
||||
ekanalyzer run FRU-Ekeying analyzer using FRU files
|
||||
|
||||
ipmitool chassis help
|
||||
.br
|
||||
@ -1465,6 +1466,196 @@ Enables access to the BMC by the given userid.
|
||||
|
||||
Determine whether a password has been stored as 16 or 20 bytes.
|
||||
.RE
|
||||
.TP
|
||||
\fIekanalyzer\fP <\fBcommand\fR> <\fBxx=filename1\fR> <\fBxx=filename2\fR> [<\fBrc=filename3\fR>] \fB...\fR
|
||||
.RS
|
||||
.TP
|
||||
.br
|
||||
\fINOTE\fP : This command can get a maximum of 8 files per command line
|
||||
.TP
|
||||
.br
|
||||
\fIfilename1\fP : binary file that stores FRU data of a Carrier or an AMC module
|
||||
.TP
|
||||
.br
|
||||
\fIfilename2\fP : binary file that stores FRU data of an AMC module.
|
||||
These binary files can be generated from command:
|
||||
\fIipmitool fru read <id> <filename>\fP
|
||||
.TP
|
||||
.br
|
||||
\fIfilename3\fP : configuration file used for configuring On-Carrier Device ID
|
||||
or OEM GUID. This file is optional.
|
||||
.TP
|
||||
.br
|
||||
\fIxx\fP : indicates the type of the file. It can take the following value:
|
||||
.RS
|
||||
.TP
|
||||
.br
|
||||
\fIoc\fP : On-Carrier device
|
||||
.TP
|
||||
.br
|
||||
\fIa1\fP : AMC slot A1
|
||||
.TP
|
||||
.br
|
||||
\fIa2\fP : AMC slot A2
|
||||
.TP
|
||||
.br
|
||||
\fIa3\fP : AMC slot A3
|
||||
.TP
|
||||
.br
|
||||
\fIa4\fP : AMC slot A4
|
||||
.TP
|
||||
.br
|
||||
\fIb1\fP : AMC slot B1
|
||||
.TP
|
||||
.br
|
||||
\fIb2\fP : AMC slot B2
|
||||
.TP
|
||||
.br
|
||||
\fIb3\fP : AMC slot B3
|
||||
.TP
|
||||
.br
|
||||
\fIb4\fP : AMC slot B4
|
||||
.TP
|
||||
.br
|
||||
\fIsm\fP : Shelf Manager
|
||||
|
||||
.RE
|
||||
.TP
|
||||
.br
|
||||
The available commands for ekanalyzer are:
|
||||
|
||||
.RE
|
||||
.RS
|
||||
.TP
|
||||
\fIprint\fP [<\fBcarrier\fR | \fBpower\fR | \fBall\fR>]
|
||||
.RS
|
||||
.TP
|
||||
\fIcarrier\fP (default) <\fBoc=filename1\fR> <\fBoc=filename2\fR> \fB...\fR
|
||||
.br
|
||||
|
||||
Display point to point physical connectivity between carriers and AMC modules.
|
||||
Example:
|
||||
> ipmitool ekanalyzer print carrier oc=fru oc=carrierfru
|
||||
From Carrier file: fru
|
||||
Number of AMC bays supported by Carrier: 2
|
||||
AMC slot B1 topology:
|
||||
Port 0 =====> On Carrier Device ID 0, Port 16
|
||||
Port 1 =====> On Carrier Device ID 0, Port 12
|
||||
Port 2 =====> AMC slot B2, Port 2
|
||||
AMC slot B2 topology:
|
||||
Port 0 =====> On Carrier Device ID 0, Port 3
|
||||
Port 2 =====> AMC slot B1, Port 2
|
||||
*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
|
||||
From Carrier file: carrierfru
|
||||
On Carrier Device ID 0 topology:
|
||||
Port 0 =====> AMC slot B1, Port 4
|
||||
Port 1 =====> AMC slot B1, Port 5
|
||||
Port 2 =====> AMC slot B2, Port 6
|
||||
Port 3 =====> AMC slot B2, Port 7
|
||||
AMC slot B1 topology:
|
||||
Port 0 =====> AMC slot B2, Port 0
|
||||
AMC slot B1 topology:
|
||||
Port 1 =====> AMC slot B2, Port 1
|
||||
Number of AMC bays supported by Carrier: 2
|
||||
|
||||
.TP
|
||||
\fIpower\fP <\fBxx=filename1\fR> <\fBxx=filename2\fR> \fB...\fr
|
||||
.br
|
||||
|
||||
Display power supply informations between carrier and AMC modules.
|
||||
.TP
|
||||
\fIall\fP <\fBxx=filename\fR> <\fBxx=filename\fR> \fB...\fr
|
||||
.br
|
||||
|
||||
Display both physical connectivity and power supply of each carrier and AMC
|
||||
modules.
|
||||
|
||||
.RE
|
||||
.TP
|
||||
\fIfrushow\fP <\fBxx=filename\fR>
|
||||
.br
|
||||
Convert a binary FRU file into human readable text format. Use -v option to get
|
||||
more display information.
|
||||
|
||||
.RE
|
||||
.RS
|
||||
.TP
|
||||
\fIsummary\fP [<\fBmatch\fR | \fBunmatch\fR | \fBall\fR>]
|
||||
.RS
|
||||
.TP
|
||||
\fImatch\fP (default) <\fBxx=filename\fR> <\fBxx=filename\fR> \fB...\fR
|
||||
.br
|
||||
Display only matched results of Ekeying match between an On-Carrier device
|
||||
and an AMC module or between 2 AMC modules. Example:
|
||||
> ipmitool ekanalyzer summary match oc=fru b1=amcB1 a2=amcA2
|
||||
On-Carrier Device vs AMC slot B1
|
||||
AMC slot B1 port 0 ==> On-Carrier Device 0 port 16
|
||||
Matching Result
|
||||
- From On-Carrier Device ID 0
|
||||
-Channel ID 11 || Lane 0: enable
|
||||
-Link Type: AMC.2 Ethernet
|
||||
-Link Type extension: 1000BASE-BX (SerDES Gigabit) Ethernet link
|
||||
-Link Group ID: 0 || Link Asym. Match: exact match
|
||||
- To AMC slot B1
|
||||
-Channel ID 0 || Lane 0: enable
|
||||
-Link Type: AMC.2 Ethernet
|
||||
-Link Type extension: 1000BASE-BX (SerDES Gigabit) Ethernet link
|
||||
-Link Group ID: 0 || Link Asym. Match: exact match
|
||||
*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
|
||||
AMC slot B1 port 1 ==> On-Carrier Device 0 port 12
|
||||
Matching Result
|
||||
- From On-Carrier Device ID 0
|
||||
-Channel ID 6 || Lane 0: enable
|
||||
-Link Type: AMC.2 Ethernet
|
||||
-Link Type extension: 1000BASE-BX (SerDES Gigabit) Ethernet link
|
||||
-Link Group ID: 0 || Link Asym. Match: exact match
|
||||
- To AMC slot B1
|
||||
-Channel ID 1 || Lane 0: enable
|
||||
-Link Type: AMC.2 Ethernet
|
||||
-Link Type extension: 1000BASE-BX (SerDES Gigabit) Ethernet link
|
||||
-Link Group ID: 0 || Link Asym. Match: exact match
|
||||
*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
|
||||
On-Carrier Device vs AMC slot A2
|
||||
AMC slot A2 port 0 ==> On-Carrier Device 0 port 3
|
||||
Matching Result
|
||||
- From On-Carrier Device ID 0
|
||||
-Channel ID 9 || Lane 0: enable
|
||||
-Link Type: AMC.2 Ethernet
|
||||
-Link Type extension: 1000BASE-BX (SerDES Gigabit) Ethernet link
|
||||
-Link Group ID: 0 || Link Asym. Match: exact match
|
||||
- To AMC slot A2
|
||||
-Channel ID 0 || Lane 0: enable
|
||||
-Link Type: AMC.2 Ethernet
|
||||
-Link Type extension: 1000BASE-BX (SerDES Gigabit) Ethernet link
|
||||
-Link Group ID: 0 || Link Asym. Match: exact match
|
||||
*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
|
||||
AMC slot B1 vs AMC slot A2
|
||||
AMC slot A2 port 2 ==> AMC slot B1 port 2
|
||||
Matching Result
|
||||
- From AMC slot B1
|
||||
-Channel ID 2 || Lane 0: enable
|
||||
-Link Type: AMC.3 Storage
|
||||
-Link Type extension: Serial Attached SCSI (SAS/SATA)
|
||||
-Link Group ID: 0 || Link Asym. Match: FC or SAS interface {exact match}
|
||||
- To AMC slot A2
|
||||
-Channel ID 2 || Lane 0: enable
|
||||
-Link Type: AMC.3 Storage
|
||||
-Link Type extension: Serial Attached SCSI (SAS/SATA)
|
||||
-Link Group ID: 0 || Link Asym. Match: FC or SAS interface {exact match}
|
||||
*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
|
||||
.TP
|
||||
\fIunmatch\fP <\fBxx=filename\fR> <\fBxx=filename\fR> \fB...\fr
|
||||
.br
|
||||
|
||||
Display the unmatched results of Ekeying match between an On-Carrier device
|
||||
and an AMC module or between 2 AMC modules
|
||||
.TP
|
||||
\fIall\fP <\fBxx=filename\fR> <\fBxx=filename\fR> \fB...\fr
|
||||
.br
|
||||
|
||||
Display both matched result and unmatched results of Ekeying match between two
|
||||
cards or two modules.
|
||||
.RE
|
||||
|
||||
.SH "OPEN INTERFACE"
|
||||
The ipmitool \fIopen\fP interface utilizes the OpenIPMI
|
||||
|
@ -37,5 +37,5 @@ noinst_HEADERS = log.h bswap.h helper.h ipmi.h ipmi_cc.h ipmi_intf.h \
|
||||
ipmi_strings.h ipmi_constants.h ipmi_user.h ipmi_pef.h \
|
||||
ipmi_oem.h ipmi_isol.h ipmi_sunoem.h ipmi_picmg.h \
|
||||
ipmi_fwum.h ipmi_main.h ipmi_tsol.h ipmi_firewall.h \
|
||||
ipmi_kontronoem.h
|
||||
ipmi_kontronoem.h ipmi_ekanalyzer.h
|
||||
|
||||
|
@ -46,6 +46,9 @@
|
||||
#define FALSE 0
|
||||
#endif
|
||||
|
||||
#ifndef tboolean
|
||||
#define tboolean int
|
||||
#endif
|
||||
|
||||
struct ipmi_intf;
|
||||
|
||||
|
68
ipmitool/include/ipmitool/ipmi_ekanalyzer.h
Normal file
68
ipmitool/include/ipmitool/ipmi_ekanalyzer.h
Normal file
@ -0,0 +1,68 @@
|
||||
/*
|
||||
* Copyright (c) 2007 Kontron Canada, Inc. All Rights Reserved.
|
||||
*
|
||||
* Base on code from
|
||||
* Copyright (c) 2003 Sun Microsystems, Inc. All Rights Reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions
|
||||
* are met:
|
||||
*
|
||||
* Redistribution of source code must retain the above copyright
|
||||
* notice, this list of conditions and the following disclaimer.
|
||||
*
|
||||
* Redistribution in binary form must reproduce the above copyright
|
||||
* notice, this list of conditions and the following disclaimer in the
|
||||
* documentation and/or other materials provided with the distribution.
|
||||
*
|
||||
* Neither the name of Sun Microsystems, Inc. or the names of
|
||||
* contributors may be used to endorse or promote products derived
|
||||
* from this software without specific prior written permission.
|
||||
*
|
||||
* This software is provided "AS IS," without a warranty of any kind.
|
||||
* ALL EXPRESS OR IMPLIED CONDITIONS, REPRESENTATIONS AND WARRANTIES,
|
||||
* INCLUDING ANY IMPLIED WARRANTY OF MERCHANTABILITY, FITNESS FOR A
|
||||
* PARTICULAR PURPOSE OR NON-INFRINGEMENT, ARE HEREBY EXCLUDED.
|
||||
* SUN MICROSYSTEMS, INC. ("SUN") AND ITS LICENSORS SHALL NOT BE LIABLE
|
||||
* FOR ANY DAMAGES SUFFERED BY LICENSEE AS A RESULT OF USING, MODIFYING
|
||||
* OR DISTRIBUTING THIS SOFTWARE OR ITS DERIVATIVES. IN NO EVENT WILL
|
||||
* SUN OR ITS LICENSORS BE LIABLE FOR ANY LOST REVENUE, PROFIT OR DATA,
|
||||
* OR FOR DIRECT, INDIRECT, SPECIAL, CONSEQUENTIAL, INCIDENTAL OR
|
||||
* PUNITIVE DAMAGES, HOWEVER CAUSED AND REGARDLESS OF THE THEORY OF
|
||||
* LIABILITY, ARISING OUT OF THE USE OF OR INABILITY TO USE THIS SOFTWARE,
|
||||
* EVEN IF SUN HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
|
||||
*/
|
||||
|
||||
#ifndef IPMI_EKANALYZER_H
|
||||
#define IPMI_EKANALYZER_H
|
||||
|
||||
#include <inttypes.h>
|
||||
#include <ipmitool/ipmi.h>
|
||||
#include <ipmitool/ipmi_fru.h>
|
||||
|
||||
#define RTM_FRU_FILE 0x00
|
||||
#define A1_AMC_FRU_FILE 0x01
|
||||
#define A2_AMC_FRU_FILE 0x02
|
||||
#define A3_AMC_FRU_FILE 0x03
|
||||
#define A4_AMC_FRU_FILE 0x04
|
||||
#define B1_AMC_FRU_FILE 0x05
|
||||
#define B2_AMC_FRU_FILE 0x06
|
||||
#define B3_AMC_FRU_FILE 0x07
|
||||
#define B4_AMC_FRU_FILE 0x08
|
||||
#define ON_CARRIER_FRU_FILE 0x09
|
||||
#define CONFIG_FILE 0x0A
|
||||
#define SHELF_MANAGER_FRU_FILE 0x0B
|
||||
|
||||
#define MIN_ARGUMENT 0x02
|
||||
#define RTM_IPMB_L 0x90
|
||||
|
||||
#define MAX_FILE_NUMBER 8
|
||||
/* this voltag is specified in AMC.0 specification Table 3-10 */
|
||||
#define AMC_VOLTAGE 12 /*volts*/
|
||||
|
||||
#define SIZE_OF_GUID 16
|
||||
#define FRU_RADIAL_IPMB0_LINK_MAPPING 0x15
|
||||
|
||||
int ipmi_ekanalyzer_main(struct ipmi_intf *, int, char **);
|
||||
|
||||
#endif /* IPMI_EKANALYZER_H */
|
@ -395,9 +395,9 @@ struct fru_picmgext_amc_channel_desc_record {
|
||||
unsigned char lane1port :5;
|
||||
unsigned char lane2port :5;
|
||||
unsigned char lane3port :5;
|
||||
unsigned char /* reserved */ :4;
|
||||
unsigned char /*reserved */ :4;
|
||||
#else
|
||||
unsigned char /* reserved */ :4;
|
||||
unsigned char /*reserved */ :4;
|
||||
unsigned char lane3port :5;
|
||||
unsigned char lane2port :5;
|
||||
unsigned char lane1port :5;
|
||||
@ -448,7 +448,8 @@ struct fru_picmgext_amc_link_desc_record {
|
||||
unsigned short channel_id :8;
|
||||
#endif
|
||||
} __attribute__ ((packed));
|
||||
|
||||
/* FRU Board manufacturing date */
|
||||
static const uint64_t secs_from_1970_1996 = 820450800;
|
||||
static const char * chassis_type_desc[] __attribute__((unused)) = {
|
||||
"Unspecified", "Other", "Unknown",
|
||||
"Desktop", "Low Profile Desktop", "Pizza Box",
|
||||
|
@ -38,7 +38,7 @@ libipmitool_la_SOURCES = helper.c ipmi_sdr.c ipmi_sel.c ipmi_sol.c ipmi_pef.c \
|
||||
ipmi_session.c ipmi_strings.c ipmi_user.c ipmi_raw.c \
|
||||
ipmi_oem.c ipmi_isol.c ipmi_sunoem.c ipmi_fwum.c ipmi_picmg.c \
|
||||
ipmi_main.c ipmi_tsol.c ipmi_firewall.c ipmi_kontronoem.c \
|
||||
ipmi_hpmfwupg.c ipmi_sdradd.c
|
||||
ipmi_hpmfwupg.c ipmi_sdradd.c ipmi_ekanalyzer.c
|
||||
|
||||
libipmitool_la_LDFLAGS = -export-dynamic
|
||||
libipmitool_la_LIBADD = -lm
|
||||
|
4025
ipmitool/lib/ipmi_ekanalyzer.c
Normal file
4025
ipmitool/lib/ipmi_ekanalyzer.c
Normal file
File diff suppressed because it is too large
Load Diff
@ -65,6 +65,7 @@
|
||||
#include <ipmitool/ipmi_raw.h>
|
||||
#include <ipmitool/ipmi_pef.h>
|
||||
#include <ipmitool/ipmi_oem.h>
|
||||
#include <ipmitool/ipmi_ekanalyzer.h>
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
# include <config.h>
|
||||
|
@ -60,6 +60,7 @@
|
||||
#include <ipmitool/ipmi_kontronoem.h>
|
||||
#include <ipmitool/ipmi_firewall.h>
|
||||
#include <ipmitool/ipmi_hpmfwupg.h>
|
||||
#include <ipmitool/ipmi_ekanalyzer.h>
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
# include <config.h>
|
||||
@ -108,7 +109,8 @@ struct ipmi_cmd ipmitool_cmd_list[] = {
|
||||
{ ipmi_exec_main, "exec", "Run list of commands from file" },
|
||||
{ ipmi_set_main, "set", "Set runtime variable for shell and exec" },
|
||||
{ ipmi_echo_main, "echo", NULL }, /* for echoing lines to stdout in scripts */
|
||||
{ ipmi_hpmfwupg_main,"hpm", "Update HPM components using PICMG HPM.1 file"},
|
||||
{ ipmi_hpmfwupg_main,"hpm", "Update HPM components using PICMG HPM.1 file"},
|
||||
{ ipmi_ekanalyzer_main,"ekanalyzer", "run FRU-Ekeying analyzer using FRU files"},
|
||||
{ NULL },
|
||||
};
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user