diff options
Diffstat (limited to 'util/ifru.c')
-rw-r--r-- | util/ifru.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/util/ifru.c b/util/ifru.c index 61a19f3..b10c42e 100644 --- a/util/ifru.c +++ b/util/ifru.c @@ -116,7 +116,7 @@ extern int ipmi_kontronoem_main(void * intf, int argc, char ** argv); #endif static char *progname = "ifru"; -static char *progver = "2.97"; +static char *progver = "2.98"; static int vend_id = 0; static int prod_id = 0; static char fdebug = 0; @@ -736,33 +736,33 @@ void show_fru_multi(char *tag, int midx, uchar mtype, uchar *pdata, int dlen) printf("\t Standby power \t%c %s\n", bdelim, (b2 ? "Yes" : "No")); v1 = pdata[1] + (pdata[2] << 8); - printf("\t Nominal voltage \t%c %.2f V\n", bdelim, v1 / 100); + printf("\t Nominal voltage \t%c %.2f V\n", bdelim, (double)v1 / 100); v2 = pdata[3] + (pdata[4] << 8); v3 = pdata[5] + (pdata[6] << 8); printf("\t Voltage deviation \t%c + %.2f V / - %.2f V\n", - bdelim, v3/100, v2/100); + bdelim, (double)v3/100, (double)v2/100); v4 = pdata[7] + (pdata[8] << 8); printf("\t Ripple and noise pk-pk \t%c %d mV\n", bdelim, v4); v5 = pdata[9] + (pdata[10] << 8); - printf("\t Min current draw \t%c %.3f A\n", bdelim, v5/1000); + printf("\t Min current draw \t%c %.3f A\n", bdelim, (double)v5/1000); v6 = pdata[11] + (pdata[12] << 8); - printf("\t Max current draw \t%c %.3f A\n", bdelim, v6/1000); + printf("\t Max current draw \t%c %.3f A\n", bdelim, (double)v6/1000); break; case 0x02: /*DC Load*/ b1 = pdata[0] & 0x0f; printf("%sDC Load %c number %d\n",mystr,bdelim,b1); v1 = pdata[1] + (pdata[2] << 8); - printf("\t Nominal voltage \t%c %.2f V\n", bdelim, v1 / 100); + printf("\t Nominal voltage \t%c %.2f V\n", bdelim, (double)v1 / 100); v2 = pdata[3] + (pdata[4] << 8); v3 = pdata[5] + (pdata[6] << 8); - printf("\t Min voltage allowed \t%c %.2f A\n", bdelim, v2); - printf("\t Max voltage allowed \t%c %.2f A\n", bdelim, v3); + printf("\t Min voltage allowed \t%c %.2f A\n", bdelim, (double)v2); + printf("\t Max voltage allowed \t%c %.2f A\n", bdelim, (double)v3); v4 = pdata[7] + (pdata[8] << 8); printf("\t Ripple and noise pk-pk \t%c %d mV\n", bdelim, v4); v5 = pdata[9] + (pdata[10] << 8); - printf("\t Min current load \t%c %.3f A\n", bdelim, v5/1000); + printf("\t Min current load \t%c %.3f A\n", bdelim, (double)v5/1000); v6 = pdata[11] + (pdata[12] << 8); - printf("\t Max current load \t%c %.3f A\n", bdelim, v6/1000); + printf("\t Max current load \t%c %.3f A\n", bdelim, (double)v6/1000); break; case 0x03: /*Management Access*/ b1 = pdata[0]; |