* Re: [PATCH] NFS: Fix infinite loop in gss_create_upcall()
From: Jiri Slaby @ 2011-04-12 18:05 UTC (permalink / raw)
To: Bryan Schumaker
Cc: Jiri Slaby, Myklebust, Trond, linux-kernel-u79uwXL29TY76Z2rM5mHXA,
akpm-de/tnXTf+JLsfHDXvbKv3WD2FQJk+8+b,
mm-commits-u79uwXL29TY76Z2rM5mHXA, ML netdev,
linux-nfs-u79uwXL29TY76Z2rM5mHXA
In-Reply-To: <4DA48EB0.40600-HgOvQuBEEgTQT0dZR+AlfA@public.gmane.org>
On 04/12/2011 07:41 PM, Bryan Schumaker wrote:
> On 04/11/2011 05:08 PM, Jiri Slaby wrote:
>>
>> Sorry for an extra message. I've just found out that there appears
>> messages in dmesg:
>> [ 58.656048] RPC: AUTH_GSS upcall timed out.
>> [ 58.656050] Please check user daemon is running.
>> [ 88.656065] RPC: AUTH_GSS upcall timed out.
>> [ 88.656068] Please check user daemon is running.
>> [ 118.656077] RPC: AUTH_GSS upcall timed out.
>> [ 118.656080] Please check user daemon is running.
>> [ 148.656049] RPC: AUTH_GSS upcall timed out.
>> [ 148.656052] Please check user daemon is running.
>> [ 178.656046] RPC: AUTH_GSS upcall timed out.
>> [ 178.656049] Please check user daemon is running.
>>
>>
>> I instrumented the code and it's stuck with trying RPC_AUTH_GSS_KRB5.
>>
>> I don't use GSS at all.
>>
>> regards,
>
> Does this patch help?
>
> - Bryan
>
>
>
> There can be an infinite loop if gss_create_upcall() is called without
> the userspace program running. To prevent this, we return -EACCES if
> we notice that pipe_version hasn't changed (indicating that the pipe
> has not been opened).
Yes, it fixes the problem. But it waits 15s before it times out. This is
inacceptable for automounted NFS dirs.
thanks,
--
js
suse labs
--
To unsubscribe from this list: send the line "unsubscribe linux-nfs" 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: [net-next-2.6 RFC PATCH] ethtool: allow custom interval for physical identification
From: Allan, Bruce W @ 2011-04-12 18:17 UTC (permalink / raw)
To: Ben Hutchings; +Cc: Stephen Hemminger, netdev@vger.kernel.org
In-Reply-To: <1302625686.2880.24.camel@bwh-desktop>
>-----Original Message-----
>From: Ben Hutchings [mailto:bhutchings@solarflare.com]
>Sent: Tuesday, April 12, 2011 9:28 AM
>To: Allan, Bruce W
>Cc: Stephen Hemminger; netdev@vger.kernel.org
>Subject: RE: [net-next-2.6 RFC PATCH] ethtool: allow custom interval for
>physical identification
>
>I enquired here and found that we do have an OEM specifying 1 Hz.
>
>> FWIW, without digging too deep into how other drivers identify their
>> respective ports through software, it appears it was split:
>> * bnx2*, cxgb3, niu, s2io, sfc, sky2, tg3 - once per second
>> * e100*, igb, ixgb*, pcnet32, ewrk3, cxgb4 - approx. twice per second
>>
>> AFAIK for parts that can set the physical identification through hardware,
>> the Intel drivers set the on/off intervals to approximately twice/second;
>> I don't know what other drivers do in that situation.
>>
>> So, I would guess it is not a common requirement to blink at a specific Hz.
>> I have no problem with changing the hard-coded blink frequency to what our
>> OEMs expect, but that might be an issue for those other vendors; I was just
>> trying to make it flexible.
>
>Sadly it appears this is necessary.
>
>Let's define the return value for drivers wanting periodic callbacks to
>be the blink frequency in Hz (normally 1 or 2), and get rid of the
>special case of -EINVAL. This also removes the rather inelegant
>semantic that drivers may need to change their state despite returning
>an error code.
>
>Ben.
OK. Would you like me to send an updated patch?
Bruce.
^ permalink raw reply
* Re: [PATCH] s2io: Fix warnings due to -Wunused-but-set-variable.
From: David Miller @ 2011-04-12 18:21 UTC (permalink / raw)
To: jdmason; +Cc: netdev
In-Reply-To: <20110412160002.GB1433@kudzu.us>
From: Jon Mason <jdmason@kudzu.us>
Date: Tue, 12 Apr 2011 11:00:04 -0500
> On Mon, Apr 11, 2011 at 04:01:43PM -0700, David Miller wrote:
>>
>> Most of these are cases where we are trying to read back a register
>> after a write to ensure completion.
>>
>> Simply pre-fixing the readl() or readq() with "(void)" is sufficient
>> because these are volatile operations and the compiler cannot eliminate
>> them just because no real assignment takes place.
>>
>> The case of free_rxd_blk()'s assignments to "struct buffAdd *ba" is a
>> real spurious assignment as this variable is completely otherwise
>> unused.
>>
>> Signed-off-by: David S. Miller <davem@davemloft.net>
> Acked-by: Jon Mason <jdmason@kudzu.us>
Thanks for reviewing.
^ permalink raw reply
* RE: [net-next-2.6 RFC PATCH] ethtool: allow custom interval for physical identification
From: Ben Hutchings @ 2011-04-12 18:23 UTC (permalink / raw)
To: Allan, Bruce W; +Cc: Stephen Hemminger, netdev@vger.kernel.org
In-Reply-To: <8DD2590731AB5D4C9DBF71A877482A90018A2A3559@orsmsx509.amr.corp.intel.com>
On Tue, 2011-04-12 at 11:17 -0700, Allan, Bruce W wrote:
> >-----Original Message-----
> >From: Ben Hutchings [mailto:bhutchings@solarflare.com]
> >Sent: Tuesday, April 12, 2011 9:28 AM
> >To: Allan, Bruce W
> >Cc: Stephen Hemminger; netdev@vger.kernel.org
> >Subject: RE: [net-next-2.6 RFC PATCH] ethtool: allow custom interval for
> >physical identification
> >
> >I enquired here and found that we do have an OEM specifying 1 Hz.
> >
> >> FWIW, without digging too deep into how other drivers identify their
> >> respective ports through software, it appears it was split:
> >> * bnx2*, cxgb3, niu, s2io, sfc, sky2, tg3 - once per second
> >> * e100*, igb, ixgb*, pcnet32, ewrk3, cxgb4 - approx. twice per second
> >>
> >> AFAIK for parts that can set the physical identification through hardware,
> >> the Intel drivers set the on/off intervals to approximately twice/second;
> >> I don't know what other drivers do in that situation.
> >>
> >> So, I would guess it is not a common requirement to blink at a specific Hz.
> >> I have no problem with changing the hard-coded blink frequency to what our
> >> OEMs expect, but that might be an issue for those other vendors; I was just
> >> trying to make it flexible.
> >
> >Sadly it appears this is necessary.
> >
> >Let's define the return value for drivers wanting periodic callbacks to
> >be the blink frequency in Hz (normally 1 or 2), and get rid of the
> >special case of -EINVAL. This also removes the rather inelegant
> >semantic that drivers may need to change their state despite returning
> >an error code.
> >
> >Ben.
>
> OK. Would you like me to send an updated patch?
Please.
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] NFS: Fix infinite loop in gss_create_upcall()
From: Trond Myklebust @ 2011-04-12 18:31 UTC (permalink / raw)
To: Jiri Slaby
Cc: Bryan Schumaker, Jiri Slaby, linux-kernel, akpm, mm-commits,
ML netdev, linux-nfs
In-Reply-To: <4DA4946D.5020403@suse.cz>
On Tue, 2011-04-12 at 20:05 +0200, Jiri Slaby wrote:
> On 04/12/2011 07:41 PM, Bryan Schumaker wrote:
> > On 04/11/2011 05:08 PM, Jiri Slaby wrote:
> >>
> >> Sorry for an extra message. I've just found out that there appears
> >> messages in dmesg:
> >> [ 58.656048] RPC: AUTH_GSS upcall timed out.
> >> [ 58.656050] Please check user daemon is running.
> >> [ 88.656065] RPC: AUTH_GSS upcall timed out.
> >> [ 88.656068] Please check user daemon is running.
> >> [ 118.656077] RPC: AUTH_GSS upcall timed out.
> >> [ 118.656080] Please check user daemon is running.
> >> [ 148.656049] RPC: AUTH_GSS upcall timed out.
> >> [ 148.656052] Please check user daemon is running.
> >> [ 178.656046] RPC: AUTH_GSS upcall timed out.
> >> [ 178.656049] Please check user daemon is running.
> >>
> >>
> >> I instrumented the code and it's stuck with trying RPC_AUTH_GSS_KRB5.
> >>
> >> I don't use GSS at all.
> >>
> >> regards,
> >
> > Does this patch help?
> >
> > - Bryan
> >
> >
> >
> > There can be an infinite loop if gss_create_upcall() is called without
> > the userspace program running. To prevent this, we return -EACCES if
> > we notice that pipe_version hasn't changed (indicating that the pipe
> > has not been opened).
>
> Yes, it fixes the problem. But it waits 15s before it times out. This is
> inacceptable for automounted NFS dirs.
I'm still confused as to why you are hitting it at all. In the normal
autonegotiation case, the client should be trying to use AUTH_SYS first
and then trying rpcsec_gss if and only if that fails.
Are you really exporting a filesystem using AUTH_NULL as the only
supported flavour?
--
Trond Myklebust
Linux NFS client maintainer
NetApp
Trond.Myklebust@netapp.com
www.netapp.com
^ permalink raw reply
* Re: [PATCH] NFS: Fix infinite loop in gss_create_upcall()
From: Jiri Slaby @ 2011-04-12 18:34 UTC (permalink / raw)
To: Trond Myklebust
Cc: Bryan Schumaker, Jiri Slaby, linux-kernel-u79uwXL29TY76Z2rM5mHXA,
akpm-de/tnXTf+JLsfHDXvbKv3WD2FQJk+8+b,
mm-commits-u79uwXL29TY76Z2rM5mHXA, ML netdev,
linux-nfs-u79uwXL29TY76Z2rM5mHXA
In-Reply-To: <1302633088.4801.48.camel-SyLVLa/KEI9HwK5hSS5vWB2eb7JE58TQ@public.gmane.org>
On 04/12/2011 08:31 PM, Trond Myklebust wrote:
>> Yes, it fixes the problem. But it waits 15s before it times out. This is
>> inacceptable for automounted NFS dirs.
>
> I'm still confused as to why you are hitting it at all. In the normal
> autonegotiation case, the client should be trying to use AUTH_SYS first
> and then trying rpcsec_gss if and only if that fails.
>
> Are you really exporting a filesystem using AUTH_NULL as the only
> supported flavour?
I don't know, I connect to a nfs server which is not maintained by me.
It looks like that. How can I find out?
thanks,
--
js
suse labs
--
To unsubscribe from this list: send the line "unsubscribe linux-nfs" 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: [PATCH] NFS: Fix infinite loop in gss_create_upcall()
From: Trond Myklebust @ 2011-04-12 18:38 UTC (permalink / raw)
To: Jiri Slaby
Cc: Bryan Schumaker, Jiri Slaby, linux-kernel-u79uwXL29TY76Z2rM5mHXA,
akpm-de/tnXTf+JLsfHDXvbKv3WD2FQJk+8+b,
mm-commits-u79uwXL29TY76Z2rM5mHXA, ML netdev,
linux-nfs-u79uwXL29TY76Z2rM5mHXA
In-Reply-To: <4DA49B49.1020005-AlSwsSmVLrQ@public.gmane.org>
On Tue, 2011-04-12 at 20:34 +0200, Jiri Slaby wrote:
> On 04/12/2011 08:31 PM, Trond Myklebust wrote:
> >> Yes, it fixes the problem. But it waits 15s before it times out. This is
> >> inacceptable for automounted NFS dirs.
> >
> > I'm still confused as to why you are hitting it at all. In the normal
> > autonegotiation case, the client should be trying to use AUTH_SYS first
> > and then trying rpcsec_gss if and only if that fails.
> >
> > Are you really exporting a filesystem using AUTH_NULL as the only
> > supported flavour?
>
> I don't know, I connect to a nfs server which is not maintained by me.
> It looks like that. How can I find out?
A wireshark trace of a successful mount would help.
--
Trond Myklebust
Linux NFS client maintainer
NetApp
Trond.Myklebust-HgOvQuBEEgTQT0dZR+AlfA@public.gmane.org
www.netapp.com
--
To unsubscribe from this list: send the line "unsubscribe linux-nfs" 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: [PATCH] NFS: Fix infinite loop in gss_create_upcall()
From: Bryan Schumaker @ 2011-04-12 18:43 UTC (permalink / raw)
To: Jiri Slaby
Cc: Trond Myklebust, Jiri Slaby, linux-kernel-u79uwXL29TY76Z2rM5mHXA,
akpm-de/tnXTf+JLsfHDXvbKv3WD2FQJk+8+b,
mm-commits-u79uwXL29TY76Z2rM5mHXA, ML netdev,
linux-nfs-u79uwXL29TY76Z2rM5mHXA
In-Reply-To: <4DA49B49.1020005-AlSwsSmVLrQ@public.gmane.org>
On 04/12/2011 02:34 PM, Jiri Slaby wrote:
> On 04/12/2011 08:31 PM, Trond Myklebust wrote:
>>> Yes, it fixes the problem. But it waits 15s before it times out. This is
>>> inacceptable for automounted NFS dirs.
>>
>> I'm still confused as to why you are hitting it at all. In the normal
>> autonegotiation case, the client should be trying to use AUTH_SYS first
>> and then trying rpcsec_gss if and only if that fails.
>>
>> Are you really exporting a filesystem using AUTH_NULL as the only
>> supported flavour?
>
> I don't know, I connect to a nfs server which is not maintained by me.
> It looks like that. How can I find out?
If you're not using gss for anything, you could try rmmod-ing rpcsec_gss_krb5 (and other rpcsec_gss_* modules).
- Bryan
>
> thanks,
--
To unsubscribe from this list: send the line "unsubscribe linux-nfs" 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: [PATCH] NFS: Fix infinite loop in gss_create_upcall()
From: Jiri Slaby @ 2011-04-12 18:52 UTC (permalink / raw)
To: Bryan Schumaker
Cc: Trond Myklebust, Jiri Slaby, linux-kernel-u79uwXL29TY76Z2rM5mHXA,
akpm-de/tnXTf+JLsfHDXvbKv3WD2FQJk+8+b,
mm-commits-u79uwXL29TY76Z2rM5mHXA, ML netdev,
linux-nfs-u79uwXL29TY76Z2rM5mHXA
In-Reply-To: <4DA49D3A.7090800-HgOvQuBEEgTQT0dZR+AlfA@public.gmane.org>
On 04/12/2011 08:43 PM, Bryan Schumaker wrote:
> On 04/12/2011 02:34 PM, Jiri Slaby wrote:
>> On 04/12/2011 08:31 PM, Trond Myklebust wrote:
>>>> Yes, it fixes the problem. But it waits 15s before it times out. This is
>>>> inacceptable for automounted NFS dirs.
>>>
>>> I'm still confused as to why you are hitting it at all. In the normal
>>> autonegotiation case, the client should be trying to use AUTH_SYS first
>>> and then trying rpcsec_gss if and only if that fails.
>>>
>>> Are you really exporting a filesystem using AUTH_NULL as the only
>>> supported flavour?
>>
>> I don't know, I connect to a nfs server which is not maintained by me.
>> It looks like that. How can I find out?
>
> If you're not using gss for anything, you could try rmmod-ing rpcsec_gss_krb5 (and other rpcsec_gss_* modules).
I don't have NFS in modules. It's all built-in. And this one is
unconditionally selected because of CONFIG_NFS_V4.
regards,
--
js
suse labs
--
To unsubscribe from this list: send the line "unsubscribe linux-nfs" 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
* [PATCH] net: bna: convert to hw_features
From: Michał Mirosław @ 2011-04-12 19:38 UTC (permalink / raw)
To: netdev; +Cc: Rasesh Mody, Debashis Dutt
Note: looks like bnad->conf_mutex is duplicating rtnl_lock.
Signed-off-by: Michał Mirosław <mirq-linux@rere.qmqm.pl>
---
drivers/net/bna/bnad.c | 22 ++++++--------
drivers/net/bna/bnad.h | 2 -
drivers/net/bna/bnad_ethtool.c | 63 ----------------------------------------
3 files changed, 9 insertions(+), 78 deletions(-)
diff --git a/drivers/net/bna/bnad.c b/drivers/net/bna/bnad.c
index 9f356d5..b9f2534 100644
--- a/drivers/net/bna/bnad.c
+++ b/drivers/net/bna/bnad.c
@@ -501,7 +501,7 @@ bnad_poll_cq(struct bnad *bnad, struct bna_ccb *ccb, int budget)
skb_put(skb, ntohs(cmpl->length));
if (likely
- (bnad->rx_csum &&
+ ((bnad->netdev->features & NETIF_F_RXCSUM) &&
(((flags & BNA_CQ_EF_IPV4) &&
(flags & BNA_CQ_EF_L3_CKSUM_OK)) ||
(flags & BNA_CQ_EF_IPV6)) &&
@@ -2903,23 +2903,20 @@ bnad_netdev_init(struct bnad *bnad, bool using_dac)
{
struct net_device *netdev = bnad->netdev;
- netdev->features |= NETIF_F_IPV6_CSUM;
- netdev->features |= NETIF_F_TSO;
- netdev->features |= NETIF_F_TSO6;
+ netdev->hw_features = NETIF_F_SG | NETIF_F_RXCSUM |
+ NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM |
+ NETIF_F_TSO | NETIF_F_TSO6 | NETIF_F_HW_VLAN_TX;
- netdev->features |= NETIF_F_GRO;
- pr_warn("bna: GRO enabled, using kernel stack GRO\n");
+ netdev->vlan_features = NETIF_F_SG | NETIF_F_HIGHDMA |
+ NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM |
+ NETIF_F_TSO | NETIF_F_TSO6;
- netdev->features |= NETIF_F_SG | NETIF_F_IP_CSUM;
+ netdev->features |= netdev->hw_features |
+ NETIF_F_HW_VLAN_RX | NETIF_F_HW_VLAN_FILTER;
if (using_dac)
netdev->features |= NETIF_F_HIGHDMA;
- netdev->features |=
- NETIF_F_HW_VLAN_TX | NETIF_F_HW_VLAN_RX |
- NETIF_F_HW_VLAN_FILTER;
-
- netdev->vlan_features = netdev->features;
netdev->mem_start = bnad->mmio_start;
netdev->mem_end = bnad->mmio_start + bnad->mmio_len - 1;
@@ -2970,7 +2967,6 @@ bnad_init(struct bnad *bnad,
bnad->txq_depth = BNAD_TXQ_DEPTH;
bnad->rxq_depth = BNAD_RXQ_DEPTH;
- bnad->rx_csum = true;
bnad->tx_coalescing_timeo = BFI_TX_COALESCING_TIMEO;
bnad->rx_coalescing_timeo = BFI_RX_COALESCING_TIMEO;
diff --git a/drivers/net/bna/bnad.h b/drivers/net/bna/bnad.h
index a89117f..ccdabad 100644
--- a/drivers/net/bna/bnad.h
+++ b/drivers/net/bna/bnad.h
@@ -237,8 +237,6 @@ struct bnad {
struct bna_rx_config rx_config[BNAD_MAX_RXS];
struct bna_tx_config tx_config[BNAD_MAX_TXS];
- u32 rx_csum;
-
void __iomem *bar0; /* BAR0 address */
struct bna bna;
diff --git a/drivers/net/bna/bnad_ethtool.c b/drivers/net/bna/bnad_ethtool.c
index 142d604..c51e078e 100644
--- a/drivers/net/bna/bnad_ethtool.c
+++ b/drivers/net/bna/bnad_ethtool.c
@@ -806,61 +806,6 @@ bnad_set_pauseparam(struct net_device *netdev,
return 0;
}
-static u32
-bnad_get_rx_csum(struct net_device *netdev)
-{
- u32 rx_csum;
- struct bnad *bnad = netdev_priv(netdev);
-
- rx_csum = bnad->rx_csum;
- return rx_csum;
-}
-
-static int
-bnad_set_rx_csum(struct net_device *netdev, u32 rx_csum)
-{
- struct bnad *bnad = netdev_priv(netdev);
-
- mutex_lock(&bnad->conf_mutex);
- bnad->rx_csum = rx_csum;
- mutex_unlock(&bnad->conf_mutex);
- return 0;
-}
-
-static int
-bnad_set_tx_csum(struct net_device *netdev, u32 tx_csum)
-{
- struct bnad *bnad = netdev_priv(netdev);
-
- mutex_lock(&bnad->conf_mutex);
- if (tx_csum) {
- netdev->features |= NETIF_F_IP_CSUM;
- netdev->features |= NETIF_F_IPV6_CSUM;
- } else {
- netdev->features &= ~NETIF_F_IP_CSUM;
- netdev->features &= ~NETIF_F_IPV6_CSUM;
- }
- mutex_unlock(&bnad->conf_mutex);
- return 0;
-}
-
-static int
-bnad_set_tso(struct net_device *netdev, u32 tso)
-{
- struct bnad *bnad = netdev_priv(netdev);
-
- mutex_lock(&bnad->conf_mutex);
- if (tso) {
- netdev->features |= NETIF_F_TSO;
- netdev->features |= NETIF_F_TSO6;
- } else {
- netdev->features &= ~NETIF_F_TSO;
- netdev->features &= ~NETIF_F_TSO6;
- }
- mutex_unlock(&bnad->conf_mutex);
- return 0;
-}
-
static void
bnad_get_strings(struct net_device *netdev, u32 stringset, u8 * string)
{
@@ -1256,14 +1201,6 @@ static struct ethtool_ops bnad_ethtool_ops = {
.set_ringparam = bnad_set_ringparam,
.get_pauseparam = bnad_get_pauseparam,
.set_pauseparam = bnad_set_pauseparam,
- .get_rx_csum = bnad_get_rx_csum,
- .set_rx_csum = bnad_set_rx_csum,
- .get_tx_csum = ethtool_op_get_tx_csum,
- .set_tx_csum = bnad_set_tx_csum,
- .get_sg = ethtool_op_get_sg,
- .set_sg = ethtool_op_set_sg,
- .get_tso = ethtool_op_get_tso,
- .set_tso = bnad_set_tso,
.get_strings = bnad_get_strings,
.get_ethtool_stats = bnad_get_ethtool_stats,
.get_sset_count = bnad_get_sset_count
--
1.7.2.5
^ permalink raw reply related
* [PATCH v5] net: bnx2x: convert to hw_features
From: Michał Mirosław @ 2011-04-12 19:38 UTC (permalink / raw)
To: netdev; +Cc: Vladislav Zolotarov, Eilon Greenstein
In-Reply-To: <20110412144940.GA26043@rere.qmqm.pl>
Since ndo_fix_features callback is postponing features change when
bp->recovery_state != BNX2X_RECOVERY_DONE, netdev_update_features()
has to be called again when this condition changes. Previously,
ethtool_ops->set_flags callback returned -EBUSY in that case
(it's not possible in the new model).
Signed-off-by: Michał Mirosław <mirq-linux@rere.qmqm.pl>
v5: - don't delay set_features, as it's rtnl_locked - same as recovery process
v4: - complete bp->rx_csum -> NETIF_F_RXCSUM conversion
- add check for failed ndo_set_features in ndo_open callback
v3: - include NETIF_F_LRO in hw_features
- don't call netdev_update_features() if bnx2x_nic_load() failed
v2: - comment in ndo_fix_features callback
---
drivers/net/bnx2x/bnx2x.h | 1 -
drivers/net/bnx2x/bnx2x_cmn.c | 49 +++++++++++++++++--
drivers/net/bnx2x/bnx2x_cmn.h | 3 +
drivers/net/bnx2x/bnx2x_ethtool.c | 95 -------------------------------------
drivers/net/bnx2x/bnx2x_main.c | 27 ++++------
5 files changed, 57 insertions(+), 118 deletions(-)
diff --git a/drivers/net/bnx2x/bnx2x.h b/drivers/net/bnx2x/bnx2x.h
index e0fca70..9e87417 100644
--- a/drivers/net/bnx2x/bnx2x.h
+++ b/drivers/net/bnx2x/bnx2x.h
@@ -918,7 +918,6 @@ struct bnx2x {
int tx_ring_size;
- u32 rx_csum;
/* L2 header size + 2*VLANs (8 bytes) + LLC SNAP (8 bytes) */
#define ETH_OVREHEAD (ETH_HLEN + 8 + 8)
#define ETH_MIN_PACKET_SIZE 60
diff --git a/drivers/net/bnx2x/bnx2x_cmn.c b/drivers/net/bnx2x/bnx2x_cmn.c
index e83ac6d..bec33a8 100644
--- a/drivers/net/bnx2x/bnx2x_cmn.c
+++ b/drivers/net/bnx2x/bnx2x_cmn.c
@@ -640,7 +640,7 @@ reuse_rx:
skb_checksum_none_assert(skb);
- if (bp->rx_csum) {
+ if (bp->dev->features & NETIF_F_RXCSUM) {
if (likely(BNX2X_RX_CSUM_OK(cqe)))
skb->ip_summed = CHECKSUM_UNNECESSARY;
else
@@ -2443,11 +2443,21 @@ alloc_err:
}
+static int bnx2x_reload_if_running(struct net_device *dev)
+{
+ struct bnx2x *bp = netdev_priv(dev);
+
+ if (unlikely(!netif_running(dev)))
+ return 0;
+
+ bnx2x_nic_unload(bp, UNLOAD_NORMAL);
+ return bnx2x_nic_load(bp, LOAD_NORMAL);
+}
+
/* called with rtnl_lock */
int bnx2x_change_mtu(struct net_device *dev, int new_mtu)
{
struct bnx2x *bp = netdev_priv(dev);
- int rc = 0;
if (bp->recovery_state != BNX2X_RECOVERY_DONE) {
printk(KERN_ERR "Handling parity error recovery. Try again later\n");
@@ -2464,12 +2474,39 @@ int bnx2x_change_mtu(struct net_device *dev, int new_mtu)
*/
dev->mtu = new_mtu;
- if (netif_running(dev)) {
- bnx2x_nic_unload(bp, UNLOAD_NORMAL);
- rc = bnx2x_nic_load(bp, LOAD_NORMAL);
+ return bnx2x_reload_if_running(dev);
+}
+
+u32 bnx2x_fix_features(struct net_device *dev, u32 features)
+{
+ struct bnx2x *bp = netdev_priv(dev);
+
+ /* TPA requires Rx CSUM offloading */
+ if (!(features & NETIF_F_RXCSUM) || bp->disable_tpa)
+ features &= ~NETIF_F_LRO;
+
+ return features;
+}
+
+int bnx2x_set_features(struct net_device *dev, u32 features)
+{
+ struct bnx2x *bp = netdev_priv(dev);
+ u32 flags = bp->flags;
+
+ if (features & NETIF_F_LRO)
+ flags |= TPA_ENABLE_FLAG;
+ else
+ flags &= ~TPA_ENABLE_FLAG;
+
+ if (flags ^ bp->flags) {
+ bp->flags = flags;
+
+ if (bp->recovery_state == BNX2X_RECOVERY_DONE)
+ return bnx2x_reload_if_running(dev);
+ /* else: bnx2x_nic_load() will be called at end of recovery */
}
- return rc;
+ return 0;
}
void bnx2x_tx_timeout(struct net_device *dev)
diff --git a/drivers/net/bnx2x/bnx2x_cmn.h b/drivers/net/bnx2x/bnx2x_cmn.h
index 775fef0..1cdab69 100644
--- a/drivers/net/bnx2x/bnx2x_cmn.h
+++ b/drivers/net/bnx2x/bnx2x_cmn.h
@@ -431,6 +431,9 @@ void bnx2x_free_mem_bp(struct bnx2x *bp);
*/
int bnx2x_change_mtu(struct net_device *dev, int new_mtu);
+u32 bnx2x_fix_features(struct net_device *dev, u32 features);
+int bnx2x_set_features(struct net_device *dev, u32 features);
+
/**
* tx timeout netdev callback
*
diff --git a/drivers/net/bnx2x/bnx2x_ethtool.c b/drivers/net/bnx2x/bnx2x_ethtool.c
index 1479994..ad7d91e 100644
--- a/drivers/net/bnx2x/bnx2x_ethtool.c
+++ b/drivers/net/bnx2x/bnx2x_ethtool.c
@@ -1299,91 +1299,6 @@ static int bnx2x_set_pauseparam(struct net_device *dev,
return 0;
}
-static int bnx2x_set_flags(struct net_device *dev, u32 data)
-{
- struct bnx2x *bp = netdev_priv(dev);
- int changed = 0;
- int rc = 0;
-
- if (bp->recovery_state != BNX2X_RECOVERY_DONE) {
- printk(KERN_ERR "Handling parity error recovery. Try again later\n");
- return -EAGAIN;
- }
-
- if (!(data & ETH_FLAG_RXVLAN))
- return -EINVAL;
-
- if ((data & ETH_FLAG_LRO) && bp->rx_csum && bp->disable_tpa)
- return -EINVAL;
-
- rc = ethtool_op_set_flags(dev, data, ETH_FLAG_LRO | ETH_FLAG_RXVLAN |
- ETH_FLAG_TXVLAN | ETH_FLAG_RXHASH);
- if (rc)
- return rc;
-
- /* TPA requires Rx CSUM offloading */
- if ((data & ETH_FLAG_LRO) && bp->rx_csum) {
- if (!(bp->flags & TPA_ENABLE_FLAG)) {
- bp->flags |= TPA_ENABLE_FLAG;
- changed = 1;
- }
- } else if (bp->flags & TPA_ENABLE_FLAG) {
- dev->features &= ~NETIF_F_LRO;
- bp->flags &= ~TPA_ENABLE_FLAG;
- changed = 1;
- }
-
- if (changed && netif_running(dev)) {
- bnx2x_nic_unload(bp, UNLOAD_NORMAL);
- rc = bnx2x_nic_load(bp, LOAD_NORMAL);
- }
-
- return rc;
-}
-
-static u32 bnx2x_get_rx_csum(struct net_device *dev)
-{
- struct bnx2x *bp = netdev_priv(dev);
-
- return bp->rx_csum;
-}
-
-static int bnx2x_set_rx_csum(struct net_device *dev, u32 data)
-{
- struct bnx2x *bp = netdev_priv(dev);
- int rc = 0;
-
- if (bp->recovery_state != BNX2X_RECOVERY_DONE) {
- printk(KERN_ERR "Handling parity error recovery. Try again later\n");
- return -EAGAIN;
- }
-
- bp->rx_csum = data;
-
- /* Disable TPA, when Rx CSUM is disabled. Otherwise all
- TPA'ed packets will be discarded due to wrong TCP CSUM */
- if (!data) {
- u32 flags = ethtool_op_get_flags(dev);
-
- rc = bnx2x_set_flags(dev, (flags & ~ETH_FLAG_LRO));
- }
-
- return rc;
-}
-
-static int bnx2x_set_tso(struct net_device *dev, u32 data)
-{
- if (data) {
- dev->features |= (NETIF_F_TSO | NETIF_F_TSO_ECN);
- dev->features |= NETIF_F_TSO6;
- } else {
- dev->features &= ~(NETIF_F_TSO | NETIF_F_TSO_ECN);
- dev->features &= ~NETIF_F_TSO6;
- }
-
- return 0;
-}
-
static const struct {
char string[ETH_GSTRING_LEN];
} bnx2x_tests_str_arr[BNX2X_NUM_TESTS] = {
@@ -2207,16 +2122,6 @@ static const struct ethtool_ops bnx2x_ethtool_ops = {
.set_ringparam = bnx2x_set_ringparam,
.get_pauseparam = bnx2x_get_pauseparam,
.set_pauseparam = bnx2x_set_pauseparam,
- .get_rx_csum = bnx2x_get_rx_csum,
- .set_rx_csum = bnx2x_set_rx_csum,
- .get_tx_csum = ethtool_op_get_tx_csum,
- .set_tx_csum = ethtool_op_set_tx_hw_csum,
- .set_flags = bnx2x_set_flags,
- .get_flags = ethtool_op_get_flags,
- .get_sg = ethtool_op_get_sg,
- .set_sg = ethtool_op_set_sg,
- .get_tso = ethtool_op_get_tso,
- .set_tso = bnx2x_set_tso,
.self_test = bnx2x_self_test,
.get_sset_count = bnx2x_get_sset_count,
.get_strings = bnx2x_get_strings,
diff --git a/drivers/net/bnx2x/bnx2x_main.c b/drivers/net/bnx2x/bnx2x_main.c
index a6915aa..696e84a 100644
--- a/drivers/net/bnx2x/bnx2x_main.c
+++ b/drivers/net/bnx2x/bnx2x_main.c
@@ -8904,8 +8904,6 @@ static int __devinit bnx2x_init_bp(struct bnx2x *bp)
bp->multi_mode = multi_mode;
bp->int_mode = int_mode;
- bp->dev->features |= NETIF_F_GRO;
-
/* Set TPA flags */
if (disable_tpa) {
bp->flags &= ~TPA_ENABLE_FLAG;
@@ -8925,8 +8923,6 @@ static int __devinit bnx2x_init_bp(struct bnx2x *bp)
bp->tx_ring_size = MAX_TX_AVAIL;
- bp->rx_csum = 1;
-
/* make sure that the numbers are in the right granularity */
bp->tx_ticks = (50 / BNX2X_BTR) * BNX2X_BTR;
bp->rx_ticks = (25 / BNX2X_BTR) * BNX2X_BTR;
@@ -9304,6 +9300,8 @@ static const struct net_device_ops bnx2x_netdev_ops = {
.ndo_validate_addr = eth_validate_addr,
.ndo_do_ioctl = bnx2x_ioctl,
.ndo_change_mtu = bnx2x_change_mtu,
+ .ndo_fix_features = bnx2x_fix_features,
+ .ndo_set_features = bnx2x_set_features,
.ndo_tx_timeout = bnx2x_tx_timeout,
#ifdef CONFIG_NET_POLL_CONTROLLER
.ndo_poll_controller = poll_bnx2x,
@@ -9430,20 +9428,17 @@ static int __devinit bnx2x_init_dev(struct pci_dev *pdev,
dev->netdev_ops = &bnx2x_netdev_ops;
bnx2x_set_ethtool_ops(dev);
- dev->features |= NETIF_F_SG;
- dev->features |= NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM;
+
+ dev->hw_features = NETIF_F_SG | NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM |
+ NETIF_F_TSO | NETIF_F_TSO_ECN | NETIF_F_TSO6 |
+ NETIF_F_RXCSUM | NETIF_F_LRO | NETIF_F_HW_VLAN_TX;
+
+ dev->vlan_features = NETIF_F_SG | NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM |
+ NETIF_F_TSO | NETIF_F_TSO_ECN | NETIF_F_TSO6 | NETIF_F_HIGHDMA;
+
+ dev->features |= dev->hw_features | NETIF_F_HW_VLAN_RX;
if (bp->flags & USING_DAC_FLAG)
dev->features |= NETIF_F_HIGHDMA;
- dev->features |= (NETIF_F_TSO | NETIF_F_TSO_ECN);
- dev->features |= NETIF_F_TSO6;
- dev->features |= (NETIF_F_HW_VLAN_TX | NETIF_F_HW_VLAN_RX);
-
- dev->vlan_features |= NETIF_F_SG;
- dev->vlan_features |= NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM;
- if (bp->flags & USING_DAC_FLAG)
- dev->vlan_features |= NETIF_F_HIGHDMA;
- dev->vlan_features |= (NETIF_F_TSO | NETIF_F_TSO_ECN);
- dev->vlan_features |= NETIF_F_TSO6;
#ifdef BCM_DCBNL
dev->dcbnl_ops = &bnx2x_dcbnl_ops;
--
1.7.2.5
^ permalink raw reply related
* [PATCH] net: ioc3: convert to hw_features
From: Michał Mirosław @ 2011-04-12 19:48 UTC (permalink / raw)
To: netdev; +Cc: Ralf Baechle, linux-mips
Signed-off-by: Michał Mirosław <mirq-linux@rere.qmqm.pl>
---
drivers/net/ioc3-eth.c | 30 ++----------------------------
1 files changed, 2 insertions(+), 28 deletions(-)
diff --git a/drivers/net/ioc3-eth.c b/drivers/net/ioc3-eth.c
index c8ee8d2..96c9561 100644
--- a/drivers/net/ioc3-eth.c
+++ b/drivers/net/ioc3-eth.c
@@ -90,8 +90,6 @@ struct ioc3_private {
u32 emcr, ehar_h, ehar_l;
spinlock_t ioc3_lock;
struct mii_if_info mii;
- unsigned long flags;
-#define IOC3_FLAG_RX_CHECKSUMS 1
struct pci_dev *pdev;
@@ -609,7 +607,7 @@ static inline void ioc3_rx(struct net_device *dev)
goto next;
}
- if (likely(ip->flags & IOC3_FLAG_RX_CHECKSUMS))
+ if (likely(dev->features & NETIF_F_RXCSUM))
ioc3_tcpudp_checksum(skb,
w0 & ERXBUF_IPCKSUM_MASK, len);
@@ -1328,6 +1326,7 @@ static int __devinit ioc3_probe(struct pci_dev *pdev,
dev->watchdog_timeo = 5 * HZ;
dev->netdev_ops = &ioc3_netdev_ops;
dev->ethtool_ops = &ioc3_ethtool_ops;
+ dev->hw_features = NETIF_F_IP_CSUM | NETIF_F_RXCSUM;
dev->features = NETIF_F_IP_CSUM;
sw_physid1 = ioc3_mdio_read(dev, ip->mii.phy_id, MII_PHYSID1);
@@ -1618,37 +1617,12 @@ static u32 ioc3_get_link(struct net_device *dev)
return rc;
}
-static u32 ioc3_get_rx_csum(struct net_device *dev)
-{
- struct ioc3_private *ip = netdev_priv(dev);
-
- return ip->flags & IOC3_FLAG_RX_CHECKSUMS;
-}
-
-static int ioc3_set_rx_csum(struct net_device *dev, u32 data)
-{
- struct ioc3_private *ip = netdev_priv(dev);
-
- spin_lock_bh(&ip->ioc3_lock);
- if (data)
- ip->flags |= IOC3_FLAG_RX_CHECKSUMS;
- else
- ip->flags &= ~IOC3_FLAG_RX_CHECKSUMS;
- spin_unlock_bh(&ip->ioc3_lock);
-
- return 0;
-}
-
static const struct ethtool_ops ioc3_ethtool_ops = {
.get_drvinfo = ioc3_get_drvinfo,
.get_settings = ioc3_get_settings,
.set_settings = ioc3_set_settings,
.nway_reset = ioc3_nway_reset,
.get_link = ioc3_get_link,
- .get_rx_csum = ioc3_get_rx_csum,
- .set_rx_csum = ioc3_set_rx_csum,
- .get_tx_csum = ethtool_op_get_tx_csum,
- .set_tx_csum = ethtool_op_set_tx_csum
};
static int ioc3_ioctl(struct net_device *dev, struct ifreq *rq, int cmd)
--
1.7.2.5
^ permalink raw reply related
* [PATCH] net: add RTNL_ASSERT in __netdev_update_features()
From: Michał Mirosław @ 2011-04-12 19:56 UTC (permalink / raw)
To: netdev
Signed-off-by: Michał Mirosław <mirq-linux@rere.qmqm.pl>
---
net/core/dev.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/net/core/dev.c b/net/core/dev.c
index 95897ff..ae9ac15 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -5241,6 +5241,8 @@ int __netdev_update_features(struct net_device *dev)
u32 features;
int err = 0;
+ ASSERT_RTNL();
+
features = netdev_get_wanted_features(dev);
if (dev->netdev_ops->ndo_fix_features)
--
1.7.2.5
^ permalink raw reply related
* Re: Network performance with small packets
From: Michael S. Tsirkin @ 2011-04-12 20:01 UTC (permalink / raw)
To: Rusty Russell
Cc: habanero, Shirley Ma, Krishna Kumar2, David Miller, kvm, netdev,
steved, Tom Lendacky, borntraeger
In-Reply-To: <87fwqv4udl.fsf@rustcorp.com.au>
On Thu, Mar 10, 2011 at 12:19:42PM +1030, Rusty Russell wrote:
> Here's an old patch where I played with implementing this:
...
>
> virtio: put last_used and last_avail index into ring itself.
>
> Generally, the other end of the virtio ring doesn't need to see where
> you're up to in consuming the ring. However, to completely understand
> what's going on from the outside, this information must be exposed.
> For example, if you want to save and restore a virtio_ring, but you're
> not the consumer because the kernel is using it directly.
>
> Fortunately, we have room to expand:
This seems to be true for x86 kvm and lguest but is it true
for s390?
err = vmem_add_mapping(config->address,
vring_size(config->num,
KVM_S390_VIRTIO_RING_ALIGN));
if (err)
goto out;
vq = vring_new_virtqueue(config->num, KVM_S390_VIRTIO_RING_ALIGN,
vdev, (void *) config->address,
kvm_notify, callback, name);
if (!vq) {
err = -ENOMEM;
goto unmap;
}
> the ring is always a whole number
> of pages and there's hundreds of bytes of padding after the avail ring
> and the used ring, whatever the number of descriptors (which must be a
> power of 2).
>
> We add a feature bit so the guest can tell the host that it's writing
> out the current value there, if it wants to use that.
>
> Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
> ---
....
> --- a/include/linux/virtio_ring.h
> +++ b/include/linux/virtio_ring.h
> @@ -29,6 +29,9 @@
> /* We support indirect buffer descriptors */
> #define VIRTIO_RING_F_INDIRECT_DESC 28
>
> +/* We publish our last-seen used index at the end of the avail ring. */
> +#define VIRTIO_RING_F_PUBLISH_INDICES 29
> +
> /* Virtio ring descriptors: 16 bytes. These can chain together via "next". */
> struct vring_desc
> {
> @@ -87,6 +90,7 @@ struct vring {
> * __u16 avail_flags;
> * __u16 avail_idx;
> * __u16 available[num];
> + * __u16 last_used_idx;
> *
> * // Padding to the next align boundary.
> * char pad[];
> @@ -95,6 +99,7 @@ struct vring {
> * __u16 used_flags;
> * __u16 used_idx;
> * struct vring_used_elem used[num];
> + * __u16 last_avail_idx;
> * };
> */
> static inline void vring_init(struct vring *vr, unsigned int num, void *p,
> @@ -111,9 +116,14 @@ static inline unsigned vring_size(unsign
> {
> return ((sizeof(struct vring_desc) * num + sizeof(__u16) * (2 + num)
> + align - 1) & ~(align - 1))
> - + sizeof(__u16) * 2 + sizeof(struct vring_used_elem) * num;
> + + sizeof(__u16) * 2 + sizeof(struct vring_used_elem) * num + 2;
> }
>
> +/* We publish the last-seen used index at the end of the available ring, and
> + * vice-versa. These are at the end for backwards compatibility. */
> +#define vring_last_used(vr) ((vr)->avail->ring[(vr)->num])
> +#define vring_last_avail(vr) (*(__u16 *)&(vr)->used->ring[(vr)->num])
> +
Will this last bit work on s390?
If I understand correctly the memory is allocated by host there?
> #ifdef __KERNEL__
> #include <linux/irqreturn.h>
> struct virtio_device;
^ permalink raw reply
* Re: [PATCH] bridge: reset IPCB in br_parse_ip_options
From: David Miller @ 2011-04-12 20:39 UTC (permalink / raw)
To: eric.dumazet
Cc: shemminger, jluebbe, lkml, shimoda.hiroaki, netdev, bandan.das
In-Reply-To: <1302628720.3233.84.camel@edumazet-laptop>
From: Eric Dumazet <eric.dumazet@gmail.com>
Date: Tue, 12 Apr 2011 19:18:40 +0200
> Commit 462fb2af9788a82 (bridge : Sanitize skb before it enters the IP
> stack), missed one IPCB init before calling ip_options_compile()
>
> Thanks to Scot Doyle for his tests and bug reports.
>
> Reported-by: Scot Doyle <lkml@scotdoyle.com>
> Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
> Cc: Hiroaki SHIMODA <shimoda.hiroaki@gmail.com>
> Acked-by: Bandan Das <bandan.das@stratus.com>
> Acked-by: Stephen Hemminger <shemminger@vyatta.com>
> Cc: Jan Lübbe <jluebbe@debian.org>
Applied, thanks everyone.
^ permalink raw reply
* Re: [net-next-2.6 PATCH] ethtool: time to blink provided in seconds not jiffies
From: David Miller @ 2011-04-12 20:47 UTC (permalink / raw)
To: bhutchings; +Cc: bruce.w.allan, netdev
In-Reply-To: <1302566234.5282.581.camel@localhost>
From: Ben Hutchings <bhutchings@solarflare.com>
Date: Tue, 12 Apr 2011 00:57:14 +0100
> On Mon, 2011-04-11 at 16:01 -0700, Bruce Allan wrote:
>> When blinking for a duration set by the user, the value specified is in
>> seconds but it is used as the number of jiffies in the timeout after which
>> the Physical ID indicator is deactivated. Fix by converting the timeout
>> to seconds.
>
> D'oh.
>
>> Signed-off-by: Bruce Allan <bruce.w.allan@intel.com>
> Acked-by: Ben Hutchings <bhutchings@solarflare.com>
Applied, thanks.
^ permalink raw reply
* Re: [Patch] iwlwifi: remove obsoleted module alias and parameters
From: John W. Linville @ 2011-04-12 20:49 UTC (permalink / raw)
To: Stanislaw Gruszka
Cc: Cong Wang, Johannes Berg, linux-wireless-u79uwXL29TY76Z2rM5mHXA,
netdev-u79uwXL29TY76Z2rM5mHXA, Intel Linux Wireless, Wey-Yi Guy,
Meenakshi Venkataraman, Larry Finger
In-Reply-To: <20110406125728.GA2197-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
On Wed, Apr 06, 2011 at 02:57:29PM +0200, Stanislaw Gruszka wrote:
> On Wed, Apr 06, 2011 at 06:42:48PM +0800, Cong Wang wrote:
> > 于 2011年04月06日 18:09, Johannes Berg 写道:
> > >On Wed, 2011-04-06 at 17:49 +0800, Amerigo Wang wrote:
> > >>As scheduled in Documentation/feature-removal-schedule.txt,
> > >>remove "*50", "disable_hw_scan" module parameters and MODULE_ALIAS("iwl4965").
> > >
> > >Mostly fine, but for iwlegacy Stanislaw we want to keep hw scan (and it
> > >was actually made default now)
>
> Indeed, disable_hw_scan should be removed in iwlwifi but leaved in iwlegacy.
>
> > Ok, I will wait for Stanislaw's response and then send an updated patch.
>
> Have it now :-)
Ping?
--
John W. Linville Someday the world will need a hero, and you
linville-2XuSBdqkA4R54TAoqtyWWQ@public.gmane.org might be all we have. Be ready.
--
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: [PATCH NET-2.6 1/1] qlcnic: limit skb frags for non tso packet
From: David Miller @ 2011-04-12 20:55 UTC (permalink / raw)
To: amit.salecha; +Cc: netdev, ameen.rahman, anirban.chakraborty, stable
In-Reply-To: <1302592781-13881-2-git-send-email-amit.salecha@qlogic.com>
From: Amit Kumar Salecha <amit.salecha@qlogic.com>
Date: Tue, 12 Apr 2011 00:19:41 -0700
> <<< No Message Collected >>>
Can you PLEASE fix your email.
PLEASE?
Yesterday you spammed us all, and today you've sent three postings
with this subject line.
1) One with the patch, and the proper set of CC:'s (myself, other
qlogic engineers, netdev, and stable)
2) One with the patch, and a too short CC: list (only netdev and
stable)
3) And now this email with no actual content and a weird message.
I really can't spend my afternoons sifting through the emails that
spam from qlogic, trying to figure out which ones I should pay
attention to for review, and which ones are spam.
Please resend properly any patches you actually want me to pay
attention to.
If you cannot make sure at this time that the patches will be sent
without incident, sit on them until you can.
Thank you.
^ permalink raw reply
* Re: [PATCH] inetpeer: reduce stack usage
From: David Miller @ 2011-04-12 20:58 UTC (permalink / raw)
To: eric.dumazet; +Cc: shimoda.hiroaki, lkml, shemminger, netdev
In-Reply-To: <1302620123.3233.58.camel@edumazet-laptop>
From: Eric Dumazet <eric.dumazet@gmail.com>
Date: Tue, 12 Apr 2011 16:55:23 +0200
> Le mardi 12 avril 2011 à 23:51 +0900, Hiroaki SHIMODA a écrit :
>
>> I couldn't understand that actually cleanup_once() was called
>> from inet_getpeer() and then the stack overflow was hit,
>> but this patch surely reduces stack usage.
>>
>> Reviewed-by: Hiroaki SHIMODA <shimoda.hiroaki@gmail.com>
>>
>
> Well, I dont believe we actually hit a stack overflow in Scot Doyle
> reported crashes, but it certainly is better to use a bit less stack
> anyway ;)
>
> Thanks for reviewing !
Applied, thanks everyone.
^ permalink raw reply
* Re: [PATCH] net: Do not wrap sysctl igmp_max_memberships in IP_MULTICAST
From: David Miller @ 2011-04-12 21:00 UTC (permalink / raw)
To: Joakim.Tjernlund; +Cc: netdev
In-Reply-To: <1302601774-24289-1-git-send-email-Joakim.Tjernlund@transmode.se>
From: Joakim Tjernlund <Joakim.Tjernlund@transmode.se>
Date: Tue, 12 Apr 2011 11:49:34 +0200
> controlling igmp_max_membership is useful even when IP_MULTICAST
> is off.
> Quagga(an OSPF deamon) uses multicast addresses for all interfaces
> using a single socket and hits igmp_max_membership limit when
> there are 20 interfaces or more.
> Always export sysctl igmp_max_memberships in proc, just like
> igmp_max_msf
>
> Signed-off-by: Joakim Tjernlund <Joakim.Tjernlund@transmode.se>
I really like your commit message, a full justification and a
reference to existing similar behavior.
If only every patch submitter did this :-/
Applied, thanks!
^ permalink raw reply
* Re: [PATCH] iproute2: parse flag XFRM_POLICY_ICMP
From: Stephen Hemminger @ 2011-04-12 21:14 UTC (permalink / raw)
To: Ulrich Weber; +Cc: netdev
In-Reply-To: <20110407073705.GA6523@babylon>
On Thu, 7 Apr 2011 09:37:05 +0200
Ulrich Weber <uweber@astaro.com> wrote:
> parse flag XFRM_POLICY_ICMP
>
> Signed-off-by: Ulrich Weber <uweber@astaro.com>
> ---
> ip/ipxfrm.c | 1 +
> ip/xfrm_policy.c | 4 +++-
> 2 files changed, 4 insertions(+), 1 deletions(-)
>
Applied to net-next branch
--
^ permalink raw reply
* Re: [patch net-next-2.6 v2] net: vlan: make non-hw-accel rx path similar to hw-accel
From: David Miller @ 2011-04-12 21:16 UTC (permalink / raw)
To: jpirko
Cc: netdev, shemminger, kaber, fubar, eric.dumazet, nicolas.2p.debian,
andy, xiaosuo, jesse, ebiederm
In-Reply-To: <1302241713-3637-1-git-send-email-jpirko@redhat.com>
From: Jiri Pirko <jpirko@redhat.com>
Date: Fri, 8 Apr 2011 07:48:33 +0200
> Now there are 2 paths for rx vlan frames. When rx-vlan-hw-accel is
> enabled, skb is untagged by NIC, vlan_tci is set and the skb gets into
> vlan code in __netif_receive_skb - vlan_hwaccel_do_receive.
>
> For non-rx-vlan-hw-accel however, tagged skb goes thru whole
> __netif_receive_skb, it's untagged in ptype_base hander and reinjected
>
> This incosistency is fixed by this patch. Vlan untagging happens early in
> __netif_receive_skb so the rest of code (ptype_all handlers, rx_handlers)
> see the skb like it was untagged by hw.
>
> Signed-off-by: Jiri Pirko <jpirko@redhat.com>
>
> v1->v2:
> remove "inline" from vlan_core.c functions
Ok, I've applied this, let's see what happens :-)
Thanks!
^ permalink raw reply
* Re: [PATCH] net: ipv4: add IPPROTO_ICMP socket kind
From: David Miller @ 2011-04-12 21:25 UTC (permalink / raw)
To: solar
Cc: segoon, linux-kernel, netdev, peak, kees.cook, dan.j.rosenberg,
eugene, nelhage, kuznet, pekkas, jmorris, yoshfuji, kaber
In-Reply-To: <20110412050659.GA14129@openwall.com>
From: Solar Designer <solar@openwall.com>
Date: Tue, 12 Apr 2011 09:06:59 +0400
> On Sat, Apr 09, 2011 at 02:15:14PM +0400, Vasiliy Kulikov wrote:
>> This patch adds IPPROTO_ICMP socket kind. It makes it possible to send
>> ICMP_ECHO messages and receive the corresponding ICMP_ECHOREPLY messages
>> without any special privileges. In other words, the patch makes it
>> possible to implement setuid-less and CAP_NET_RAW-less /bin/ping. In
>> order not to increase the kernel's attack surface (in case of
>> vulnerabilities in the newly added code), the new functionality is
>> disabled by default, but is enabled at bootup by supporting Linux
>> distributions, optionally with restriction to a group or a group range
> ...
>> For Openwall GNU/*/Linux it is the last step on the road to the
>> setuid-less distro.
>
> More correctly, it _was_ the last step - we've already taken it, so a
> revision of the patch (against OpenVZ/RHEL5 kernels) is currently in use.
>
> We would really like this accepted into mainline, which is why Vasiliy
> spends extra effort to keep the patch updated to current mainline
> kernels and re-test it. If there are any comments/concerns/objections,
> we'd be happy to hear those.
>
>> Signed-off-by: Vasiliy Kulikov <segoon@openwall.com>
>
> Acked-by: Solar Designer <solar@openwall.com>
I have no fundamental objections to this change and I'll be happy to
apply it after we iron out a few details.
First, please get rid of the debug option, we have pr_debug() which can
be dynamically turned on and off at run time these days.
Second, if this is a bonafide core facility we'd like everyone to use,
let's make it so. I want it so that every ping binary can expect this
facility to be there if the kernel is new enough.
So let's get rid of the config option.
Third, either we trust this code or we do not. If we are OK with a
user application spamming whatever they wish out of a datagram UDP
socket, they can do no more harm with this thing unless there are
bugs.
The group range thing I also consider hackish. In my opinion two
other approaches seem more reasonable:
1) On/Off sysctl, default to ON. This is to handle the "oh crap
there's a really bad bug discovered in this thing" situations.
2) A single group ID, if zero it means "all groups" else it limits
the facility to specific groups.
I would mention capabilities, but probably that's undesirable for
something like this as it creeps us back to the original problem
this is trying to resolve.
Finally, longer term, I'd really like to see ipv6 support for this
feature as well. I absolutely am not requiring that ipv6 get
worked on right now just to apply the ipv4 variant.
So let's sort out the ipv4 side issues so I can get this into the
net-next-2.6 tree and people can start testing it.
Thanks.
^ permalink raw reply
* Re: [PATCH] driver/e1000e: Fix default interrupt mode select
From: David Miller @ 2011-04-12 21:27 UTC (permalink / raw)
To: prabhakar
Cc: linuxppc-dev, linux.nics, auke-jan.h.kok, e1000-devel, netdev,
meet2prabhu, b24347, jeffrey.t.kirsher
In-Reply-To: <1302584163-22318-1-git-send-email-prabhakar@freescale.com>
From: Prabhakar Kushwaha <prabhakar@freescale.com>
Date: Tue, 12 Apr 2011 10:26:03 +0530
> From: Prabhakar <prabhakar@freescale.com>
>
> The Intel e1000 device driver defaults to MSI interrupt mode, even if MSI
> support is not enabled
>
> Signed-off-by: Jin Qing <b24347@freescale.com>
> Signed-off-by: Prabhakar Kushwaha <prabhakar@freescale.com>
> ---
> Based upon git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git(branch master)
>
> added netdev mail-list and e1000 mail-list & maintainer
Intel folks, you got this?
^ permalink raw reply
* Re: [PATCH] driver/e1000e: Fix default interrupt mode select
From: Jeff Kirsher @ 2011-04-12 21:31 UTC (permalink / raw)
To: David Miller
Cc: prabhakar@freescale.com, linuxppc-dev@lists.ozlabs.org,
Linux NICS, Kok, Auke-jan H, e1000-devel@lists.sourceforge.net,
netdev@vger.kernel.org, meet2prabhu@gmail.com,
b24347@freescale.com
In-Reply-To: <20110412.142727.39177723.davem@davemloft.net>
[-- Attachment #1: Type: text/plain, Size: 673 bytes --]
On Tue, 2011-04-12 at 14:27 -0700, David Miller wrote:
> From: Prabhakar Kushwaha <prabhakar@freescale.com>
> Date: Tue, 12 Apr 2011 10:26:03 +0530
>
> > From: Prabhakar <prabhakar@freescale.com>
> >
> > The Intel e1000 device driver defaults to MSI interrupt mode, even if MSI
> > support is not enabled
> >
> > Signed-off-by: Jin Qing <b24347@freescale.com>
> > Signed-off-by: Prabhakar Kushwaha <prabhakar@freescale.com>
> > ---
> > Based upon git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git(branch master)
> >
> > added netdev mail-list and e1000 mail-list & maintainer
>
> Intel folks, you got this?
Yes. Thanks Dave.
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 490 bytes --]
^ 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