Netdev List
 help / color / mirror / Atom feed
* [PATCH net-26 3/4] cxgb4vf: Quiesce Virtual Interfaces on shutdown ...
From: Casey Leedom @ 2011-02-14 22:56 UTC (permalink / raw)
  To: netdev; +Cc: davem, Casey Leedom
In-Reply-To: <1297724185-27452-1-git-send-email-leedom@chelsio.com>

When a Virtual Machine is rebooted, KVM currently fails to issue a Function
Level Reset against any "Attached PCI Devices" (AKA "PCI Passthrough").  In
addition to leaving the attached device in a random state in the next booted
kernel (which sort of violates the entire idea of a reboot reseting hardware
state), this leaves our peer thinking that the link is still up.  (Note that
a bug has been filed with the KVM folks, #25332, but there's been no
response on that as of yet.)  So, we add a "->shutdown()" method for the
Virtual Function PCI Device to handle administrative shutdowns like a
reboot.

Signed-off-by: Casey Leedom <leedom@chelsio.com>
---
 drivers/net/cxgb4vf/cxgb4vf_main.c |   41 ++++++++++++++++++++++++++++++++++++
 1 files changed, 41 insertions(+), 0 deletions(-)

diff --git a/drivers/net/cxgb4vf/cxgb4vf_main.c b/drivers/net/cxgb4vf/cxgb4vf_main.c
index 2be1088..6aad64d 100644
--- a/drivers/net/cxgb4vf/cxgb4vf_main.c
+++ b/drivers/net/cxgb4vf/cxgb4vf_main.c
@@ -2862,6 +2862,46 @@ static void __devexit cxgb4vf_pci_remove(struct pci_dev *pdev)
 }
 
 /*
+ * "Shutdown" quiesce the device, stopping Ingress Packet and Interrupt
+ * delivery.
+ */
+static void __devexit cxgb4vf_pci_shutdown(struct pci_dev *pdev)
+{
+	struct adapter *adapter;
+	int pidx;
+
+	adapter = pci_get_drvdata(pdev);
+	if (!adapter)
+		return;
+
+	/*
+	 * Disable all Virtual Interfaces.  This will shut down the
+	 * delivery of all ingress packets into the chip for these
+	 * Virtual Interfaces.
+	 */
+	for_each_port(adapter, pidx) {
+		struct net_device *netdev;
+		struct port_info *pi;
+
+		if (!test_bit(pidx, &adapter->registered_device_map))
+			continue;
+
+		netdev = adapter->port[pidx];
+		if (!netdev)
+			continue;
+
+		pi = netdev_priv(netdev);
+		t4vf_enable_vi(adapter, pi->viid, false, false);
+	}
+
+	/*
+	 * Free up all Queues which will prevent further DMA and
+	 * Interrupts allowing various internal pathways to drain.
+	 */
+	t4vf_free_sge_resources(adapter);
+}
+
+/*
  * PCI Device registration data structures.
  */
 #define CH_DEVICE(devid, idx) \
@@ -2894,6 +2934,7 @@ static struct pci_driver cxgb4vf_driver = {
 	.id_table	= cxgb4vf_pci_tbl,
 	.probe		= cxgb4vf_pci_probe,
 	.remove		= __devexit_p(cxgb4vf_pci_remove),
+	.shutdown	= __devexit_p(cxgb4vf_pci_shutdown),
 };
 
 /*
-- 
1.7.0.4


^ permalink raw reply related

* [PATCH net-26 2/4] cxgb4vf: Behave properly when CONFIG_DEBUG_FS isn't defined ...
From: Casey Leedom @ 2011-02-14 22:56 UTC (permalink / raw)
  To: netdev; +Cc: davem, Casey Leedom
In-Reply-To: <1297724185-27452-1-git-send-email-leedom@chelsio.com>

When CONFIG_DEBUG_FS we get "ERR_PTR()"s back from the debugfs routines
instead of NULL.  Use the right predicates to check for this.

Signed-off-by: Casey Leedom <leedom@chelsio.com>
---
 drivers/net/cxgb4vf/cxgb4vf_main.c |   16 ++++++++--------
 1 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/drivers/net/cxgb4vf/cxgb4vf_main.c b/drivers/net/cxgb4vf/cxgb4vf_main.c
index 072b64e..2be1088 100644
--- a/drivers/net/cxgb4vf/cxgb4vf_main.c
+++ b/drivers/net/cxgb4vf/cxgb4vf_main.c
@@ -2040,7 +2040,7 @@ static int __devinit setup_debugfs(struct adapter *adapter)
 {
 	int i;
 
-	BUG_ON(adapter->debugfs_root == NULL);
+	BUG_ON(IS_ERR_OR_NULL(adapter->debugfs_root));
 
 	/*
 	 * Debugfs support is best effort.
@@ -2061,7 +2061,7 @@ static int __devinit setup_debugfs(struct adapter *adapter)
  */
 static void cleanup_debugfs(struct adapter *adapter)
 {
-	BUG_ON(adapter->debugfs_root == NULL);
+	BUG_ON(IS_ERR_OR_NULL(adapter->debugfs_root));
 
 	/*
 	 * Unlike our sister routine cleanup_proc(), we don't need to remove
@@ -2700,11 +2700,11 @@ static int __devinit cxgb4vf_pci_probe(struct pci_dev *pdev,
 	/*
 	 * Set up our debugfs entries.
 	 */
-	if (cxgb4vf_debugfs_root) {
+	if (!IS_ERR_OR_NULL(cxgb4vf_debugfs_root)) {
 		adapter->debugfs_root =
 			debugfs_create_dir(pci_name(pdev),
 					   cxgb4vf_debugfs_root);
-		if (adapter->debugfs_root == NULL)
+		if (IS_ERR_OR_NULL(adapter->debugfs_root))
 			dev_warn(&pdev->dev, "could not create debugfs"
 				 " directory");
 		else
@@ -2759,7 +2759,7 @@ static int __devinit cxgb4vf_pci_probe(struct pci_dev *pdev,
 	 */
 
 err_free_debugfs:
-	if (adapter->debugfs_root) {
+	if (!IS_ERR_OR_NULL(adapter->debugfs_root)) {
 		cleanup_debugfs(adapter);
 		debugfs_remove_recursive(adapter->debugfs_root);
 	}
@@ -2828,7 +2828,7 @@ static void __devexit cxgb4vf_pci_remove(struct pci_dev *pdev)
 		/*
 		 * Tear down our debugfs entries.
 		 */
-		if (adapter->debugfs_root) {
+		if (!IS_ERR_OR_NULL(adapter->debugfs_root)) {
 			cleanup_debugfs(adapter);
 			debugfs_remove_recursive(adapter->debugfs_root);
 		}
@@ -2916,12 +2916,12 @@ static int __init cxgb4vf_module_init(void)
 
 	/* Debugfs support is optional, just warn if this fails */
 	cxgb4vf_debugfs_root = debugfs_create_dir(KBUILD_MODNAME, NULL);
-	if (!cxgb4vf_debugfs_root)
+	if (IS_ERR_OR_NULL(cxgb4vf_debugfs_root))
 		printk(KERN_WARNING KBUILD_MODNAME ": could not create"
 		       " debugfs entry, continuing\n");
 
 	ret = pci_register_driver(&cxgb4vf_driver);
-	if (ret < 0)
+	if (ret < 0 && !IS_ERR_OR_NULL(cxgb4vf_debugfs_root))
 		debugfs_remove(cxgb4vf_debugfs_root);
 	return ret;
 }
-- 
1.7.0.4


^ permalink raw reply related

* [PATCH net-26 1/4] cxgb4vf: Check driver parameters in the right place ...
From: Casey Leedom @ 2011-02-14 22:56 UTC (permalink / raw)
  To: netdev; +Cc: davem, Casey Leedom
In-Reply-To: <1297724185-27452-1-git-send-email-leedom@chelsio.com>

Check module parameter validity in the module initialization routine instead
of the PCI Device Probe routine.

Signed-off-by: Casey Leedom <leedom@chelsio.com>
---
 drivers/net/cxgb4vf/cxgb4vf_main.c |   23 +++++++++++------------
 1 files changed, 11 insertions(+), 12 deletions(-)

diff --git a/drivers/net/cxgb4vf/cxgb4vf_main.c b/drivers/net/cxgb4vf/cxgb4vf_main.c
index 56166ae..072b64e 100644
--- a/drivers/net/cxgb4vf/cxgb4vf_main.c
+++ b/drivers/net/cxgb4vf/cxgb4vf_main.c
@@ -2489,17 +2489,6 @@ static int __devinit cxgb4vf_pci_probe(struct pci_dev *pdev,
 	struct net_device *netdev;
 
 	/*
-	 * Vet our module parameters.
-	 */
-	if (msi != MSI_MSIX && msi != MSI_MSI) {
-		dev_err(&pdev->dev, "bad module parameter msi=%d; must be %d"
-			" (MSI-X or MSI) or %d (MSI)\n", msi, MSI_MSIX,
-			MSI_MSI);
-		err = -EINVAL;
-		goto err_out;
-	}
-
-	/*
 	 * Print our driver banner the first time we're called to initialize a
 	 * device.
 	 */
@@ -2802,7 +2791,6 @@ err_release_regions:
 err_disable_device:
 	pci_disable_device(pdev);
 
-err_out:
 	return err;
 }
 
@@ -2915,6 +2903,17 @@ static int __init cxgb4vf_module_init(void)
 {
 	int ret;
 
+	/*
+	 * Vet our module parameters.
+	 */
+	if (msi != MSI_MSIX && msi != MSI_MSI) {
+		printk(KERN_WARNING KBUILD_MODNAME
+		       ": bad module parameter msi=%d; must be %d"
+		       " (MSI-X or MSI) or %d (MSI)\n",
+		       msi, MSI_MSIX, MSI_MSI);
+		return -EINVAL;
+	}
+
 	/* Debugfs support is optional, just warn if this fails */
 	cxgb4vf_debugfs_root = debugfs_create_dir(KBUILD_MODNAME, NULL);
 	if (!cxgb4vf_debugfs_root)
-- 
1.7.0.4


^ permalink raw reply related

* [PATCH net-26 0/4] cxgb4vf: minor bug fixes -- revised patch set
From: Casey Leedom @ 2011-02-14 22:56 UTC (permalink / raw)
  To: netdev; +Cc: davem

  This is the same as the previous patch set but with the unacceptable patch
removed.  Let me know if there's anything else I should do.  Thanks and
sorry for not know the rules about that unacceptable patch.

[01/04]: Check driver parameters in the right place ...
[02/04]: Behave properly when CONFIG_DEBUG_FS isn't defined ...
[03/04]: Quiesce Virtual Interfaces on shutdown ...
[04/04]: Use defined Mailbox Timeout

 drivers/net/cxgb4vf/cxgb4vf_main.c |   80 +++++++++++++++++++++++++++---------
 drivers/net/cxgb4vf/t4vf_hw.c      |    2 +-
 2 files changed, 61 insertions(+), 21 deletions(-)


^ permalink raw reply

* [PATCH net-26 4/4] cxgb4vf: Use defined Mailbox Timeout
From: Casey Leedom @ 2011-02-14 22:56 UTC (permalink / raw)
  To: netdev; +Cc: davem, Casey Leedom
In-Reply-To: <1297724185-27452-1-git-send-email-leedom@chelsio.com>

VF Driver should use mailbox command timeout specified in t4fw_interface.h
rather than hard-coded value of 500ms.

Signed-off-by: Casey Leedom <leedom@chelsio.com>
---
 drivers/net/cxgb4vf/t4vf_hw.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/cxgb4vf/t4vf_hw.c b/drivers/net/cxgb4vf/t4vf_hw.c
index 0f51c80..192db22 100644
--- a/drivers/net/cxgb4vf/t4vf_hw.c
+++ b/drivers/net/cxgb4vf/t4vf_hw.c
@@ -171,7 +171,7 @@ int t4vf_wr_mbox_core(struct adapter *adapter, const void *cmd, int size,
 	delay_idx = 0;
 	ms = delay[0];
 
-	for (i = 0; i < 500; i += ms) {
+	for (i = 0; i < FW_CMD_MAX_TIMEOUT; i += ms) {
 		if (sleep_ok) {
 			ms = delay[delay_idx];
 			if (delay_idx < ARRAY_SIZE(delay) - 1)
-- 
1.7.0.4


^ permalink raw reply related

* Re: [PATCH][trivial] Batman: Remove two duplicate includes.
From: Sven Eckelmann @ 2011-02-14 22:44 UTC (permalink / raw)
  To: Jesper Juhl
  Cc: trivial-DgEjT+Ai2ygdnm+yROfE0A, netdev-u79uwXL29TY76Z2rM5mHXA,
	b.a.t.m.a.n-ZwoEplunGu2X36UT3dwllkB+6BGkLq7r,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA, Simon Wunderlich,
	Marek Lindner, David S. Miller
In-Reply-To: <alpine.LNX.2.00.1102142335331.4530-h2p7t3/P30RzeRGmFJ5qR7ZzlVVXadcDXqFh9Ls21Oc@public.gmane.org>

[-- Attachment #1: Type: Text/Plain, Size: 189 bytes --]

On Monday 14 February 2011 23:38:18 Jesper Juhl wrote:
> Remove duplicate inclusion of "send.h" and "routing.h" from
> net/batman-adv/soft-interface.c

Applied, thanks

Best regards,
	Sven

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply

* [PATCH][trivial] Batman: Remove two duplicate includes.
From: Jesper Juhl @ 2011-02-14 22:38 UTC (permalink / raw)
  To: b.a.t.m.a.n-ZwoEplunGu2X36UT3dwllkB+6BGkLq7r
  Cc: trivial-DgEjT+Ai2ygdnm+yROfE0A, netdev-u79uwXL29TY76Z2rM5mHXA,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA, Simon Wunderlich,
	Marek Lindner, David S. Miller

Remove duplicate inclusion of "send.h" and "routing.h" from net/batman-adv/soft-interface.c

Patch is against linux-next as of today.

Signed-off-by: Jesper Juhl <jj-IYz4IdjRLj0sV2N9l4h3zg@public.gmane.org>
---
 soft-interface.c |    2 --
 1 file changed, 2 deletions(-)

diff --git a/net/batman-adv/soft-interface.c b/net/batman-adv/soft-interface.c
index bd088f8..7e37077 100644
--- a/net/batman-adv/soft-interface.c
+++ b/net/batman-adv/soft-interface.c
@@ -29,14 +29,12 @@
 #include "hash.h"
 #include "gateway_common.h"
 #include "gateway_client.h"
-#include "send.h"
 #include "bat_sysfs.h"
 #include <linux/slab.h>
 #include <linux/ethtool.h>
 #include <linux/etherdevice.h>
 #include <linux/if_vlan.h>
 #include "unicast.h"
-#include "routing.h"
 
 
 static int bat_get_settings(struct net_device *dev, struct ethtool_cmd *cmd);


-- 
Jesper Juhl <jj-IYz4IdjRLj0sV2N9l4h3zg@public.gmane.org>            http://www.chaosbits.net/
Plain text mails only, please.
Don't top-post http://www.catb.org/~esr/jargon/html/T/top-post.html

^ permalink raw reply related

* Re: [PATCH net-26 1/5] cxgb4vf: Virtual Interfaces are always up ...
From: David Miller @ 2011-02-14 22:34 UTC (permalink / raw)
  To: leedom; +Cc: netdev
In-Reply-To: <201102141431.32535.leedom@chelsio.com>

From: Casey Leedom <leedom@chelsio.com>
Date: Mon, 14 Feb 2011 14:31:32 -0800

> | From: Casey Leedom <leedom@chelsio.com>
> | Date: Monday, February 14, 2011 11:13 am
> | 
> | | No driver specific module parameters!  Add something generic and common
> | | so other drivers can use it too.
> | | 
> | | Otherwise every user has to learn a different way to control this
> | | attribute, depending upon the device type, which is rediculious.
> | | 
> | | How many times do we have to tell driver authors this?
> | 
> |   Sorry.  I wasn't aware of this rule.  My bad.  Is this writeen down
> | somewhere under Documentation?  I'm not being snarky.  I really would like
> | to know so I can read through the general ground rules and avoid making
> | more mistakes in the future.
> | 
> |   As for a generic mechanism, what's the preferred way of doing this?  A
> | new ethtool flag?  Sorry for being a doofus here, I'm happy to follow
> | whatever the accepted standard is.  Thanks for your time and patience.
> 
>   Also, I assume then the the entire patch series is now rejected, right?  And 
> that I should resubmit the patch series without the unacceptable module 
> parameter, right?  I'm just trying to figure out what I need to do next.  

You need to resubmit the whole series, because changing an earlier
patch causes the subsequent ones to have, at a minimum, offsets which
GIT apply will reject.

^ permalink raw reply

* Re: [PATCH net-26 1/5] cxgb4vf: Virtual Interfaces are always up ...
From: Casey Leedom @ 2011-02-14 22:31 UTC (permalink / raw)
  To: David Miller; +Cc: netdev
In-Reply-To: <201102141113.58068.leedom@chelsio.com>

| From: Casey Leedom <leedom@chelsio.com>
| Date: Monday, February 14, 2011 11:13 am
| 
| | No driver specific module parameters!  Add something generic and common
| | so other drivers can use it too.
| | 
| | Otherwise every user has to learn a different way to control this
| | attribute, depending upon the device type, which is rediculious.
| | 
| | How many times do we have to tell driver authors this?
| 
|   Sorry.  I wasn't aware of this rule.  My bad.  Is this writeen down
| somewhere under Documentation?  I'm not being snarky.  I really would like
| to know so I can read through the general ground rules and avoid making
| more mistakes in the future.
| 
|   As for a generic mechanism, what's the preferred way of doing this?  A
| new ethtool flag?  Sorry for being a doofus here, I'm happy to follow
| whatever the accepted standard is.  Thanks for your time and patience.

  Also, I assume then the the entire patch series is now rejected, right?  And 
that I should resubmit the patch series without the unacceptable module 
parameter, right?  I'm just trying to figure out what I need to do next.  
Thanks.

Casey

^ permalink raw reply

* Re: [PATCH -next] PCI: fix tlan build when CONFIG_PCI is not enabled
From: Sakari Ailus @ 2011-02-14 22:02 UTC (permalink / raw)
  To: Randy Dunlap
  Cc: Stephen Rothwell, netdev, linux-pci, linux-next, LKML, davem,
	Jesse Barnes
In-Reply-To: <4D599F60.4010800@iki.fi>

Sakari Ailus wrote:
> Randy Dunlap wrote:
>> From: Randy Dunlap<randy.dunlap@oracle.com>
>>
>> When CONFIG_PCI is not enabled, tlan.c has a build error:
>> drivers/net/tlan.c:503: error: implicit declaration of function 'pci_wake_from_d3'
>>
>> so add an inline function stub for this function to pci.h when
>> PCI is not enabled, similar to other stubbed PCI functions.
>>
>> Signed-off-by: Randy Dunlap<randy.dunlap@oracle.com>
>> Cc: Sakari Ailus<sakari.ailus@iki.fi>
>
> Hi Randy,
>
> I think this issue in tlan driver was caused by my recent patch which
> added the suspend/resume support to tlan:
>
> <URL:http://marc.info/?l=linux-netdev&m=129564436110754&w=3>
>
> There apparently are tlan cards which are EISA (not PCI) which I forgot
> when writing the patch. The suspend/resume has been only tested with PCI
> as I have no EISA bus (let alone EISA tlan card!).

Right; so I suppose there's no PM support in EISA anyway. Other pci 
functions appear to be no-ops when CONFIG_PCI isn't defined so this 
patch seems right to me --- and no changes are needed in the tlan driver.

Acked-by: Sakari Ailus <sakari.ailus@iki.fi>

-- 
Sakari Ailus
sakari.ailus@iki.fi

^ permalink raw reply

* Re: [PATCH] pch_gbe: Fix the MAC Address load issue.
From: David Miller @ 2011-02-14 21:37 UTC (permalink / raw)
  To: toshiharu-linux
  Cc: netdev, tomoya-linux, linux-kernel, qi.wang, yong.y.wang,
	andrew.chih.howe.khor, joel.clark, kok.howg.ewe
In-Reply-To: <4D58ED2A.9050706@dsn.okisemi.com>

From: Toshiharu Okada <toshiharu-linux@dsn.okisemi.com>
Date: Mon, 14 Feb 2011 17:51:54 +0900

> With the specification of hardware,
> the processing at the time of driver starting was modified.
> 
> This device write automatically the MAC address read from serial ROM
> into a MAC Adress1A/1B register at the time of power on reset.
> However, when stable clock is not supplied,
> the writing of MAC Adress1A/1B register may not be completed.
> In this case, it is necessary to load MAC address to MAC Address1A/1B register
> by the MAC Address1 load register.
> 
> This patch always does the above processing,
> in order not to be dependent on system environment.
> 
> Signed-off-by: Toshiharu Okada <toshiharu-linux@dsn.okisemi.com>

Applied.

^ permalink raw reply

* Re: [PATCH] [ROSE] AX25 packet routing improvement
From: David Miller @ 2011-02-14 21:35 UTC (permalink / raw)
  To: bernard.pidoux; +Cc: netdev, ralf, f6bvp
In-Reply-To: <4D596BC9.4030509@upmc.fr>

From: Bernard Pidoux <bernard.pidoux@upmc.fr>
Date: Mon, 14 Feb 2011 18:52:09 +0100

> [PATCH] [ROSE] [AX25] finding routes simplification
> 
> With previous patch, rose_get_neigh() routine
> investigates the full list of neighbor nodes
> until it finds or not an already connected node whether
> it is called locally or through a level 3 transit frame.
> If no routes are opened through an adjacent connected node
> then a classical connect request is attempted.
> 
> Then there is no more reason for an extra loop such
> as the one removed by this patch.
> 
> Signed-off-by: Bernard Pidoux <f6bvp@free.fr>

Also applied to net-next-2.6, thanks!

^ permalink raw reply

* Re: [PATCH] [ROSE] packet routing improvement
From: David Miller @ 2011-02-14 21:33 UTC (permalink / raw)
  To: bpidoux; +Cc: netdev, ralf, f6bvp
In-Reply-To: <4D596B25.9080309@free.fr>

From: Bernard Pidoux <bpidoux@free.fr>
Date: Mon, 14 Feb 2011 18:49:25 +0100

> [PATCH] [ROSE] rose AX25 packet routing improvement
> 
> FPAC AX25 packet application is using Linux kernel ROSE
> routing skills in order to connect or send packets to remote stations
> knowing their ROSE address via a network of interconnected nodes.
> 
> Each FPAC node has a ROSE routing table that Linux ROSE module is
> looking at each time a ROSE frame is relayed by the node or when
> a connect request to a neighbor node is received.
> 
> A previous patch improved the system time response by looking at
> already established routes each time the system was looking for a
> route to relay a frame. If a neighbor node routing the destination
> address was already connected, then the frame would be sent
> through him. If not, a connection request would be issued.
> 
> The present patch extends the same routing capability to a connect
> request asked by a user locally connected into an FPAC node.
> Without this patch, a connect request was not well handled unless it
> was directed to an immediate connected neighbor of the local node.
> 
> Implemented at a number of ROSE FPAC node stations, the present patch
> improved dramatically FPAC ROSE routing time response and efficiency.
> 
> Signed-off-by: Bernard Pidoux <f6bvp@free.fr>

Applied to net-next-2.6


^ permalink raw reply

* Re: [PATCH -next] PCI: fix tlan build when CONFIG_PCI is not enabled
From: Sakari Ailus @ 2011-02-14 21:32 UTC (permalink / raw)
  To: Randy Dunlap
  Cc: Stephen Rothwell, netdev, linux-pci, linux-next, LKML, davem,
	Jesse Barnes
In-Reply-To: <20110214122750.e1e03bc8.randy.dunlap@oracle.com>

Randy Dunlap wrote:
> From: Randy Dunlap <randy.dunlap@oracle.com>
> 
> When CONFIG_PCI is not enabled, tlan.c has a build error:
> drivers/net/tlan.c:503: error: implicit declaration of function 'pci_wake_from_d3'
> 
> so add an inline function stub for this function to pci.h when
> PCI is not enabled, similar to other stubbed PCI functions.
> 
> Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
> Cc: Sakari Ailus <sakari.ailus@iki.fi>

Hi Randy,

I think this issue in tlan driver was caused by my recent patch which
added the suspend/resume support to tlan:

<URL:http://marc.info/?l=linux-netdev&m=129564436110754&w=3>

There apparently are tlan cards which are EISA (not PCI) which I forgot
when writing the patch. The suspend/resume has been only tested with PCI
as I have no EISA bus (let alone EISA tlan card!).

I'm going to send a fix to the tlan driver in any case.

Regards,

-- 
Sakari Ailus
sakari.ailus@iki.fi

^ permalink raw reply

* Re: pull request: wireless-2.6 2011-02-14
From: David Miller @ 2011-02-14 21:28 UTC (permalink / raw)
  To: johannes; +Cc: linville, linux-wireless, netdev, linux-kernel
In-Reply-To: <1297717942.3953.9.camel@jlt3.sipsolutions.net>

From: Johannes Berg <johannes@sipsolutions.net>
Date: Mon, 14 Feb 2011 22:12:22 +0100

> On Mon, 2011-02-14 at 13:00 -0800, David Miller wrote:
> 
>> Please address this newly introduced warning in a future pull request,
>> thanks:
>> 
>> drivers/net/wireless/iwlwifi/iwl-3945.c:411:13: warning: 'iwl3945_good_plcp_health' defined but not used
> 
> The function can simply be deleted.

Done.

^ permalink raw reply

* Re: pull request: wireless-2.6 2011-02-14
From: Johannes Berg @ 2011-02-14 21:12 UTC (permalink / raw)
  To: David Miller; +Cc: linville, linux-wireless, netdev, linux-kernel
In-Reply-To: <20110214.130056.115934219.davem@davemloft.net>

On Mon, 2011-02-14 at 13:00 -0800, David Miller wrote:

> Please address this newly introduced warning in a future pull request,
> thanks:
> 
> drivers/net/wireless/iwlwifi/iwl-3945.c:411:13: warning: 'iwl3945_good_plcp_health' defined but not used

The function can simply be deleted.

johannes

^ permalink raw reply

* Re: pull request: wireless-2.6 2011-02-14
From: David Miller @ 2011-02-14 21:00 UTC (permalink / raw)
  To: linville; +Cc: linux-wireless, netdev, linux-kernel
In-Reply-To: <20110214.125148.59672184.davem@davemloft.net>

From: David Miller <davem@davemloft.net>
Date: Mon, 14 Feb 2011 12:51:48 -0800 (PST)

> From: "John W. Linville" <linville@tuxdriver.com>
> Date: Mon, 14 Feb 2011 15:44:06 -0500
> 
>> A handful of fixes intended for 2.6.38...
>> 
>> This includes a couple of bluetooth device IDs, a bluetooth one-liner
>> to avoid multiple connection responses, a locking fix to avoid some
>> log spam, and a patch to turn off PCLP health checking for iwl3945
>> (because the checking has not proven helpful and it kills performance).
>> 
>> Please let me know if there are problems!
> 
> Pulled, thanks John.

Please address this newly introduced warning in a future pull request,
thanks:

drivers/net/wireless/iwlwifi/iwl-3945.c:411:13: warning: 'iwl3945_good_plcp_health' defined but not used

^ permalink raw reply

* Re: pull request: wireless-2.6 2011-02-14
From: David Miller @ 2011-02-14 20:51 UTC (permalink / raw)
  To: linville; +Cc: linux-wireless, netdev, linux-kernel
In-Reply-To: <20110214204406.GG2722@tuxdriver.com>

From: "John W. Linville" <linville@tuxdriver.com>
Date: Mon, 14 Feb 2011 15:44:06 -0500

> A handful of fixes intended for 2.6.38...
> 
> This includes a couple of bluetooth device IDs, a bluetooth one-liner
> to avoid multiple connection responses, a locking fix to avoid some
> log spam, and a patch to turn off PCLP health checking for iwl3945
> (because the checking has not proven helpful and it kills performance).
> 
> Please let me know if there are problems!

Pulled, thanks John.

^ permalink raw reply

* net.ipv6.route.max_size
From: Lukasz Trabinski @ 2011-02-14 20:39 UTC (permalink / raw)
  To: netdev

Hello

IPv6 route table size is still growing. In stanard linux box configuration
with IPv6 BGP session (with ipv6 world table) and BGP application like Quagga,
we have problem like this:

2011/02/12 18:43:52 ZEBRA: netlink-cmd error: Cannot allocate memory,
type=RTM_NEWROUTE(24), seq=11124600, pid=0

This problem shows us that's all prefixes comes from BGP can't be install into 
FIB

IN BGP application we can see, that's we recive 4484 prefixes from ipv6 
neighbor:

cosmos> show bgp summary
Neighbor        V    AS MsgRcvd MsgSent   TblVer  InQ OutQ Up/Down State/PfxRcd
2001:1a68:0:c::1
                 4 24724  431945   70172        0    0    0 2d01h18m     4484


I suggest that net->ipv6.sysctl.ip6_rt_max_size should be increase.
Below _simple_ patch for this problem. I don't understand why in ipv4/route we 
have different method to count ip4_rt_max_size? My value 65536 in near future 
will be also wrong. I know also, that we can change it by sysctl, but I thing 
that it's not good way to fix it.


--- route.c~    2011-02-08 01:03:55.000000000 +0100
+++ route.c     2011-02-14 20:48:53.000000000 +0100
@@ -2708,7 +2708,7 @@
  #endif

         net->ipv6.sysctl.flush_delay = 0;
-       net->ipv6.sysctl.ip6_rt_max_size = 4096;
+       net->ipv6.sysctl.ip6_rt_max_size = 65536;
         net->ipv6.sysctl.ip6_rt_gc_min_interval = HZ / 2;
         net->ipv6.sysctl.ip6_rt_gc_timeout = 60*HZ;
         net->ipv6.sysctl.ip6_rt_gc_interval = 30*HZ;


^ permalink raw reply

* pull request: wireless-2.6 2011-02-14
From: John W. Linville @ 2011-02-14 20:44 UTC (permalink / raw)
  To: davem; +Cc: linux-wireless, netdev, linux-kernel

Dave,

A handful of fixes intended for 2.6.38...

This includes a couple of bluetooth device IDs, a bluetooth one-liner
to avoid multiple connection responses, a locking fix to avoid some
log spam, and a patch to turn off PCLP health checking for iwl3945
(because the checking has not proven helpful and it kills performance).

Please let me know if there are problems!

Thanks,

John

---

The following changes since commit ddfdb508866b3c07b295f6c85c271981d88afe4c:

  net/can/softing: make CAN_SOFTING_CS depend on CAN_SOFTING (2011-02-14 11:44:01 -0800)

are available in the git repository at:
  git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6.git master

Bao Liang (1):
      Bluetooth: Set conn state to BT_DISCONN to avoid multiple responses

Cho, Yu-Chen (1):
      Bluetooth: add Atheros BT AR9285 fw supported

Eliad Peller (1):
      mac80211: add missing locking in ieee80211_reconfig

John W. Linville (1):
      Merge branch 'master' of git://git.kernel.org/.../padovan/bluetooth-2.6

Stanislaw Gruszka (1):
      iwl3945: remove plcp check

 drivers/bluetooth/ath3k.c               |    2 ++
 drivers/bluetooth/btusb.c               |    3 +++
 drivers/net/wireless/iwlwifi/iwl-3945.c |    1 -
 net/bluetooth/l2cap.c                   |    1 +
 net/mac80211/util.c                     |    2 ++
 5 files changed, 8 insertions(+), 1 deletions(-)

diff --git a/drivers/bluetooth/ath3k.c b/drivers/bluetooth/ath3k.c
index a126e61..333c212 100644
--- a/drivers/bluetooth/ath3k.c
+++ b/drivers/bluetooth/ath3k.c
@@ -39,6 +39,8 @@ static struct usb_device_id ath3k_table[] = {
 	/* Atheros AR3011 with sflash firmware*/
 	{ USB_DEVICE(0x0CF3, 0x3002) },
 
+	/* Atheros AR9285 Malbec with sflash firmware */
+	{ USB_DEVICE(0x03F0, 0x311D) },
 	{ }	/* Terminating entry */
 };
 
diff --git a/drivers/bluetooth/btusb.c b/drivers/bluetooth/btusb.c
index 1da773f..4cefa91 100644
--- a/drivers/bluetooth/btusb.c
+++ b/drivers/bluetooth/btusb.c
@@ -102,6 +102,9 @@ static struct usb_device_id blacklist_table[] = {
 	/* Atheros 3011 with sflash firmware */
 	{ USB_DEVICE(0x0cf3, 0x3002), .driver_info = BTUSB_IGNORE },
 
+	/* Atheros AR9285 Malbec with sflash firmware */
+	{ USB_DEVICE(0x03f0, 0x311d), .driver_info = BTUSB_IGNORE },
+
 	/* Broadcom BCM2035 */
 	{ USB_DEVICE(0x0a5c, 0x2035), .driver_info = BTUSB_WRONG_SCO_MTU },
 	{ USB_DEVICE(0x0a5c, 0x200a), .driver_info = BTUSB_WRONG_SCO_MTU },
diff --git a/drivers/net/wireless/iwlwifi/iwl-3945.c b/drivers/net/wireless/iwlwifi/iwl-3945.c
index a9b852b..3eb14fd 100644
--- a/drivers/net/wireless/iwlwifi/iwl-3945.c
+++ b/drivers/net/wireless/iwlwifi/iwl-3945.c
@@ -2734,7 +2734,6 @@ static struct iwl_lib_ops iwl3945_lib = {
 	.isr_ops = {
 		.isr = iwl_isr_legacy,
 	},
-	.check_plcp_health = iwl3945_good_plcp_health,
 
 	.debugfs_ops = {
 		.rx_stats_read = iwl3945_ucode_rx_stats_read,
diff --git a/net/bluetooth/l2cap.c b/net/bluetooth/l2cap.c
index 7550abb..675614e 100644
--- a/net/bluetooth/l2cap.c
+++ b/net/bluetooth/l2cap.c
@@ -859,6 +859,7 @@ static void __l2cap_sock_close(struct sock *sk, int reason)
 				result = L2CAP_CR_SEC_BLOCK;
 			else
 				result = L2CAP_CR_BAD_PSM;
+			sk->sk_state = BT_DISCONN;
 
 			rsp.scid   = cpu_to_le16(l2cap_pi(sk)->dcid);
 			rsp.dcid   = cpu_to_le16(l2cap_pi(sk)->scid);
diff --git a/net/mac80211/util.c b/net/mac80211/util.c
index cf68700..d036597 100644
--- a/net/mac80211/util.c
+++ b/net/mac80211/util.c
@@ -1210,7 +1210,9 @@ int ieee80211_reconfig(struct ieee80211_local *local)
 		switch (sdata->vif.type) {
 		case NL80211_IFTYPE_STATION:
 			changed |= BSS_CHANGED_ASSOC;
+			mutex_lock(&sdata->u.mgd.mtx);
 			ieee80211_bss_info_change_notify(sdata, changed);
+			mutex_unlock(&sdata->u.mgd.mtx);
 			break;
 		case NL80211_IFTYPE_ADHOC:
 			changed |= BSS_CHANGED_IBSS;
-- 
John W. Linville		Someday the world will need a hero, and you
linville@tuxdriver.com			might be all we have.  Be ready.

^ permalink raw reply related

* Re: [PATCH -next] PCI: fix tlan build when CONFIG_PCI is not enabled
From: David Miller @ 2011-02-14 20:39 UTC (permalink / raw)
  To: randy.dunlap
  Cc: sfr, netdev, linux-pci, linux-next, linux-kernel, jbarnes,
	sakari.ailus
In-Reply-To: <20110214122750.e1e03bc8.randy.dunlap@oracle.com>

From: Randy Dunlap <randy.dunlap@oracle.com>
Date: Mon, 14 Feb 2011 12:27:50 -0800

> From: Randy Dunlap <randy.dunlap@oracle.com>
> 
> When CONFIG_PCI is not enabled, tlan.c has a build error:
> drivers/net/tlan.c:503: error: implicit declaration of function 'pci_wake_from_d3'
> 
> so add an inline function stub for this function to pci.h when
> PCI is not enabled, similar to other stubbed PCI functions.
> 
> Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
> Cc: Sakari Ailus <sakari.ailus@iki.fi>

Acked-by: David S. Miller <davem@davemloft.net>

^ permalink raw reply

* [PATCH -next] PCI: fix tlan build when CONFIG_PCI is not enabled
From: Randy Dunlap @ 2011-02-14 20:27 UTC (permalink / raw)
  To: Stephen Rothwell, netdev, linux-pci
  Cc: linux-next, LKML, davem, Jesse Barnes, Sakari Ailus
In-Reply-To: <20110214181137.ee8d4c08.sfr@canb.auug.org.au>

From: Randy Dunlap <randy.dunlap@oracle.com>

When CONFIG_PCI is not enabled, tlan.c has a build error:
drivers/net/tlan.c:503: error: implicit declaration of function 'pci_wake_from_d3'

so add an inline function stub for this function to pci.h when
PCI is not enabled, similar to other stubbed PCI functions.

Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Cc: Sakari Ailus <sakari.ailus@iki.fi>
---
 include/linux/pci.h |    5 +++++
 1 file changed, 5 insertions(+)

--- linux-next-20110214.orig/include/linux/pci.h
+++ linux-next-20110214/include/linux/pci.h
@@ -1191,6 +1191,11 @@ static inline int pci_set_power_state(st
 	return 0;
 }
 
+static inline int pci_wake_from_d3(struct pci_dev *dev, bool enable)
+{
+	return 0;
+}
+
 static inline pci_power_t pci_choose_state(struct pci_dev *dev,
 					   pm_message_t state)
 {

^ permalink raw reply

* Re: [Bugme-new] [Bug 29122] New: r6040: interface status messaged logged once per second
From: Andrew Morton @ 2011-02-14 20:15 UTC (permalink / raw)
  To: netdev; +Cc: bugzilla-daemon, bugme-daemon, signtalk000, Florian Fainelli
In-Reply-To: <bug-29122-10286@https.bugzilla.kernel.org/>


(switched to email.  Please respond via emailed reply-to-all, not via the
bugzilla web interface).

On Mon, 14 Feb 2011 19:39:50 GMT
bugzilla-daemon@bugzilla.kernel.org wrote:

> https://bugzilla.kernel.org/show_bug.cgi?id=29122
> 
>            Summary: r6040: interface status messaged logged once per
>                     second
>            Product: Drivers
>            Version: 2.5
>     Kernel Version: 2.6.35.10
>           Platform: All
>         OS/Version: Linux
>               Tree: Mainline
>             Status: NEW
>           Severity: normal
>           Priority: P1
>          Component: Network
>         AssignedTo: drivers_network@kernel-bugs.osdl.org
>         ReportedBy: signtalk000@aol.com
>         Regression: No
> 
> 
> In the following patch by Florian Fainelli - 2010-05-16, the added call to
> mii_check_media() has the "printit" flag, the 2nd parameter, set which causes a
> status message to be logged once per second.
> 
> diff --git a/drivers/net/r6040.c b/drivers/net/r6040.c
> index 4122916..eeee379 100644
> --- a/drivers/net/r6040.c
> +++ b/drivers/net/r6040.c
> @@ -400,9 +400,6 @@  static void r6040_init_mac_regs(struct net_device *dev)
>       * we may got called by r6040_tx_timeout which has left
>       * some unsent tx buffers */
>      iowrite16(0x01, ioaddr + MTPR);
> -
> -    /* Check media */
> -    mii_check_media(&lp->mii_if, 1, 1);
>  }
> 
>  static void r6040_tx_timeout(struct net_device *dev)
> @@ -530,8 +527,6 @@  static int r6040_phy_mode_chk(struct net_device *dev)
>              phy_dat = 0x0000;
>      }
> 
> -    mii_check_media(&lp->mii_if, 0, 1);
> -
>      return phy_dat;
>  };
> 
> @@ -813,6 +808,9 @@  static void r6040_timer(unsigned long data)
> 
>      /* Timer active again */
>      mod_timer(&lp->timer, round_jiffies(jiffies + HZ));
> +
> +    /* Check media */
> +    mii_check_media(&lp->mii_if, 1, 1);
>  }
> 
>  /* Read/set MAC address routines */
> 


^ permalink raw reply

* Re: [PATCH] net/can/softing: make CAN_SOFTING_CS depend on CAN_SOFTING
From: David Miller @ 2011-02-14 19:44 UTC (permalink / raw)
  To: kurt.van.dijck; +Cc: randy.dunlap, akpm, netdev, linux-kernel
In-Reply-To: <20110214075507.GB374@e-circ.dyndns.org>

From: Kurt Van Dijck <kurt.van.dijck@eia.be>
Date: Mon, 14 Feb 2011 08:55:07 +0100

> The statement 'select CAN_SOFTING' may ignore the dependancies
> for CAN_SOFTING while selecting CAN_SOFTING_CS, as is therefore a bad choice.
> 
> Signed-off-by: Kurt Van Dijck <kurt.van.dijck@eia.be>
> Acked-by: Randy Dunlap <randy.dunlap@oracle.com>

Applied, thanks.

^ permalink raw reply

* Re: [Bugme-new] [Bug 27212] New: Warning kmemcheck: Caught 64-bit read from uninitialized memory in netlink_broadcast_filtered
From: David Miller @ 2011-02-14 19:43 UTC (permalink / raw)
  To: eric.dumazet
  Cc: penberg, akpm, netdev, bugzilla-daemon, bugme-daemon,
	casteyde.christian, xiaosuo, vegardno, linux-kernel
In-Reply-To: <1297704922.2996.60.camel@edumazet-laptop>

From: Eric Dumazet <eric.dumazet@gmail.com>
Date: Mon, 14 Feb 2011 18:35:22 +0100

> Le vendredi 21 janvier 2011 à 09:49 +0200, Pekka Enberg a écrit :
> 
>> It actually looks like a bug in SLUB+kmemcheck. The 
>> kmemcheck_slab_alloc() call in slab_post_alloc_hook() should use ksize() 
>> instead of s->objsize. SLAB seems to do the right thing already. Anyone 
>> care to send a patch my way?
>> 
> 
> Hmm, what do you think of following patch ?
> 
> Thanks, and sorry for the delay.
> 
> [PATCH] slub: fix kmemcheck calls to match ksize() hints
> 
> Recent use of ksize() in network stack (commit ca44ac38 : net: don't
> reallocate skb->head unless the current one hasn't the needed extra size
> or is shared) triggers kmemcheck warnings, because ksize() can return
> more space than kmemcheck is aware of.
> 
> Pekka Enberg noticed SLAB+kmemcheck is doing the right thing, while SLUB
> +kmemcheck doesnt.
> 
> Bugzilla reference #27212
> 
> Reported-by: Christian Casteyde <casteyde.christian@free.fr>
> Suggested-by: Pekka Enberg <penberg@kernel.org>
> Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>

Acked-by: David S. Miller <davem@davemloft.net>

^ permalink raw reply


This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox