From b0f92cfb130cfe7b452cf4ccf9a83efd7c5960b5 Mon Sep 17 00:00:00 2001
From: Duncan Idaho <dune.idaho@gmail.com>
Date: Sat, 28 Apr 2012 12:52:52 +0000
Subject: [PATCH 18/18] lib/ipmi_picmg.c - amend help print-out Signed-off-by:
 Duncan Idaho <dune.idaho@gmail.com>

Commit amends PICMG's help print out and changes it to ipmitool's way. It
doesn't matter whether printf() outputs at same output as LOG_NOTICE does. Such
things should be the same for all modules.
---
 lib/ipmi_picmg.c |   60 ++++++++++++++++++++++++++++++-----------------------
 1 files changed, 34 insertions(+), 26 deletions(-)

diff --git a/lib/ipmi_picmg.c b/lib/ipmi_picmg.c
index bd462cf..03a8b08 100644
--- a/lib/ipmi_picmg.c
+++ b/lib/ipmi_picmg.c
@@ -73,32 +73,40 @@ static t_picmg_card_type PicmgCardType = PICMG_CARD_TYPE_RESERVED;
 void
 ipmi_picmg_help (void)
 {
-	printf(" properties           - get PICMG properties\n");
-	printf(" frucontrol           - FRU control\n");
-	printf(" addrinfo             - get address information\n");
-	printf(" activate             - activate a FRU\n");
-	printf(" deactivate           - deactivate a FRU\n");
-	printf(" policy get           - get the FRU activation policy\n");
-	printf(" policy set           - set the FRU activation policy\n");
-	printf(" portstate get        - get port state \n");
-	printf(" portstate getdenied  - get all denied[disabled] port description\n");
-	printf(" portstate getgranted - get all granted[enabled] port description\n");
-	printf(" portstate getall     - get all port state description\n");
-	printf(" portstate set        - set port state \n");
-	printf(" amcportstate get     - get port state \n");
-	printf(" amcportstate set     - set port state \n");
-	printf(" led prop             - get led properties\n");
-	printf(" led cap              - get led color capabilities\n");
-	printf(" led get              - get led state\n");
-	printf(" led set              - set led state\n");
-	printf(" power get            - get power level info\n");
-	printf(" power set            - set power level\n");
-	printf(" clk get              - get clk state\n");
-	printf(" clk getdenied        - get all(up to 16) denied[disabled] clock descriptions\n");
-	printf(" clk getgranted       - get all(up to 16) granted[enabled] clock descriptions\n");
-	printf(" clk getall           - get all(up to 16) clock descriptions\n");
-	printf(" clk set              - set clk state\n");
-	printf(" busres summary       - display brief bused resource status info \n");
+	lprintf(LOG_NOTICE, "PICMG commands:");
+	lprintf(LOG_NOTICE, " properties           - get PICMG properties");
+	lprintf(LOG_NOTICE, " frucontrol           - FRU control");
+	lprintf(LOG_NOTICE, " addrinfo             - get address information");
+	lprintf(LOG_NOTICE, " activate             - activate a FRU");
+	lprintf(LOG_NOTICE, " deactivate           - deactivate a FRU");
+	lprintf(LOG_NOTICE, " policy get           - get the FRU activation policy");
+	lprintf(LOG_NOTICE, " policy set           - set the FRU activation policy");
+	lprintf(LOG_NOTICE, " portstate get        - get port state");
+	lprintf(LOG_NOTICE,
+			" portstate getdenied  - get all denied[disabled] port description");
+	lprintf(LOG_NOTICE,
+			" portstate getgranted - get all granted[enabled] port description");
+	lprintf(LOG_NOTICE,
+			" portstate getall     - get all port state description");
+	lprintf(LOG_NOTICE, " portstate set        - set port state");
+	lprintf(LOG_NOTICE, " amcportstate get     - get port state");
+	lprintf(LOG_NOTICE, " amcportstate set     - set port state");
+	lprintf(LOG_NOTICE, " led prop             - get led properties");
+	lprintf(LOG_NOTICE, " led cap              - get led color capabilities");
+	lprintf(LOG_NOTICE, " led get              - get led state");
+	lprintf(LOG_NOTICE, " led set              - set led state");
+	lprintf(LOG_NOTICE, " power get            - get power level info");
+	lprintf(LOG_NOTICE, " power set            - set power level");
+	lprintf(LOG_NOTICE, " clk get              - get clk state");
+	lprintf(LOG_NOTICE,
+			" clk getdenied        - get all(up to 16) denied[disabled] clock descriptions");
+	lprintf(LOG_NOTICE,
+			" clk getgranted       - get all(up to 16) granted[enabled] clock descriptions");
+	lprintf(LOG_NOTICE,
+			" clk getall           - get all(up to 16) clock descriptions");
+	lprintf(LOG_NOTICE, " clk set              - set clk state");
+	lprintf(LOG_NOTICE,
+			" busres summary       - display brief bused resource status info");
 }
 
 
-- 
1.7.5.1

