* [PATCH 15/17] janz: mfd_cell is now implicitly available to drivers
From: Andres Salomon @ 2011-02-12 2:17 UTC (permalink / raw)
To: Samuel Ortiz
Cc: socketcan-core-0fE9KPoRgkgATYTw5x5z8w,
netdev-u79uwXL29TY76Z2rM5mHXA, Mark Brown,
linux-kernel-u79uwXL29TY76Z2rM5mHXA, Wolfgang Grandegger
The cell's platform_data is now accessed with a helper function;
change clients to use that, and remove the now-unused data_size.
Signed-off-by: Andres Salomon <dilinger-pFFUokh25LWsTnJN9+BGXg@public.gmane.org>
---
drivers/gpio/janz-ttl.c | 2 +-
drivers/mfd/janz-cmodio.c | 1 -
drivers/net/can/janz-ican3.c | 2 +-
3 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/gpio/janz-ttl.c b/drivers/gpio/janz-ttl.c
index 813ac07..ef399ee 100644
--- a/drivers/gpio/janz-ttl.c
+++ b/drivers/gpio/janz-ttl.c
@@ -149,7 +149,7 @@ static int __devinit ttl_probe(struct platform_device *pdev)
struct resource *res;
int ret;
- pdata = pdev->dev.platform_data;
+ pdata = mfd_get_data(pdev);
if (!pdata) {
dev_err(dev, "no platform data\n");
ret = -ENXIO;
diff --git a/drivers/mfd/janz-cmodio.c b/drivers/mfd/janz-cmodio.c
index 36a166b..58de1e2 100644
--- a/drivers/mfd/janz-cmodio.c
+++ b/drivers/mfd/janz-cmodio.c
@@ -87,7 +87,6 @@ static int __devinit cmodio_setup_subdevice(struct cmodio_device *priv,
/* Add platform data */
pdata->modno = modno;
cell->platform_data = pdata;
- cell->data_size = sizeof(*pdata);
/* MODULbus registers -- PCI BAR3 is big-endian MODULbus access */
res->flags = IORESOURCE_MEM;
diff --git a/drivers/net/can/janz-ican3.c b/drivers/net/can/janz-ican3.c
index 366f5cc..bc2b15b 100644
--- a/drivers/net/can/janz-ican3.c
+++ b/drivers/net/can/janz-ican3.c
@@ -1643,7 +1643,7 @@ static int __devinit ican3_probe(struct platform_device *pdev)
struct device *dev;
int ret;
- pdata = pdev->dev.platform_data;
+ pdata = mfd_get_data(pdev);
if (!pdata)
return -ENXIO;
--
1.7.2.3
^ permalink raw reply related
* Re: [RFD][PATCH] Add JMEMCMP to Berkeley Packet Filters
From: Paul Mackerras @ 2011-02-12 2:14 UTC (permalink / raw)
To: Ian Molton; +Cc: netdev, rdunlap, isdn, arnd, davem, herbert, ebiederm
In-Reply-To: <1297340087-10963-1-git-send-email-ian.molton@collabora.co.uk>
On Thu, Feb 10, 2011 at 12:14:46PM +0000, Ian Molton wrote:
> This patch implements an extension for BPF to allow filter programs to use a
> data section, along with a MEMCMP instruction.
>
> There are a few issues noted in the patch itself, which can easily be
> addressed, and I would like to check wether sk_run_filter is ever expected to
> be called from a context that cannot sleep (I dont think it is).
The ppp driver (ppp_generic.c) calls sk_run_filter inside a region
protected by spin_lock_bh, so we can't sleep there. Having sk_run_filter
potentially sleep would make it useless for ppp.
Paul.
^ permalink raw reply
* Re: [PATCH 1/2] net: Add RX queue weights
From: Dimitris Michailidis @ 2011-02-12 3:49 UTC (permalink / raw)
To: Tom Herbert; +Cc: davem, netdev
In-Reply-To: <alpine.DEB.2.00.1102111552090.2793@pokey.mtv.corp.google.com>
Tom Herbert wrote:
> This patch adds a weight attribute to the netdev RX queues. This allows
> control over the relative receive packet load for each queue. These
> values are set in sysfs variable 'weight' in the rxq directory for
> a device. When a weight is set, a new netdev operation is called to
> inform the driver of the changed weight. The driver is expected to
> apply the queue weights in a logical manner to the RSS indirection table
> of the device to achieve the desired weighting. The driver
> implementation for this is unspecified.
>
> If a weight for a queue is zero, this effectively disables that queue
> for RSS (but possibly still usable by accelerated RFS, etc.), except
> in the case that all queue weights are zero, then all queues are
> considered equally weighted (the default).
>
> Example configuration:
> echo 1 > /sys/class/net/eth4/queues/rx-0/weight
> echo 1 > /sys/class/net/eth4/queues/rx-1/weight
> echo 5 > /sys/class/net/eth4/queues/rx-2/weight
> echo 0 > /sys/class/net/eth4/queues/rx-3/weight
>
> So rx queue 0 and 1 have equal weight, queue 2 is 5X in weight and
> queue 3 is disabled for RSS.
Doesn't ethtool -X already do this? With the added benefit that ethtool
doesn't need each driver to provide its own weight handling arithmetic.
^ permalink raw reply
* Re: [PATCH net-next 00/15] be2net: patch series
From: David Miller @ 2011-02-12 5:15 UTC (permalink / raw)
To: ajit.khaparde; +Cc: netdev
In-Reply-To: <20110211233215.GA18258@akhaparde-VBox>
From: Ajit Khaparde <ajit.khaparde@emulex.com>
Date: Fri, 11 Feb 2011 17:32:15 -0600
> Patch series for the be2net driver.
>
> [01/15]: While configuring QOS for VF, pass proper domain id
> [02/15]: endianness fix in be_cmd_set_qos().
> [03/15]: Use domain id when be_cmd_if_destroy is called.
> [04/15]: Initialize and cleanup sriov resources only if pci_enable_sriov has succeeded.
> [05/15]: call be_vf_eth_addr_config() after register_netdev
> [06/15]: Cleanup the VF interface handles
> [07/15]: For the VF MAC, use the OUI from current MAC address
> [08/15]: pass domain numbers for pmac_add/del functions
> [09/15]: Allow VFs to call be_cmd_reset_function.
> [10/15]: Fix broken priority setting when vlan tagging is enabled.
> [11/15]: pass proper hdr_size while flashing redboot.
> [12/15]: fix be_suspend/resume/shutdown
> [13/15]: gracefully handle situations when UE is detected
> [14/15]: detect a UE even when a interface is down.
> [15/15]: restrict WOL to PFs only.
>
> Please Apply.
All applied, thanks.
^ permalink raw reply
* Re: [net-next-2.6 v2 00/15][pull request] Intel Wired LAN Driver Updates
From: David Miller @ 2011-02-12 5:15 UTC (permalink / raw)
To: jeffrey.t.kirsher; +Cc: netdev, gospo, bphilips
In-Reply-To: <1297444862-32091-1-git-send-email-jeffrey.t.kirsher@intel.com>
From: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Date: Fri, 11 Feb 2011 09:20:47 -0800
> The following series contains e1000e cleanup patches, the addition of igb
> PF support for i350 devices and several ixgbe cleanup patches.
>
> v2 - drop "e1000e: do not wakeup Tx queue until ready" while Bruce takes a
> second look at the patch.
>
> The following are changes since commit 6431cbc25fa21635ee04eb0516ba6c51389fbfac:
> inet: Create a mechanism for upward inetpeer propagation into routes.
>
> and are available in the git repository at:
> master.kernel.org:/pub/scm/linux/kernel/git/jkirsher/net-next-2.6 master
Pulled, thanks Jeff.
^ permalink raw reply
* Re: [PATCH net-26 1/5] cxgb4vf: Virtual Interfaces are always up ...
From: David Miller @ 2011-02-12 5:19 UTC (permalink / raw)
To: leedom; +Cc: netdev
In-Reply-To: <1297472423-15672-2-git-send-email-leedom@chelsio.com>
From: Casey Leedom <leedom@chelsio.com>
Date: Fri, 11 Feb 2011 17:00:19 -0800
> Implement new default mode of always reporting the Virtual Interface link as
> being "up". This allows different Virtual Interfaces on the same port to
> continue to communicate with each other even when the physical port link is
> down. This new behavior is controlled via the module parameter
> force_link_up (default 1). The old behavior can be achieved by setting
> force_link_up=0.
>
> Signed-off-by: Casey Leedom <leedom@chelsio.com>
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?
^ permalink raw reply
* Re: pull request: batman-adv 2011-02-12
From: David Miller @ 2011-02-12 5:21 UTC (permalink / raw)
To: sven; +Cc: netdev, b.a.t.m.a.n
In-Reply-To: <1297466503-13246-1-git-send-email-sven@narfation.org>
From: Sven Eckelmann <sven@narfation.org>
Date: Sat, 12 Feb 2011 00:21:39 +0100
> Hi,
>
> I would like propose following changes for net-next-2.6.git. Two of them are
> minor code style changes and the other two change minor issues in the
> routing/fragmentation code.
>
> thanks,
> Sven
>
> The following changes since commit 091b948306d2628320e77977eb7ae4a757b12180:
>
> batman-adv: Merge README of v2011.0.0 release (2011-01-31 14:57:13 +0100)
>
> are available in the git repository at:
> git://git.open-mesh.org/ecsv/linux-merge.git batman-adv/next
Pulled, thanks Sven.
^ permalink raw reply
* Re: [PATCH 02/14] net/fec: release mem_region requested in probe in error path and remove
From: David Miller @ 2011-02-12 5:25 UTC (permalink / raw)
To: u.kleine-koenig; +Cc: netdev, shawn.guo, kernel
In-Reply-To: <20110211110339.GH27982@pengutronix.de>
From: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Date: Fri, 11 Feb 2011 12:03:39 +0100
> Hello,
>
> On Fri, Feb 11, 2011 at 11:32:10AM +0100, Uwe Kleine-König wrote:
>> Noticed-by: Lothar Waßmann <LW@KARO-electronics.de>
> I changed that to Reported-by: in this and the other patches.
> (this was Reported-by: Wolfram Sang via irc). The updated patches can
> be found at
>
> git://git.pengutronix.de/git/ukl/linux-2.6.git fec
I can't pull from that tree because it is _NOT_ based upon net-next-2.6
and therefore brings in all kinds of commits not related to your work.
^ permalink raw reply
* Re: [PATCH 2/2 v2] network: Allow af_packet to transmit +4 bytes for VLAN packets.
From: David Miller @ 2011-02-12 5:26 UTC (permalink / raw)
To: eric.dumazet; +Cc: greearb, netdev
In-Reply-To: <1297462718.2510.10.camel@edumazet-laptop>
From: Eric Dumazet <eric.dumazet@gmail.com>
Date: Fri, 11 Feb 2011 23:18:38 +0100
> Le vendredi 11 février 2011 à 11:35 -0800, greearb@candelatech.com a
> écrit :
>> From: Ben Greear <greearb@candelatech.com>
>>
>> This allows user-space to send a '1500' MTU VLAN packet on a
>> 1500 MTU ethernet frame. The extra 4 bytes of a VLAN header is
>> not usually charged against the MTU when other parts of the
>> network stack is transmitting vlans...
>>
>> Signed-off-by: Ben Greear <greearb@candelatech.com>
>> ---
>
> Reviewed-by: Eric Dumazet <eric.dumazet@gmail.com>
Applied to net-next-2.6, thanks.
^ permalink raw reply
* Re: [PATCH 1/2] net: Add RX queue weights
From: Tom Herbert @ 2011-02-12 5:32 UTC (permalink / raw)
To: Dimitris Michailidis; +Cc: davem, netdev
In-Reply-To: <4D560350.5080002@chelsio.com>
> Doesn't ethtool -X already do this? With the added benefit that ethtool doesn't need each driver to provide its own weight handling arithmetic.
>
Indeed. Patches withdrawn.
Tom
^ permalink raw reply
* Re: bridge: Fix mglist corruption that leads to memory corruption
From: David Miller @ 2011-02-12 5:58 UTC (permalink / raw)
To: herbert; +Cc: netdev, ihands, jbacik
In-Reply-To: <20110211225559.GA5922@gondor.apana.org.au>
From: Herbert Xu <herbert@gondor.apana.org.au>
Date: Sat, 12 Feb 2011 09:55:59 +1100
> On Sat, Feb 12, 2011 at 09:36:55AM +1100, Herbert Xu wrote:
>>
>> Normally this would be quite obvious as it would cause an infinite
>> loop when walking the list. However, as this list is never actually
>> walked (which means that we don't really need it, I'll get rid of
>> it in a subsequent patch), this instead is hidden until we perform
>> a delete operation on the affected nodes.
>
> Here is the patch that replaces the mglist hlist with just a bool.
>
> bridge: Replace mp->mglist hlist with a bool
>
> As it turns out we never need to walk through the list of multicast
> groups subscribed by the bridge interface itself (the only time we'd
> want to do that is when we shut down the bridge, in which case we
> simply walk through all multicast groups), we don't really need to
> keep an hlist for mp->mglist.
>
> This means that we can replace it with just a single bit to indicate
> whether the bridge interface is subscribed to a group.
>
> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Well if it's a bool, please use "true" and "false" instead of "1" and
"0" :-)
^ permalink raw reply
* Re: bridge: Fix mglist corruption that leads to memory corruption
From: David Miller @ 2011-02-12 5:59 UTC (permalink / raw)
To: herbert; +Cc: netdev, ihands, jbacik
In-Reply-To: <20110211223655.GA5585@gondor.apana.org.au>
From: Herbert Xu <herbert@gondor.apana.org.au>
Date: Sat, 12 Feb 2011 09:36:55 +1100
> This patch fixes a nasty memory corruption issue.
>
> bridge: Fix mglist corruption that leads to memory corruption
Applied.
^ permalink raw reply
* Re: bridge: Fix mglist corruption that leads to memory corruption
From: David Miller @ 2011-02-12 5:59 UTC (permalink / raw)
To: herbert; +Cc: netdev, ihands, jbacik
In-Reply-To: <20110211224207.GA5715@gondor.apana.org.au>
From: Herbert Xu <herbert@gondor.apana.org.au>
Date: Sat, 12 Feb 2011 09:42:07 +1100
> This patch fixes a typo that is not too serious.
>
> bridge: Fix timer typo that may render snooping less effective
Also applied.
^ permalink raw reply
* Re: bridge: Fix mglist corruption that leads to memory corruption
From: Herbert Xu @ 2011-02-12 6:05 UTC (permalink / raw)
To: David Miller; +Cc: netdev, ihands, jbacik
In-Reply-To: <20110211.215804.15260765.davem@davemloft.net>
On Fri, Feb 11, 2011 at 09:58:04PM -0800, David Miller wrote:
>
> Well if it's a bool, please use "true" and "false" instead of "1" and
> "0" :-)
Serves me right for trying to be green :)
bridge: Replace mp->mglist hlist with a bool
As it turns out we never need to walk through the list of multicast
groups subscribed by the bridge interface itself (the only time we'd
want to do that is when we shut down the bridge, in which case we
simply walk through all multicast groups), we don't really need to
keep an hlist for mp->mglist.
This means that we can replace it with just a single bit to indicate
whether the bridge interface is subscribed to a group.
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
diff --git a/net/bridge/br_input.c b/net/bridge/br_input.c
index 6f6d8e1..88e4aa9 100644
--- a/net/bridge/br_input.c
+++ b/net/bridge/br_input.c
@@ -80,7 +80,7 @@ int br_handle_frame_finish(struct sk_buff *skb)
if (is_multicast_ether_addr(dest)) {
mdst = br_mdb_get(br, skb);
if (mdst || BR_INPUT_SKB_CB_MROUTERS_ONLY(skb)) {
- if ((mdst && !hlist_unhashed(&mdst->mglist)) ||
+ if ((mdst && mdst->mglist) ||
br_multicast_is_router(br))
skb2 = skb;
br_multicast_forward(mdst, skb, skb2);
diff --git a/net/bridge/br_multicast.c b/net/bridge/br_multicast.c
index c558274..30e3a08 100644
--- a/net/bridge/br_multicast.c
+++ b/net/bridge/br_multicast.c
@@ -232,8 +232,7 @@ static void br_multicast_group_expired(unsigned long data)
if (!netif_running(br->dev) || timer_pending(&mp->timer))
goto out;
- if (!hlist_unhashed(&mp->mglist))
- hlist_del_init(&mp->mglist);
+ mp->mglist = false;
if (mp->ports)
goto out;
@@ -276,7 +275,7 @@ static void br_multicast_del_pg(struct net_bridge *br,
del_timer(&p->query_timer);
call_rcu_bh(&p->rcu, br_multicast_free_pg);
- if (!mp->ports && hlist_unhashed(&mp->mglist) &&
+ if (!mp->ports && !mp->mglist &&
netif_running(br->dev))
mod_timer(&mp->timer, jiffies);
@@ -528,7 +527,7 @@ static void br_multicast_group_query_expired(unsigned long data)
struct net_bridge *br = mp->br;
spin_lock(&br->multicast_lock);
- if (!netif_running(br->dev) || hlist_unhashed(&mp->mglist) ||
+ if (!netif_running(br->dev) || !mp->mglist ||
mp->queries_sent >= br->multicast_last_member_count)
goto out;
@@ -719,8 +718,7 @@ static int br_multicast_add_group(struct net_bridge *br,
goto err;
if (!port) {
- if (hlist_unhashed(&mp->mglist))
- hlist_add_head(&mp->mglist, &br->mglist);
+ mp->mglist = true;
mod_timer(&mp->timer, now + br->multicast_membership_interval);
goto out;
}
@@ -1166,7 +1164,7 @@ static int br_ip4_multicast_query(struct net_bridge *br,
max_delay *= br->multicast_last_member_count;
- if (!hlist_unhashed(&mp->mglist) &&
+ if (mp->mglist &&
(timer_pending(&mp->timer) ?
time_after(mp->timer.expires, now + max_delay) :
try_to_del_timer_sync(&mp->timer) >= 0))
@@ -1237,7 +1235,7 @@ static int br_ip6_multicast_query(struct net_bridge *br,
goto out;
max_delay *= br->multicast_last_member_count;
- if (!hlist_unhashed(&mp->mglist) &&
+ if (mp->mglist &&
(timer_pending(&mp->timer) ?
time_after(mp->timer.expires, now + max_delay) :
try_to_del_timer_sync(&mp->timer) >= 0))
@@ -1284,7 +1282,7 @@ static void br_multicast_leave_group(struct net_bridge *br,
br->multicast_last_member_interval;
if (!port) {
- if (!hlist_unhashed(&mp->mglist) &&
+ if (mp->mglist &&
(timer_pending(&mp->timer) ?
time_after(mp->timer.expires, time) :
try_to_del_timer_sync(&mp->timer) >= 0)) {
diff --git a/net/bridge/br_private.h b/net/bridge/br_private.h
index 84aac77..4e1b620 100644
--- a/net/bridge/br_private.h
+++ b/net/bridge/br_private.h
@@ -84,13 +84,13 @@ struct net_bridge_port_group {
struct net_bridge_mdb_entry
{
struct hlist_node hlist[2];
- struct hlist_node mglist;
struct net_bridge *br;
struct net_bridge_port_group __rcu *ports;
struct rcu_head rcu;
struct timer_list timer;
struct timer_list query_timer;
struct br_ip addr;
+ bool mglist;
u32 queries_sent;
};
@@ -238,7 +238,6 @@ struct net_bridge
spinlock_t multicast_lock;
struct net_bridge_mdb_htable __rcu *mdb;
struct hlist_head router_list;
- struct hlist_head mglist;
struct timer_list multicast_router_timer;
struct timer_list multicast_querier_timer;
Cheers,
--
Email: Herbert Xu <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
^ permalink raw reply related
* [PATCH -next/mmotm] net/can: fix softing build errors
From: Randy Dunlap @ 2011-02-12 6:33 UTC (permalink / raw)
To: akpm, netdev; +Cc: linux-kernel, davem, Kurt Van Dijck
In-Reply-To: <201102110100.p1B10sDx029244@imap1.linux-foundation.org>
From: Randy Dunlap <randy.dunlap@oracle.com>
Fix can/softing build errors due to kconfig error.
kconfig tells us about a problem...
warning: (CAN_SOFTING_CS) selects CAN_SOFTING which has unmet direct dependencies (NET && CAN && CAN_DEV && HAS_IOMEM)
and then this is what happens due to that kconfig problem:
ERROR: "register_candev" [drivers/net/can/softing/softing.ko] undefined!
ERROR: "alloc_candev" [drivers/net/can/softing/softing.ko] undefined!
ERROR: "can_bus_off" [drivers/net/can/softing/softing.ko] undefined!
ERROR: "close_candev" [drivers/net/can/softing/softing.ko] undefined!
ERROR: "free_candev" [drivers/net/can/softing/softing.ko] undefined!
ERROR: "unregister_candev" [drivers/net/can/softing/softing.ko] undefined!
ERROR: "alloc_can_skb" [drivers/net/can/softing/softing.ko] undefined!
ERROR: "open_candev" [drivers/net/can/softing/softing.ko] undefined!
with this partial config:
CONFIG_CAN=m
# CONFIG_CAN_RAW is not set
# CONFIG_CAN_BCM is not set
# CAN Device Drivers
# CONFIG_CAN_VCAN is not set
CONFIG_CAN_SLCAN=m
# CONFIG_CAN_DEV is not set
CONFIG_CAN_SOFTING=m
CONFIG_CAN_SOFTING_CS=m
# CONFIG_CAN_DEBUG_DEVICES is not set
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Cc: Kurt Van Dijck <kurt.van.dijck@eia.be>
---
drivers/net/can/softing/Kconfig | 1 +
1 file changed, 1 insertion(+)
--- mmotm-2011-0210-1626.orig/drivers/net/can/softing/Kconfig
+++ mmotm-2011-0210-1626/drivers/net/can/softing/Kconfig
@@ -18,6 +18,7 @@ config CAN_SOFTING
config CAN_SOFTING_CS
tristate "Softing Gmbh CAN pcmcia cards"
depends on PCMCIA
+ depends on CAN_DEV && HAS_IOMEM
select CAN_SOFTING
---help---
Support for PCMCIA cards from Softing Gmbh & some cards
^ permalink raw reply
* Re: [PATCH net-26 4/5] cxgb4vf: Quiesce Virtual Interfaces on shutdown ...
From: Anirban Chakraborty @ 2011-02-12 7:17 UTC (permalink / raw)
To: Casey Leedom; +Cc: netdev@vger.kernel.org, davem@davemloft.net
In-Reply-To: <1297472423-15672-5-git-send-email-leedom@chelsio.com>
On Feb 11, 2011, at 5:00 PM, Casey Leedom wrote:
> 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 daac6ed..f78d6e1 100644
> --- a/drivers/net/cxgb4vf/cxgb4vf_main.c
> +++ b/drivers/net/cxgb4vf/cxgb4vf_main.c
> @@ -2886,6 +2886,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) \
> @@ -2918,6 +2958,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
You could invoke pci_reset_function as an alternative, that would make sure FLR happens.
-Anirban
This message and any attached documents contain information from QLogic Corporation or its wholly-owned subsidiaries that may be confidential. If you are not the intended recipient, you may not read, copy, distribute, or use this information. If you have received this transmission in error, please notify the sender immediately by reply e-mail and then delete this message.
^ permalink raw reply
* Re: bridge: Fix mglist corruption that leads to memory corruption
From: David Miller @ 2011-02-12 9:06 UTC (permalink / raw)
To: herbert; +Cc: netdev, ihands, jbacik
In-Reply-To: <20110212060538.GA911@gondor.apana.org.au>
From: Herbert Xu <herbert@gondor.apana.org.au>
Date: Sat, 12 Feb 2011 17:05:38 +1100
> On Fri, Feb 11, 2011 at 09:58:04PM -0800, David Miller wrote:
>>
>> Well if it's a bool, please use "true" and "false" instead of "1" and
>> "0" :-)
>
> Serves me right for trying to be green :)
>
> bridge: Replace mp->mglist hlist with a bool
:-) Applied.
^ permalink raw reply
* [patch net-next-2.6] net: remove the unnecessary dance around skb_bond_should_drop
From: Jiri Pirko @ 2011-02-12 10:46 UTC (permalink / raw)
To: netdev; +Cc: davem
No need to check (master) twice and to drive in and out the header file.
Signed-off-by: Jiri Pirko <jpirko@redhat.com>
---
include/linux/netdevice.h | 11 -----------
net/core/dev.c | 6 +++---
2 files changed, 3 insertions(+), 14 deletions(-)
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
index c7d7074..5a5baea 100644
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
@@ -2437,17 +2437,6 @@ static inline void netif_set_gso_max_size(struct net_device *dev,
dev->gso_max_size = size;
}
-extern int __skb_bond_should_drop(struct sk_buff *skb,
- struct net_device *master);
-
-static inline int skb_bond_should_drop(struct sk_buff *skb,
- struct net_device *master)
-{
- if (master)
- return __skb_bond_should_drop(skb, master);
- return 0;
-}
-
extern struct pernet_operations __net_initdata loopback_net_ops;
static inline int dev_ethtool_get_settings(struct net_device *dev,
diff --git a/net/core/dev.c b/net/core/dev.c
index 6392ea0..d874fd1 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -3105,7 +3105,8 @@ static inline void skb_bond_set_mac_by_master(struct sk_buff *skb,
* duplicates except for 802.3ad ETH_P_SLOW, alb non-mcast/bcast, and
* ARP on active-backup slaves with arp_validate enabled.
*/
-int __skb_bond_should_drop(struct sk_buff *skb, struct net_device *master)
+static int __skb_bond_should_drop(struct sk_buff *skb,
+ struct net_device *master)
{
struct net_device *dev = skb->dev;
@@ -3139,7 +3140,6 @@ int __skb_bond_should_drop(struct sk_buff *skb, struct net_device *master)
}
return 0;
}
-EXPORT_SYMBOL(__skb_bond_should_drop);
static int __netif_receive_skb(struct sk_buff *skb)
{
@@ -3177,7 +3177,7 @@ static int __netif_receive_skb(struct sk_buff *skb)
if (skb->deliver_no_wcard)
null_or_orig = orig_dev;
else if (master) {
- if (skb_bond_should_drop(skb, master)) {
+ if (__skb_bond_should_drop(skb, master)) {
skb->deliver_no_wcard = 1;
null_or_orig = orig_dev; /* deliver only exact match */
} else
--
1.7.3.4
^ permalink raw reply related
* Re: [PATCH -next/mmotm] net/can: fix softing build errors
From: Kurt Van Dijck @ 2011-02-12 11:15 UTC (permalink / raw)
To: Randy Dunlap; +Cc: akpm, netdev, linux-kernel, davem
In-Reply-To: <20110211223312.be571303.randy.dunlap@oracle.com>
On Fri, Feb 11, 2011 at 10:33:12PM -0800, Randy Dunlap wrote:
>
> warning: (CAN_SOFTING_CS) selects CAN_SOFTING which has unmet direct dependencies (NET && CAN && CAN_DEV && HAS_IOMEM)
>
> with this partial config:
>
> CONFIG_CAN=m
> # CONFIG_CAN_RAW is not set
> # CONFIG_CAN_BCM is not set
> # CAN Device Drivers
> # CONFIG_CAN_VCAN is not set
> CONFIG_CAN_SLCAN=m
> # CONFIG_CAN_DEV is not set
> CONFIG_CAN_SOFTING=m
> CONFIG_CAN_SOFTING_CS=m
> # CONFIG_CAN_DEBUG_DEVICES is not set
I understand the output, but I don't understand the cause well enough.
CAN_SOFTING=m has a 'depends on CAN_DEV'
Is it then possible to have CAN_SOFTING=m _and not_ CAN_DEV ?
>
regards,
Kurt
^ permalink raw reply
* Re: any way to reset all marked connections when using CONNMARK?
From: Andrew Beverley @ 2011-02-12 11:42 UTC (permalink / raw)
To: Chris Friesen; +Cc: netdev, netfilter-devel, netfilter
In-Reply-To: <4D55A927.7060703@genband.com>
On Fri, 2011-02-11 at 15:24 -0600, Chris Friesen wrote:
> It has been proposed to add a custom patch to clear the mark for all
> marked connections--is there a better way of doing this?
>
How about using the conntrack userspace command-line interface?
conntrack -U -m 0
looks like it should do what you want.
Andy
^ permalink raw reply
* Re: [RFD][PATCH] Add JMEMCMP to Berkeley Packet Filters
From: Ian Molton @ 2011-02-12 12:47 UTC (permalink / raw)
To: Paul Mackerras; +Cc: netdev, rdunlap, isdn, arnd, davem, herbert, ebiederm
In-Reply-To: <20110212021441.GA3035@sammy.paulus.ozlabs.org>
On 12/02/11 02:14, Paul Mackerras wrote:
> On Thu, Feb 10, 2011 at 12:14:46PM +0000, Ian Molton wrote:
>
>> This patch implements an extension for BPF to allow filter programs to use a
>> data section, along with a MEMCMP instruction.
>>
>> There are a few issues noted in the patch itself, which can easily be
>> addressed, and I would like to check wether sk_run_filter is ever expected to
>> be called from a context that cannot sleep (I dont think it is).
>
> The ppp driver (ppp_generic.c) calls sk_run_filter inside a region
> protected by spin_lock_bh, so we can't sleep there. Having sk_run_filter
> potentially sleep would make it useless for ppp.
Thanks for the review.
I'll fix it not to sleep :)
Do I take it from the lack of people comlpaining that the concept of
adding this type of instruction itself is not a problem ?
Thanks!
-Ian
^ permalink raw reply
* Re: [patch net-next-2.6] net: remove the unnecessary dance around skb_bond_should_drop
From: Nicolas de Pesloüan @ 2011-02-12 12:51 UTC (permalink / raw)
To: Jiri Pirko; +Cc: netdev, davem
In-Reply-To: <20110212104605.GA2786@psychotron.redhat.com>
Le 12/02/2011 11:46, Jiri Pirko a écrit :
> No need to check (master) twice and to drive in and out the header file.
>
> Signed-off-by: Jiri Pirko<jpirko@redhat.com>
Reviewed-by: Nicolas de Pesloüan <nicolas.2p.debian@free.fr>
> ---
> include/linux/netdevice.h | 11 -----------
> net/core/dev.c | 6 +++---
> 2 files changed, 3 insertions(+), 14 deletions(-)
>
> diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
> index c7d7074..5a5baea 100644
> --- a/include/linux/netdevice.h
> +++ b/include/linux/netdevice.h
> @@ -2437,17 +2437,6 @@ static inline void netif_set_gso_max_size(struct net_device *dev,
> dev->gso_max_size = size;
> }
>
> -extern int __skb_bond_should_drop(struct sk_buff *skb,
> - struct net_device *master);
> -
> -static inline int skb_bond_should_drop(struct sk_buff *skb,
> - struct net_device *master)
> -{
> - if (master)
> - return __skb_bond_should_drop(skb, master);
> - return 0;
> -}
> -
> extern struct pernet_operations __net_initdata loopback_net_ops;
>
> static inline int dev_ethtool_get_settings(struct net_device *dev,
> diff --git a/net/core/dev.c b/net/core/dev.c
> index 6392ea0..d874fd1 100644
> --- a/net/core/dev.c
> +++ b/net/core/dev.c
> @@ -3105,7 +3105,8 @@ static inline void skb_bond_set_mac_by_master(struct sk_buff *skb,
> * duplicates except for 802.3ad ETH_P_SLOW, alb non-mcast/bcast, and
> * ARP on active-backup slaves with arp_validate enabled.
> */
> -int __skb_bond_should_drop(struct sk_buff *skb, struct net_device *master)
> +static int __skb_bond_should_drop(struct sk_buff *skb,
> + struct net_device *master)
> {
> struct net_device *dev = skb->dev;
>
> @@ -3139,7 +3140,6 @@ int __skb_bond_should_drop(struct sk_buff *skb, struct net_device *master)
> }
> return 0;
> }
> -EXPORT_SYMBOL(__skb_bond_should_drop);
>
> static int __netif_receive_skb(struct sk_buff *skb)
> {
> @@ -3177,7 +3177,7 @@ static int __netif_receive_skb(struct sk_buff *skb)
> if (skb->deliver_no_wcard)
> null_or_orig = orig_dev;
> else if (master) {
> - if (skb_bond_should_drop(skb, master)) {
> + if (__skb_bond_should_drop(skb, master)) {
> skb->deliver_no_wcard = 1;
> null_or_orig = orig_dev; /* deliver only exact match */
> } else
^ permalink raw reply
* Re: [patch net-next-2.6 3/4] bond: implement slave management operations
From: Nicolas de Pesloüan @ 2011-02-12 13:16 UTC (permalink / raw)
To: Jiri Pirko; +Cc: netdev, davem, shemminger, kaber, fubar
In-Reply-To: <20110211152257.GC2763@psychotron.brq.redhat.com>
Le 11/02/2011 16:22, Jiri Pirko a écrit :
>
> Signed-off-by: Jiri Pirko<jpirko@redhat.com>
> ---
> drivers/net/bonding/bond_main.c | 38 ++++++++++++++++++++++++++++++++++++++
> 1 files changed, 38 insertions(+), 0 deletions(-)
>
> diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c
> index 1df9f0e..f8e59f9 100644
> --- a/drivers/net/bonding/bond_main.c
> +++ b/drivers/net/bonding/bond_main.c
> @@ -4285,6 +4285,40 @@ unwind:
> return res;
> }
>
> +static int bond_add_slave(struct net_device *bond_dev,
> + struct net_device *slave_dev)
> +{
> + return bond_enslave(bond_dev, slave_dev);
> +}
> +
> +static int bond_del_slave(struct net_device *bond_dev,
> + struct net_device *slave_dev)
> +{
> + return bond_release(bond_dev, slave_dev);
> +}
> +
Hi Jiri,
Why did you add another level of function nesting (bond_add_slave() and bond_del_slave()) instead of
using bond_enslave() and bond_release() directly in the structure below ?
The function prototypes are identical.
Or may be, rename bond_enslave() to bond_add_slave() and bond_release() to bond_del_slave(), for
consistency.
> + .ndo_add_slave = bond_add_slave,
> + .ndo_del_slave = bond_del_slave,
> + .ndo_get_slave_count = bond_get_slave_count,
> + .ndo_get_slave = bond_get_slave,
Nicolas.
^ permalink raw reply
* Re: [patch net-next-2.6 3/4] bond: implement slave management operations
From: Jiri Pirko @ 2011-02-12 13:20 UTC (permalink / raw)
To: Nicolas de Pesloüan; +Cc: netdev, davem, shemminger, kaber, fubar
In-Reply-To: <4D568822.3010402@gmail.com>
Sat, Feb 12, 2011 at 02:16:18PM CET, nicolas.2p.debian@gmail.com wrote:
>Le 11/02/2011 16:22, Jiri Pirko a écrit :
>>
>>Signed-off-by: Jiri Pirko<jpirko@redhat.com>
>>---
>> drivers/net/bonding/bond_main.c | 38 ++++++++++++++++++++++++++++++++++++++
>> 1 files changed, 38 insertions(+), 0 deletions(-)
>>
>>diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c
>>index 1df9f0e..f8e59f9 100644
>>--- a/drivers/net/bonding/bond_main.c
>>+++ b/drivers/net/bonding/bond_main.c
>>@@ -4285,6 +4285,40 @@ unwind:
>> return res;
>> }
>>
>>+static int bond_add_slave(struct net_device *bond_dev,
>>+ struct net_device *slave_dev)
>>+{
>>+ return bond_enslave(bond_dev, slave_dev);
>>+}
>>+
>>+static int bond_del_slave(struct net_device *bond_dev,
>>+ struct net_device *slave_dev)
>>+{
>>+ return bond_release(bond_dev, slave_dev);
>>+}
>>+
>
>Hi Jiri,
>
>Why did you add another level of function nesting (bond_add_slave()
>and bond_del_slave()) instead of using bond_enslave() and
>bond_release() directly in the structure below ?
>
>The function prototypes are identical.
>
>Or may be, rename bond_enslave() to bond_add_slave() and
>bond_release() to bond_del_slave(), for consistency.
Yes you are right - I did it in bonding by copy & paste code I did in
bridge and I didn't see that here it isn't necessary... Will remake this
in respin patchset.
Thanks.
Jirka
>
>>+ .ndo_add_slave = bond_add_slave,
>>+ .ndo_del_slave = bond_del_slave,
>>+ .ndo_get_slave_count = bond_get_slave_count,
>>+ .ndo_get_slave = bond_get_slave,
>
> Nicolas.
^ permalink raw reply
* Re: [PATCH net-next-2.6 v7 1/1] can: c_can: Added support for Bosch C_CAN controller
From: Wolfgang Grandegger @ 2011-02-12 14:24 UTC (permalink / raw)
To: Bhupesh Sharma
Cc: Socketcan-core-0fE9KPoRgkgATYTw5x5z8w,
netdev-u79uwXL29TY76Z2rM5mHXA
In-Reply-To: <1297419478-27667-1-git-send-email-bhupesh.sharma-qxv4g6HH51o@public.gmane.org>
On 02/11/2011 11:17 AM, Bhupesh Sharma wrote:
> Bosch C_CAN controller is a full-CAN implementation which is compliant
> to CAN protocol version 2.0 part A and B. Bosch C_CAN user manual can be
> obtained from:
> http://www.semiconductors.bosch.de/media/en/pdf/ipmodules_1/
> c_can/users_manual_c_can.pdf
>
> This patch adds the support for this controller.
> The following are the design choices made while writing the controller
> driver:
> 1. Interface Register set IF1 has be used only in the current design.
> 2. Out of the 32 Message objects available, 16 are kept aside for RX
> purposes and the rest for TX purposes.
> 3. NAPI implementation is such that both the TX and RX paths function
> in polling mode.
>
> Signed-off-by: Bhupesh Sharma <bhupesh.sharma-qxv4g6HH51o@public.gmane.org>
> ---
> Changes since V6:
> 1. Added check for calling netif_stop_queue() in case next TX object
> is busy.
> 2. Added logic *not* to copy data to rx'ed RTR frames.
> 3. Moved enums, defines and structs present in c_can.h file to the respective
> c-file where they are actually used.
> 4. Corrected message object busy status routine by using a better name
> and design approach.
> 5. Moved *set_bittiming* call to the *c_can_chip_config* function.
Acked-by: Wolfgang Grandegger <wg-5Yr1BZd7O62+XT7JhA+gdA@public.gmane.org>
Thanks for your contribution. As soon as the patch is accepted, I will
send a patch for the PCH CAN.
Wolfgang.
^ permalink raw reply
page: next (older) | prev (newer) | latest
- recent:[subjects (threaded)|topics (new)|topics (active)]
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox