1.0.25 bump

This commit is contained in:
Petr Šabata 2012-11-27 17:00:01 +01:00
parent 0d7f2241f6
commit 6e5d849e9c
10 changed files with 642 additions and 23 deletions

1
.gitignore vendored
View File

@ -37,3 +37,4 @@ fcoe-utils-*.rpm
/fcoe-utils-1.0.22.tar.bz2 /fcoe-utils-1.0.22.tar.bz2
/fcoe-utils-1.0.23.tar.bz2 /fcoe-utils-1.0.23.tar.bz2
/fcoe-utils-1.0.24.tar.bz2 /fcoe-utils-1.0.24.tar.bz2
/fcoe-utils-1.0.25.tar.bz2

View File

@ -0,0 +1,56 @@
From 1b380ac803a682113616f4cd1e85f371fad997f8 Mon Sep 17 00:00:00 2001
From: Robert Love <robert.w.love@intel.com>
Date: Wed, 10 Oct 2012 07:14:01 +0000
Subject: [PATCH 2/7] QUICKSTART: Add clone instructions for libhbalinux and
fcoe-utils
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
The QUICKSTART lists these repos at the top of the file, but doesn't
mention the repo names at all in the install instructions. This
patch explains where to clone from in the install instructions for
both libhbalinux.git and fcoe-utils.git.
Signed-off-by: Robert Love <robert.w.love@intel.com>
Tested-by: Ross Brattain <ross.b.brattain@intel.com>
Signed-off-by: Petr Šabata <contyk@redhat.com>
---
QUICKSTART | 14 ++++++++++++--
1 file changed, 12 insertions(+), 2 deletions(-)
diff --git a/QUICKSTART b/QUICKSTART
index a273d98..3634ee2 100644
--- a/QUICKSTART
+++ b/QUICKSTART
@@ -165,7 +165,12 @@ DEPENDENCIES
PROCESS
-1) Bootstrap, configure, make and make install
+1) Obtain the latest source
+
+ git clone git://open-fcoe.org/fcoe/libhbalinux.git
+
+2) Bootstrap, configure, make and make install
+ # cd libhbalinux
# ./bootstrap.sh
# rpm --eval "%configure" | sh
# make
@@ -190,7 +195,12 @@ DEPENDENCIES
PROCESS
-1) Bootstrap, configure, make and make install
+1) Obtain the latest source
+
+ git clone git://open-fcoe.org/fcoe/fcoe-utils.git
+
+2) Bootstrap, configure, make and make install
+ # cd fcoe-utils
# ./bootstrap.sh
# rpm --eval "%configure" | sh
# make
--
1.7.11.7

View File

@ -0,0 +1,59 @@
From 90d2c333010103ef65d6d12f186d0b483e152b1d Mon Sep 17 00:00:00 2001
From: Robert Love <robert.w.love@intel.com>
Date: Wed, 10 Oct 2012 07:14:06 +0000
Subject: [PATCH 3/7] QUICKSTART: Update references to libHBAAPI.git
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
The SourceForge HBAAPI project has merged into the
hbaapi_build.git repository, resulting in the
libHBAAPI.git repository. This patch converts the
documentation to point to the new repository and
removes a now unnecessary installation step.
Signed-off-by: Robert Love <robert.w.love@intel.com>
Tested-by: Ross Brattain <ross.b.brattain@intel.com>
Signed-off-by: Petr Šabata <contyk@redhat.com>
---
QUICKSTART | 15 +++++----------
1 file changed, 5 insertions(+), 10 deletions(-)
diff --git a/QUICKSTART b/QUICKSTART
index 3634ee2..3534c5e 100644
--- a/QUICKSTART
+++ b/QUICKSTART
@@ -11,7 +11,7 @@ distributions.
# Dependencies
###############
-git://open-fcoe.org/fcoe/hbaapi_build.git
+git://open-fcoe.org/fcoe/libHBAAPI.git
git://open-fcoe.org/fcoe/libhbalinux.git
git://open-fcoe.org/fcoe/fcoe-utils.git
@@ -131,17 +131,12 @@ DEPENDENCIES
PROCESS
-1) Obtain the source tarball from sourceforge
- http://sourceforge.net/projects/hbaapi/
+1) Obtain the latest source
-2) Untar the tarball and move its contents to hbaapi_build/
- and change into its directory
- # tar -xvzf hbaapi_src_2.2.tgz
- # mv hbaapi_src_2.2/* hbaapi_build/
- # rmdir hbaapi_src_2.2/
- # cd hbaapi_build/
+ git clone git://open-fcoe.org/fcoe/libHBAAPI.git
-3) Bootstrap, configure, make and make install
+2) Bootstrap, configure, make and make install
+ # cd libHBAAPI
# ./bootstrap.sh
# rpm --eval "%configure" | sh
# make
--
1.7.11.7

View File

@ -0,0 +1,125 @@
From 4d996fd760ccd1b25b1e96284d411916b3a97b42 Mon Sep 17 00:00:00 2001
From: Mark Rustad <mark.d.rustad@intel.com>
Date: Thu, 25 Oct 2012 04:49:36 +0000
Subject: [PATCH 5/7] build: Fix new warnings made by gcc 4.7
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
This fixes a number of warning messages now generated by
-Wall with newer versions of gcc. The warnings resolved
are all of the type:
warning: variable '<variable>' set but not used
Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Tested-by: Ross Brattain <ross.b.brattain@intel.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: Petr Šabata <contyk@redhat.com>
---
fcoeadm_display.c | 4 ++--
fcoemon.c | 5 +----
lib/rtnetlink.c | 4 ----
3 files changed, 3 insertions(+), 10 deletions(-)
diff --git a/fcoeadm_display.c b/fcoeadm_display.c
index 56401dc..85aa0a0 100644
--- a/fcoeadm_display.c
+++ b/fcoeadm_display.c
@@ -246,6 +246,8 @@ static void show_target_info(const char *symbolic_name,
ifname = get_ifname_from_symbolic_name(symbolic_name);
rc = sa_sys_read_line(rp_info->OSDeviceName, "roles", buf, sizeof(buf));
+ if (rc)
+ strncpy(buf, "Unknown", sizeof(buf));
printf(" Interface: %s\n", ifname);
printf(" Roles: %s\n", buf);
@@ -1223,7 +1225,6 @@ enum fcoe_status display_adapter_info(const char *ifname)
struct hba_name_table_list *hba_table_list = NULL;
enum fcoe_status rc = SUCCESS;
int i, j, num_hbas = 0;
- HBA_HANDLE hba_handle;
HBA_PORTATTRIBUTES *port_attrs;
HBA_PORTATTRIBUTES *sport_attrs;
HBA_ADAPTERATTRIBUTES *hba_attrs;
@@ -1251,7 +1252,6 @@ enum fcoe_status display_adapter_info(const char *ifname)
hba_table_list->hba_table[i].displayed)
continue;
- hba_handle = hba_table_list->hba_table[i].hba_handle;
port_attrs = &hba_table_list->hba_table[i].port_attrs;
hba_attrs = &hba_table_list->hba_table[i].hba_attrs;
diff --git a/fcoemon.c b/fcoemon.c
index daf9fab..13977eb 100644
--- a/fcoemon.c
+++ b/fcoemon.c
@@ -2326,7 +2326,6 @@ static void fcm_dcbd_cmd_resp(char *resp, cmd_status st)
u_int32_t ver;
u_int32_t cmd;
u_int32_t feature;
- u_int32_t subtype;
u_int32_t state;
char *ep;
char *cp;
@@ -2352,7 +2351,7 @@ static void fcm_dcbd_cmd_resp(char *resp, cmd_status st)
FCM_LOG("parse error on resp feature: resp %s", resp);
return;
}
- subtype = fcm_get_hex(resp + DCB_SUBTYPE_OFF, DCB_SUBTYPE_LEN, &ep);
+ fcm_get_hex(resp + DCB_SUBTYPE_OFF, DCB_SUBTYPE_LEN, &ep);
if (ep != NULL) {
FCM_LOG("parse error on resp subtype: resp %s", resp);
return;
@@ -2791,7 +2790,6 @@ static void fcm_handle_changes()
{
struct fcm_netif *ff;
struct fcoe_port *p;
- int i;
/*
* Perform pending actions (dcbd queries) on network interfaces.
@@ -2802,7 +2800,6 @@ static void fcm_handle_changes()
/*
* Perform actions on FCoE ports
*/
- i = 0;
p = fcoe_config.port;
while (p) {
ff = fcm_netif_lookup(p->real_ifname);
diff --git a/lib/rtnetlink.c b/lib/rtnetlink.c
index 38ef802..ddaeb16 100644
--- a/lib/rtnetlink.c
+++ b/lib/rtnetlink.c
@@ -371,12 +371,10 @@ static ssize_t rtnl_send_getlink(int s, int ifindex, char *name)
static int rtnl_getlinkname_handler(struct nlmsghdr *nh, void *arg)
{
char *name = arg;
- struct ifinfomsg *ifm;
struct rtattr *ifla[__IFLA_MAX];
switch (nh->nlmsg_type) {
case RTM_NEWLINK:
- ifm = NLMSG_DATA(nh);
parse_ifinfo(ifla, nh);
strncpy(name, RTA_DATA(ifla[IFLA_IFNAME]), IFNAMSIZ);
return 0;
@@ -413,14 +411,12 @@ struct vlan_identifier {
static int rtnl_find_vlan_handler(struct nlmsghdr *nh, void *arg)
{
struct vlan_identifier *vlan = arg;
- struct ifinfomsg *ifm;
struct rtattr *ifla[__IFLA_MAX];
struct rtattr *linkinfo[__IFLA_INFO_MAX];
struct rtattr *vlaninfo[__IFLA_VLAN_MAX];
switch (nh->nlmsg_type) {
case RTM_NEWLINK:
- ifm = NLMSG_DATA(nh);
parse_ifinfo(ifla, nh);
if (!ifla[IFLA_LINK])
break;
--
1.7.11.7

View File

@ -0,0 +1,47 @@
From 0a9af08a5661ceac87d7b9f98b204a9f80169333 Mon Sep 17 00:00:00 2001
From: Mark Rustad <mark.d.rustad@intel.com>
Date: Thu, 25 Oct 2012 04:49:23 +0000
Subject: [PATCH 4/7] build: Remove dependency on libnl
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
fcoe-utils really did not need to be dependent on libnl. It was
only including netlink/netlink.h, not actually using the library,
and the only real need for netlink/netlink.h was to get the
including files stdint.h, linux/netlink.h and linux/rtnetlink.h.
So, just include those directly and forget about libnl.
Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Tested-by: Ross Brattain <ross.b.brattain@intel.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: Petr Šabata <contyk@redhat.com>
---
fcoemon.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/fcoemon.c b/fcoemon.c
index 9217552..daf9fab 100644
--- a/fcoemon.c
+++ b/fcoemon.c
@@ -24,6 +24,7 @@
#include <stddef.h>
#include <stdio.h>
#include <stdlib.h>
+#include <stdint.h>
#include <time.h>
#include <libgen.h>
#include <ulimit.h>
@@ -40,7 +41,8 @@
#include <linux/sockios.h>
#include <linux/if.h>
#include <linux/if_arp.h>
-#include <netlink/netlink.h>
+#include <linux/netlink.h>
+#include <linux/rtnetlink.h>
#include <linux/ethtool.h>
#include <linux/if_vlan.h>
#include <linux/dcbnl.h>
--
1.7.11.7

View File

@ -0,0 +1,82 @@
From 3cb7cf3e6f756e15377f7512ba0dc27c10063935 Mon Sep 17 00:00:00 2001
From: Robert Love <robert.w.love@intel.com>
Date: Thu, 4 Oct 2012 03:17:23 +0000
Subject: [PATCH 1/7] doc: Make '-s|--stats' description more readable
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
This patch improves the language in the fcoeadm
man page for the '-s|--stats' option to make it more
readable.
Signed-off-by: Robert Love <robert.w.love@intel.com>
Tested-by: Ross Brattain <ross.b.brattain@intel.com>
Signed-off-by: Petr Šabata <contyk@redhat.com>
---
doc/fcoeadm.8 | 12 +++++++-----
doc/fcoeadm.txt | 12 ++++++------
2 files changed, 13 insertions(+), 11 deletions(-)
diff --git a/doc/fcoeadm.8 b/doc/fcoeadm.8
index 2a696b3..6dd6d9b 100644
--- a/doc/fcoeadm.8
+++ b/doc/fcoeadm.8
@@ -2,12 +2,12 @@
.\" Title: fcoeadm
.\" Author: [FIXME: author] [see http://docbook.sf.net/el/author]
.\" Generator: DocBook XSL Stylesheets v1.76.1 <http://docbook.sf.net/>
-.\" Date: 01/30/2012
+.\" Date: 07/20/2012
.\" Manual: Open-FCoE Tools
.\" Source: Open-FCoE
.\" Language: English
.\"
-.TH "FCOEADM" "8" "01/30/2012" "Open\-FCoE" "Open\-FCoE Tools"
+.TH "FCOEADM" "8" "07/20/2012" "Open\-FCoE" "Open\-FCoE Tools"
.\" -----------------------------------------------------------------
.\" * Define some portability stuff
.\" -----------------------------------------------------------------
@@ -102,11 +102,13 @@ Show detailed information about the discovered SCSI LUNs associated with the FCo
.PP
\fB\-s\fR, \fB\-\-stats\fR \fIethX\fR [\fIinterval\fR]
.RS 4
-Show the statistics (including FC4 statistics) of the FCoE interface on the specified network interface\&. The information will be display in one line on the screen per given time interval\&.
+Show the statistics (including FC4 statistics) of the FCoE connection on the specified network interface\&. The information will be displayed repeatedly until the user cancels the command\&. The statistics will be printed every specified
\fIinterval\fR
-should be specified in whole integers greater than 0\&. It specifies the time interval in the unit of seconds\&. If
+(in seconds)\&.
+\fIinterval\fR
+should be specified as a whole number greater than 0\&. If
\fIinterval\fR
-is not specified, the default interval is one second\&.
+is not specified, a default interval of one second is used\&.
.RE
.PP
\fB\-b\fR, \fB\-\-lesb\fR \fIethX\fR [\fIinterval\fR]
diff --git a/doc/fcoeadm.txt b/doc/fcoeadm.txt
index 4069978..40348ab 100644
--- a/doc/fcoeadm.txt
+++ b/doc/fcoeadm.txt
@@ -100,12 +100,12 @@ OPTIONS
*-s*, *--stats* _ethX_ [_interval_]::
Show the statistics (including FC4 statistics) of the FCoE
- interface on the specified network interface.
- The information will be display in one line on the screen per given
- time interval. _interval_ should be specified in whole integers
- greater than 0. It specifies the time interval in the unit of
- seconds. If _interval_ is not specified, the default interval is
- one second.
+ connection on the specified network interface. The information will
+ be displayed repeatedly until the user cancels the command. The
+ statistics will be printed every specified _interval_ (in seconds).
+ _interval_ should be specified as a whole number greater than 0.
+ If _interval_ is not specified, a default interval of one second is
+ used.
*-b*, *--lesb* _ethX_ [_interval_]::
Show the Link Error Statistics Block (LESB) of the FCoE connection
--
1.7.11.7

View File

@ -0,0 +1,118 @@
From 2e92b21a3c075c4f0558c6323664d377281c8bd7 Mon Sep 17 00:00:00 2001
From: Mark Rustad <mark.d.rustad@intel.com>
Date: Thu, 25 Oct 2012 04:51:07 +0000
Subject: [PATCH 7/7] fcoeadm: Fix scsi_target_id access
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
This fixes a few problems with how the function show_target_info
accesses the scsi_target_id. First off, it tries to read it as a
u32 value, but checks for the special value -1. There are two
problems with that, -1 can't be read by sa_sys_read_u32 (it
will return an error) and if it were to return 0xffffffff in
the u32, the comparison with -1 would always be false. A third
problem is that the error return from sa_sys_read_u32 is not
checked. Fix this by adding a function sa_sys_read_int and
use it properly.
Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Tested-by: Ross Brattain <ross.b.brattain@intel.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: Petr Šabata <contyk@redhat.com>
---
fcoeadm_display.c | 13 +++++++++----
include/fcoemon_utils.h | 1 +
lib/sa_sys.c | 26 ++++++++++++++++++++++++++
3 files changed, 36 insertions(+), 4 deletions(-)
diff --git a/fcoeadm_display.c b/fcoeadm_display.c
index 85aa0a0..e1cbd48 100644
--- a/fcoeadm_display.c
+++ b/fcoeadm_display.c
@@ -239,7 +239,7 @@ static void show_target_info(const char *symbolic_name,
HBA_PORTATTRIBUTES *rp_info)
{
char buf[256];
- u_int32_t tgt_id;
+ int tgt_id;
int rc;
char *ifname;
@@ -259,9 +259,14 @@ static void show_target_info(const char *symbolic_name,
show_wwn(rp_info->PortWWN.wwn);
printf("\n");
- rc = sa_sys_read_u32(rp_info->OSDeviceName, "scsi_target_id", &tgt_id);
- if (tgt_id != -1)
- printf(" Target ID: %d\n", tgt_id);
+ rc = sa_sys_read_int(rp_info->OSDeviceName, "scsi_target_id", &tgt_id);
+ printf(" Target ID: ");
+ if (rc)
+ printf("Unknown\n");
+ else if (tgt_id != -1)
+ printf("%d\n", tgt_id);
+ else
+ printf("Unset\n");
printf(" MaxFrameSize: %d\n", rp_info->PortMaxFrameSize);
diff --git a/include/fcoemon_utils.h b/include/fcoemon_utils.h
index 3bdb377..a8ad27b 100644
--- a/include/fcoemon_utils.h
+++ b/include/fcoemon_utils.h
@@ -288,6 +288,7 @@ struct sa_table {
*/
extern int sa_sys_read_line(const char *, const char *, char *, size_t);
extern int sa_sys_write_line(const char *, const char *, const char *);
+extern int sa_sys_read_int(const char *, const char *, int *);
extern int sa_sys_read_u32(const char *, const char *, u_int32_t *);
extern int sa_sys_read_u64(const char *, const char *, u_int64_t *);
extern int sa_dir_read(char *, int (*)(struct dirent *, void *), void *);
diff --git a/lib/sa_sys.c b/lib/sa_sys.c
index bb35083..86988ca 100644
--- a/lib/sa_sys.c
+++ b/lib/sa_sys.c
@@ -18,6 +18,8 @@
#include "fcoemon_utils.h"
+#include <limits.h>
+
/*
* Read a line from the specified file in the specified directory
* into the buffer. The file is opened and closed.
@@ -90,6 +92,30 @@ sa_sys_write_line(const char *dir, const char *file, const char *string)
return rc;
}
+int sa_sys_read_int(const char *dir, const char *file, int *vp)
+{
+ char buf[256];
+ int rc;
+ long val;
+ char *endptr;
+
+ rc = sa_sys_read_line(dir, file, buf, sizeof(buf));
+ if (rc)
+ return rc;
+
+ val = strtol(buf, &endptr, 0);
+ if (*endptr != '\0') {
+ fprintf(stderr, "%s: parse error. file %s/%s line '%s'\n",
+ __func__, dir, file, buf);
+ return -1;
+ }
+ if (val > INT_MAX || val < INT_MIN)
+ return ERANGE;
+
+ *vp = val;
+ return 0;
+}
+
int
sa_sys_read_u32(const char *dir, const char *file, u_int32_t *vp)
{
--
1.7.11.7

View File

@ -0,0 +1,114 @@
From 966595269eee103be34d01149493e2a78a402514 Mon Sep 17 00:00:00 2001
From: Mark Rustad <mark.d.rustad@intel.com>
Date: Thu, 25 Oct 2012 04:49:59 +0000
Subject: [PATCH 6/7] fcoemon: Fix format string errors
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Tested-by: Ross Brattain <ross.b.brattain@intel.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: Petr Šabata <contyk@redhat.com>
---
fcoemon.c | 22 ++++++++++++----------
1 file changed, 12 insertions(+), 10 deletions(-)
diff --git a/fcoemon.c b/fcoemon.c
index 13977eb..a4d1169 100644
--- a/fcoemon.c
+++ b/fcoemon.c
@@ -17,8 +17,10 @@
* Maintained at www.Open-FCoE.org
*/
+#define __STDC_FORMAT_MACROS 1
#include <ctype.h>
#include <getopt.h>
+#include <inttypes.h>
#include <malloc.h>
#include <signal.h>
#include <stddef.h>
@@ -604,7 +606,7 @@ static void fcm_fc_event_log(struct fc_nl_event *fe)
for (i = 0; i < ARRAY_SIZE(fc_host_event_code_names); i++) {
if (fe->event_code == fc_host_event_code_names[i].value) {
/* only do u32 data even len is not, e.g. vendor */
- FCM_LOG("FC_HOST_EVENT %d at %lld secs on host%d:"
+ FCM_LOG("FC_HOST_EVENT %d at %" PRIu64 " secs on host%d:"
"code %d=%s datalen %d data=%d\n",
fe->event_num, fe->seconds,
fe->host_no, fe->event_code,
@@ -1856,12 +1858,12 @@ static void fcm_dcbd_rx(void *arg)
&ep);
if (ep != NULL)
FCM_LOG("unexpected response code from lldpad: "
- "len %d buf %s rc %d", len, buf, rc);
+ "len %zd buf %s rc %d", len, buf, rc);
else if (st != cmd_success &&
st != cmd_not_applicable &&
st != cmd_device_not_found) {
FCM_LOG("error response from lldpad: "
- "error %d len %d %s",
+ "error %d len %zd %s",
st, len, buf);
}
fcm_clif->cl_busy = 0;
@@ -1882,7 +1884,7 @@ static void fcm_dcbd_rx(void *arg)
break;
default:
FCM_LOG("Unexpected cmd in response "
- "from lldpad: len %d %s",
+ "from lldpad: len %zd %s",
len, buf);
break;
}
@@ -1892,7 +1894,7 @@ static void fcm_dcbd_rx(void *arg)
fcm_dcbd_event(buf, len);
break;
default:
- FCM_LOG("Unexpected message from lldpad: len %d buf %s",
+ FCM_LOG("Unexpected message from lldpad: len %zd buf %s",
len, buf);
break;
}
@@ -1916,7 +1918,7 @@ static int fcm_dcbd_request(char *req)
fcm_clif->cl_busy = 1;
rc = write(fcm_clif->cl_fd, req, len);
if (rc < 0) {
- FCM_LOG_ERR(errno, "Failed write req %s len %d", req, len);
+ FCM_LOG_ERR(errno, "Failed write req %s len %zd", req, len);
fcm_clif->cl_busy = 0;
fcm_dcbd_disconnect();
sa_timer_set(&fcm_dcbd_timer, DCBD_CONNECT_RETRY_TIMEOUT);
@@ -2276,7 +2278,7 @@ static void fcm_dcbd_get_oper(struct fcm_netif *ff, char *resp, char *cp)
if (ep) {
FCM_LOG_DEV(ff, "Invalid get oper response "
- "parse error byte %d, resp %s", ep - cp, cp);
+ "parse error byte %ld, resp %s", ep - cp, cp);
fcm_dcbd_state_set(ff, FCD_ERROR);
} else {
if (val && fcoe_config.debug)
@@ -2871,8 +2873,8 @@ static void fcm_dump(void)
FCM_LOG("ieee_resp_pending: %d\n", head->ieee_resp_pending);
FCM_LOG("ieee_pfc_info: %d\n", head->ieee_pfc_info);
FCM_LOG("ieee_app_info: %d\n", head->ieee_app_info);
- FCM_LOG("ff_pfc_info: %d\n", head->ff_pfc_info);
- FCM_LOG("ff_app_info: %d\n", head->ff_app_info);
+ FCM_LOG("ff_pfc_info: %d\n", head->ff_pfc_info.op_mode);
+ FCM_LOG("ff_app_info: %d\n", head->ff_app_info.op_mode);
FCM_LOG("ff_operstate: %d\n", head->ff_operstate);
FCM_LOG("ff_dcb_state: %d\n", head->ff_dcb_state);
FCM_LOG("response_pending: %d\n", head->response_pending);
@@ -2911,7 +2913,7 @@ static void fcm_pidfile_create(void)
exit(1);
}
if (!sscanf(sp, "%d", &pid)) {
- FCM_LOG("Error reading pid ('%s') - exiting\n",
+ FCM_LOG("Error reading pid ('%d') - exiting\n",
pid);
exit(1);
}
--
1.7.11.7

View File

@ -2,8 +2,8 @@
%define _hardened_build 1 %define _hardened_build 1
Name: fcoe-utils Name: fcoe-utils
Version: 1.0.24 Version: 1.0.25
Release: 2%{?dist} Release: 1%{?dist}
Summary: Fibre Channel over Ethernet utilities Summary: Fibre Channel over Ethernet utilities
Group: Applications/System Group: Applications/System
License: GPLv2 License: GPLv2
@ -19,11 +19,18 @@ Patch1: fcoe-utils-1.0.19-make.patch
Patch2: fcoe-utils-1.0.18-help.patch Patch2: fcoe-utils-1.0.18-help.patch
Patch3: fcoe-utils-1.0.18-config.patch Patch3: fcoe-utils-1.0.18-config.patch
Patch4: fcoe-utils-1.0.23-archiver.patch Patch4: fcoe-utils-1.0.23-archiver.patch
# Upstream patches
Patch10: %{name}-1.0.25-doc-Make-s-stats-description-more-readable.patch
Patch11: %{name}-1.0.25-QUICKSTART-Add-clone-instructions-for-libhbalinux-an.patch
Patch12: %{name}-1.0.25-QUICKSTART-Update-references-to-libHBAAPI.git.patch
Patch13: %{name}-1.0.25-build-Remove-dependency-on-libnl.patch
Patch14: %{name}-1.0.25-build-Fix-new-warnings-made-by-gcc-4.7.patch
Patch15: %{name}-1.0.25-fcoemon-Fix-format-string-errors.patch
Patch16: %{name}-1.0.25-fcoeadm-Fix-scsi_target_id-access.patch
BuildRequires: libtool automake autoconf BuildRequires: libtool automake autoconf
BuildRequires: lldpad-devel >= 0.9.43 BuildRequires: lldpad-devel >= 0.9.43
BuildRequires: libhbaapi-devel >= 2.2-12 BuildRequires: libhbaapi-devel >= 2.2-12
BuildRequires: libhbalinux-devel >= 1.0.13 BuildRequires: libhbalinux-devel >= 1.0.13
BuildRequires: libnl-devel
BuildRequires: systemd-units BuildRequires: systemd-units
Requires: lldpad >= 0.9.43 Requires: lldpad >= 0.9.43
Requires: libhbalinux >= 1.0.13 Requires: libhbalinux >= 1.0.13
@ -40,10 +47,19 @@ fcoemon - service to configure DCB Ethernet QOS filters, works with lldpad
%prep %prep
%setup -q %setup -q
cp -v %{SOURCE1} quickstart.txt
%patch1 -p1 -b .make %patch1 -p1 -b .make
%patch2 -p1 -b .help %patch2 -p1 -b .help
%patch3 -p1 -b .config %patch3 -p1 -b .config
%patch4 -p1 -b .archiver %patch4 -p1 -b .archiver
# upstream
%patch10 -p1
%patch11 -p1
%patch12 -p1
%patch13 -p1
%patch14 -p1
%patch15 -p1
%patch16 -p1
%build %build
./bootstrap.sh ./bootstrap.sh
@ -53,16 +69,15 @@ make %{?_smp_mflags}
%install %install
make install DESTDIR=%{buildroot} make install DESTDIR=%{buildroot}
rm -rf %{buildroot}/etc/init.d rm -rf %{buildroot}/etc/init.d
install -m 644 %{SOURCE1} quickstart.txt
mkdir -p %{buildroot}%{_sysconfdir}/sysconfig %{buildroot}%{_unitdir} mkdir -p %{buildroot}%{_sysconfdir}/sysconfig %{buildroot}%{_unitdir}
install -m 644 %{SOURCE2} %{buildroot}%{_unitdir} install -m 644 %{SOURCE2} %{buildroot}%{_unitdir}
install -m 644 %{SOURCE3} %{buildroot}%{_sysconfdir}/sysconfig/fcoe install -m 644 %{SOURCE3} %{buildroot}%{_sysconfdir}/sysconfig/fcoe
mkdir -p %{buildroot}%{_libexecdir}/fcoe mkdir -p %{buildroot}%{_libexecdir}/fcoe
install -m 755 contrib/fcc.sh %{buildroot}%{_libexecdir}/fcoe/fcc.sh for file in \
install -m 755 contrib/fcoe_edd.sh %{buildroot}%{_libexecdir}/fcoe/fcoe_edd.sh contrib/*.sh \
install -m 755 contrib/fcoe-setup.sh %{buildroot}%{_libexecdir}/fcoe/fcoe-setup.sh debug/*sh
install -m 755 debug/fcoedump.sh %{buildroot}%{_libexecdir}/fcoe/fcoedump.sh do install -m 755 ${file} %{buildroot}%{_libexecdir}/fcoe/
install -m 755 debug/dcbcheck.sh %{buildroot}%{_libexecdir}/fcoe/dcbcheck.sh done
%post %post
%systemd_post fcoe.service %systemd_post fcoe.service
@ -74,23 +89,25 @@ install -m 755 debug/dcbcheck.sh %{buildroot}%{_libexecdir}/fcoe/dcbcheck.sh
%systemd_postun_with_restart fcoe.service %systemd_postun_with_restart fcoe.service
%files %files
%doc README COPYING quickstart.txt %doc README COPYING QUICKSTART quickstart.txt
%{_sbindir}/* %{_sbindir}/*
%{_mandir}/man8/* %{_mandir}/man8/*
%{_unitdir}/fcoe.service %{_unitdir}/fcoe.service
%config(noreplace) %{_sysconfdir}/sysconfig/fcoe %{_sysconfdir}/fcoe/
%dir %{_sysconfdir}/fcoe/
%config(noreplace) %{_sysconfdir}/fcoe/cfg-ethx %config(noreplace) %{_sysconfdir}/fcoe/cfg-ethx
%dir %{_sysconfdir}/bash_completion.d/ #%config(noreplace) %{_sysconfdir}/fcoe/config
%{_sysconfdir}/bash_completion.d/* %config(noreplace) %{_sysconfdir}/sysconfig/fcoe
%attr(0755,root,root) %{_libexecdir}/fcoe/fcoe_edd.sh %{_sysconfdir}/bash_completion.d/
%attr(0755,root,root) %{_libexecdir}/fcoe/fcoe-setup.sh %{_libexecdir}/fcoe/
%attr(0755,root,root) %{_libexecdir}/fcoe/fcc.sh
%attr(0755,root,root) %{_libexecdir}/fcoe/fcoedump.sh
%attr(0755,root,root) %{_libexecdir}/fcoe/dcbcheck.sh
%changelog %changelog
* Tue Nov 27 2012 Petr Šabata <contyk@redhat.com> - 1.0.25-1
- 1.0.25 (with latest fixes)
- Simplify the spec a bit
- Fix bogus dates in changelog
* Thu Nov 01 2012 Petr Šabata <contyk@redhat.com> - 1.0.25-1
* Tue Aug 28 2012 Petr Šabata <contyk@redhat.com> - 1.0.24-2 * Tue Aug 28 2012 Petr Šabata <contyk@redhat.com> - 1.0.24-2
- Migrate to systemd scriptlets (#850104) - Migrate to systemd scriptlets (#850104)
@ -142,7 +159,7 @@ install -m 755 debug/dcbcheck.sh %{buildroot}%{_libexecdir}/fcoe/dcbcheck.sh
* Thu Jun 02 2011 Petr Sabata <contyk@redhat.com> - 1.0.19-1 * Thu Jun 02 2011 Petr Sabata <contyk@redhat.com> - 1.0.19-1
- 1.0.19 bump - 1.0.19 bump
* Wed May 3 2011 Petr Sabata <psabata@redhat.com> - 1.0.18-2 * Tue May 3 2011 Petr Sabata <psabata@redhat.com> - 1.0.18-2
- fcoemon: Do not create a world and group writable PID file - fcoemon: Do not create a world and group writable PID file
* Wed Apr 20 2011 Petr Sabata <psabata@redhat.com> - 1.0.18-1 * Wed Apr 20 2011 Petr Sabata <psabata@redhat.com> - 1.0.18-1
@ -233,7 +250,7 @@ install -m 755 debug/dcbcheck.sh %{buildroot}%{_libexecdir}/fcoe/dcbcheck.sh
* Mon May 4 2009 Jan Zeleny <jzeleny@redhat.com> - 1.0.7-5 * Mon May 4 2009 Jan Zeleny <jzeleny@redhat.com> - 1.0.7-5
- fixed SIGSEGV when fcoe module isn't loaded (#498550) - fixed SIGSEGV when fcoe module isn't loaded (#498550)
* Wed Apr 27 2009 Jan Zeleny <jzeleny@redhat.com> - 1.0.7-4 * Mon Apr 27 2009 Jan Zeleny <jzeleny@redhat.com> - 1.0.7-4
- added libhbalinux to Requires (#497605) - added libhbalinux to Requires (#497605)
- correction of spec file (_initddir -> _initrddir) - correction of spec file (_initddir -> _initrddir)

View File

@ -1 +1 @@
fa7b748f44f02e279c836946e9d9ec0a fcoe-utils-1.0.24.tar.bz2 311a767fa140376a69e636ab0cdee967 fcoe-utils-1.0.25.tar.bz2