Mailinglist Archive: opensuse-commit (1059 mails)

< Previous Next >
commit ipmitool
  • From: root@xxxxxxxxxxxxxxx (h_root)
  • Date: Thu, 17 Jan 2008 23:11:59 +0100
  • Message-id: <20080117221200.3E8C2678335@xxxxxxxxxxxxxxx>

Hello community,

here is the log from the commit of package ipmitool
checked in at Thu Jan 17 23:11:59 CET 2008.

--------
--- ipmitool/ipmitool.changes 2007-03-08 13:01:20.000000000 +0100
+++ /mounts/work_src_done/STABLE/ipmitool/ipmitool.changes 2008-01-17
15:29:12.000000000 +0100
@@ -1,0 +2,5 @@
+Thu Jan 17 15:28:30 CET 2008 - duwe@xxxxxxx
+
+- Fix bugs 298222 and 144023 (arg checking and POH scaling)
+
+-------------------------------------------------------------------

New:
----
ipmitool-lan-set.patch
ipmitool-POH-scale

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ ipmitool.spec ++++++
--- /var/tmp/diff_new_pack.V24634/_old 2008-01-17 23:06:23.000000000 +0100
+++ /var/tmp/diff_new_pack.V24634/_new 2008-01-17 23:06:23.000000000 +0100
@@ -1,7 +1,7 @@
#
# spec file for package ipmitool (Version 1.8.9)
#
-# Copyright (c) 2007 SUSE LINUX Products GmbH, Nuernberg, Germany.
+# Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany.
# This file and all modifications and additions to the pristine
# package are under the same license as the package itself.
#
@@ -12,14 +12,16 @@

Name: ipmitool
BuildRequires: openssl-devel readline-devel
-URL: http://ipmitool.sourceforge.net/
+Url: http://ipmitool.sourceforge.net/
Summary: Utility for IPMI Control
Version: 1.8.9
-Release: 2
-License: BSD License and BSD-like
+Release: 54
+License: BSD 3-Clause
Group: System/Management
Source:
http://heanet.dl.sourceforge.net/sourceforge/%{name}/%{name}-%{version}.tar.bz2
Patch: compile-fixes
+Patch1: ipmitool-lan-set.patch
+Patch2: ipmitool-POH-scale
BuildRoot: %{_tmppath}/%{name}-%{version}-build

%description
@@ -43,6 +45,8 @@
%prep
%setup
%patch -p1
+%patch1 -p1
+%patch2 -p1

%build
CFLAGS="$RPM_OPT_FLAGS" ./configure \
@@ -74,15 +78,17 @@
%doc %{_mandir}/man8/*

%changelog
-* Thu Mar 08 2007 - duwe@xxxxxxx
+* Thu Jan 17 2008 duwe@xxxxxxx
+- Fix bugs 298222 and 144023 (arg checking and POH scaling)
+* Thu Mar 08 2007 duwe@xxxxxxx
- add new compile fixes
-* Wed Mar 07 2007 - duwe@xxxxxxx
+* Wed Mar 07 2007 duwe@xxxxxxx
- update to 1.8.9, fixing ipmievd crashing.
This was requesten in Bug#246456
-* Fri Oct 13 2006 - duwe@xxxxxxx
+* Fri Oct 13 2006 duwe@xxxxxxx
- update to today's CVS state
* might fix SoL issues (Fate #30911)
-* Tue Oct 10 2006 - duwe@xxxxxxx
+* Tue Oct 10 2006 duwe@xxxxxxx
- update to 1.8.8 mainly various fixes:
version 1.8.8
* Fix segfaults in sensor data repository list
@@ -110,13 +116,13 @@
* Fix gcc4 compile warnings
* Make ipmievd generate pidfile
* Add initscripts for ipmievd
-* Mon May 29 2006 - kukuk@xxxxxxx
+* Mon May 29 2006 kukuk@xxxxxxx
- Fix type conversion bug in ipmi_pef.c [#173658]
-* Fri May 26 2006 - schwab@xxxxxxx
+* Fri May 26 2006 schwab@xxxxxxx
- Add readline-devel to BuildRequires to enable shell command.
- Fix use of channel_info bitfield.
- Fix byte swapping.
-* Mon Feb 13 2006 - kukuk@xxxxxxx
+* Mon Feb 13 2006 kukuk@xxxxxxx
- Update to ipmitool 1.8.6 [#134708,#131823]
- Fix memory corruption when sending encrypted SOL traffic
- Add keepalive timer to IPMIv2 SOL sessions
@@ -129,11 +135,11 @@
- Add support for command bridging over lan and lanplus interfaces
- New 'chassis selftest' command
- Many bufxies and patches from contributors
-* Wed Jan 25 2006 - mls@xxxxxxx
+* Wed Jan 25 2006 mls@xxxxxxx
- converted neededforbuild to BuildRequires
-* Fri Jan 20 2006 - schwab@xxxxxxx
+* Fri Jan 20 2006 schwab@xxxxxxx
- Don't strip binaries.
-* Mon Sep 19 2005 - kukuk@xxxxxxx
+* Mon Sep 19 2005 kukuk@xxxxxxx
- Fix missing return value
-* Thu Aug 04 2005 - kukuk@xxxxxxx
+* Thu Aug 04 2005 kukuk@xxxxxxx
- Initial release (FeatureID #165)

++++++ ipmitool-lan-set.patch ++++++
--- ipmitool-1.8.9/lib/ipmi_lanp.c 2007-07-18 14:47:43.822052004 -0500
+++ ipmitool-1.8.9/lib/ipmi_lanp.c 2007-07-19 09:56:31.567441299 -0500
@@ -1489,28 +1489,49 @@
}
}
/* ip address */
- else if ((strncmp(argv[1], "ipaddr", 6) == 0) &&
- (get_cmdline_ipaddr(argv[2], data) == 0)) {
- printf("Setting LAN %s to %d.%d.%d.%d\n",
- ipmi_lan_params[IPMI_LANP_IP_ADDR].desc,
- data[0], data[1], data[2], data[3]);
- rc = set_lan_param(intf, chan, IPMI_LANP_IP_ADDR, data, 4);
+ else if (strncmp(argv[1], "ipaddr", 6) == 0) {
+ if(argc != 3)
+ {
+ ipmi_lan_set_usage();
+ return -1;
+ }
+ rc = get_cmdline_ipaddr(argv[2], data);
+ if (rc == 0) {
+ printf("Setting LAN %s to %d.%d.%d.%d\n",
+ ipmi_lan_params[IPMI_LANP_IP_ADDR].desc,
+ data[0], data[1], data[2], data[3]);
+ rc = set_lan_param(intf, chan, IPMI_LANP_IP_ADDR, data,
4);
+ }
}
/* network mask */
- else if ((strncmp(argv[1], "netmask", 7) == 0) &&
- (get_cmdline_ipaddr(argv[2], data) == 0)) {
- printf("Setting LAN %s to %d.%d.%d.%d\n",
- ipmi_lan_params[IPMI_LANP_SUBNET_MASK].desc,
- data[0], data[1], data[2], data[3]);
- rc = set_lan_param(intf, chan, IPMI_LANP_SUBNET_MASK, data, 4);
+ else if (strncmp(argv[1], "netmask", 7) == 0) {
+ if(argc != 3)
+ {
+ ipmi_lan_set_usage();
+ return -1;
+ }
+ rc = get_cmdline_ipaddr(argv[2], data);
+ if (rc == 0) {
+ printf("Setting LAN %s to %d.%d.%d.%d\n",
+ ipmi_lan_params[IPMI_LANP_SUBNET_MASK].desc,
+ data[0], data[1], data[2], data[3]);
+ rc = set_lan_param(intf, chan, IPMI_LANP_SUBNET_MASK,
data, 4);
+ }
}
/* mac address */
- else if ((strncmp(argv[1], "macaddr", 7) == 0) &&
- (get_cmdline_macaddr(argv[2], data) == 0)) {
- printf("Setting LAN %s to %02x:%02x:%02x:%02x:%02x:%02x\n",
- ipmi_lan_params[IPMI_LANP_MAC_ADDR].desc,
- data[0], data[1], data[2], data[3], data[4], data[5]);
- rc = set_lan_param(intf, chan, IPMI_LANP_MAC_ADDR, data, 6);
+ else if (strncmp(argv[1], "macaddr", 7) == 0) {
+ if(argc != 3)
+ {
+ ipmi_lan_set_usage();
+ return -1;
+ }
+ rc = get_cmdline_macaddr(argv[2], data);
+ if (rc == 0) {
+ printf("Setting LAN %s to
%02x:%02x:%02x:%02x:%02x:%02x\n",
+ ipmi_lan_params[IPMI_LANP_MAC_ADDR].desc,
+ data[0], data[1], data[2], data[3], data[4],
data[5]);
+ rc = set_lan_param(intf, chan, IPMI_LANP_MAC_ADDR,
data, 6);
+ }
}
/* default gateway settings */
else if (strncmp(argv[1], "defgw", 5) == 0) {
@@ -1531,6 +1552,10 @@
data[0], data[1], data[2], data[3], data[4],
data[5]);
rc = set_lan_param(intf, chan,
IPMI_LANP_DEF_GATEWAY_MAC, data, 6);
}
+ else {
+ ipmi_lan_set_usage();
+ return -1;
+ }
}
/* backup gateway settings */
else if (strncmp(argv[1], "bakgw", 5) == 0) {
@@ -1551,6 +1576,10 @@
data[0], data[1], data[2], data[3], data[4],
data[5]);
rc = set_lan_param(intf, chan,
IPMI_LANP_BAK_GATEWAY_MAC, data, 6);
}
+ else {
+ ipmi_lan_set_usage();
+ return -1;
+ }
}
else if (strncasecmp(argv[1], "vlan", 4) == 0) {
if (argc < 4 || strncmp(argv[2], "help", 4) == 0) {
++++++ ipmitool-POH-scale ++++++
--- ipmitool-1.8.9/lib/ipmi_chassis.c.orig 2007-02-22 09:38:56.000000000
+0100
+++ ipmitool-1.8.9/lib/ipmi_chassis.c 2008-01-17 15:07:23.000000000 +0100
@@ -189,6 +189,8 @@ ipmi_chassis_poh(struct ipmi_intf * intf
struct ipmi_rs * rsp;
struct ipmi_rq req;
uint32_t count;
+ unsigned long hcount;
+ unsigned char minutes, scale;

memset(&req, 0, sizeof(req));
req.msg.netfn = IPMI_NETFN_CHASSIS;
@@ -206,9 +208,16 @@ ipmi_chassis_poh(struct ipmi_intf * intf
}

memcpy(&count, rsp->data+1, 4);
+#if WORDS_BIGENDIAN
+ count = BSWAP_32(count);
+#endif
+ scale = rsp->data[0];
+ hcount = count * scale;
+ minutes = hcount % 60;
+ hcount /= 60;

- printf("POH Counter : %li hours total (%li days, %li hours)\n",
- (long)count, (long)(count / 24), (long)(count % 24));
+ printf("POH Counter : %li hours total (%li days, %lih%02d')\n",
+ (long)hcount, (long)(hcount / 24), (long)(hcount % 24), minutes);

return 0;
}

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++



Remember to have fun...

---------------------------------------------------------------------
To unsubscribe, e-mail: opensuse-commit+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse-commit+help@xxxxxxxxxxxx

< Previous Next >
This Thread
  • No further messages