* Re: [VLAN 00/18]: Vlan update
From: David Miller @ 2008-01-21 8:34 UTC (permalink / raw)
To: kaber; +Cc: netdev
In-Reply-To: <20080120171117.7980.67072.sendpatchset@localhost.localdomain>
From: Patrick McHardy <kaber@trash.net>
Date: Sun, 20 Jan 2008 18:11:17 +0100 (MET)
> the following patches contain a VLAN update for 2.6.25, consisting mainly
> of minor cleanups removing duplicate code, avoiding forward declarations,
> makeing functions static etc. Next I'll look into the skb->cb issues
> with VLAN.
>
> Please apply, thanks.
All applied, thanks.
I wasn't thrilled to see MAC_FMT return, but then again I could
not recommend a better alternative :-)
^ permalink raw reply
* Re: [PATCH 2/4] dsmark: get rid of trivial function
From: Ilpo Järvinen @ 2008-01-21 8:39 UTC (permalink / raw)
To: Patrick McHardy, Stephen Hemminger; +Cc: David Miller, Netdev
In-Reply-To: <4793E460.5020804@trash.net>
On Mon, 21 Jan 2008, Patrick McHardy wrote:
> Stephen Hemminger wrote:
> > Replace loop in dsmark_valid_indices with equivalent bit math.
> >
> > Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
> >
> > --- a/net/sched/sch_dsmark.c 2008-01-20 13:07:58.000000000 -0800
> > +++ b/net/sched/sch_dsmark.c 2008-01-20 13:22:54.000000000 -0800
> > @@ -45,13 +45,8 @@ struct dsmark_qdisc_data {
> >
> > static inline int dsmark_valid_indices(u16 indices)
> > {
> > - while (indices != 1) {
> > - if (indices & 1)
> > - return 0;
> > - indices >>= 1;
> > - }
> > -
> > - return 1;
> > + /* Must have only one bit set */
> > + return (indices & (indices - 1)) == 0;
Isn't there some magic under include/linux to do that btw, I suppose
that if the caller side zero check is pushed down there too, the
is_power_of_2() is 100% match? :-)
> hweight seems easier to understand, it took me a bit
> to realize that the comment matches the code :)
In addition, the original seems infinite loop with zero indices given
but luckily that was checked at the caller site already...
--
i.
^ permalink raw reply
* [PATCH]: Fix IWLWIFI mis-merge.
From: David Miller @ 2008-01-21 8:44 UTC (permalink / raw)
To: netdev; +Cc: linux-wireless, jgarzik, linville
I just corrected the iwlwifi driver build in the net-2.6.25 tree.
The cause is very simple, the patches applied after Christoph
Hellwig's namespace pollution cleanup to these drivers were not even
build tested.
[IWLWIFI]: Fix up merge errors.
Christoph Hellwig did a driver-wide namespace pollution cleanup
changing iwl_* over to iwl{3945,4965}_*
But subsequent patches to these drivers were not made against that
change and thus kept using the iwl_* names, thus breaking the build.
Signed-off-by: David S. Miller <davem@davemloft.net>
diff --git a/drivers/net/wireless/iwlwifi/iwl-3945-rs.c b/drivers/net/wireless/iwlwifi/iwl-3945-rs.c
index 122d712..dc78fb0 100644
--- a/drivers/net/wireless/iwlwifi/iwl-3945-rs.c
+++ b/drivers/net/wireless/iwlwifi/iwl-3945-rs.c
@@ -560,8 +560,8 @@ static void rs_tx_status(void *priv_rate,
return;
}
-static u16 iwl_get_adjacent_rate(struct iwl_rate_scale_priv *rs_priv,
- u8 index, u16 rate_mask, int phymode)
+static u16 iwl3945_get_adjacent_rate(struct iwl3945_rate_scale_priv *rs_priv,
+ u8 index, u16 rate_mask, int phymode)
{
u8 high = IWL_RATE_INVALID;
u8 low = IWL_RATE_INVALID;
@@ -658,7 +658,7 @@ static void rs_get_rate(void *priv_rate, struct net_device *dev,
struct ieee80211_hdr *hdr = (struct ieee80211_hdr *)skb->data;
struct sta_info *sta;
u16 rate_mask;
- struct iwl_priv *priv = (struct iwl_priv *)priv_rate;
+ struct iwl3945_priv *priv = (struct iwl3945_priv *)priv_rate;
DECLARE_MAC_BUF(mac);
IWL_DEBUG_RATE("enter\n");
@@ -726,7 +726,7 @@ static void rs_get_rate(void *priv_rate, struct net_device *dev,
current_tpt = window->average_tpt;
high_low = iwl3945_get_adjacent_rate(rs_priv, index, rate_mask,
- local->hw.conf.phymode);
+ local->hw.conf.phymode);
low = high_low & 0xff;
high = (high_low >> 8) & 0xff;
diff --git a/drivers/net/wireless/iwlwifi/iwl-4965-rs.c b/drivers/net/wireless/iwlwifi/iwl-4965-rs.c
index 5d6a540..b8f2483 100644
--- a/drivers/net/wireless/iwlwifi/iwl-4965-rs.c
+++ b/drivers/net/wireless/iwlwifi/iwl-4965-rs.c
@@ -83,7 +83,7 @@ struct iwl4965_rate_scale_data {
/**
* struct iwl4965_scale_tbl_info -- tx params and success history for all rates
*
- * There are two of these in struct iwl_rate_scale_priv,
+ * There are two of these in struct iwl4965_rate_scale_priv,
* one for "active", and one for "search".
*/
struct iwl4965_scale_tbl_info {
@@ -99,7 +99,7 @@ struct iwl4965_scale_tbl_info {
};
/**
- * struct iwl_rate_scale_priv -- driver's rate scaling private structure
+ * struct iwl4965_rate_scale_priv -- driver's rate scaling private structure
*
* Pointer to this gets passed back and forth between driver and mac80211.
*/
@@ -2017,8 +2017,8 @@ static void rs_get_rate(void *priv_rate, struct net_device *dev,
struct ieee80211_conf *conf = &local->hw.conf;
struct ieee80211_hdr *hdr = (struct ieee80211_hdr *)skb->data;
struct sta_info *sta;
- struct iwl_priv *priv = (struct iwl_priv *)priv_rate;
- struct iwl_rate_scale_priv *lq;
+ struct iwl4965_priv *priv = (struct iwl4965_priv *)priv_rate;
+ struct iwl4965_rate_scale_priv *lq;
IWL_DEBUG_RATE_LIMIT("rate scale calculate new rate for skb\n");
diff --git a/drivers/net/wireless/iwlwifi/iwl3945-base.c b/drivers/net/wireless/iwlwifi/iwl3945-base.c
index 9d38af4..d702662 100644
--- a/drivers/net/wireless/iwlwifi/iwl3945-base.c
+++ b/drivers/net/wireless/iwlwifi/iwl3945-base.c
@@ -8636,7 +8636,7 @@ static void iwl3945_pci_remove(struct pci_dev *pdev)
set_bit(STATUS_EXIT_PENDING, &priv->status);
- iwl_down(priv);
+ iwl3945_down(priv);
/* Free MAC hash list for ADHOC */
for (i = 0; i < IWL_IBSS_MAC_HASH_SIZE; i++) {
@@ -8698,7 +8698,7 @@ static int iwl3945_pci_suspend(struct pci_dev *pdev, pm_message_t state)
set_bit(STATUS_IN_SUSPEND, &priv->status);
/* Take down the device; powers it off, etc. */
- iwl_down(priv);
+ iwl3945_down(priv);
if (priv->mac80211_registered)
ieee80211_stop_queues(priv->hw);
diff --git a/drivers/net/wireless/iwlwifi/iwl4965-base.c b/drivers/net/wireless/iwlwifi/iwl4965-base.c
index d10f487..4066515 100644
--- a/drivers/net/wireless/iwlwifi/iwl4965-base.c
+++ b/drivers/net/wireless/iwlwifi/iwl4965-base.c
@@ -9206,7 +9206,7 @@ static void iwl4965_pci_remove(struct pci_dev *pdev)
set_bit(STATUS_EXIT_PENDING, &priv->status);
- iwl_down(priv);
+ iwl4965_down(priv);
/* Free MAC hash list for ADHOC */
for (i = 0; i < IWL_IBSS_MAC_HASH_SIZE; i++) {
@@ -9268,7 +9268,7 @@ static int iwl4965_pci_suspend(struct pci_dev *pdev, pm_message_t state)
set_bit(STATUS_IN_SUSPEND, &priv->status);
/* Take down the device; powers it off, etc. */
- iwl_down(priv);
+ iwl4965_down(priv);
if (priv->mac80211_registered)
ieee80211_stop_queues(priv->hw);
^ permalink raw reply related
* Re: [MACVLAN]: Fix thinko in macvlan_transfer_operstate()
From: David Miller @ 2008-01-21 8:47 UTC (permalink / raw)
To: kaber; +Cc: netdev
In-Reply-To: <47935EEC.6010402@trash.net>
From: Patrick McHardy <kaber@trash.net>
Date: Sun, 20 Jan 2008 15:47:08 +0100
> [MACVLAN]: Fix thinko in macvlan_transfer_operstate()
>
> When the lower device's carrier is off, the macvlan devices's
> carrier state should be checked to decide whether it needs to
> be turned off. Currently the lower device's state is checked
> a second time.
>
> This still works, but unnecessarily tries to turn off the
> carrier when its already off.
>
> Signed-off-by: Patrick McHardy <kaber@trash.net>
Applied to net-2.6.25, thanks.
^ permalink raw reply
* Re: [NET_SCHED]: kill obsolete NET_CLS_POLICE option
From: David Miller @ 2008-01-21 8:47 UTC (permalink / raw)
To: kaber; +Cc: netdev
In-Reply-To: <47935F30.9080106@trash.net>
From: Patrick McHardy <kaber@trash.net>
Date: Sun, 20 Jan 2008 15:48:16 +0100
> [NET_SCHED]: kill obsolete NET_CLS_POLICE option
>
> The code is already gone for about half a year, the config option
> has been kept around to select the replacement options for easier
> upgrades. This seems long enough, people upgrading from older
> kernels will have to reconfigure a lot anyway.
>
> Signed-off-by: Patrick McHardy <kaber@trash.net>
Applied to net-2.6.25
^ permalink raw reply
* Re: [PATCH] ipv6: addrconf sparse warnings
From: David Miller @ 2008-01-21 8:48 UTC (permalink / raw)
To: shemminger; +Cc: yoshfuji, netdev
In-Reply-To: <20080120100140.0f5e2fce@deepthought>
From: Stephen Hemminger <shemminger@vyatta.com>
Date: Sun, 20 Jan 2008 10:01:40 -0800
> Get rid of a couple of sparse warnings in IPV6 addrconf code.
>
> Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Applied, thanks Stephen.
^ permalink raw reply
* Re: [PATCH 1/4] dsmark: get rid of wrappers
From: David Miller @ 2008-01-21 8:50 UTC (permalink / raw)
To: shemminger; +Cc: kaber, netdev
In-Reply-To: <20080120131008.2039a35d@deepthought>
From: Stephen Hemminger <shemminger@vyatta.com>
Date: Sun, 20 Jan 2008 13:10:08 -0800
> Remove extraneous macro wrappers for printk and qdisc_priv.
>
> Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
APplied.
^ permalink raw reply
* [PATCH 2/2] IPV6: RFC 2011 compatibility broken
From: Wang Chen @ 2008-01-21 9:46 UTC (permalink / raw)
To: David S. Miller; +Cc: David L Stevens, netdev, Herbert Xu
In-Reply-To: <478DD57B.6020503@cn.fujitsu.com>
[IPV6]: RFC 2011 compatibility broken
The snmp6 entry name was changed, and it broke compatibility
to RFC 2011.
Signed-off-by: Wang Chen <wangchen@cn.fujitsu.com>
--- linux-2.6.24.rc8.org/net/ipv6/proc.c 2008-01-16 17:45:03.000000000 +0800
+++ linux-2.6.24.rc8/net/ipv6/proc.c 2008-01-21 15:48:52.000000000 +0800
@@ -88,7 +88,7 @@ static char *icmp6type2name[256] = {
[ICMPV6_PKT_TOOBIG] = "PktTooBigs",
[ICMPV6_TIME_EXCEED] = "TimeExcds",
[ICMPV6_PARAMPROB] = "ParmProblems",
- [ICMPV6_ECHO_REQUEST] = "EchoRequest",
+ [ICMPV6_ECHO_REQUEST] = "Echos",
[ICMPV6_ECHO_REPLY] = "EchoReplies",
[ICMPV6_MGM_QUERY] = "GroupMembQueries",
[ICMPV6_MGM_REPORT] = "GroupMembResponses",
@@ -98,7 +98,7 @@ static char *icmp6type2name[256] = {
[NDISC_ROUTER_SOLICITATION] = "RouterSolicits",
[NDISC_NEIGHBOUR_ADVERTISEMENT] = "NeighborAdvertisements",
[NDISC_NEIGHBOUR_SOLICITATION] = "NeighborSolicits",
- [NDISC_REDIRECT] = "NeighborRedirects",
+ [NDISC_REDIRECT] = "Redirects",
};
^ permalink raw reply
* [PATCH 1/2] IPV6: ICMP6_MIB_OUTMSGS increment duplicated
From: Wang Chen @ 2008-01-21 9:46 UTC (permalink / raw)
To: David S. Miller; +Cc: David L Stevens, netdev, Herbert Xu
In-Reply-To: <478DD57B.6020503@cn.fujitsu.com>
[IPV6]: ICMP6_MIB_OUTMSGS increment duplicated
icmpv6_send() calls ip6_push_pending_frames() indirectly.
Both ip6_push_pending_frames() and icmpv6_send() increment
counter ICMP6_MIB_OUTMSGS.
This patch remove the increment from icmpv6_send.
Signed-off-by: Wang Chen <wangchen@cn.fujitsu.com>
--- linux-2.6.24.rc8.org/net/ipv6/icmp.c 2008-01-16 17:45:03.000000000 +0800
+++ linux-2.6.24.rc8/net/ipv6/icmp.c 2008-01-21 15:56:06.000000000 +0800
@@ -458,8 +458,6 @@ void icmpv6_send(struct sk_buff *skb, in
}
err = icmpv6_push_pending_frames(sk, &fl, &tmp_hdr, len + sizeof(struct icmp6hdr));
- ICMP6_INC_STATS_BH(idev, ICMP6_MIB_OUTMSGS);
-
out_put:
if (likely(idev != NULL))
in6_dev_put(idev);
^ permalink raw reply
* Re: [PATCH 2/2] IPV6: RFC 2011 compatibility broken
From: YOSHIFUJI Hideaki / 吉藤英明 @ 2008-01-21 9:58 UTC (permalink / raw)
To: wangchen; +Cc: davem, dlstevens, netdev, herbert
In-Reply-To: <47946A04.3080702@cn.fujitsu.com>
In article <47946A04.3080702@cn.fujitsu.com> (at Mon, 21 Jan 2008 17:46:44 +0800), Wang Chen <wangchen@cn.fujitsu.com> says:
> The snmp6 entry name was changed, and it broke compatibility
> to RFC 2011.
>
> Signed-off-by: Wang Chen <wangchen@cn.fujitsu.com>
Acked-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
--yoshfuji
^ permalink raw reply
* Re: [PATCH 1/2] IPV6: ICMP6_MIB_OUTMSGS increment duplicated
From: YOSHIFUJI Hideaki / 吉藤英明 @ 2008-01-21 9:59 UTC (permalink / raw)
To: wangchen; +Cc: davem, dlstevens, netdev, herbert
In-Reply-To: <479469F8.4010203@cn.fujitsu.com>
In article <479469F8.4010203@cn.fujitsu.com> (at Mon, 21 Jan 2008 17:46:32 +0800), Wang Chen <wangchen@cn.fujitsu.com> says:
> [IPV6]: ICMP6_MIB_OUTMSGS increment duplicated
>
> icmpv6_send() calls ip6_push_pending_frames() indirectly.
> Both ip6_push_pending_frames() and icmpv6_send() increment
> counter ICMP6_MIB_OUTMSGS.
>
> This patch remove the increment from icmpv6_send.
>
> Signed-off-by: Wang Chen <wangchen@cn.fujitsu.com>
Acked-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
--yoshfuji
^ permalink raw reply
* Re: [PATCH 2/4] dsmark: get rid of trivial function
From: David Miller @ 2008-01-21 10:22 UTC (permalink / raw)
To: kaber; +Cc: shemminger, netdev
In-Reply-To: <4793E460.5020804@trash.net>
From: Patrick McHardy <kaber@trash.net>
Date: Mon, 21 Jan 2008 01:16:32 +0100
> Stephen Hemminger wrote:
> > Replace loop in dsmark_valid_indices with equivalent bit math.
> >
> > Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
> >
> > --- a/net/sched/sch_dsmark.c 2008-01-20 13:07:58.000000000 -0800
> > +++ b/net/sched/sch_dsmark.c 2008-01-20 13:22:54.000000000 -0800
> > @@ -45,13 +45,8 @@ struct dsmark_qdisc_data {
> >
> > static inline int dsmark_valid_indices(u16 indices)
> > {
> > - while (indices != 1) {
> > - if (indices & 1)
> > - return 0;
> > - indices >>= 1;
> > - }
> > -
> > - return 1;
> > + /* Must have only one bit set */
> > + return (indices & (indices - 1)) == 0;
>
> hweight seems easier to understand, it took me a bit
> to realize that the comment matches the code :)
Sounds good. Here is what I ended up checking in.
[PKT_SCHED] dsmark: Use hweight32() instead of convoluted loop.
Based upon a patch by Stephen Hemminger and suggestions
from Patrick McHardy.
Signed-off-by: David S. Miller <davem@davemloft.net>
diff --git a/net/sched/sch_dsmark.c b/net/sched/sch_dsmark.c
index a9732ae..d96eaf0 100644
--- a/net/sched/sch_dsmark.c
+++ b/net/sched/sch_dsmark.c
@@ -10,6 +10,7 @@
#include <linux/errno.h>
#include <linux/skbuff.h>
#include <linux/rtnetlink.h>
+#include <linux/bitops.h>
#include <net/pkt_sched.h>
#include <net/dsfield.h>
#include <net/inet_ecn.h>
@@ -43,17 +44,6 @@ struct dsmark_qdisc_data {
int set_tc_index;
};
-static inline int dsmark_valid_indices(u16 indices)
-{
- while (indices != 1) {
- if (indices & 1)
- return 0;
- indices >>= 1;
- }
-
- return 1;
-}
-
static inline int dsmark_valid_index(struct dsmark_qdisc_data *p, u16 index)
{
return (index <= p->indices && index > 0);
@@ -348,7 +338,8 @@ static int dsmark_init(struct Qdisc *sch, struct rtattr *opt)
goto errout;
indices = RTA_GET_U16(tb[TCA_DSMARK_INDICES-1]);
- if (!indices || !dsmark_valid_indices(indices))
+
+ if (hweight32(indices) != 1)
goto errout;
if (tb[TCA_DSMARK_DEFAULT_INDEX-1])
^ permalink raw reply related
* Re: [PATCH 3/4] dsmark: handle cloned and non-linear skb's
From: David Miller @ 2008-01-21 10:23 UTC (permalink / raw)
To: shemminger; +Cc: kaber, netdev
In-Reply-To: <20080120132354.55de46ed@deepthought>
From: Stephen Hemminger <shemminger@vyatta.com>
Date: Sun, 20 Jan 2008 13:23:54 -0800
> Make dsmark work properly with non-linear and cloned skb's
> Before modifying the header, it needs to check that skb header is
> writeable.
>
> Note: this makes the assumption, that if it queues a good skb
> then a good skb will come out of the embedded qdisc.
>
> Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Applied.
^ permalink raw reply
* Re: [PATCH 4/4] dsmark: checkpatch warning cleanup
From: David Miller @ 2008-01-21 10:24 UTC (permalink / raw)
To: shemminger; +Cc: kaber, netdev
In-Reply-To: <20080120132536.6f29edda@deepthought>
From: Stephen Hemminger <shemminger@vyatta.com>
Date: Sun, 20 Jan 2008 13:25:36 -0800
> Get rid of all style things checkpatch warns about, indentation
> and whitespace.
>
> Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Applied, thanks.
^ permalink raw reply
* Re: [PATCH] sch_atm: style cleanup
From: David Miller @ 2008-01-21 10:25 UTC (permalink / raw)
To: shemminger; +Cc: kaber, chas, netdev, linux-atm-general
In-Reply-To: <20080120140342.13139be7@deepthought>
From: Stephen Hemminger <shemminger@vyatta.com>
Date: Sun, 20 Jan 2008 14:03:42 -0800
> ATM scheduler clean house:
> * get rid of printk and qdisc_priv() wrapper
> * split some assignment in if() statements
> * whitespace and line breaks.
>
> Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Applied.
^ permalink raw reply
* Re: [PATCH] net classifier: style cleanup's
From: David Miller @ 2008-01-21 10:26 UTC (permalink / raw)
To: shemminger; +Cc: kaber, netdev
In-Reply-To: <20080120140613.10a7d29b@deepthought>
From: Stephen Hemminger <shemminger@vyatta.com>
Date: Sun, 20 Jan 2008 14:06:13 -0800
> Classifier code cleanup. Get rid of printk wrapper, and fix whitespace
> and other style stuff reported by checkpatch
Applied, thanks.
^ permalink raw reply
* Re: [PATCH] net: add sparse annotation to ptype_seq_start/stop
From: David Miller @ 2008-01-21 10:28 UTC (permalink / raw)
To: josh; +Cc: paulmck, shemminger, netdev
In-Reply-To: <479449DC.4020105@freedesktop.org>
From: Josh Triplett <josh@freedesktop.org>
Date: Sun, 20 Jan 2008 23:29:32 -0800
> At the moment, Sparse doesn't actually use the context expression. In
> the ideal case when it does, all references to the same lock should
> use a context expression which resolves to that lock (whatever that
> may mean; hence why Sparse doesn't handle it yet). For mechanisms
> like RCU without a lock variable, this will likely entail some sort of
> fake lock expression, which again needs to match between all users of
> the same mechanism. Like any expression in C, case matters; thus,
> please match the existing references to "RCU" rather than "rcu".
Thus, I've checked in Stephen's patch with __acquires(RCU) and
__releases(RCU).
Thanks.
^ permalink raw reply
* Re: [PATCH 1/3][NET] gen_estimator: faster gen_kill_estimator
From: David Miller @ 2008-01-21 10:35 UTC (permalink / raw)
To: jarkao2; +Cc: netdev, slavon, kaber, hadi
In-Reply-To: <20080120234659.GA2691@ami.dom.local>
From: Jarek Poplawski <jarkao2@gmail.com>
Date: Mon, 21 Jan 2008 00:46:59 +0100
I like the technique you used to fix this bug, but:
> diff -Nurp 2.6.24-rc8-mm1-/include/linux/gen_stats.h 2.6.24-rc8-mm1+/include/linux/gen_stats.h
> --- 2.6.24-rc8-mm1-/include/linux/gen_stats.h 2007-10-09 22:31:38.000000000 +0200
> +++ 2.6.24-rc8-mm1+/include/linux/gen_stats.h 2008-01-20 20:37:08.000000000 +0100
> @@ -28,11 +28,13 @@ struct gnet_stats_basic
> * struct gnet_stats_rate_est - rate estimator
> * @bps: current byte rate
> * @pps: current packet rate
> + * @gen_estimator: internal data
> */
> struct gnet_stats_rate_est
> {
> __u32 bps;
> __u32 pps;
> + unsigned long gen_estimator;
> };
>
> /**
Sorry, this structure is exported to userspace so we can't
change it like that.
It is an attribute passed over netlink sockets.
^ permalink raw reply
* Re: [PATCH 2/3][NET] gen_estimator: list_empty() check in est_timer() fixed
From: David Miller @ 2008-01-21 10:36 UTC (permalink / raw)
To: jarkao2; +Cc: shemminger, slavon, kaber, hadi, netdev
In-Reply-To: <20080121064240.GB981@ff.dom.local>
From: Jarek Poplawski <jarkao2@gmail.com>
Date: Mon, 21 Jan 2008 07:42:40 +0100
> On Mon, Jan 21, 2008 at 07:34:55AM +0100, Jarek Poplawski wrote:
> ...
> > BTW, I've forgotten to mention with patch 1/3 that this checking with
> > warning on gen_new_estimator() double call should be only temporary,
> > and after more testing gen_estimator structure could be probably
> > decreased after removing bstats and rate_est fields.
>
> Hmm, let's forget about this again: it's too early in the morning...
:-)
FWIW I agree that double-negatives are confusing and we should
avoid them.
^ permalink raw reply
* Re: [PATCH 3/3][NET] gen_estimator: gen_replace_estimator() cosmetic changes
From: David Miller @ 2008-01-21 10:36 UTC (permalink / raw)
To: jarkao2; +Cc: netdev, slavon, kaber, hadi
In-Reply-To: <20080120235115.GC2691@ami.dom.local>
From: Jarek Poplawski <jarkao2@gmail.com>
Date: Mon, 21 Jan 2008 00:51:15 +0100
> White spaces etc. are changed in gen_replace_estimator() to make it similar
> to others in a file.
>
> Signed-off-by: Jarek Poplawski <jarkao2@gmail.com>
Applied to net-2.6.25, thanks.
^ permalink raw reply
* Re: [PATCH] [IPV4] route: fix locking in rt_run_flush()
From: David Miller @ 2008-01-21 10:40 UTC (permalink / raw)
To: joonwpark81; +Cc: netdev, dada1
In-Reply-To: <12009281372201-git-send-email-joonwpark81@gmail.com>
From: Joonwoo Park <joonwpark81@gmail.com>
Date: Tue, 22 Jan 2008 00:08:57 +0900
> The rt_run_flush() can be stucked if it was called while netdev is on the
> high load.
> It's possible when pushing rtable to rt_hash is faster than pulling
> from it.
>
> The commands 'ifconfig up or ifconfig mtu' and netif_carrier_on() can
> introduce soft lockup like this:
>
> [ 363.528001] BUG: soft lockup - CPU#0 stuck for 11s! [events/0:9]
> [ 363.531492]
> [ 363.535027] Pid: 9, comm: events/0 Not tainted (2.6.24-rc8 #14)
> [ 363.538837] EIP: 0060:[<c4086a39>] EFLAGS: 00000286 CPU: 0
> [ 363.542762] EIP is at kfree+0xa9/0xf0
> ...
> [ 363.660815] [<c42fb0fd>] skb_release_data+0x5d/0x90
> [ 363.666989] [<c42fb7dc>] skb_release_all+0x5c/0xd0
> [ 363.673207] [<c42faf8b>] __kfree_skb+0xb/0x90
> [ 363.679474] [<c42fb029>] kfree_skb+0x19/0x40
> [ 363.685811] [<c4322d87>] ip_rcv+0x27/0x290
> [ 363.692223] [<c4300ae5>] netif_receive_skb+0x255/0x320
> [ 363.698759] [<f88465aa>] e1000_clean_rx_irq+0x14a/0x4f0 [e1000]
> [ 363.705456] [<f88437c2>] e1000_clean+0x62/0x270 [e1000]
> [ 363.712217] [<c43031ee>] net_rx_action+0x16e/0x220
> [ 363.719065] [<c40346d7>] __do_softirq+0x87/0x100
> [ 363.726001] [<c40347a7>] do_softirq+0x57/0x60
> [ 363.732979] [<c4034b4e>] local_bh_enable_ip+0xae/0x100
> [ 363.740094] [<c43e73f5>] _spin_unlock_bh+0x25/0x30
> [ 363.747283] [<c431ec88>] rt_run_flush+0xc8/0xe0
> [ 363.754566] [<c4320c76>] rt_cache_flush+0xd6/0xe0
> [ 363.761917] [<c4350269>] fib_netdev_event+0x89/0xa0
> [ 363.769361] [<c4047d67>] notifier_call_chain+0x37/0x80
> ...
>
> This patch makes rt_run_flush() to run with softirq is disabled.
>
> Signed-off-by: Joonwoo Park <joonwpark81@gmail.com>
I agree with the analysis of the problem, however not the solution.
This will absolutely kill software interrupt latency.
In fact, we have moved much of the flush work into a workqueue in
net-2.6.25 because of how important that is
We need to find some other way to solve this.
Eric, any ideas?
^ permalink raw reply
* Re: [PATCH 1/3][NET] gen_estimator: faster gen_kill_estimator
From: Jarek Poplawski @ 2008-01-21 10:56 UTC (permalink / raw)
To: David Miller; +Cc: netdev, slavon, kaber, hadi
In-Reply-To: <20080121.023515.256390630.davem@davemloft.net>
On Mon, Jan 21, 2008 at 02:35:15AM -0800, David Miller wrote:
...
> Sorry, this structure is exported to userspace so we can't
> change it like that.
>
> It is an attribute passed over netlink sockets.
>
Thanks for finding this! I'll try to rethink this (especially why
my "tests" seemed to show something could be working there...).
Jarek P.
^ permalink raw reply
* Re: [PATCH 1/2] IPV6: ICMP6_MIB_OUTMSGS increment duplicated
From: David Miller @ 2008-01-21 10:57 UTC (permalink / raw)
To: wangchen; +Cc: dlstevens, netdev, herbert
In-Reply-To: <479469F8.4010203@cn.fujitsu.com>
From: Wang Chen <wangchen@cn.fujitsu.com>
Date: Mon, 21 Jan 2008 17:46:32 +0800
> [IPV6]: ICMP6_MIB_OUTMSGS increment duplicated
>
> icmpv6_send() calls ip6_push_pending_frames() indirectly.
> Both ip6_push_pending_frames() and icmpv6_send() increment
> counter ICMP6_MIB_OUTMSGS.
>
> This patch remove the increment from icmpv6_send.
>
> Signed-off-by: Wang Chen <wangchen@cn.fujitsu.com>
Which tree are these two changes targetted at?
^ permalink raw reply
* Re: [PATCH 1/2] IPV6: ICMP6_MIB_OUTMSGS increment duplicated
From: Wang Chen @ 2008-01-21 10:59 UTC (permalink / raw)
To: David Miller; +Cc: dlstevens, netdev, herbert
In-Reply-To: <20080121.025722.147904573.davem@davemloft.net>
David Miller said the following on 2008-1-21 18:57:
>> [IPV6]: ICMP6_MIB_OUTMSGS increment duplicated
>>
>> icmpv6_send() calls ip6_push_pending_frames() indirectly.
>> Both ip6_push_pending_frames() and icmpv6_send() increment
>> counter ICMP6_MIB_OUTMSGS.
>>
>> This patch remove the increment from icmpv6_send.
>>
>> Signed-off-by: Wang Chen <wangchen@cn.fujitsu.com>
>
> Which tree are these two changes targetted at?
>
>
Dave, because the network of my working place can't clone git
tree, I used 2.6.24-rc8 to make the patches.
Can you apply them to net-2.6 tree?
^ permalink raw reply
* IPv6 problems (mtu is less than advmss?)
From: Jim Paris @ 2008-01-21 10:52 UTC (permalink / raw)
To: netdev
Hi,
When the IPv6 default route is first autoconfigured, it seems the
advertised MSS doesn't get set properly.
I have computer A connected to an external interface with IPv4 and
tunneling IPv6 using 6to4. It runs radvd on an internal interface to
provide connectivity to my LAN. radvd.conf contains:
interface brint {
AdvLinkMTU 1420; # advertise tiny MTU due to tunnel
AdvSendAdvert on;
prefix 0:0:0:1::/64
{ Base6to4Interface brext; };
};
Computer B is on the LAN and autoconfigures an IPv6 address. However,
I have problems with some specific hosts [1]. They're probably doing
broken ICMP/PMTU filtering or something, but I've tracked down some
weirdness in the kernel:
computerA# /etc/init.d/radvd start
computerB# ifconfig eth0 down
computerB# ifconfig eth0 up
computerB# ip -6 route
2002:125f:205:1::/64 dev eth0 proto kernel metric 256 expires 2592312sec mtu 1420 advmss 1360 hoplimit 4294967295
fe80::/64 dev eth0 metric 256 expires 21334361sec mtu 1420 advmss 1360 hoplimit 4294967295
ff00::/8 dev eth0 metric 256 expires 21334361sec mtu 1420 advmss 1360 hoplimit 4294967295
default via fe80::230:48ff:fe8b:5df4 dev eth0 proto kernel metric 1024 expires 1788sec mtu 1420 advmss 1440 hoplimit 64
At this point, I see the network problems. Note how the advmss in the
last line is not only larger than all the other lines, it's even
bigger than the MTU. I won't be able to download [1] until I manually
fix advmss, _or_ just restart radvd on the other computer:
computerA# /etc/init.d/radvd restart
computerB# ip -6 route
2002:125f:205:1::/64 dev eth0 proto kernel metric 256 expires 2592160sec mtu 1420 advmss 1360 hoplimit 4294967295
fe80::/64 dev eth0 metric 256 expires 21334355sec mtu 1420 advmss 1360 hoplimit 4294967295
ff00::/8 dev eth0 metric 256 expires 21334355sec mtu 1420 advmss 1360 hoplimit 4294967295
default via fe80::230:48ff:fe8b:5df4 dev eth0 proto kernel metric 1024 expires 1798sec mtu 1420 advmss 1360 hoplimit 64
Now the advmss is better and everything works fine. It seems that if
it's being created for the first time, the advmss is not correctly set
based on the MTU, but if there's already a route when it gets the RA,
it reconfigures it correctly.
Computer A is 2.6.23.1 and computer B is 2.6.24-rc8, both x86_64.
Any suggestions or other debugging I can do?
-jim
[1] wget -6 http://releases.mozilla.org/pub/mozilla.org/addons/12/all-in-one_gestures-0.18.0-fx.xpi
^ 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