328 lines
11 KiB
Diff
328 lines
11 KiB
Diff
From b15710a9b96c15e8cdcf3dcfda7b40559d565b3c Mon Sep 17 00:00:00 2001
|
|
From: Eddie Wai <eddie.wai@broadcom.com>
|
|
Date: Mon, 15 Oct 2012 14:47:54 -0700
|
|
Subject: [PATCH] ISCSIUIO: Updated to 0.7.6.1
|
|
|
|
Signed-off-by: Eddie Wai <eddie.wai@broadcom.com>
|
|
---
|
|
iscsiuio/README | 4 ++--
|
|
iscsiuio/RELEASE.TXT | 34 ++++++++++++++++++++++++++++++++--
|
|
iscsiuio/configure | 18 +++++++++---------
|
|
iscsiuio/configure.ac | 4 ++--
|
|
iscsiuio/docs/iscsiuio.8 | 4 ++--
|
|
iscsiuio/src/uip/uip_arp.c | 1 -
|
|
iscsiuio/src/unix/libs/bnx2x.c | 19 ++++++++++++++++---
|
|
iscsiuio/src/unix/libs/bnx2x.h | 8 +++++++-
|
|
iscsiuio/src/unix/nic.c | 3 ++-
|
|
iscsiuio/src/unix/nic_nl.c | 2 +-
|
|
10 files changed, 73 insertions(+), 24 deletions(-)
|
|
|
|
diff --git a/iscsiuio/README b/iscsiuio/README
|
|
index a716263..e5ee23f 100644
|
|
--- a/iscsiuio/README
|
|
+++ b/iscsiuio/README
|
|
@@ -1,6 +1,6 @@
|
|
iscsiuio Userspace Tool
|
|
-Version 0.7.4.3
|
|
-Aug 16, 2012
|
|
+Version 0.7.6.1
|
|
+Oct 09, 2012
|
|
------------------------------------------------------
|
|
|
|
This tool is to be used in conjunction with the Broadcom NetXtreme II Linux
|
|
diff --git a/iscsiuio/RELEASE.TXT b/iscsiuio/RELEASE.TXT
|
|
index cb1d470..0e7665c 100644
|
|
--- a/iscsiuio/RELEASE.TXT
|
|
+++ b/iscsiuio/RELEASE.TXT
|
|
@@ -1,7 +1,7 @@
|
|
Release Notes
|
|
Broadcom uIP Linux Driver
|
|
- Version 0.7.4.3
|
|
- 08/16/2012
|
|
+ Version 0.7.6.1
|
|
+ 10/15/2012
|
|
|
|
Broadcom Corporation
|
|
5300 California Avenue,
|
|
@@ -11,6 +11,36 @@
|
|
All rights reserved
|
|
|
|
|
|
+uIP v0.7.6.1 (Oct 15, 2012)
|
|
+=======================================================
|
|
+ Fixes
|
|
+ -----
|
|
+ 1. Problem: Cont00065690 - Vconfig method of connecting over
|
|
+ tagged vlan with IPv6 failed
|
|
+ Cause: The new net param support changes has prevented
|
|
+ the old vconfig method from execising the IPv6
|
|
+ acquisition engine properly
|
|
+ Change: Ensure that this old vconfig method to run the IPv6
|
|
+ acquisition engine properly and to its entirety
|
|
+ Impact: IPv6 + VLAN using the network VLAN configuration
|
|
+ method
|
|
+
|
|
+ 2. Problem: Cont00065768 - RHEL5.X iscsiuio segfault possible
|
|
+ if there is a specific 1024 byte size broadcast
|
|
+ packet
|
|
+ Cause: This is a corner case where the packet size is
|
|
+ exactly 1024 bytes + padding that exceeded the
|
|
+ DMA rx buffer. This has been there since day 1.
|
|
+ Change: Ensure that the packet size + padding do not
|
|
+ exceed this limit.
|
|
+ Impact: 10G only. 1G already has the guard against it.
|
|
+
|
|
+ Enhancements
|
|
+ ------------
|
|
+ 1. Change: Added support for 10G 57840 4x10 and 2x20
|
|
+ Impact: 10G 57840
|
|
+
|
|
+
|
|
uIP v0.7.4.3 (Aug 16, 2012)
|
|
=======================================================
|
|
Fixes
|
|
diff --git a/iscsiuio/configure b/iscsiuio/configure
|
|
index 6ff2e68..0b2abc4 100644
|
|
--- a/iscsiuio/configure
|
|
+++ b/iscsiuio/configure
|
|
@@ -1,6 +1,6 @@
|
|
#! /bin/sh
|
|
# Guess values for system-dependent variables and create Makefiles.
|
|
-# Generated by GNU Autoconf 2.59 for iscsiuio 0.7.4.3.
|
|
+# Generated by GNU Autoconf 2.59 for iscsiuio 0.7.6.1.
|
|
#
|
|
# Report bugs to <eddie.wai@broadcom.com>.
|
|
#
|
|
@@ -423,8 +423,8 @@ SHELL=${CONFIG_SHELL-/bin/sh}
|
|
# Identity of this package.
|
|
PACKAGE_NAME='iscsiuio'
|
|
PACKAGE_TARNAME='iscsiuio'
|
|
-PACKAGE_VERSION='0.7.4.3'
|
|
-PACKAGE_STRING='iscsiuio 0.7.4.3'
|
|
+PACKAGE_VERSION='0.7.6.1'
|
|
+PACKAGE_STRING='iscsiuio 0.7.6.1'
|
|
PACKAGE_BUGREPORT='eddie.wai@broadcom.com'
|
|
|
|
# Factoring default headers for most tests.
|
|
@@ -954,7 +954,7 @@ if test "$ac_init_help" = "long"; then
|
|
# Omit some internal or obsolete options to make the list less imposing.
|
|
# This message is too long to be a string in the A/UX 3.1 sh.
|
|
cat <<_ACEOF
|
|
-\`configure' configures iscsiuio 0.7.4.3 to adapt to many kinds of systems.
|
|
+\`configure' configures iscsiuio 0.7.6.1 to adapt to many kinds of systems.
|
|
|
|
Usage: $0 [OPTION]... [VAR=VALUE]...
|
|
|
|
@@ -1020,7 +1020,7 @@ fi
|
|
|
|
if test -n "$ac_init_help"; then
|
|
case $ac_init_help in
|
|
- short | recursive ) echo "Configuration of iscsiuio 0.7.4.3:";;
|
|
+ short | recursive ) echo "Configuration of iscsiuio 0.7.6.1:";;
|
|
esac
|
|
cat <<\_ACEOF
|
|
|
|
@@ -1161,7 +1161,7 @@ fi
|
|
test -n "$ac_init_help" && exit 0
|
|
if $ac_init_version; then
|
|
cat <<\_ACEOF
|
|
-iscsiuio configure 0.7.4.3
|
|
+iscsiuio configure 0.7.6.1
|
|
generated by GNU Autoconf 2.59
|
|
|
|
Copyright (C) 2003 Free Software Foundation, Inc.
|
|
@@ -1175,7 +1175,7 @@ cat >&5 <<_ACEOF
|
|
This file contains any messages produced by compilers while
|
|
running configure, to aid debugging if configure makes a mistake.
|
|
|
|
-It was created by iscsiuio $as_me 0.7.4.3, which was
|
|
+It was created by iscsiuio $as_me 0.7.6.1, which was
|
|
generated by GNU Autoconf 2.59. Invocation command line was
|
|
|
|
$ $0 $@
|
|
@@ -21726,7 +21726,7 @@ _ASBOX
|
|
} >&5
|
|
cat >&5 <<_CSEOF
|
|
|
|
-This file was extended by iscsiuio $as_me 0.7.4.3, which was
|
|
+This file was extended by iscsiuio $as_me 0.7.6.1, which was
|
|
generated by GNU Autoconf 2.59. Invocation command line was
|
|
|
|
CONFIG_FILES = $CONFIG_FILES
|
|
@@ -21789,7 +21789,7 @@ _ACEOF
|
|
|
|
cat >>$CONFIG_STATUS <<_ACEOF
|
|
ac_cs_version="\\
|
|
-iscsiuio config.status 0.7.4.3
|
|
+iscsiuio config.status 0.7.6.1
|
|
configured by $0, generated by GNU Autoconf 2.59,
|
|
with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
|
|
|
|
diff --git a/iscsiuio/configure.ac b/iscsiuio/configure.ac
|
|
index 0b1e7f1..1045a80 100644
|
|
--- a/iscsiuio/configure.ac
|
|
+++ b/iscsiuio/configure.ac
|
|
@@ -11,9 +11,9 @@ dnl Maintained by: Eddie Wai (eddie.wai@broadcom.com)
|
|
dnl
|
|
|
|
PACKAGE=iscsiuio
|
|
-VERSION=0.7.4.3
|
|
+VERSION=0.7.6.1
|
|
|
|
-AC_INIT(iscsiuio, 0.7.4.3, eddie.wai@broadcom.com)
|
|
+AC_INIT(iscsiuio, 0.7.6.1, eddie.wai@broadcom.com)
|
|
|
|
AM_INIT_AUTOMAKE($PACKAGE, $VERSION)
|
|
AC_CONFIG_HEADER(config.h)
|
|
diff --git a/iscsiuio/docs/iscsiuio.8 b/iscsiuio/docs/iscsiuio.8
|
|
index 4bf26df..d107327 100644
|
|
--- a/iscsiuio/docs/iscsiuio.8
|
|
+++ b/iscsiuio/docs/iscsiuio.8
|
|
@@ -3,9 +3,9 @@
|
|
.\" modify it under the terms of the GNU General Public License as
|
|
.\" published by the Free Software Foundation.
|
|
.\"
|
|
-.\" bnx2.4,v 0.7.4.3
|
|
+.\" bnx2.4,v 0.7.6.1
|
|
.\"
|
|
-.TH iscsiuio 8 "08/16/2012" "Broadcom Corporation"
|
|
+.TH iscsiuio 8 "10/09/2012" "Broadcom Corporation"
|
|
.\"
|
|
.\" NAME part
|
|
.\"
|
|
diff --git a/iscsiuio/src/uip/uip_arp.c b/iscsiuio/src/uip/uip_arp.c
|
|
index 3ef3b07..9dd02a1 100644
|
|
--- a/iscsiuio/src/uip/uip_arp.c
|
|
+++ b/iscsiuio/src/uip/uip_arp.c
|
|
@@ -273,7 +273,6 @@ uip_arp_arpin(nic_interface_t * nic_iface,
|
|
pkt->buf_size = sizeof(*arp) +
|
|
sizeof(struct uip_vlan_eth_hdr);
|
|
}
|
|
- pkt->buf_size = sizeof(*arp) + sizeof(*eth);
|
|
}
|
|
break;
|
|
case const_htons(ARP_REPLY):
|
|
diff --git a/iscsiuio/src/unix/libs/bnx2x.c b/iscsiuio/src/unix/libs/bnx2x.c
|
|
index 5e33420..70e85c0 100644
|
|
--- a/iscsiuio/src/unix/libs/bnx2x.c
|
|
+++ b/iscsiuio/src/unix/libs/bnx2x.c
|
|
@@ -103,6 +103,10 @@ static const char brcm_57840_MF[] = "Broadcom NetXtreme II BCM57840 MF "
|
|
"10-Gigabit";
|
|
static const char brcm_57840_VF[] = "Broadcom NetXtreme II BCM57840 VF "
|
|
"10-Gigabit";
|
|
+static const char brcm_57840_4_10[] = "Broadcom NetXtreme II BCM57840 4x"
|
|
+ "10-Gigabit";
|
|
+static const char brcm_57840_2_20[] = "Broadcom NetXtreme II BCM57840 2x"
|
|
+ "20-Gigabit";
|
|
|
|
/*******************************************************************************
|
|
* PCI ID constants
|
|
@@ -123,6 +127,8 @@ static const char brcm_57840_VF[] = "Broadcom NetXtreme II BCM57840 VF "
|
|
#define PCI_DEVICE_ID_NX2_57840 0x168d
|
|
#define PCI_DEVICE_ID_NX2_57840_MF 0x16ab
|
|
#define PCI_DEVICE_ID_NX2_57840_VF 0x16ad
|
|
+#define PCI_DEVICE_ID_NX2_57840_4_10 0x16a1
|
|
+#define PCI_DEVICE_ID_NX2_57840_2_20 0x16a2
|
|
#define PCI_ANY_ID (~0)
|
|
|
|
/* This is the table used to match PCI vendor and device ID's to the
|
|
@@ -158,6 +164,10 @@ static const struct pci_device_id bnx2x_pci_tbl[] = {
|
|
PCI_ANY_ID, PCI_ANY_ID, brcm_57840_MF},
|
|
{PCI_VENDOR_ID_BROADCOM, PCI_DEVICE_ID_NX2_57840_VF,
|
|
PCI_ANY_ID, PCI_ANY_ID, brcm_57840_VF},
|
|
+ {PCI_VENDOR_ID_BROADCOM, PCI_DEVICE_ID_NX2_57840_4_10,
|
|
+ PCI_ANY_ID, PCI_ANY_ID, brcm_57840_4_10},
|
|
+ {PCI_VENDOR_ID_BROADCOM, PCI_DEVICE_ID_NX2_57840_2_20,
|
|
+ PCI_ANY_ID, PCI_ANY_ID, brcm_57840_2_20},
|
|
};
|
|
|
|
static struct iro e1_iro[2] = {
|
|
@@ -1401,7 +1411,7 @@ static int bnx2x_read(nic_t * nic, packet_t * pkt)
|
|
union eth_rx_cqe *cqe;
|
|
__u8 cqe_fp_flags;
|
|
void *rx_pkt;
|
|
- int len, pad, cqe_size;
|
|
+ int len, pad, cqe_size, max_len;
|
|
rc = 1;
|
|
|
|
if (bnx2x_is_ver70(bp)) {
|
|
@@ -1427,10 +1437,13 @@ static int bnx2x_read(nic_t * nic, packet_t * pkt)
|
|
|
|
/* Doto query MTU size of physical device */
|
|
/* Ensure len is valid */
|
|
- if (len > pkt->max_buf_size)
|
|
+ max_len = pkt->max_buf_size < bp->rx_buffer_size ?
|
|
+ pkt->max_buf_size : bp->rx_buffer_size;
|
|
+ if (len > max_len) {
|
|
LOG_DEBUG(PFX "%s: bad BD length: %d",
|
|
nic->log_name, len);
|
|
-
|
|
+ len = max_len;
|
|
+ }
|
|
if (len > 0) {
|
|
msync(rx_pkt, len, MS_SYNC);
|
|
/* Copy the data */
|
|
diff --git a/iscsiuio/src/unix/libs/bnx2x.h b/iscsiuio/src/unix/libs/bnx2x.h
|
|
index b758179..1f47011 100644
|
|
--- a/iscsiuio/src/unix/libs/bnx2x.h
|
|
+++ b/iscsiuio/src/unix/libs/bnx2x.h
|
|
@@ -430,6 +430,8 @@ struct client_init_general_data {
|
|
#define CHIP_NUM_57800 0x168a
|
|
#define CHIP_NUM_57810 0x168e
|
|
#define CHIP_NUM_57840 0x168d
|
|
+#define CHIP_NUM_57840_4_10 0x16a1
|
|
+#define CHIP_NUM_57840_2_20 0x16a2
|
|
|
|
#define CHIP_IS_E1(bp) (BNX2X_CHIP_NUM(bp) == CHIP_NUM_57710)
|
|
#define CHIP_IS_57711(bp) (BNX2X_CHIP_NUM(bp) == CHIP_NUM_57711)
|
|
@@ -438,7 +440,11 @@ struct client_init_general_data {
|
|
#define CHIP_IS_57712E(bp) (BNX2X_CHIP_NUM(bp) == CHIP_NUM_57712E)
|
|
#define CHIP_IS_57800(bp) (BNX2X_CHIP_NUM(bp) == CHIP_NUM_57800)
|
|
#define CHIP_IS_57810(bp) (BNX2X_CHIP_NUM(bp) == CHIP_NUM_57810)
|
|
-#define CHIP_IS_57840(bp) (BNX2X_CHIP_NUM(bp) == CHIP_NUM_57840)
|
|
+#define CHIP_IS_57840_4_10(bp) (BNX2X_CHIP_NUM(bp) == CHIP_NUM_57840_4_10)
|
|
+#define CHIP_IS_57840_2_20(bp) (BNX2X_CHIP_NUM(bp) == CHIP_NUM_57840_2_20)
|
|
+#define CHIP_IS_57840(bp) (BNX2X_CHIP_NUM(bp) == CHIP_NUM_57840 || \
|
|
+ CHIP_IS_57840_4_10(bp) || \
|
|
+ CHIP_IS_57840_2_20(bp))
|
|
#define CHIP_IS_E1H(bp) (CHIP_IS_57711(bp) || \
|
|
CHIP_IS_57711E(bp))
|
|
#define CHIP_IS_E2(bp) (CHIP_IS_57712(bp) || \
|
|
diff --git a/iscsiuio/src/unix/nic.c b/iscsiuio/src/unix/nic.c
|
|
index 0b3c538..72afff0 100644
|
|
--- a/iscsiuio/src/unix/nic.c
|
|
+++ b/iscsiuio/src/unix/nic.c
|
|
@@ -460,6 +460,7 @@ int nic_remove(nic_t * nic)
|
|
rc = stat(nic->uio_device_name, &file_stat);
|
|
if ((rc == 0) && (nic->ops))
|
|
nic->ops->close(nic, 0);
|
|
+ pthread_mutex_unlock(&nic->nic_mutex);
|
|
|
|
nic->state = NIC_EXIT;
|
|
|
|
@@ -910,7 +911,7 @@ int do_timers_per_nic_iface(nic_t *nic, nic_interface_t *nic_iface,
|
|
if (pkt == NULL)
|
|
return -EIO;
|
|
|
|
- if (nic_iface->ustack.ip_config == AF_INET) {
|
|
+ if (nic_iface->protocol == AF_INET) {
|
|
for (i = 0; i < UIP_UDP_CONNS; i++) {
|
|
prepare_ustack(nic, nic_iface, ustack, pkt);
|
|
|
|
diff --git a/iscsiuio/src/unix/nic_nl.c b/iscsiuio/src/unix/nic_nl.c
|
|
index 34e2062..8afd9ae 100644
|
|
--- a/iscsiuio/src/unix/nic_nl.c
|
|
+++ b/iscsiuio/src/unix/nic_nl.c
|
|
@@ -408,7 +408,7 @@ static int ctldev_handle(char *data, nic_t *nic)
|
|
persist_all_nic_iface(nic);
|
|
|
|
nic_iface = vlan_iface;
|
|
-
|
|
+ nic_iface->flags |= NIC_IFACE_ACQUIRE;
|
|
pthread_mutex_unlock(&nic->nic_mutex);
|
|
|
|
/* nic_disable but not going down */
|
|
--
|
|
1.7.7.4
|
|
|