* Re: [patch net-next-2.6 5/6 v2] bonding: get rid of IFF_SLAVE_INACTIVE netdev->priv_flag
From: David Miller @ 2011-03-16 19:52 UTC (permalink / raw)
To: jpirko
Cc: netdev, shemminger, kaber, fubar, eric.dumazet, nicolas.2p.debian,
andy, xiaosuo
In-Reply-To: <20110316184642.GB15224@psychotron.redhat.com>
From: Jiri Pirko <jpirko@redhat.com>
Date: Wed, 16 Mar 2011 19:46:43 +0100
> Since bond-related code was moved from net/core/dev.c into bonding,
> IFF_SLAVE_INACTIVE is no longer needed. Replace is with flag "inactive"
> stored in slave structure
>
> Signed-off-by: Jiri Pirko <jpirko@redhat.com>
> Reviewed-by: Nicolas de Pesloüan <nicolas.2p.debian@free.fr>
Applied.
^ permalink raw reply
* Re: [patch net-next-2.6 4/6] bonding: wrap slave state work
From: David Miller @ 2011-03-16 19:52 UTC (permalink / raw)
To: jpirko
Cc: netdev, shemminger, kaber, fubar, eric.dumazet, nicolas.2p.debian,
andy, xiaosuo
In-Reply-To: <1299935679-18135-5-git-send-email-jpirko@redhat.com>
From: Jiri Pirko <jpirko@redhat.com>
Date: Sat, 12 Mar 2011 14:14:37 +0100
> transfers slave->state into slave->backup (that it's going to transfer
> into bitfield. Introduce wrapper inlines to do the work with it.
>
> Signed-off-by: Jiri Pirko <jpirko@redhat.com>
> Reviewed-by: Nicolas de Pesloüan <nicolas.2p.debian@free.fr>
Applied.
^ permalink raw reply
* Re: [patch net-next-2.6 3/6 v2] net: get rid of multiple bond-related netdevice->priv_flags
From: David Miller @ 2011-03-16 19:52 UTC (permalink / raw)
To: jpirko
Cc: netdev, shemminger, kaber, fubar, eric.dumazet, nicolas.2p.debian,
andy, xiaosuo
In-Reply-To: <20110316184522.GA15224@psychotron.redhat.com>
From: Jiri Pirko <jpirko@redhat.com>
Date: Wed, 16 Mar 2011 19:45:23 +0100
> Now when bond-related code is moved from net/core/dev.c into bonding
> code, multiple priv_flags are not needed anymore. So let them rot.
>
> Signed-off-by: Jiri Pirko <jpirko@redhat.com>
> Reviewed-by: Nicolas de Pesloüan <nicolas.2p.debian@free.fr>
Applied.
^ permalink raw reply
* Re: [patch net-next-2.6 2/6] bonding: register slave pointer for rx_handler
From: David Miller @ 2011-03-16 19:52 UTC (permalink / raw)
To: jpirko
Cc: netdev, shemminger, kaber, fubar, eric.dumazet, nicolas.2p.debian,
andy, xiaosuo
In-Reply-To: <1299935679-18135-3-git-send-email-jpirko@redhat.com>
From: Jiri Pirko <jpirko@redhat.com>
Date: Sat, 12 Mar 2011 14:14:35 +0100
> Register slave pointer as rx_handler data. That would eventually prevent
> need to loop over slave devices to find the right slave.
>
> Use synchronize_net to ensure that bond_handle_frame does not get slave
> structure freed when working with that.
>
> Signed-off-by: Jiri Pirko <jpirko@redhat.com>
> Reviewed-by: Nicolas de Pesloüan <nicolas.2p.debian@free.fr>
Applied.
^ permalink raw reply
* [RFC] netfilter: get rid of atomic ops in fast path
From: Eric Dumazet @ 2011-03-16 19:00 UTC (permalink / raw)
To: Patrick McHardy
Cc: Netfilter Development Mailinglist, netdev, Jesper Dangaard Brouer
We currently use a percpu spinlock to 'protect' rule bytes/packets
counters, after various attempts to use RCU instead.
Lately we added a seqlock so that get_counters() can run without
blocking BH or 'writers'. But we really use the seqcount in it.
Spinlock itself is only locked by the current cpu, so we can remove it
completely.
This cleanups api, using correct 'writer' vs 'reader' semantic.
At replace time, the get_counters() call makes sure all cpus are done
using the old table.
We could probably avoid blocking BH (we currently block them in xmit
path), but thats a different topic ;)
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
---
This is a POC patch (based on net-next-2.6), only handling ip_tables.
ip6/arp/... need similar changes.
include/linux/netfilter/x_tables.h | 77 ++++++++-------------------
net/ipv4/netfilter/ip_tables.c | 27 +++------
net/netfilter/x_tables.c | 9 +--
3 files changed, 39 insertions(+), 74 deletions(-)
diff --git a/include/linux/netfilter/x_tables.h b/include/linux/netfilter/x_tables.h
index 3721952..5b13fa5 100644
--- a/include/linux/netfilter/x_tables.h
+++ b/include/linux/netfilter/x_tables.h
@@ -457,71 +457,42 @@ extern struct xt_table_info *xt_alloc_table_info(unsigned int size);
extern void xt_free_table_info(struct xt_table_info *info);
/*
- * Per-CPU spinlock associated with per-cpu table entries, and
- * with a counter for the "reading" side that allows a recursive
- * reader to avoid taking the lock and deadlocking.
- *
- * "reading" is used by ip/arp/ip6 tables rule processing which runs per-cpu.
- * It needs to ensure that the rules are not being changed while the packet
- * is being processed. In some cases, the read lock will be acquired
- * twice on the same CPU; this is okay because of the count.
- *
- * "writing" is used when reading counters.
- * During replace any readers that are using the old tables have to complete
- * before freeing the old table. This is handled by the write locking
- * necessary for reading the counters.
+ * xt_recseq is a recursive seqcount
+ *
+ * Packet processing changes the seqcount only if no recursion happened
+ * get_counters() can use read_seqcount_begin()/read_seqcount_retry()
*/
-struct xt_info_lock {
- seqlock_t lock;
- unsigned char readers;
-};
-DECLARE_PER_CPU(struct xt_info_lock, xt_info_locks);
+DECLARE_PER_CPU(seqcount_t, xt_recseq);
-/*
- * Note: we need to ensure that preemption is disabled before acquiring
- * the per-cpu-variable, so we do it as a two step process rather than
- * using "spin_lock_bh()".
+/** xt_write_recseq_begin - start of a write section
*
- * We _also_ need to disable bottom half processing before updating our
- * nesting count, to make sure that the only kind of re-entrancy is this
- * code being called by itself: since the count+lock is not an atomic
- * operation, we can allow no races.
- *
- * _Only_ that special combination of being per-cpu and never getting
- * re-entered asynchronously means that the count is safe.
+ * Begin packet processing : all readers must wait the end
+ * Must be called with BH off
*/
-static inline void xt_info_rdlock_bh(void)
+static inline seqcount_t *xt_write_recseq_begin(void)
{
- struct xt_info_lock *lock;
+ seqcount_t *s;
- local_bh_disable();
- lock = &__get_cpu_var(xt_info_locks);
- if (likely(!lock->readers++))
- write_seqlock(&lock->lock);
-}
+ s = &__get_cpu_var(xt_recseq);
-static inline void xt_info_rdunlock_bh(void)
-{
- struct xt_info_lock *lock = &__get_cpu_var(xt_info_locks);
+ if (s->sequence & 1)
+ return NULL;
- if (likely(!--lock->readers))
- write_sequnlock(&lock->lock);
- local_bh_enable();
+ write_seqcount_begin(s);
+ return s;
}
-/*
- * The "writer" side needs to get exclusive access to the lock,
- * regardless of readers. This must be called with bottom half
- * processing (and thus also preemption) disabled.
+/** xt_write_recseq_end - end of a write section
+ *
+ * @seq: pointer to seqcount or NULL, return value from xt_write_recseq_begin
+ *
+ * End packet processing : all readers can proceed
+ * Must be called with BH off
*/
-static inline void xt_info_wrlock(unsigned int cpu)
-{
- write_seqlock(&per_cpu(xt_info_locks, cpu).lock);
-}
-
-static inline void xt_info_wrunlock(unsigned int cpu)
+static inline void xt_write_recseq_end(seqcount_t *seq)
{
- write_sequnlock(&per_cpu(xt_info_locks, cpu).lock);
+ if (seq)
+ write_seqcount_end(seq);
}
/*
diff --git a/net/ipv4/netfilter/ip_tables.c b/net/ipv4/netfilter/ip_tables.c
index b09ed0d..af5cf4a 100644
--- a/net/ipv4/netfilter/ip_tables.c
+++ b/net/ipv4/netfilter/ip_tables.c
@@ -68,15 +68,6 @@ void *ipt_alloc_initial_table(const struct xt_table *info)
}
EXPORT_SYMBOL_GPL(ipt_alloc_initial_table);
-/*
- We keep a set of rules for each CPU, so we can avoid write-locking
- them in the softirq when updating the counters and therefore
- only need to read-lock in the softirq; doing a write_lock_bh() in user
- context stops packets coming through and allows user context to read
- the counters or update the rules.
-
- Hence the start of any table is given by get_table() below. */
-
/* Returns whether matches rule or not. */
/* Performance critical - called for every packet */
static inline bool
@@ -311,6 +302,7 @@ ipt_do_table(struct sk_buff *skb,
unsigned int *stackptr, origptr, cpu;
const struct xt_table_info *private;
struct xt_action_param acpar;
+ seqcount_t *seqp;
/* Initialization */
ip = ip_hdr(skb);
@@ -331,7 +323,8 @@ ipt_do_table(struct sk_buff *skb,
acpar.hooknum = hook;
IP_NF_ASSERT(table->valid_hooks & (1 << hook));
- xt_info_rdlock_bh();
+ local_bh_disable();
+ seqp = xt_write_recseq_begin();
private = table->private;
cpu = smp_processor_id();
table_base = private->entries[cpu];
@@ -427,7 +420,8 @@ ipt_do_table(struct sk_buff *skb,
/* Verdict */
break;
} while (!acpar.hotdrop);
- xt_info_rdunlock_bh();
+ xt_write_recseq_end(seqp);
+ local_bh_enable();
pr_debug("Exiting %s; resetting sp from %u to %u\n",
__func__, *stackptr, origptr);
*stackptr = origptr;
@@ -886,7 +880,7 @@ get_counters(const struct xt_table_info *t,
unsigned int i;
for_each_possible_cpu(cpu) {
- seqlock_t *lock = &per_cpu(xt_info_locks, cpu).lock;
+ seqcount_t *s = &per_cpu(xt_recseq, cpu);
i = 0;
xt_entry_foreach(iter, t->entries[cpu], t->size) {
@@ -894,10 +888,10 @@ get_counters(const struct xt_table_info *t,
unsigned int start;
do {
- start = read_seqbegin(lock);
+ start = read_seqcount_begin(s);
bcnt = iter->counters.bcnt;
pcnt = iter->counters.pcnt;
- } while (read_seqretry(lock, start));
+ } while (read_seqcount_retry(s, start));
ADD_COUNTER(counters[i], bcnt, pcnt);
++i; /* macro does multi eval of i */
@@ -1312,6 +1306,7 @@ do_add_counters(struct net *net, const void __user *user,
int ret = 0;
void *loc_cpu_entry;
struct ipt_entry *iter;
+ seqcount_t *seqp;
#ifdef CONFIG_COMPAT
struct compat_xt_counters_info compat_tmp;
@@ -1368,12 +1363,12 @@ do_add_counters(struct net *net, const void __user *user,
/* Choose the copy that is on our node */
curcpu = smp_processor_id();
loc_cpu_entry = private->entries[curcpu];
- xt_info_wrlock(curcpu);
+ seqp = xt_write_recseq_begin();
xt_entry_foreach(iter, loc_cpu_entry, private->size) {
ADD_COUNTER(iter->counters, paddc[i].bcnt, paddc[i].pcnt);
++i;
}
- xt_info_wrunlock(curcpu);
+ xt_write_recseq_end(seqp);
unlock_up_free:
local_bh_enable();
xt_table_unlock(t);
diff --git a/net/netfilter/x_tables.c b/net/netfilter/x_tables.c
index a9adf4c..18290d2 100644
--- a/net/netfilter/x_tables.c
+++ b/net/netfilter/x_tables.c
@@ -762,8 +762,8 @@ void xt_compat_unlock(u_int8_t af)
EXPORT_SYMBOL_GPL(xt_compat_unlock);
#endif
-DEFINE_PER_CPU(struct xt_info_lock, xt_info_locks);
-EXPORT_PER_CPU_SYMBOL_GPL(xt_info_locks);
+DEFINE_PER_CPU(seqcount_t, xt_recseq);
+EXPORT_PER_CPU_SYMBOL_GPL(xt_recseq);
static int xt_jumpstack_alloc(struct xt_table_info *i)
{
@@ -1362,10 +1362,9 @@ static int __init xt_init(void)
int rv;
for_each_possible_cpu(i) {
- struct xt_info_lock *lock = &per_cpu(xt_info_locks, i);
+ seqcount_t *s = &per_cpu(xt_recseq, i);
- seqlock_init(&lock->lock);
- lock->readers = 0;
+ seqcount_init(s);
}
xt = kmalloc(sizeof(struct xt_af) * NFPROTO_NUMPROTO, GFP_KERNEL);
^ permalink raw reply related
* Re: [PATCH] tcp: avoid cwnd moderation in undo
From: John Heffner @ 2011-03-16 18:52 UTC (permalink / raw)
To: Carsten Wolff
Cc: Yuchung Cheng, David Miller, Ilpo Jarvinen, Nandita Dukkipati,
netdev, Alexander Zimmermann
In-Reply-To: <201103161718.39110.carsten@wolffcarsten.de>
On Wed, Mar 16, 2011 at 12:18 PM, Carsten Wolff <carsten@wolffcarsten.de> wrote:
> Unfortunately, no. ;-) My point is, that cwnd should be moderated when the
> congestion state changes are undone after a spurious recovery has been
> detected. Reordering is only one possible reason for a false recovery. And I
> stick to that point because of the thoughts I pointed out in my mail to john,
> i.e. undo typically leading to exceptionally large segment bursts.
There's a more general discussion here as to how much it's worth
avoiding bursts at all. What research on the subject I'm aware of is
somewhat inconclusive. It's possible to construct scenarios where
bursting, burst suppression, or pacing each win or lose badly. If you
can choose only one approach as one-size-fits all it's difficult with
the information at hand to pick only one. However, I really do wonder
why it's so important to suppress bursts on congestion state undo when
other, likely far more common, sources of bursts are not suppressed.
Carsten, do you have any specific examples of cases you're concerned
about? FWIW, there are exactly two causes for spurious retransmits:
spurious fast retransmit due to reordering, and spurious timeouts due
to a delay spike. Are you particularly concerned with one more than
the other?
Thanks,
-John
^ permalink raw reply
* [patch net-next-2.6 5/6 v2] bonding: get rid of IFF_SLAVE_INACTIVE netdev->priv_flag
From: Jiri Pirko @ 2011-03-16 18:46 UTC (permalink / raw)
To: netdev
Cc: davem, shemminger, kaber, fubar, eric.dumazet, nicolas.2p.debian,
andy, xiaosuo
In-Reply-To: <1299935679-18135-6-git-send-email-jpirko@redhat.com>
Since bond-related code was moved from net/core/dev.c into bonding,
IFF_SLAVE_INACTIVE is no longer needed. Replace is with flag "inactive"
stored in slave structure
Signed-off-by: Jiri Pirko <jpirko@redhat.com>
Reviewed-by: Nicolas de Pesloüan <nicolas.2p.debian@free.fr>
---
drivers/net/bonding/bond_main.c | 6 ++----
drivers/net/bonding/bond_sysfs.c | 4 ++--
drivers/net/bonding/bonding.h | 14 ++++++++++----
3 files changed, 14 insertions(+), 10 deletions(-)
diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c
index c5f3a01..c3150df 100644
--- a/drivers/net/bonding/bond_main.c
+++ b/drivers/net/bonding/bond_main.c
@@ -1461,7 +1461,7 @@ static bool bond_should_deliver_exact_match(struct sk_buff *skb,
struct slave *slave,
struct bonding *bond)
{
- if (slave->dev->priv_flags & IFF_SLAVE_INACTIVE) {
+ if (bond_is_slave_inactive(slave)) {
if (slave_do_arp_validate(bond, slave) &&
skb->protocol == __cpu_to_be16(ETH_P_ARP))
return false;
@@ -2122,7 +2122,7 @@ int bond_release(struct net_device *bond_dev, struct net_device *slave_dev)
dev_set_mtu(slave_dev, slave->original_mtu);
- slave_dev->priv_flags &= ~(IFF_SLAVE_INACTIVE | IFF_BONDING);
+ slave_dev->priv_flags &= ~IFF_BONDING;
kfree(slave);
@@ -2233,8 +2233,6 @@ static int bond_release_all(struct net_device *bond_dev)
dev_set_mac_address(slave_dev, &addr);
}
- slave_dev->priv_flags &= ~IFF_SLAVE_INACTIVE;
-
kfree(slave);
/* re-acquire the lock before getting the next slave */
diff --git a/drivers/net/bonding/bond_sysfs.c b/drivers/net/bonding/bond_sysfs.c
index 344d23f..5161183 100644
--- a/drivers/net/bonding/bond_sysfs.c
+++ b/drivers/net/bonding/bond_sysfs.c
@@ -1581,9 +1581,9 @@ static ssize_t bonding_store_slaves_active(struct device *d,
bond_for_each_slave(bond, slave, i) {
if (!bond_is_active_slave(slave)) {
if (new_value)
- slave->dev->priv_flags &= ~IFF_SLAVE_INACTIVE;
+ slave->inactive = 0;
else
- slave->dev->priv_flags |= IFF_SLAVE_INACTIVE;
+ slave->inactive = 1;
}
}
out:
diff --git a/drivers/net/bonding/bonding.h b/drivers/net/bonding/bonding.h
index 63e9cf7..6b26962 100644
--- a/drivers/net/bonding/bonding.h
+++ b/drivers/net/bonding/bonding.h
@@ -192,8 +192,9 @@ struct slave {
unsigned long last_arp_rx;
s8 link; /* one of BOND_LINK_XXXX */
s8 new_link;
- u8 backup; /* indicates backup slave. Value corresponds with
- BOND_STATE_ACTIVE and BOND_STATE_BACKUP */
+ u8 backup:1, /* indicates backup slave. Value corresponds with
+ BOND_STATE_ACTIVE and BOND_STATE_BACKUP */
+ inactive:1; /* indicates inactive slave */
u32 original_mtu;
u32 link_failure_count;
u8 perm_hwaddr[ETH_ALEN];
@@ -376,13 +377,18 @@ static inline void bond_set_slave_inactive_flags(struct slave *slave)
if (!bond_is_lb(bond))
bond_set_backup_slave(slave);
if (!bond->params.all_slaves_active)
- slave->dev->priv_flags |= IFF_SLAVE_INACTIVE;
+ slave->inactive = 1;
}
static inline void bond_set_slave_active_flags(struct slave *slave)
{
bond_set_active_slave(slave);
- slave->dev->priv_flags &= ~IFF_SLAVE_INACTIVE;
+ slave->inactive = 0;
+}
+
+static inline bool bond_is_slave_inactive(struct slave *slave)
+{
+ return slave->inactive;
}
struct vlan_entry *bond_next_vlan(struct bonding *bond, struct vlan_entry *curr);
--
1.7.4
^ permalink raw reply related
* [patch net-next-2.6 3/6 v2] net: get rid of multiple bond-related netdevice->priv_flags
From: Jiri Pirko @ 2011-03-16 18:45 UTC (permalink / raw)
To: netdev
Cc: davem, shemminger, kaber, fubar, eric.dumazet, nicolas.2p.debian,
andy, xiaosuo
In-Reply-To: <1299935679-18135-4-git-send-email-jpirko@redhat.com>
Now when bond-related code is moved from net/core/dev.c into bonding
code, multiple priv_flags are not needed anymore. So let them rot.
Signed-off-by: Jiri Pirko <jpirko@redhat.com>
Reviewed-by: Nicolas de Pesloüan <nicolas.2p.debian@free.fr>
---
drivers/net/bonding/bond_main.c | 33 ++++++++++++++-------------------
drivers/net/bonding/bond_sysfs.c | 8 --------
drivers/net/bonding/bonding.h | 24 +-----------------------
3 files changed, 15 insertions(+), 50 deletions(-)
diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c
index 29f69da..3c6ac2f 100644
--- a/drivers/net/bonding/bond_main.c
+++ b/drivers/net/bonding/bond_main.c
@@ -1458,20 +1458,20 @@ static void bond_setup_by_slave(struct net_device *bond_dev,
* ARP on active-backup slaves with arp_validate enabled.
*/
static bool bond_should_deliver_exact_match(struct sk_buff *skb,
- struct net_device *slave_dev,
- struct net_device *bond_dev)
+ struct slave *slave,
+ struct bonding *bond)
{
- if (slave_dev->priv_flags & IFF_SLAVE_INACTIVE) {
- if (slave_dev->priv_flags & IFF_SLAVE_NEEDARP &&
+ if (slave->dev->priv_flags & IFF_SLAVE_INACTIVE) {
+ if (slave_do_arp_validate(bond, slave) &&
skb->protocol == __cpu_to_be16(ETH_P_ARP))
return false;
- if (bond_dev->priv_flags & IFF_MASTER_ALB &&
+ if (bond->params.mode == BOND_MODE_ALB &&
skb->pkt_type != PACKET_BROADCAST &&
skb->pkt_type != PACKET_MULTICAST)
return false;
- if (bond_dev->priv_flags & IFF_MASTER_8023AD &&
+ if (bond->params.mode == BOND_MODE_8023AD &&
skb->protocol == __cpu_to_be16(ETH_P_SLOW))
return false;
@@ -1484,6 +1484,7 @@ static struct sk_buff *bond_handle_frame(struct sk_buff *skb)
{
struct slave *slave;
struct net_device *bond_dev;
+ struct bonding *bond;
skb = skb_share_check(skb, GFP_ATOMIC);
if (unlikely(!skb))
@@ -1494,17 +1495,19 @@ static struct sk_buff *bond_handle_frame(struct sk_buff *skb)
if (unlikely(!bond_dev))
return skb;
- if (bond_dev->priv_flags & IFF_MASTER_ARPMON)
+ bond = netdev_priv(bond_dev);
+
+ if (bond->params.arp_interval)
slave->dev->last_rx = jiffies;
- if (bond_should_deliver_exact_match(skb, slave->dev, bond_dev)) {
+ if (bond_should_deliver_exact_match(skb, slave, bond)) {
skb->deliver_no_wcard = 1;
return skb;
}
skb->dev = bond_dev;
- if (bond_dev->priv_flags & IFF_MASTER_ALB &&
+ if (bond->params.mode == BOND_MODE_ALB &&
bond_dev->priv_flags & IFF_BRIDGE_PORT &&
skb->pkt_type == PACKET_HOST) {
@@ -2119,9 +2122,7 @@ int bond_release(struct net_device *bond_dev, struct net_device *slave_dev)
dev_set_mtu(slave_dev, slave->original_mtu);
- slave_dev->priv_flags &= ~(IFF_MASTER_8023AD | IFF_MASTER_ALB |
- IFF_SLAVE_INACTIVE | IFF_BONDING |
- IFF_SLAVE_NEEDARP);
+ slave_dev->priv_flags &= ~(IFF_SLAVE_INACTIVE | IFF_BONDING);
kfree(slave);
@@ -2232,8 +2233,7 @@ static int bond_release_all(struct net_device *bond_dev)
dev_set_mac_address(slave_dev, &addr);
}
- slave_dev->priv_flags &= ~(IFF_MASTER_8023AD | IFF_MASTER_ALB |
- IFF_SLAVE_INACTIVE);
+ slave_dev->priv_flags &= ~IFF_SLAVE_INACTIVE;
kfree(slave);
@@ -4416,11 +4416,9 @@ void bond_set_mode_ops(struct bonding *bond, int mode)
case BOND_MODE_BROADCAST:
break;
case BOND_MODE_8023AD:
- bond_set_master_3ad_flags(bond);
bond_set_xmit_hash_policy(bond);
break;
case BOND_MODE_ALB:
- bond_set_master_alb_flags(bond);
/* FALLTHRU */
case BOND_MODE_TLB:
break;
@@ -4511,9 +4509,6 @@ static void bond_setup(struct net_device *bond_dev)
bond_dev->priv_flags |= IFF_BONDING;
bond_dev->priv_flags &= ~IFF_XMIT_DST_RELEASE;
- if (bond->params.arp_interval)
- bond_dev->priv_flags |= IFF_MASTER_ARPMON;
-
/* At first, we block adding VLANs. That's the only way to
* prevent problems that occur when adding VLANs over an
* empty bond. The block will be removed once non-challenged
diff --git a/drivers/net/bonding/bond_sysfs.c b/drivers/net/bonding/bond_sysfs.c
index 72bb0f6..05e0ae5 100644
--- a/drivers/net/bonding/bond_sysfs.c
+++ b/drivers/net/bonding/bond_sysfs.c
@@ -322,11 +322,6 @@ static ssize_t bonding_store_mode(struct device *d,
ret = -EINVAL;
goto out;
}
- if (bond->params.mode == BOND_MODE_8023AD)
- bond_unset_master_3ad_flags(bond);
-
- if (bond->params.mode == BOND_MODE_ALB)
- bond_unset_master_alb_flags(bond);
bond->params.mode = new_value;
bond_set_mode_ops(bond, bond->params.mode);
@@ -527,8 +522,6 @@ static ssize_t bonding_store_arp_interval(struct device *d,
pr_info("%s: Setting ARP monitoring interval to %d.\n",
bond->dev->name, new_value);
bond->params.arp_interval = new_value;
- if (bond->params.arp_interval)
- bond->dev->priv_flags |= IFF_MASTER_ARPMON;
if (bond->params.miimon) {
pr_info("%s: ARP monitoring cannot be used with MII monitoring. %s Disabling MII monitoring.\n",
bond->dev->name, bond->dev->name);
@@ -1004,7 +997,6 @@ static ssize_t bonding_store_miimon(struct device *d,
pr_info("%s: MII monitoring cannot be used with ARP monitoring. Disabling ARP monitoring...\n",
bond->dev->name);
bond->params.arp_interval = 0;
- bond->dev->priv_flags &= ~IFF_MASTER_ARPMON;
if (bond->params.arp_validate) {
bond_unregister_arp(bond);
bond->params.arp_validate =
diff --git a/drivers/net/bonding/bonding.h b/drivers/net/bonding/bonding.h
index ff9af31..049619f 100644
--- a/drivers/net/bonding/bonding.h
+++ b/drivers/net/bonding/bonding.h
@@ -356,34 +356,12 @@ static inline void bond_set_slave_inactive_flags(struct slave *slave)
slave->state = BOND_STATE_BACKUP;
if (!bond->params.all_slaves_active)
slave->dev->priv_flags |= IFF_SLAVE_INACTIVE;
- if (slave_do_arp_validate(bond, slave))
- slave->dev->priv_flags |= IFF_SLAVE_NEEDARP;
}
static inline void bond_set_slave_active_flags(struct slave *slave)
{
slave->state = BOND_STATE_ACTIVE;
- slave->dev->priv_flags &= ~(IFF_SLAVE_INACTIVE | IFF_SLAVE_NEEDARP);
-}
-
-static inline void bond_set_master_3ad_flags(struct bonding *bond)
-{
- bond->dev->priv_flags |= IFF_MASTER_8023AD;
-}
-
-static inline void bond_unset_master_3ad_flags(struct bonding *bond)
-{
- bond->dev->priv_flags &= ~IFF_MASTER_8023AD;
-}
-
-static inline void bond_set_master_alb_flags(struct bonding *bond)
-{
- bond->dev->priv_flags |= IFF_MASTER_ALB;
-}
-
-static inline void bond_unset_master_alb_flags(struct bonding *bond)
-{
- bond->dev->priv_flags &= ~IFF_MASTER_ALB;
+ slave->dev->priv_flags &= ~IFF_SLAVE_INACTIVE;
}
struct vlan_entry *bond_next_vlan(struct bonding *bond, struct vlan_entry *curr);
--
1.7.4
^ permalink raw reply related
* Re: [PATCH] net: 2.6.38 Compile Failure e1000e Module
From: Randy Dunlap @ 2011-03-16 18:31 UTC (permalink / raw)
To: David Miller; +Cc: frank.peters, linux-kernel, netdev
In-Reply-To: <20110316.111544.115931576.davem@davemloft.net>
On 03/16/11 11:15, David Miller wrote:
> From: Randy Dunlap <randy.dunlap@oracle.com>
> Date: Wed, 16 Mar 2011 08:21:05 -0700
>
>> Hi,
>> Please test this patch:
>>
>>
>> From: Randy Dunlap <randy.dunlap@oracle.com>
>>
>> e1000e needs to select CRC32 for CRC support.
>> This patch fixes the build error:
>> ERROR: "crc32_le" [drivers/net/e1000e/e1000e.ko] undefined!
>>
>> Reported-by: Frank Peters <frank.peters@comcast.net>
>> Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
>
> Randy, I applied Eric Dumazet's copy of this fix only because
> his submission preceded your's in terms of time of submission :-)
Ack. :)
thanks,
--
~Randy
*** Remember to use Documentation/SubmitChecklist when testing your code ***
^ permalink raw reply
* Re: [PATCH net-next 2/2] be2net: Bump up the version number
From: David Miller @ 2011-03-16 18:30 UTC (permalink / raw)
To: ajit.khaparde; +Cc: netdev
In-Reply-To: <20110316182100.GA6274@akhaparde-VBox>
From: Ajit Khaparde <ajit.khaparde@emulex.com>
Date: Wed, 16 Mar 2011 13:21:00 -0500
>
> Signed-off-by: Ajit Khaparde <ajit.khaparde@emulex.com>
Applied.
^ permalink raw reply
* Re: [PATCH net-next 1/2] be2net: Copyright notice change. Update to Emulex instead of ServerEngines
From: David Miller @ 2011-03-16 18:29 UTC (permalink / raw)
To: ajit.khaparde; +Cc: netdev
In-Reply-To: <20110316182046.GA6254@akhaparde-VBox>
From: Ajit Khaparde <ajit.khaparde@emulex.com>
Date: Wed, 16 Mar 2011 13:20:46 -0500
>
> Signed-off-by: Ajit Khaparde <ajit.khaparde@emulex.com>
Applied.
^ permalink raw reply
* [PATCH net-next 1/2] be2net: Copyright notice change. Update to Emulex instead of ServerEngines
From: Ajit Khaparde @ 2011-03-16 18:20 UTC (permalink / raw)
To: netdev
Signed-off-by: Ajit Khaparde <ajit.khaparde@emulex.com>
---
drivers/net/benet/be.h | 10 +++++-----
drivers/net/benet/be_cmds.c | 10 +++++-----
drivers/net/benet/be_cmds.h | 10 +++++-----
drivers/net/benet/be_ethtool.c | 10 +++++-----
drivers/net/benet/be_hw.h | 10 +++++-----
drivers/net/benet/be_main.c | 10 +++++-----
6 files changed, 30 insertions(+), 30 deletions(-)
diff --git a/drivers/net/benet/be.h b/drivers/net/benet/be.h
index 62af707..7721699 100644
--- a/drivers/net/benet/be.h
+++ b/drivers/net/benet/be.h
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2005 - 2010 ServerEngines
+ * Copyright (C) 2005 - 2011 Emulex
* All rights reserved.
*
* This program is free software; you can redistribute it and/or
@@ -8,11 +8,11 @@
* Public License is included in this distribution in the file called COPYING.
*
* Contact Information:
- * linux-drivers@serverengines.com
+ * linux-drivers@emulex.com
*
- * ServerEngines
- * 209 N. Fair Oaks Ave
- * Sunnyvale, CA 94085
+ * Emulex
+ * 3333 Susan Street
+ * Costa Mesa, CA 92626
*/
#ifndef BE_H
diff --git a/drivers/net/benet/be_cmds.c b/drivers/net/benet/be_cmds.c
index e1124c8..5a4a87e 100644
--- a/drivers/net/benet/be_cmds.c
+++ b/drivers/net/benet/be_cmds.c
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2005 - 2010 ServerEngines
+ * Copyright (C) 2005 - 2011 Emulex
* All rights reserved.
*
* This program is free software; you can redistribute it and/or
@@ -8,11 +8,11 @@
* Public License is included in this distribution in the file called COPYING.
*
* Contact Information:
- * linux-drivers@serverengines.com
+ * linux-drivers@emulex.com
*
- * ServerEngines
- * 209 N. Fair Oaks Ave
- * Sunnyvale, CA 94085
+ * Emulex
+ * 3333 Susan Street
+ * Costa Mesa, CA 92626
*/
#include "be.h"
diff --git a/drivers/net/benet/be_cmds.h b/drivers/net/benet/be_cmds.h
index e41fcba..4f254cf 100644
--- a/drivers/net/benet/be_cmds.h
+++ b/drivers/net/benet/be_cmds.h
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2005 - 2010 ServerEngines
+ * Copyright (C) 2005 - 2011 Emulex
* All rights reserved.
*
* This program is free software; you can redistribute it and/or
@@ -8,11 +8,11 @@
* Public License is included in this distribution in the file called COPYING.
*
* Contact Information:
- * linux-drivers@serverengines.com
+ * linux-drivers@emulex.com
*
- * ServerEngines
- * 209 N. Fair Oaks Ave
- * Sunnyvale, CA 94085
+ * Emulex
+ * 3333 Susan Street
+ * Costa Mesa, CA 92626
*/
/*
diff --git a/drivers/net/benet/be_ethtool.c b/drivers/net/benet/be_ethtool.c
index 6e5e433..aac248f 100644
--- a/drivers/net/benet/be_ethtool.c
+++ b/drivers/net/benet/be_ethtool.c
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2005 - 2010 ServerEngines
+ * Copyright (C) 2005 - 2011 Emulex
* All rights reserved.
*
* This program is free software; you can redistribute it and/or
@@ -8,11 +8,11 @@
* Public License is included in this distribution in the file called COPYING.
*
* Contact Information:
- * linux-drivers@serverengines.com
+ * linux-drivers@emulex.com
*
- * ServerEngines
- * 209 N. Fair Oaks Ave
- * Sunnyvale, CA 94085
+ * Emulex
+ * 3333 Susan Street
+ * Costa Mesa, CA 92626
*/
#include "be.h"
diff --git a/drivers/net/benet/be_hw.h b/drivers/net/benet/be_hw.h
index e06aa15..d4344a0 100644
--- a/drivers/net/benet/be_hw.h
+++ b/drivers/net/benet/be_hw.h
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2005 - 2010 ServerEngines
+ * Copyright (C) 2005 - 2011 Emulex
* All rights reserved.
*
* This program is free software; you can redistribute it and/or
@@ -8,11 +8,11 @@
* Public License is included in this distribution in the file called COPYING.
*
* Contact Information:
- * linux-drivers@serverengines.com
+ * linux-drivers@emulex.com
*
- * ServerEngines
- * 209 N. Fair Oaks Ave
- * Sunnyvale, CA 94085
+ * Emulex
+ * 3333 Susan Street
+ * Costa Mesa, CA 92626
*/
/********* Mailbox door bell *************/
diff --git a/drivers/net/benet/be_main.c b/drivers/net/benet/be_main.c
index 5e15006..a71163f 100644
--- a/drivers/net/benet/be_main.c
+++ b/drivers/net/benet/be_main.c
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2005 - 2010 ServerEngines
+ * Copyright (C) 2005 - 2011 Emulex
* All rights reserved.
*
* This program is free software; you can redistribute it and/or
@@ -8,11 +8,11 @@
* Public License is included in this distribution in the file called COPYING.
*
* Contact Information:
- * linux-drivers@serverengines.com
+ * linux-drivers@emulex.com
*
- * ServerEngines
- * 209 N. Fair Oaks Ave
- * Sunnyvale, CA 94085
+ * Emulex
+ * 3333 Susan Street
+ * Costa Mesa, CA 92626
*/
#include "be.h"
--
1.7.1
^ permalink raw reply related
* [PATCH net-next 2/2] be2net: Bump up the version number
From: Ajit Khaparde @ 2011-03-16 18:21 UTC (permalink / raw)
To: netdev
Signed-off-by: Ajit Khaparde <ajit.khaparde@emulex.com>
---
drivers/net/benet/be.h | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/net/benet/be.h b/drivers/net/benet/be.h
index 7721699..f803c58 100644
--- a/drivers/net/benet/be.h
+++ b/drivers/net/benet/be.h
@@ -33,7 +33,7 @@
#include "be_hw.h"
-#define DRV_VER "2.103.175u"
+#define DRV_VER "4.0.100u"
#define DRV_NAME "be2net"
#define BE_NAME "ServerEngines BladeEngine2 10Gbps NIC"
#define BE3_NAME "ServerEngines BladeEngine3 10Gbps NIC"
--
1.7.1
^ permalink raw reply related
* Re: net-next-2.6 status...
From: David Miller @ 2011-03-16 18:17 UTC (permalink / raw)
To: bhutchings
Cc: jpirko, netdev, linux-wireless, netfilter-devel, eric.dumazet,
linville, kaber
In-Reply-To: <1300299219.2811.7.camel@bwh-desktop>
From: Ben Hutchings <bhutchings@solarflare.com>
Date: Wed, 16 Mar 2011 18:13:39 +0000
> Though, in this case, the priv_flags are not in any way visible to
> user-space, so it would be quite hard to find a use for them!
There are pieces of infrastructure, such as scripts that turn header
file visible macro values into values usable in other languages such
as perl, that do that wholesale for entire header files and therefore
expect these individual values to be there.
I'm not going to be the person who breaks such things.
^ permalink raw reply
* Re: [PATCH] net: 2.6.38 Compile Failure e1000e Module
From: David Miller @ 2011-03-16 18:15 UTC (permalink / raw)
To: randy.dunlap; +Cc: frank.peters, linux-kernel, netdev
In-Reply-To: <20110316082105.c911bb1c.randy.dunlap@oracle.com>
From: Randy Dunlap <randy.dunlap@oracle.com>
Date: Wed, 16 Mar 2011 08:21:05 -0700
> Hi,
> Please test this patch:
>
>
> From: Randy Dunlap <randy.dunlap@oracle.com>
>
> e1000e needs to select CRC32 for CRC support.
> This patch fixes the build error:
> ERROR: "crc32_le" [drivers/net/e1000e/e1000e.ko] undefined!
>
> Reported-by: Frank Peters <frank.peters@comcast.net>
> Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Randy, I applied Eric Dumazet's copy of this fix only because
his submission preceded your's in terms of time of submission :-)
Thanks!
^ permalink raw reply
* Re: 2.6.38 Compile Failure e1000e Module
From: David Miller @ 2011-03-16 18:15 UTC (permalink / raw)
To: eric.dumazet
Cc: frank.peters, linux-kernel, bruce.w.allan, jeffrey.t.kirsher,
netdev
In-Reply-To: <1300288617.3202.10.camel@edumazet-laptop>
From: Eric Dumazet <eric.dumazet@gmail.com>
Date: Wed, 16 Mar 2011 16:16:57 +0100
> [PATCH] e1000e: fix kconfig for crc32 dependency
>
> ERROR: "crc32_le" [drivers/net/e1000e/e1000e.ko] undefined!
>
> Reported-by: Frank Peters <frank.peters@comcast.net>
> Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
> Cc: Bruce Allan <bruce.w.allan@intel.com>
> Cc: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Applied, thanks Eric.
^ permalink raw reply
* Re: net-next-2.6 status...
From: Ben Hutchings @ 2011-03-16 18:13 UTC (permalink / raw)
To: David Miller
Cc: jpirko, netdev, linux-wireless, netfilter-devel, eric.dumazet,
linville, kaber
In-Reply-To: <20110316.104236.104065822.davem@davemloft.net>
On Wed, 2011-03-16 at 10:42 -0700, David Miller wrote:
> From: Jiri Pirko <jpirko@redhat.com>
> Date: Wed, 16 Mar 2011 09:40:23 +0100
>
> > Wed, Mar 16, 2011 at 08:38:03AM CET, jpirko@redhat.com wrote:
> >>Wed, Mar 16, 2011 at 08:02:51AM CET, davem@davemloft.net wrote:
> >>>From: Jiri Pirko <jpirko@redhat.com>
> >>>Date: Wed, 16 Mar 2011 07:50:09 +0100
> >>>
> >>>>>Jiri, I know there is your patch set there, but I think you and Changli
> >>>>>still need to go back and forth one more time wrt. orig_dev semantics.
> >>>>>Since you have been posting this patch set for some time I'm still
> >>>>>willing to apply it for this merge window, but please make haste and
> >>>>>work out the remaining discussion. Thank you.
> >>>>
> >>>> Dave, you can apply the rest of the series and leave only the first
> >>>> patch (af_packet) out. There's no dependency. We will figure out things
> >>>> around origdev later.
> >>>
> >>>I was about to do that but I've found other problems.
> >>>
> >>>You cannot make the modifications you make to linux/if.h, those
> >>>interface flags are visible to userspace.
> >>
> >>What do you suggest? To remove unused flags and leave gaps there or to
> >>not to remove the flags at all?
> >
> > Well, the following comment:
> > <quote>
> > /* Private (from user) interface flags (netdevice->priv_flags). */
> > </quote>
> > leads me to think that these flags should not be used by userspace.
> > So maybe it may not be problem to change those values.
>
> Comments don't block user applications from using defines we expose
> to them. The person who was wise enough to write that comment should
> have also been wise enough to add appropriate __KERNEL__ protection
> to the definitions.
Though, in this case, the priv_flags are not in any way visible to
user-space, so it would be quite hard to find a use for them!
> They were not, therefore we are stuck with them forever.
So should we also expose struct net_device_stats again? During the
introduction to 64-bit stats I changed and un-exported the definition,
then later had to revert the definition but left it un-exported. This
broke compilation of iproute2, though in the process it revealed an
existing bug: <http://thread.gmane.org/gmane.linux.network/169764>.
Ben.
--
Ben Hutchings, Senior Software Engineer, Solarflare
Not speaking for my employer; that's the marketing department's job.
They asked us to note that Solarflare product names are trademarked.
^ permalink raw reply
* Re: [PATCH 00/01] netfilter: netfilter fix for net-next
From: David Miller @ 2011-03-16 18:12 UTC (permalink / raw)
To: kaber; +Cc: netfilter-devel, netdev
In-Reply-To: <1300297111-28116-1-git-send-email-kaber@trash.net>
From: kaber@trash.net
Date: Wed, 16 Mar 2011 18:38:30 +0100
> following is a single netfilter fix from Thomas for net-next. The new
> AUDIT target is supposed to work with ebtables, however it returns
> a xtables verdict, which are unfortunately incompatible with ebtables
> verdicts.
>
> Please apply or pull from:
>
> git://git.kernel.org/pub/scm/linux/kernel/git/kaber/nf-next-2.6.git master
I'll pull this, thanks Patrick.
^ permalink raw reply
* Re: net-next-2.6 status...
From: David Miller @ 2011-03-16 18:00 UTC (permalink / raw)
To: jpirko
Cc: netdev, linux-wireless, netfilter-devel, eric.dumazet, linville,
kaber
In-Reply-To: <20110316175642.GB2867@psychotron.redhat.com>
From: Jiri Pirko <jpirko@redhat.com>
Date: Wed, 16 Mar 2011 18:56:44 +0100
> So would you leave out if.h hunk out or should I repost?
What makes you think it's a good idea for me to have to do more work?
I have the entire merge window and thousands of other patches to worry
about...
^ permalink raw reply
* Re: net-next-2.6 status...
From: Jiri Pirko @ 2011-03-16 17:56 UTC (permalink / raw)
To: David Miller
Cc: netdev-u79uwXL29TY76Z2rM5mHXA,
linux-wireless-u79uwXL29TY76Z2rM5mHXA,
netfilter-devel-u79uwXL29TY76Z2rM5mHXA,
eric.dumazet-Re5JQEeQqe8AvxtiuMwx3w,
linville-2XuSBdqkA4R54TAoqtyWWQ, kaber-dcUjhNyLwpNeoWH0uzbU5w
In-Reply-To: <20110316.103857.226773145.davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org>
Wed, Mar 16, 2011 at 06:38:57PM CET, davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org wrote:
>From: Jiri Pirko <jpirko-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
>Date: Wed, 16 Mar 2011 08:38:03 +0100
>
>> Wed, Mar 16, 2011 at 08:02:51AM CET, davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org wrote:
>>>From: Jiri Pirko <jpirko-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
>>>Date: Wed, 16 Mar 2011 07:50:09 +0100
>>>
>>>>>Jiri, I know there is your patch set there, but I think you and Changli
>>>>>still need to go back and forth one more time wrt. orig_dev semantics.
>>>>>Since you have been posting this patch set for some time I'm still
>>>>>willing to apply it for this merge window, but please make haste and
>>>>>work out the remaining discussion. Thank you.
>>>>
>>>> Dave, you can apply the rest of the series and leave only the first
>>>> patch (af_packet) out. There's no dependency. We will figure out things
>>>> around origdev later.
>>>
>>>I was about to do that but I've found other problems.
>>>
>>>You cannot make the modifications you make to linux/if.h, those
>>>interface flags are visible to userspace.
>>
>> What do you suggest? To remove unused flags and leave gaps there or to
>> not to remove the flags at all?
>
>You can't remove them, otherwise if it happened to be reference in the
>sources to some app out there, it will start to fail to compile.
>
>This is pretty obvious stuff, I hope :-)
Ok :( So would you leave out if.h hunk out or should I repost?
--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply
* Re: build breakage due to br_multicast.c referencing ipv6_dev_get_saddr()
From: David Miller @ 2011-03-16 17:49 UTC (permalink / raw)
To: JBeulich; +Cc: linus.luessing, shemminger, bridge, netdev
In-Reply-To: <4D80BC5B0200007800036D85@vpn.id2.novell.com>
From: "Jan Beulich" <JBeulich@novell.com>
Date: Wed, 16 Mar 2011 12:34:19 +0000
> With BRIDGE=y and IPV6=m commit
> fe29ec41aaa51902aebd63658dfb04fe6fea8be5 ("bridge: Use IPv6
> link-local address for multicast listener queries") causes the build to
> break.
Fixed by:
commit dcbcdf22f500ac6e4ec06485341024739b9dc241
Author: Randy Dunlap <randy.dunlap@oracle.com>
Date: Thu Mar 10 13:45:57 2011 -0800
net: bridge builtin vs. ipv6 modular
When configs BRIDGE=y and IPV6=m, this build error occurs:
br_multicast.c:(.text+0xa3341): undefined reference to `ipv6_dev_get_saddr'
BRIDGE_IGMP_SNOOPING is boolean; if it were tristate, then adding
depends on IPV6 || IPV6=n
to BRIDGE_IGMP_SNOOPING would be a good fix. As it is currently,
making BRIDGE depend on the IPV6 config works.
Reported-by: Patrick Schaaf <netdev@bof.de>
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
diff --git a/net/bridge/Kconfig b/net/bridge/Kconfig
index 9190ae4..6dee7bf 100644
--- a/net/bridge/Kconfig
+++ b/net/bridge/Kconfig
@@ -6,6 +6,7 @@ config BRIDGE
tristate "802.1d Ethernet Bridging"
select LLC
select STP
+ depends on IPV6 || IPV6=n
---help---
If you say Y here, then your Linux box will be able to act as an
Ethernet bridge, which means that the different Ethernet segments it
^ permalink raw reply related
* Re: build breakage due to br_multicast.c referencing ipv6_dev_get_saddr()
From: David Miller @ 2011-03-16 17:49 UTC (permalink / raw)
To: shemminger; +Cc: JBeulich, linus.luessing, bridge, netdev
In-Reply-To: <20110316082441.45db3018@nehalam>
From: Stephen Hemminger <shemminger@linux-foundation.org>
Date: Wed, 16 Mar 2011 08:24:41 -0700
> On Wed, 16 Mar 2011 12:34:19 +0000
> "Jan Beulich" <JBeulich@novell.com> wrote:
>
>> With BRIDGE=y and IPV6=m commit
>> fe29ec41aaa51902aebd63658dfb04fe6fea8be5 ("bridge: Use IPv6
>> link-local address for multicast listener queries") causes the build to
>> break.
>
> Rather than continue with the config games, lets just make the necessary
> ipv6 pieces accessible.
You can't Stephen, ipv6_dev_get_saddr() requires access to the actual ipv6
device state, that means you have to pull in the entire ipv6 stack in because
there are dependencies all the way down into the routing code.
We added a Kconfig fix to cure this specific problem, which made it
into 2.6.38-final, so I don't understand why Jan is even seeing this,
it's supposed to force BRIDGE modular if IPV6 is modular:
commit dcbcdf22f500ac6e4ec06485341024739b9dc241
Author: Randy Dunlap <randy.dunlap@oracle.com>
Date: Thu Mar 10 13:45:57 2011 -0800
net: bridge builtin vs. ipv6 modular
When configs BRIDGE=y and IPV6=m, this build error occurs:
br_multicast.c:(.text+0xa3341): undefined reference to `ipv6_dev_get_saddr'
BRIDGE_IGMP_SNOOPING is boolean; if it were tristate, then adding
depends on IPV6 || IPV6=n
to BRIDGE_IGMP_SNOOPING would be a good fix. As it is currently,
making BRIDGE depend on the IPV6 config works.
Reported-by: Patrick Schaaf <netdev@bof.de>
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
diff --git a/net/bridge/Kconfig b/net/bridge/Kconfig
index 9190ae4..6dee7bf 100644
--- a/net/bridge/Kconfig
+++ b/net/bridge/Kconfig
@@ -6,6 +6,7 @@ config BRIDGE
tristate "802.1d Ethernet Bridging"
select LLC
select STP
+ depends on IPV6 || IPV6=n
---help---
If you say Y here, then your Linux box will be able to act as an
Ethernet bridge, which means that the different Ethernet segments it
^ permalink raw reply related
* Re: net-next-2.6 status...
From: David Miller @ 2011-03-16 17:42 UTC (permalink / raw)
To: jpirko
Cc: netdev, linux-wireless, netfilter-devel, eric.dumazet, linville,
kaber
In-Reply-To: <20110316084022.GA2845@psychotron.brq.redhat.com>
From: Jiri Pirko <jpirko@redhat.com>
Date: Wed, 16 Mar 2011 09:40:23 +0100
> Wed, Mar 16, 2011 at 08:38:03AM CET, jpirko@redhat.com wrote:
>>Wed, Mar 16, 2011 at 08:02:51AM CET, davem@davemloft.net wrote:
>>>From: Jiri Pirko <jpirko@redhat.com>
>>>Date: Wed, 16 Mar 2011 07:50:09 +0100
>>>
>>>>>Jiri, I know there is your patch set there, but I think you and Changli
>>>>>still need to go back and forth one more time wrt. orig_dev semantics.
>>>>>Since you have been posting this patch set for some time I'm still
>>>>>willing to apply it for this merge window, but please make haste and
>>>>>work out the remaining discussion. Thank you.
>>>>
>>>> Dave, you can apply the rest of the series and leave only the first
>>>> patch (af_packet) out. There's no dependency. We will figure out things
>>>> around origdev later.
>>>
>>>I was about to do that but I've found other problems.
>>>
>>>You cannot make the modifications you make to linux/if.h, those
>>>interface flags are visible to userspace.
>>
>>What do you suggest? To remove unused flags and leave gaps there or to
>>not to remove the flags at all?
>
> Well, the following comment:
> <quote>
> /* Private (from user) interface flags (netdevice->priv_flags). */
> </quote>
> leads me to think that these flags should not be used by userspace.
> So maybe it may not be problem to change those values.
Comments don't block user applications from using defines we expose
to them. The person who was wise enough to write that comment should
have also been wise enough to add appropriate __KERNEL__ protection
to the definitions.
They were not, therefore we are stuck with them forever.
^ permalink raw reply
* Re: [PATCH V4] Export ACPI _DSM provided firmware instance number and string name to sysfs
From: Jesse Barnes @ 2011-03-16 17:41 UTC (permalink / raw)
To: Shyam_Iyer
Cc: Narendra_K, greg, a.beregalov, linux-next, linux-pci,
linux-hotplug, netdev, mjg, Matt_Domsch, Charles_Rose,
Jordan_Hargrave, sfr
In-Reply-To: <DBFB1B45AF80394ABD1C807E9F28D157026585D732@BLRX7MCDC203.AMER.DELL.COM>
On Fri, 11 Mar 2011 03:35:56 +0530
<Shyam_Iyer@Dell.com> wrote:
>
> > -----Original Message-----
> > From: K, Narendra
> > Sent: Monday, March 07, 2011 3:56 PM
> > To: Greg KH
> > Cc: a.beregalov@gmail.com; linux-next@vger.kernel.org;
> > jbarnes@virtuousgeek.org; linux-pci@vger.kernel.org; linux-
> > hotplug@vger.kernel.org; netdev@vger.kernel.org; mjg@redhat.com;
> > Domsch, Matt; Rose, Charles; Hargrave, Jordan; Iyer, Shyam;
> > sfr@canb.auug.org.au
> > Subject: Re: [PATCH V4] Export ACPI _DSM provided firmware instance
> > number and string name to sysfs
> >
> > On Tue, Mar 08, 2011 at 01:26:16AM +0530, Greg KH wrote:
> > > On Mon, Mar 07, 2011 at 11:44:52AM -0800, Narendra_K@Dell.com wrote:
> > > > --- a/drivers/pci/pci-label.c
> > > > +++ b/drivers/pci/pci-label.c
> > > > @@ -29,7 +29,9 @@
> > > > #include <linux/nls.h>
> > > > #include <linux/acpi.h>
> > > > #include <linux/pci-acpi.h>
> > > > +#ifdef CONFIG_ACPI
> > > > #include <acpi/acpi_drivers.h>
> > > > +#endif
> > >
> > > You should never need a #ifdef in a .c file for an include file. If
> > so,
> > > something is really wrong.
> >
> > I agree. Also, i realized that the include was not required to address
> > the
> > reported error. Please find the revised patch here.
> >
> > From: Narendra K <narendra_k@dell.com>
> > Subject: [PATCH] Fix compilation error when CONFIG_ACPI is unset
> >
> > This patch fixes compilation error descibed below introduced by
> > the commit 6058989bad05b82e78baacce69ec14f27a11b5fd
> >
> > drivers/pci/pci-label.c: In function ‘pci_create_firmware_label_files’:
> > drivers/pci/pci-label.c:366:2: error: implicit declaration of function
> > ‘device_has_dsm’
> >
> > Signed-off-by: Narendra K <narendra_k@dell.com>
> > ---
> > drivers/pci/pci-label.c | 6 ++++++
> > 1 files changed, 6 insertions(+), 0 deletions(-)
> >
> > diff --git a/drivers/pci/pci-label.c b/drivers/pci/pci-label.c
> > index 824e247..8c80138 100644
> > --- a/drivers/pci/pci-label.c
> > +++ b/drivers/pci/pci-label.c
> > @@ -174,6 +174,12 @@ pci_remove_acpi_index_label_files(struct pci_dev
> > *pdev)
> > return -1;
> > }
> >
> > +static inline bool
> > +device_has_dsm(struct device *dev)
> > +{
> > + return false;
> > +}
> > +
> > #else
> >
> > static const char device_label_dsm_uuid[] = {
> > --
> > 1.7.3.1
> >
> > With regards,
> > Narendra K
>
> So this works and fixes the additional build failure.
>
> I tested with CONFIG_ACPI set/unset and with "make allmodconfig"
>
> Additionally I found that including acpi/apci_drivers.h is not necessary and introduces these warnings..
>
> The below patch fixes the additional warnigs..
>
> In file included from drivers/pci/pci-label.c:32:
> include/acpi/acpi_drivers.h:103: warning: ‘struct acpi_device’ declared inside parameter list
> include/acpi/acpi_drivers.h:103: warning: its scope is only this definition or declaration, which is probably not what you want
> include/acpi/acpi_drivers.h:107: warning: ‘struct acpi_pci_root’ declared inside parameter list
>
> Signed-off-by: Shyam Iyer <shyam_iyer@dell.com>
Ok, I've applied these two fixes, thanks guys. I hope that's the last
of the issues we'll see with this patch!
--
Jesse Barnes, Intel Open Source Technology Center
^ permalink raw reply
* Re: [PATCH 1/2] xfrm: Force a dst refcount before entering the xfrm type handlers
From: David Miller @ 2011-03-16 17:41 UTC (permalink / raw)
To: steffen.klassert; +Cc: eric.dumazet, netdev
In-Reply-To: <20110316074306.GT31402@secunet.com>
From: Steffen Klassert <steffen.klassert@secunet.com>
Date: Wed, 16 Mar 2011 08:43:06 +0100
> On Wed, Mar 16, 2011 at 12:17:32AM -0700, David Miller wrote:
>>
>> Steffen we really need to find another way to fix these problems.
>>
>> We already make way too many expensive atomic operations in these code
>> paths modified by your 3 patches, we should strive to not add new
>> ones.
>>
>
> I know that it is exspensive, but we have to take a refcount if
> the crypto layer returns asyncronous. Unfortunately it is too
> late to take the refcount when the crypto layer notifies us about
> that as the skb might be already gone.
We can pass around an atomic_t for the crypto layer to bump when
it decides to take an async path, bump it on entry and upon event
wakeup decrement it.
Actually, a plain atomic_t is a bad idea because we might have to
release the object. So callbacks with private void pointer arg is
better.
^ 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