* Re: [PATCH net] r8152: fix setting RTL8152_UNPLUG
From: David Miller @ 2014-09-30 20:24 UTC (permalink / raw)
To: hayeswang; +Cc: netdev, nic_swsd, linux-kernel, linux-usb
In-Reply-To: <1394712342-15778-50-Taiwan-albertk@realtek.com>
From: Hayes Wang <hayeswang@realtek.com>
Date: Tue, 30 Sep 2014 16:48:01 +0800
> The flag of RTL8152_UNPLUG should only be set when the device is
> unplugged, not each time the rtl8152_disconnect() is called.
> Otherwise, the device wouldn't be stopped normally.
>
> Signed-off-by: Hayes Wang <hayeswang@realtek.com>
Applied, thanks.
^ permalink raw reply
* [PATCH 1/1 linux-next] irda: add __init to irlan_open
From: Fabian Frederick @ 2014-09-30 20:24 UTC (permalink / raw)
To: linux-kernel; +Cc: Fabian Frederick, Samuel Ortiz, David S. Miller, netdev
irlan_open is only called by __init irlan_init in same module.
Signed-off-by: Fabian Frederick <fabf@skynet.be>
---
net/irda/irlan/irlan_common.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/net/irda/irlan/irlan_common.c b/net/irda/irlan/irlan_common.c
index 1bc49ed..5a2d0a6 100644
--- a/net/irda/irlan/irlan_common.c
+++ b/net/irda/irlan/irlan_common.c
@@ -98,7 +98,7 @@ static const struct file_operations irlan_fops = {
extern struct proc_dir_entry *proc_irda;
#endif /* CONFIG_PROC_FS */
-static struct irlan_cb *irlan_open(__u32 saddr, __u32 daddr);
+static struct irlan_cb __init *irlan_open(__u32 saddr, __u32 daddr);
static void __irlan_close(struct irlan_cb *self);
static int __irlan_insert_param(struct sk_buff *skb, char *param, int type,
__u8 value_byte, __u16 value_short,
@@ -196,7 +196,7 @@ static void __exit irlan_cleanup(void)
* Open new instance of a client/provider, we should only register the
* network device if this instance is ment for a particular client/provider
*/
-static struct irlan_cb *irlan_open(__u32 saddr, __u32 daddr)
+static struct irlan_cb __init *irlan_open(__u32 saddr, __u32 daddr)
{
struct net_device *dev;
struct irlan_cb *self;
--
1.9.3
^ permalink raw reply related
* Re: [PATCH net 0/2] netxen: Bug fixes.
From: David Miller @ 2014-09-30 20:23 UTC (permalink / raw)
To: manish.chopra; +Cc: netdev, umgwanakikbuti, Dept-GELinuxNICDev
In-Reply-To: <1412063796-25959-1-git-send-email-manish.chopra@qlogic.com>
From: Manish Chopra <manish.chopra@qlogic.com>
Date: Tue, 30 Sep 2014 03:56:34 -0400
> This series fixes some TX specific issues.
> * Move spin_lock(tx_clean_lock) in down path to fix
> atomic sleep bug (Reported by Mike Galbraith).
> * Fix hang in interface down while running traffic.
>
> Please consider applying this to 'net'.
Series applied, thanks.
^ permalink raw reply
* RE: How exactly does CHECKSUM_COMPLETE works?
From: Yuval Mintz @ 2014-09-30 20:19 UTC (permalink / raw)
To: Eric Dumazet; +Cc: Tom Herbert (Partner - google), netdev
In-Reply-To: <1412105832.30721.95.camel@edumazet-glaptop2.roam.corp.google.com>
> > Can you pinpoint me to what exactly in the code corrects NAPI_GRO_CB(skb)->csum
> > by negating the ipv4 part in the ones' complete checksum?
> >
> > E.g., for ipv6 [in ipv6_gro_receive()] I can see that skb_gro_postpull_rcsum() is
> > called after pulling the ipv6 header [and before proceeding to the next protocol],
> > but I can't seem to find anything similar to this for ipv4 [in inet_gro_receive()].
> >
>
>
> IPv4 header is supposed to have a 0 checksum ;)
>
Oops. Sorry, you're right.
But this is a bit strange.
I mean, if I go back to the IP-GRE case [with GRE checksum], the IP
csum negates the rest of the IP header and the GRE csum negates
everything else [GRE header, inner headers and payload].
So the mechanism might work as-is, but all the driver has to
do in order to claim that an IP-gre packet with checksum option is
CHECKSUM_COMPLETE is to write 0xffffffff on the skb's csum field.
^ permalink raw reply
* Re: How exactly does CHECKSUM_COMPLETE works?
From: David Miller @ 2014-09-30 20:14 UTC (permalink / raw)
To: eric.dumazet; +Cc: Yuval.Mintz, therbert, netdev
In-Reply-To: <1412105832.30721.95.camel@edumazet-glaptop2.roam.corp.google.com>
From: Eric Dumazet <eric.dumazet@gmail.com>
Date: Tue, 30 Sep 2014 12:37:12 -0700
> On Tue, 2014-09-30 at 12:22 -0700, Eric Dumazet wrote:
>> On Tue, 2014-09-30 at 19:05 +0000, Yuval Mintz wrote:
>>
>> > Can you pinpoint me to what exactly in the code corrects NAPI_GRO_CB(skb)->csum
>> > by negating the ipv4 part in the ones' complete checksum?
>> >
>> > E.g., for ipv6 [in ipv6_gro_receive()] I can see that skb_gro_postpull_rcsum() is
>> > called after pulling the ipv6 header [and before proceeding to the next protocol],
>> > but I can't seem to find anything similar to this for ipv4 [in inet_gro_receive()].
>> >
>>
>>
>> IPv4 header is supposed to have a 0 checksum ;)
>>
>
> Or if you prefer :
Someone please submit this formally :)
^ permalink raw reply
* Re: [PATCH net-next 2/4] net/mlx5_core: Use hardware registers description header file
From: David Miller @ 2014-09-30 20:13 UTC (permalink / raw)
To: eli; +Cc: alexei.starovoitov, eli, netdev, ogerlitz, yevgenyp
In-Reply-To: <CFE9BFE80FFE4D4892AA5D31387E310F014FC6C85B@MTLDAG02.mtl.com>
From: Eli Cohen <eli@mellanox.com>
Date: Tue, 30 Sep 2014 19:34:40 +0000
>> I find hard time believing that all of 4k auto generated macros are actually used. Could you trim it down to only usable bits?
>
> 4K is the size of a header file that defines structs that describe the
> driver/firmware interface. It does not contribute a bit to code size.
> It's an autogenerated file based on data from the reference manual and
> I see no point in trimming it.
People will try to review it only to discover that it's completely unused.
I've been through this before with other device driver teams telling us
that it's part of some automated framework etc. and that doesn't make
it acceptable.
Please trim these things down to exactly what the driver uses.
^ permalink raw reply
* Re: [PATCH] et131x: Promote staging et131x driver to drivers/net
From: Mark Einon @ 2014-09-30 19:45 UTC (permalink / raw)
To: Greg KH; +Cc: devel, Mark Einon, netdev, davem, linux-kernel
In-Reply-To: <20140930193201.GA2349@kroah.com>
On Tue, Sep 30, 2014 at 12:32:01PM -0700, Greg KH wrote:
>
> This is a fine way to make a patch, but it's no way that any of the
> netdev developers could ever review it to know what the code happens to
> look like in my staging-next branch :(
>
> How about just sending a patch that adds the driver to drivers/net/...
> Don't worry about the staging driver at the moment. If it gets added to
> drivers/net we can then delete the staging driver.
>
> Sound easier? Should make the patches half as big.
Sounds resonable, will do.
Cheers,
Mark
^ permalink raw reply
* RE: How exactly does CHECKSUM_COMPLETE works?
From: Eric Dumazet @ 2014-09-30 19:37 UTC (permalink / raw)
To: Yuval Mintz; +Cc: Tom Herbert (Partner - google), netdev
In-Reply-To: <1412104977.30721.94.camel@edumazet-glaptop2.roam.corp.google.com>
On Tue, 2014-09-30 at 12:22 -0700, Eric Dumazet wrote:
> On Tue, 2014-09-30 at 19:05 +0000, Yuval Mintz wrote:
>
> > Can you pinpoint me to what exactly in the code corrects NAPI_GRO_CB(skb)->csum
> > by negating the ipv4 part in the ones' complete checksum?
> >
> > E.g., for ipv6 [in ipv6_gro_receive()] I can see that skb_gro_postpull_rcsum() is
> > called after pulling the ipv6 header [and before proceeding to the next protocol],
> > but I can't seem to find anything similar to this for ipv4 [in inet_gro_receive()].
> >
>
>
> IPv4 header is supposed to have a 0 checksum ;)
>
Or if you prefer :
diff --git a/net/ipv4/af_inet.c b/net/ipv4/af_inet.c
index 28e589c5f32d..92db7a69f2b9 100644
--- a/net/ipv4/af_inet.c
+++ b/net/ipv4/af_inet.c
@@ -1369,6 +1369,9 @@ static struct sk_buff **inet_gro_receive(struct sk_buff **head,
* immediately following this IP hdr.
*/
+ /* Note : No need to call skb_gro_postpull_rcsum() here,
+ * as we already checked checksum over ipv4 header was 0
+ */
skb_gro_pull(skb, sizeof(*iph));
skb_set_transport_header(skb, skb_gro_offset(skb));
^ permalink raw reply related
* RE: [PATCH net-next 2/4] net/mlx5_core: Use hardware registers description header file
From: Eli Cohen @ 2014-09-30 19:34 UTC (permalink / raw)
To: Alexei Starovoitov, Eli Cohen
Cc: davem@davemloft.net, netdev@vger.kernel.org, Or Gerlitz,
Yevgeny Petrilin
In-Reply-To: <20140930153445.GA9303@localhost.westell.com>
> I find hard time believing that all of 4k auto generated macros are actually used. Could you trim it down to only usable bits?
4K is the size of a header file that defines structs that describe the
driver/firmware interface. It does not contribute a bit to code size.
It's an autogenerated file based on data from the reference manual and
I see no point in trimming it.
^ permalink raw reply
* Re: [PATCH] et131x: Promote staging et131x driver to drivers/net
From: Greg KH @ 2014-09-30 19:32 UTC (permalink / raw)
To: Mark Einon; +Cc: devel, netdev, davem, linux-kernel
In-Reply-To: <1412104572-2931-1-git-send-email-mark.einon@gmail.com>
On Tue, Sep 30, 2014 at 08:16:12PM +0100, Mark Einon wrote:
> This patch moves the et131x gigabit ethernet driver from drivers/staging
> to drivers/net/ethernet/agere.
>
> Signed-off-by: Mark Einon <mark.einon@gmail.com>
> ---
>
> This patch appiles to both staging-next and the linux-next tag next-20140930,
> and takes into account all feedback recieved from the recent RFC for this
> patch.
>
> MAINTAINERS | 10 +++----
> drivers/net/ethernet/Kconfig | 1 +
> drivers/net/ethernet/Makefile | 1 +
> drivers/net/ethernet/agere/Kconfig | 31 ++++++++++++++++++++++
> .../et131x => net/ethernet/agere}/Makefile | 0
> .../et131x => net/ethernet/agere}/et131x.c | 0
> .../et131x => net/ethernet/agere}/et131x.h | 0
> drivers/staging/Kconfig | 2 --
> drivers/staging/Makefile | 1 -
> drivers/staging/et131x/Kconfig | 10 -------
> drivers/staging/et131x/README | 15 -----------
> 11 files changed, 38 insertions(+), 33 deletions(-)
> create mode 100644 drivers/net/ethernet/agere/Kconfig
> rename drivers/{staging/et131x => net/ethernet/agere}/Makefile (100%)
> rename drivers/{staging/et131x => net/ethernet/agere}/et131x.c (100%)
> rename drivers/{staging/et131x => net/ethernet/agere}/et131x.h (100%)
> delete mode 100644 drivers/staging/et131x/Kconfig
> delete mode 100644 drivers/staging/et131x/README
This is a fine way to make a patch, but it's no way that any of the
netdev developers could ever review it to know what the code happens to
look like in my staging-next branch :(
How about just sending a patch that adds the driver to drivers/net/...
Don't worry about the staging driver at the moment. If it gets added to
drivers/net we can then delete the staging driver.
Sound easier? Should make the patches half as big.
thanks,
greg k-h
^ permalink raw reply
* [PATCH v2 net 1/3] bridge: Add a default_pvid sysfs attribute
From: Vladislav Yasevich @ 2014-09-30 19:31 UTC (permalink / raw)
To: netdev; +Cc: toshiaki.makita1, stephen, bridge, Vladislav Yasevich
In-Reply-To: <1412105462-340-1-git-send-email-vyasevic@redhat.com>
This patch allows the user to set and retrieve default_pvid
value. A new value can only be stored when vlan filtering
is disabled.
Signed-off-by: Vladislav Yasevich <vyasevic@redhat.com>
---
net/bridge/br_private.h | 2 ++
net/bridge/br_sysfs_br.c | 17 +++++++++++++++++
net/bridge/br_vlan.c | 28 ++++++++++++++++++++++++++++
3 files changed, 47 insertions(+)
diff --git a/net/bridge/br_private.h b/net/bridge/br_private.h
index b6c04cb..6fe8680 100644
--- a/net/bridge/br_private.h
+++ b/net/bridge/br_private.h
@@ -299,6 +299,7 @@ struct net_bridge
#ifdef CONFIG_BRIDGE_VLAN_FILTERING
u8 vlan_enabled;
__be16 vlan_proto;
+ u16 default_pvid;
struct net_port_vlans __rcu *vlan_info;
#endif
};
@@ -605,6 +606,7 @@ void br_recalculate_fwd_mask(struct net_bridge *br);
int br_vlan_filter_toggle(struct net_bridge *br, unsigned long val);
int br_vlan_set_proto(struct net_bridge *br, unsigned long val);
void br_vlan_init(struct net_bridge *br);
+int br_vlan_set_default_pvid(struct net_bridge *br, unsigned long val);
int nbp_vlan_add(struct net_bridge_port *port, u16 vid, u16 flags);
int nbp_vlan_delete(struct net_bridge_port *port, u16 vid);
void nbp_vlan_flush(struct net_bridge_port *port);
diff --git a/net/bridge/br_sysfs_br.c b/net/bridge/br_sysfs_br.c
index c9e2572..b969d9e 100644
--- a/net/bridge/br_sysfs_br.c
+++ b/net/bridge/br_sysfs_br.c
@@ -725,6 +725,22 @@ static ssize_t vlan_protocol_store(struct device *d,
return store_bridge_parm(d, buf, len, br_vlan_set_proto);
}
static DEVICE_ATTR_RW(vlan_protocol);
+
+static ssize_t default_pvid_show(struct device *d,
+ struct device_attribute *attr,
+ char *buf)
+{
+ struct net_bridge *br = to_bridge(d);
+ return sprintf(buf, "%d\n", br->default_pvid);
+}
+
+static ssize_t default_pvid_store(struct device *d,
+ struct device_attribute *attr,
+ const char *buf, size_t len)
+{
+ return store_bridge_parm(d, buf, len, br_vlan_set_default_pvid);
+}
+static DEVICE_ATTR_RW(default_pvid);
#endif
static struct attribute *bridge_attrs[] = {
@@ -771,6 +787,7 @@ static struct attribute *bridge_attrs[] = {
#ifdef CONFIG_BRIDGE_VLAN_FILTERING
&dev_attr_vlan_filtering.attr,
&dev_attr_vlan_protocol.attr,
+ &dev_attr_default_pvid.attr,
#endif
NULL
};
diff --git a/net/bridge/br_vlan.c b/net/bridge/br_vlan.c
index 3ba57fc..295ad0d 100644
--- a/net/bridge/br_vlan.c
+++ b/net/bridge/br_vlan.c
@@ -499,9 +499,37 @@ err_filt:
goto unlock;
}
+int br_vlan_set_default_pvid(struct net_bridge *br, unsigned long val)
+{
+ u16 pvid = val;
+ int err = 0;
+
+ if (!pvid || pvid >= VLAN_VID_MASK)
+ return -EINVAL;
+
+ if (!rtnl_trylock())
+ return restart_syscall();
+
+ if (pvid == br->default_pvid)
+ goto unlock;
+
+ /* Only allow default pvid change when filtering is disabled */
+ if (br->vlan_enabled) {
+ err = -EPERM;
+ goto unlock;
+ }
+
+ br->default_pvid = vid;
+
+unlock:
+ rtnl_unlock();
+ return err;
+}
+
void br_vlan_init(struct net_bridge *br)
{
br->vlan_proto = htons(ETH_P_8021Q);
+ br->default_pvid = 1;
}
/* Must be protected by RTNL.
--
1.9.3
^ permalink raw reply related
* [PATCH v2 net 3/3] bridge: Add filtering support for default_pvid
From: Vladislav Yasevich @ 2014-09-30 19:31 UTC (permalink / raw)
To: netdev; +Cc: toshiaki.makita1, stephen, bridge, Vladislav Yasevich
In-Reply-To: <1412105462-340-1-git-send-email-vyasevic@redhat.com>
Currently when vlan filtering is turned on on the bridge, the bridge
will drop all traffic untill the user configures the filter. This
isn't very nice for ports that don't care about vlans and just
want untagged traffic.
A concept of a default_pvid was recently introduced. This patch
adds filtering support for default_pvid. Now, ports that don't
care about vlans and don't define there own filter will belong
to the VLAN of the default_pvid and continue to receive untagged
traffic.
This filtering can be disabled by setting default_pvid to 0.
Signed-off-by: Vladislav Yasevich <vyasevic@redhat.com>
---
net/bridge/br_device.c | 8 +++-
net/bridge/br_if.c | 2 +
net/bridge/br_private.h | 13 +++++-
net/bridge/br_vlan.c | 116 ++++++++++++++++++++++++++++++++++++++++++++++--
4 files changed, 132 insertions(+), 7 deletions(-)
diff --git a/net/bridge/br_device.c b/net/bridge/br_device.c
index 568cccd..af8f706 100644
--- a/net/bridge/br_device.c
+++ b/net/bridge/br_device.c
@@ -88,12 +88,17 @@ out:
static int br_dev_init(struct net_device *dev)
{
struct net_bridge *br = netdev_priv(dev);
+ int err;
br->stats = netdev_alloc_pcpu_stats(struct pcpu_sw_netstats);
if (!br->stats)
return -ENOMEM;
- return 0;
+ err = br_vlan_init(br);
+ if (err)
+ free_percpu(br->stats);
+
+ return err;
}
static int br_dev_open(struct net_device *dev)
@@ -389,5 +394,4 @@ void br_dev_setup(struct net_device *dev)
br_netfilter_rtable_init(br);
br_stp_timer_init(br);
br_multicast_init(br);
- br_vlan_init(br);
}
diff --git a/net/bridge/br_if.c b/net/bridge/br_if.c
index 078d336..b7a00bc 100644
--- a/net/bridge/br_if.c
+++ b/net/bridge/br_if.c
@@ -500,6 +500,8 @@ int br_add_if(struct net_bridge *br, struct net_device *dev)
if (br_fdb_insert(br, p, dev->dev_addr, 0))
netdev_err(dev, "failed insert local address bridge forwarding table\n");
+ nbp_vlan_init(p);
+
spin_lock_bh(&br->lock);
changed_addr = br_stp_recalculate_bridge_id(br);
diff --git a/net/bridge/br_private.h b/net/bridge/br_private.h
index 873d9da..49575b3 100644
--- a/net/bridge/br_private.h
+++ b/net/bridge/br_private.h
@@ -605,12 +605,13 @@ bool br_vlan_find(struct net_bridge *br, u16 vid);
void br_recalculate_fwd_mask(struct net_bridge *br);
int br_vlan_filter_toggle(struct net_bridge *br, unsigned long val);
int br_vlan_set_proto(struct net_bridge *br, unsigned long val);
-void br_vlan_init(struct net_bridge *br);
+int br_vlan_init(struct net_bridge *br);
int br_vlan_set_default_pvid(struct net_bridge *br, unsigned long val);
int nbp_vlan_add(struct net_bridge_port *port, u16 vid, u16 flags);
int nbp_vlan_delete(struct net_bridge_port *port, u16 vid);
void nbp_vlan_flush(struct net_bridge_port *port);
bool nbp_vlan_find(struct net_bridge_port *port, u16 vid);
+int nbp_vlan_init(struct net_bridge_port *port);
static inline struct net_port_vlans *br_get_vlan_info(
const struct net_bridge *br)
@@ -643,6 +644,8 @@ static inline int br_vlan_get_tag(const struct sk_buff *skb, u16 *vid)
static inline u16 br_get_pvid(const struct net_port_vlans *v)
{
+ if (!v)
+ return 0;
/* Return just the VID if it is set, or VLAN_N_VID (invalid vid) if
* vid wasn't set
*/
@@ -706,8 +709,9 @@ static inline void br_recalculate_fwd_mask(struct net_bridge *br)
{
}
-static inline void br_vlan_init(struct net_bridge *br)
+static inline int br_vlan_init(struct net_bridge *br)
{
+ return 0;
}
static inline int nbp_vlan_add(struct net_bridge_port *port, u16 vid, u16 flags)
@@ -740,6 +744,11 @@ static inline bool nbp_vlan_find(struct net_bridge_port *port, u16 vid)
return false;
}
+static inline int nbp_vlan_init(struct net_bridge_port *port)
+{
+ return 0;
+}
+
static inline u16 br_vlan_get_tag(const struct sk_buff *skb, u16 *tag)
{
return 0;
diff --git a/net/bridge/br_vlan.c b/net/bridge/br_vlan.c
index f5eee61..377cea6 100644
--- a/net/bridge/br_vlan.c
+++ b/net/bridge/br_vlan.c
@@ -499,12 +499,110 @@ err_filt:
goto unlock;
}
+static void br_vlan_disable_default_pvid(struct net_bridge *br)
+{
+ struct net_bridge_port *p;
+ unsigned short pvid = br->default_pvid;
+
+ /* This function runs under RTNL with vlan filter disabled.
+ * It is safe to directly access rcu pointers.
+ *
+ * Disable default_pvid on all ports where it is still
+ * configured.
+ */
+ if (pvid == br_get_pvid(br_get_vlan_info(br)) &&
+ test_bit(pvid, br->vlan_info->untagged_bitmap))
+ br_vlan_delete(br, pvid);
+
+ list_for_each_entry(p, &br->port_list, list) {
+ if (pvid == br_get_pvid(nbp_get_vlan_info(p)) &&
+ test_bit(pvid, p->vlan_info->untagged_bitmap))
+ nbp_vlan_delete(p, pvid);
+ }
+
+ br->default_pvid = 0;
+}
+
+static int __br_vlan_set_default_pvid(struct net_bridge *br, u16 pvid)
+{
+ struct net_bridge_port *p;
+ u16 old_pvid;
+ int err;
+ DECLARE_BITMAP(changed, BR_MAX_PORTS);
+
+ bitmap_zero(changed, BR_MAX_PORTS);
+
+ /* This function runs with filtering turned off so we can
+ * remove the old pvid configuration and add the new one after
+ * without impacting traffic.
+ */
+
+ old_pvid = br->default_pvid;
+
+ /* If the user has set a different PVID or if the new default pvid
+ * conflicts with user configuration, do not modify the configuration.
+ */
+ if (old_pvid != br_get_pvid(br_get_vlan_info(br)) ||
+ br_vlan_find(br, pvid))
+ goto do_ports;
+
+ set_bit(0, changed);
+ br_vlan_delete(br, old_pvid);
+ err = br_vlan_add(br, pvid,
+ BRIDGE_VLAN_INFO_PVID | BRIDGE_VLAN_INFO_UNTAGGED);
+ if (err)
+ goto err_br;
+
+do_ports:
+ list_for_each_entry(p, &br->port_list, list) {
+ /* If the user has set a different PVID or if the new default
+ * pvid conflicts with user configuration, do not modify the
+ * configuration.
+ */
+ if (old_pvid != br_get_pvid(nbp_get_vlan_info(p)) ||
+ nbp_vlan_find(p, pvid))
+ continue;
+
+ set_bit(p->port_no, changed);
+ err = nbp_vlan_add(p, pvid,
+ BRIDGE_VLAN_INFO_PVID |
+ BRIDGE_VLAN_INFO_UNTAGGED);
+ if (err)
+ goto err_port;
+ nbp_vlan_delete(p, old_pvid);
+ }
+
+ br->default_pvid = pvid;
+
+ return 0;
+
+err_port:
+ list_for_each_entry_continue_reverse(p, &br->port_list, list) {
+ if (!test_bit(p->port_no, changed))
+ continue;
+
+ nbp_vlan_delete(p, pvid);
+ nbp_vlan_add(p, old_pvid,
+ BRIDGE_VLAN_INFO_PVID |
+ BRIDGE_VLAN_INFO_UNTAGGED);
+ }
+
+err_br:
+ if (test_bit(0, changed)) {
+ br_vlan_delete(br, pvid);
+ br_vlan_add(br, old_pvid,
+ BRIDGE_VLAN_INFO_PVID |
+ BRIDGE_VLAN_INFO_UNTAGGED);
+ }
+ return err;
+}
+
int br_vlan_set_default_pvid(struct net_bridge *br, unsigned long val)
{
u16 pvid = val;
int err = 0;
- if (!pvid || pvid >= VLAN_VID_MASK)
+ if (pvid >= VLAN_VID_MASK)
return -EINVAL;
if (!rtnl_trylock())
@@ -519,17 +617,22 @@ int br_vlan_set_default_pvid(struct net_bridge *br, unsigned long val)
goto unlock;
}
- br->default_pvid = vid;
+ if (!pvid)
+ br_vlan_disable_default_pvid(br);
+ else
+ err = __br_vlan_set_default_pvid(br, pvid);
unlock:
rtnl_unlock();
return err;
}
-void br_vlan_init(struct net_bridge *br)
+int br_vlan_init(struct net_bridge *br)
{
br->vlan_proto = htons(ETH_P_8021Q);
br->default_pvid = 1;
+ return br_vlan_add(br, 1,
+ BRIDGE_VLAN_INFO_PVID | BRIDGE_VLAN_INFO_UNTAGGED);
}
/* Must be protected by RTNL.
@@ -621,3 +724,10 @@ out:
rcu_read_unlock();
return found;
}
+
+int nbp_vlan_init(struct net_bridge_port *p)
+{
+ return nbp_vlan_add(p, p->br->default_pvid,
+ BRIDGE_VLAN_INFO_PVID |
+ BRIDGE_VLAN_INFO_UNTAGGED);
+}
--
1.9.3
^ permalink raw reply related
* [PATCH v2 net 2/3] bridge: Simplify pvid checks.
From: Vladislav Yasevich @ 2014-09-30 19:31 UTC (permalink / raw)
To: netdev; +Cc: toshiaki.makita1, stephen, bridge, Vladislav Yasevich
In-Reply-To: <1412105462-340-1-git-send-email-vyasevic@redhat.com>
Currently, if the pvid is not set, we return an illegal vlan value
even though the pvid value is set to 0. Since pvid of 0 is currently
invalid, just return 0 instead. This makes the current and future
checks simpler.
Signed-off-by: Vladislav Yasevich <vyasevic@redhat.com>
---
net/bridge/br_private.h | 2 +-
net/bridge/br_vlan.c | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/net/bridge/br_private.h b/net/bridge/br_private.h
index 6fe8680..873d9da 100644
--- a/net/bridge/br_private.h
+++ b/net/bridge/br_private.h
@@ -647,7 +647,7 @@ static inline u16 br_get_pvid(const struct net_port_vlans *v)
* vid wasn't set
*/
smp_rmb();
- return v->pvid ?: VLAN_N_VID;
+ return v->pvid;
}
static inline int br_vlan_enabled(struct net_bridge *br)
diff --git a/net/bridge/br_vlan.c b/net/bridge/br_vlan.c
index 295ad0d..f5eee61 100644
--- a/net/bridge/br_vlan.c
+++ b/net/bridge/br_vlan.c
@@ -223,7 +223,7 @@ bool br_allowed_ingress(struct net_bridge *br, struct net_port_vlans *v,
* See if pvid is set on this port. That tells us which
* vlan untagged or priority-tagged traffic belongs to.
*/
- if (pvid == VLAN_N_VID)
+ if (!pvid)
goto drop;
/* PVID is set on this port. Any untagged or priority-tagged
@@ -292,7 +292,7 @@ bool br_should_learn(struct net_bridge_port *p, struct sk_buff *skb, u16 *vid)
if (!*vid) {
*vid = br_get_pvid(v);
- if (*vid == VLAN_N_VID)
+ if (!*vid)
return false;
return true;
--
1.9.3
^ permalink raw reply related
* [PATCH v2 net 0/3] bridge: Add vlan filtering support for default pvid
From: Vladislav Yasevich @ 2014-09-30 19:30 UTC (permalink / raw)
To: netdev; +Cc: stephen, bridge, Vladislav Yasevich
Version 2 of the series to introduce the default pvid support to
vlan filtering in the bridge. VLAN 1 (as recommended by 802.1q spec)
is used as default pvid on ports.
The the user can over-ride this configuration by configuring their
own vlan information.
The user can additionally change the default value throught the
sysfs interface (netlink comming shortly).
The user can turn off default pvid functionality by setting default
pvid to 0.
This series changes the default behavior of the bridge when
vlan filtering is turned on. Currently, ports without any vlan
filtering configured will not recevie any traffic at all. This patch
changes the behavior of the above ports to receive only untagged traffic.
Since v2:
- Add ability to turn off default_pvid settings.
- Drop the automiatic filtering support based on configured vlan devices (will
be its own series)
Thanks
-vlad
Vladislav Yasevich (3):
bridge: Add a default_pvid sysfs attribute
bridge: Simplify pvid checks.
bridge: Add filtering support for default_pvid
net/bridge/br_device.c | 8 ++-
net/bridge/br_if.c | 2 +
net/bridge/br_private.h | 17 +++++-
net/bridge/br_sysfs_br.c | 17 ++++++
net/bridge/br_vlan.c | 143 ++++++++++++++++++++++++++++++++++++++++++++++-
5 files changed, 179 insertions(+), 8 deletions(-)
--
1.9.3
^ permalink raw reply
* RE: How exactly does CHECKSUM_COMPLETE works?
From: Eric Dumazet @ 2014-09-30 19:22 UTC (permalink / raw)
To: Yuval Mintz; +Cc: Tom Herbert (Partner - google), netdev
In-Reply-To: <B5657A6538887040AD3A81F1008BEC63B4152D@avmb3.qlogic.org>
On Tue, 2014-09-30 at 19:05 +0000, Yuval Mintz wrote:
> Can you pinpoint me to what exactly in the code corrects NAPI_GRO_CB(skb)->csum
> by negating the ipv4 part in the ones' complete checksum?
>
> E.g., for ipv6 [in ipv6_gro_receive()] I can see that skb_gro_postpull_rcsum() is
> called after pulling the ipv6 header [and before proceeding to the next protocol],
> but I can't seem to find anything similar to this for ipv4 [in inet_gro_receive()].
>
IPv4 header is supposed to have a 0 checksum ;)
^ permalink raw reply
* [PATCH] et131x: Promote staging et131x driver to drivers/net
From: Mark Einon @ 2014-09-30 19:16 UTC (permalink / raw)
To: gregkh, davem; +Cc: devel, netdev, linux-kernel, Mark Einon
This patch moves the et131x gigabit ethernet driver from drivers/staging
to drivers/net/ethernet/agere.
Signed-off-by: Mark Einon <mark.einon@gmail.com>
---
This patch appiles to both staging-next and the linux-next tag next-20140930,
and takes into account all feedback recieved from the recent RFC for this
patch.
MAINTAINERS | 10 +++----
drivers/net/ethernet/Kconfig | 1 +
drivers/net/ethernet/Makefile | 1 +
drivers/net/ethernet/agere/Kconfig | 31 ++++++++++++++++++++++
.../et131x => net/ethernet/agere}/Makefile | 0
.../et131x => net/ethernet/agere}/et131x.c | 0
.../et131x => net/ethernet/agere}/et131x.h | 0
drivers/staging/Kconfig | 2 --
drivers/staging/Makefile | 1 -
drivers/staging/et131x/Kconfig | 10 -------
drivers/staging/et131x/README | 15 -----------
11 files changed, 38 insertions(+), 33 deletions(-)
create mode 100644 drivers/net/ethernet/agere/Kconfig
rename drivers/{staging/et131x => net/ethernet/agere}/Makefile (100%)
rename drivers/{staging/et131x => net/ethernet/agere}/et131x.c (100%)
rename drivers/{staging/et131x => net/ethernet/agere}/et131x.h (100%)
delete mode 100644 drivers/staging/et131x/Kconfig
delete mode 100644 drivers/staging/et131x/README
diff --git a/MAINTAINERS b/MAINTAINERS
index 637112c..26b5238 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -3572,6 +3572,11 @@ T: git git://git.kernel.org/pub/scm/linux/kernel/git/kristoffer/linux-hpc.git
F: drivers/video/fbdev/s1d13xxxfb.c
F: include/video/s1d13xxxfb.h
+ET131X NETWORK DRIVER
+M: Mark Einon <mark.einon@gmail.com>
+S: Odd Fixes
+F: drivers/net/ethernet/agere/
+
ETHERNET BRIDGE
M: Stephen Hemminger <stephen@networkplumber.org>
L: bridge@lists.linux-foundation.org
@@ -8764,11 +8769,6 @@ M: H Hartley Sweeten <hsweeten@visionengravers.com>
S: Odd Fixes
F: drivers/staging/comedi/
-STAGING - ET131X NETWORK DRIVER
-M: Mark Einon <mark.einon@gmail.com>
-S: Odd Fixes
-F: drivers/staging/et131x/
-
STAGING - FLARION FT1000 DRIVERS
M: Marek Belisko <marek.belisko@gmail.com>
S: Odd Fixes
diff --git a/drivers/net/ethernet/Kconfig b/drivers/net/ethernet/Kconfig
index dc7406c..d48fc9c 100644
--- a/drivers/net/ethernet/Kconfig
+++ b/drivers/net/ethernet/Kconfig
@@ -20,6 +20,7 @@ config SUNGEM_PHY
source "drivers/net/ethernet/3com/Kconfig"
source "drivers/net/ethernet/adaptec/Kconfig"
source "drivers/net/ethernet/aeroflex/Kconfig"
+source "drivers/net/ethernet/agere/Kconfig"
source "drivers/net/ethernet/allwinner/Kconfig"
source "drivers/net/ethernet/alteon/Kconfig"
source "drivers/net/ethernet/altera/Kconfig"
diff --git a/drivers/net/ethernet/Makefile b/drivers/net/ethernet/Makefile
index 224a018..89207ac 100644
--- a/drivers/net/ethernet/Makefile
+++ b/drivers/net/ethernet/Makefile
@@ -6,6 +6,7 @@ obj-$(CONFIG_NET_VENDOR_3COM) += 3com/
obj-$(CONFIG_NET_VENDOR_8390) += 8390/
obj-$(CONFIG_NET_VENDOR_ADAPTEC) += adaptec/
obj-$(CONFIG_GRETH) += aeroflex/
+obj-$(CONFIG_NET_VENDOR_AGERE) += agere/
obj-$(CONFIG_NET_VENDOR_ALLWINNER) += allwinner/
obj-$(CONFIG_NET_VENDOR_ALTEON) += alteon/
obj-$(CONFIG_ALTERA_TSE) += altera/
diff --git a/drivers/net/ethernet/agere/Kconfig b/drivers/net/ethernet/agere/Kconfig
new file mode 100644
index 0000000..63e805d
--- /dev/null
+++ b/drivers/net/ethernet/agere/Kconfig
@@ -0,0 +1,31 @@
+#
+# Agere device configuration
+#
+
+config NET_VENDOR_AGERE
+ bool "Agere devices"
+ default y
+ depends on PCI
+ ---help---
+ If you have a network (Ethernet) card belonging to this class, say Y
+ and read the Ethernet-HOWTO, available from
+ <http://www.tldp.org/docs.html#howto>.
+
+ Note that the answer to this question doesn't directly affect the
+ kernel: saying N will just cause the configurator to skip all
+ the questions about Agere devices. If you say Y, you will be asked
+ for your specific card in the following questions.
+
+if NET_VENDOR_AGERE
+
+config ET131X
+ tristate "Agere ET-1310 Gigabit Ethernet support"
+ depends on PCI
+ select PHYLIB
+ ---help---
+ This driver supports Agere ET-1310 ethernet adapters.
+
+ To compile this driver as a module, choose M here. The module
+ will be called et131x.
+
+endif # NET_VENDOR_AGERE
diff --git a/drivers/staging/et131x/Makefile b/drivers/net/ethernet/agere/Makefile
similarity index 100%
rename from drivers/staging/et131x/Makefile
rename to drivers/net/ethernet/agere/Makefile
diff --git a/drivers/staging/et131x/et131x.c b/drivers/net/ethernet/agere/et131x.c
similarity index 100%
rename from drivers/staging/et131x/et131x.c
rename to drivers/net/ethernet/agere/et131x.c
diff --git a/drivers/staging/et131x/et131x.h b/drivers/net/ethernet/agere/et131x.h
similarity index 100%
rename from drivers/staging/et131x/et131x.h
rename to drivers/net/ethernet/agere/et131x.h
diff --git a/drivers/staging/Kconfig b/drivers/staging/Kconfig
index 6e2d6fd..9d18a1c 100644
--- a/drivers/staging/Kconfig
+++ b/drivers/staging/Kconfig
@@ -24,8 +24,6 @@ menuconfig STAGING
if STAGING
-source "drivers/staging/et131x/Kconfig"
-
source "drivers/staging/slicoss/Kconfig"
source "drivers/staging/wlan-ng/Kconfig"
diff --git a/drivers/staging/Makefile b/drivers/staging/Makefile
index 74c679e..8c56326 100644
--- a/drivers/staging/Makefile
+++ b/drivers/staging/Makefile
@@ -4,7 +4,6 @@
obj-$(CONFIG_STAGING) += staging.o
obj-y += media/
-obj-$(CONFIG_ET131X) += et131x/
obj-$(CONFIG_SLICOSS) += slicoss/
obj-$(CONFIG_PRISM2_USB) += wlan-ng/
obj-$(CONFIG_COMEDI) += comedi/
diff --git a/drivers/staging/et131x/Kconfig b/drivers/staging/et131x/Kconfig
deleted file mode 100644
index 8190f2a..0000000
--- a/drivers/staging/et131x/Kconfig
+++ /dev/null
@@ -1,10 +0,0 @@
-config ET131X
- tristate "Agere ET-1310 Gigabit Ethernet support"
- depends on PCI && NET && NETDEVICES
- select PHYLIB
- default n
- ---help---
- This driver supports Agere ET-1310 ethernet adapters.
-
- To compile this driver as a module, choose M here. The module
- will be called et131x.
diff --git a/drivers/staging/et131x/README b/drivers/staging/et131x/README
deleted file mode 100644
index 13c8168..0000000
--- a/drivers/staging/et131x/README
+++ /dev/null
@@ -1,15 +0,0 @@
-This is a driver for the ET1310 network device.
-
-Based on the driver found at https://sourceforge.net/projects/et131x/
-
-Cleaned up immensely by Olaf Hartman and Christoph Hellwig <hch@infradead.org>
-
-Note, the powermanagement options were removed from the vendor provided
-driver as they did not build properly at the time.
-
-TODO:
-
-Please send patches to:
- Greg Kroah-Hartman <gregkh@linuxfoundation.org>
- Mark Einon <mark.einon@gmail.com>
-
--
2.1.0
^ permalink raw reply related
* Re: [PATCH] net: ethernet : stmicro: fixed power suspend and resume failure in stmmac driver
From: David Miller @ 2014-09-30 19:10 UTC (permalink / raw)
To: hliang1025; +Cc: peppe.cavallaro, netdev, linux-kernel, adi-linux-docs
In-Reply-To: <1412056534-7995-1-git-send-email-hliang1025@gmail.com>
From: <hliang1025@gmail.com>
Date: Tue, 30 Sep 2014 13:55:34 +0800
> From: Hao Liang <hliang1025@gmail.com>
>
> This is the fix for a power management issue caused by suspend and resume function in stmmac_main.c.
> After enable CONFIG_DEBUG_ATOMIC_SLEEP which enable sleep-inside atomic section checking, power
> managemet can not work normally. Board couldn't wakeup successfully after suspend. Command
> "echo mem > /sys/power/state" suspend the board.
>
> In suspend and resume function of stmmac driver, there are some sleep-inside function in atomic section
> created by spin lock. These functions will causes system warnings and wakeup issue when enable
> CONFIG_DEBUG_ATOMIC_SLEEP.
>
> This bug was fixed by:
> * replace some sleep function with non-sleep function
> clk_disable_unprepare -> clk_disable ...
> * decrease the atomic area created by spin lock function. The original atomic area in resume function is
> too large.
>
> Signed-off-by: Hao Liang <hliang1025@gmail.com>
I really think the ->mac->xxx calls need to be under the lock, and therefore this
spinlock region shortening is not valid.
^ permalink raw reply
* RE: How exactly does CHECKSUM_COMPLETE works?
From: Yuval Mintz @ 2014-09-30 19:05 UTC (permalink / raw)
To: Tom Herbert (Partner - google); +Cc: netdev
In-Reply-To: <CA+mtBx_17aJuK=xjnDukGJOfw-twHg=rF5rDacg6pga6ZTTRcw@mail.gmail.com>
> > Scenario 1 - TCP/IPv4 packet. This will eventually reach
> > tcp4_gro_receive(), and from there into skb_gro_checksum_validate().
> > Since this SKB is marked as COMPLETE, the pseudo TCP checksum will be
> > computed and skb_gro_checksum_validate_complete() be called.
> > Now, it seems to me as if the only way by which the flow won't
> > actually try to re-calculate the checksum over TCP header and payload
> > is if NAPI_GRO_CB(skb)->csum is actually the one's complement to the
> > TCP pseudo header. But that sounds.... odd, since that's the csum that
> > should have been listed on the SKB - and it doesn't protect any of the data,
> only the "metadata".
> >
> With CHECKSUM_COMPLETE, on entrance into GRO NAPI_GRO_CB(skb)->csum
> is set to skb->csum. As the packet is parsed through various levels of GRO the
> value is adjusted so that at any header level it is the complete checksum starting
> from that header to the end of the packet.
> So to validate a TCP checksum we just need to add the value of the pseudo
> header checksum (a little computation) and compare to zero.
...
>> 1. What should a driver set as the SKBs csum value when passing CHECKSUM_COMPLETE?
>This ones complete checksum of the Ethernet payload (start of IP header to the end of the packet).
Can you pinpoint me to what exactly in the code corrects NAPI_GRO_CB(skb)->csum
by negating the ipv4 part in the ones' complete checksum?
E.g., for ipv6 [in ipv6_gro_receive()] I can see that skb_gro_postpull_rcsum() is
called after pulling the ipv6 header [and before proceeding to the next protocol],
but I can't seem to find anything similar to this for ipv4 [in inet_gro_receive()].
________________________________
This message and any attached documents contain information from QLogic Corporation or its wholly-owned subsidiaries that may be confidential. If you are not the intended recipient, you may not read, copy, distribute, or use this information. If you have received this transmission in error, please notify the sender immediately by reply e-mail and then delete this message.
^ permalink raw reply
* [PATCH] tg3: Allow for receive of full-size 8021AD frames
From: Vlad Yasevich @ 2014-09-30 18:53 UTC (permalink / raw)
To: netdev; +Cc: Vladislav Yasevich, Prashant Sreedharan, Michael Chan
In-Reply-To: <1411165389-21276-1-git-send-email-vyasevic@redhat.com>
When receiving a vlan-tagged frame that still contains
a vlan header, the length of the packet will be greater
then MTU+ETH_HLEN since it will account of the extra
vlan header. TG3 checks this for the case for 802.1Q,
but not for 802.1ad. As a result, full sized 802.1ad
frames get dropped by the card.
Add a check for 802.1ad protocol when receiving full
sized frames.
Suggested-by: Prashant Sreedharan <prashant@broadcom.com>
CC: Prashant Sreedharan <prashant@broadcom.com>
CC: Michael Chan <mchan@broadcom.com>
Acked-by: Prashant Sreedharan <prashant@broadcom.com>
Signed-off-by: Vladislav Yasevich <vyasevic@redhat.com>
---
This patch somehow got dropped. Please apply and queue for stable.
drivers/net/ethernet/broadcom/tg3.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/net/ethernet/broadcom/tg3.c b/drivers/net/ethernet/broadcom/tg3.c
index 0a0938d..4f674f9 100644
--- a/drivers/net/ethernet/broadcom/tg3.c
+++ b/drivers/net/ethernet/broadcom/tg3.c
@@ -6918,7 +6918,8 @@ static int tg3_rx(struct tg3_napi *tnapi, int budget)
skb->protocol = eth_type_trans(skb, tp->dev);
if (len > (tp->dev->mtu + ETH_HLEN) &&
- skb->protocol != htons(ETH_P_8021Q)) {
+ skb->protocol != htons(ETH_P_8021Q) &&
+ skb->protocol != htons(ETH_P_8021AD)) {
dev_kfree_skb_any(skb);
goto drop_it_no_recycle;
}
--
1.9.3
^ permalink raw reply related
* Re: How exactly does CHECKSUM_COMPLETE works?
From: David Miller @ 2014-09-30 18:48 UTC (permalink / raw)
To: alexei.starovoitov; +Cc: therbert, Yuval.Mintz, netdev
In-Reply-To: <CAADnVQLxX4LGFfqd6x+krfEMB57y_o80xW_3brkPvEJueDNWVg@mail.gmail.com>
From: Alexei Starovoitov <alexei.starovoitov@gmail.com>
Date: Tue, 30 Sep 2014 09:58:32 -0700
> On Tue, Sep 30, 2014 at 7:59 AM, Tom Herbert <therbert@google.com> wrote:
>>
>>> So, to summarize my questions -
>>> 1. What should a driver set as the SKBs csum value when passing CHECKSUM_COMPLETE?
>>
>> This ones complete checksum of the Ethernet payload (start of IP
>> header to the end of the packet).
>
> I think it's confusing to describe CHECKSUM_COMPLETE this way.
> It is such only because driver pulls eth header before passing skb to stack.
> CHECKSUM_COMPLETE should cover the whole packet. If there are multiple
> vlan headers in front of IP they should be part of csum, since not all
> drivers may
> have hw offloading for vlan. The most simplistic HW would compute csum over
> the whole packet including eth header and driver will do
> eth_type_trans+skb_postpull_rcsum
The sungem computes the checksum over the entire frame. Here are the relevant
parts from the programmer's manual:
RX Descriptor Fields
...
TCP Pseudo-Checksum - Contains the 16-bit TCP checksum calculated over
the entire frame, starting at an offset programmable in the RX
Configuration Register.
In the gengem driver this is the RXDMA_CFG_CSUMOFF field of the RXDMA_CFG
register.
The driver seems to set this to the size of the ethernet header, which has
the problems you mention.
^ permalink raw reply
* Re: [PATCH iproute2] iplink: do not require assigning negative ifindex at link creation
From: Cong Wang @ 2014-09-30 18:26 UTC (permalink / raw)
To: Atzm Watanabe; +Cc: netdev, Cong Wang, Stephen Hemminger
In-Reply-To: <87wq8l5ppn.wl%atzm@stratosphere.co.jp>
On Tue, Sep 30, 2014 at 4:10 AM, Atzm Watanabe <atzm@stratosphere.co.jp> wrote:
> Since commit 3c682146aeff, iplink requires assigning negative
> ifindex (-1) to the kernel when creating interface without
> specifying index.
>
> Cc: Cong Wang <xiyou.wangcong@gmail.com>
> Signed-off-by: Atzm Watanabe <atzm@stratosphere.co.jp>
> ---
> ip/iplink.c | 5 ++++-
> 1 file changed, 4 insertions(+), 1 deletion(-)
>
> diff --git a/ip/iplink.c b/ip/iplink.c
> index cb9c870..de6b2a9 100644
> --- a/ip/iplink.c
> +++ b/ip/iplink.c
> @@ -689,7 +689,10 @@ static int iplink_modify(int cmd, unsigned int flags, int argc, char **argv)
> addattr_l(&req.n, sizeof(req), IFLA_LINK, &ifindex, 4);
> }
>
> - req.i.ifi_index = index;
> + if (index <= 0)
> + req.i.ifi_index = 0;
> + else
> + req.i.ifi_index = index;
How about checking if it is -1?
if (index == -1)
req.i.ifi_index = 0;
else
req.i.ifi_index = index;
Thanks for fixing it.
^ permalink raw reply
* Re: [net-next PATCH V5] qdisc: bulk dequeue support for qdiscs with TCQ_F_ONETXQUEUE
From: David Miller @ 2014-09-30 18:20 UTC (permalink / raw)
To: jhs
Cc: brouer, netdev, therbert, eric.dumazet, hannes, fw, dborkman,
alexander.duyck, john.r.fastabend, dave.taht, toke
In-Reply-To: <542A8EF9.10403@mojatatu.com>
From: Jamal Hadi Salim <jhs@mojatatu.com>
Date: Tue, 30 Sep 2014 07:07:37 -0400
> Note, there are benefits as you have shown - but i would not
> consider those to be standard use cases (actully one which would
> have shown clear win is the VM thing Rusty was after).
I completely disagree, you will see at least decreased cpu utilization
for a very common case, bulk single stream transfers.
> For this reason my view is that i should be able to disable via
> ifdef bulking (yes, I know DaveM hates ifdefs ;->).
Vehemntly _disagree_. :)
^ permalink raw reply
* Why include/net/tcp_states.h is not exported to user-space?
From: Cong Wang @ 2014-09-30 18:12 UTC (permalink / raw)
To: Arnaldo Carvalho de Melo; +Cc: David Miller, netdev
Hello,
These states are needed for user-space to specify ->idiag_states.
Currently both libnl and ss make their own copy of these definitions.
Of course, new sock diag is not just limited to TCP, so we probably
need to rename them to SS_* before exporting them.
I can send a patch if you agree.
Thanks!
^ permalink raw reply
* Re: [PATCH net-next] netfilter: bridge: build br_nf_core only if required
From: David Miller @ 2014-09-30 18:10 UTC (permalink / raw)
To: pablo; +Cc: netfilter-devel, netdev, eric.dumazet, therbert, fw
In-Reply-To: <1412067559-28733-1-git-send-email-pablo@netfilter.org>
From: Pablo Neira Ayuso <pablo@netfilter.org>
Date: Tue, 30 Sep 2014 10:59:18 +0200
> From: Florian Westphal <fw@strlen.de>
>
> Eric reports build failure with
> CONFIG_BRIDGE_NETFILTER=n
>
> We insist to build br_nf_core.o unconditionally, but we must only do so
> if br_netfilter was enabled, else it fails to build due to
> functions being defined to empty stubs (and some structure members
> being defined out).
>
> Also, BRIDGE_NETFILTER=y|m makes no sense when BRIDGE=n.
>
> Fixes: 34666d467 (netfilter: bridge: move br_netfilter out of the core)
> Reported-by: Eric Dumazet <eric.dumazet@gmail.com>
> Signed-off-by: Florian Westphal <fw@strlen.de>
> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Applied, thanks.
^ permalink raw reply
* Re: [PATCH] hostap: proc: Remove unused variable
From: John W. Linville @ 2014-09-30 16:56 UTC (permalink / raw)
To: Mark Brown; +Cc: Jouni Malinen, linux-wireless, netdev, linaro-kernel
In-Reply-To: <1410909415-11661-1-git-send-email-broonie@kernel.org>
On Tue, Sep 16, 2014 at 04:16:55PM -0700, Mark Brown wrote:
> Since "hostap: proc: substitute loops by %*phN" (62c5afb8e388) the
> variable i has been unused in prism2_bss_list_proc_show() so remove it.
>
> Signed-off-by: Mark Brown <broonie@kernel.org>
> ---
> drivers/net/wireless/hostap/hostap_proc.c | 1 -
> 1 file changed, 1 deletion(-)
>
> diff --git a/drivers/net/wireless/hostap/hostap_proc.c b/drivers/net/wireless/hostap/hostap_proc.c
> index 3a23a6d..dd84557 100644
> --- a/drivers/net/wireless/hostap/hostap_proc.c
> +++ b/drivers/net/wireless/hostap/hostap_proc.c
> @@ -168,7 +168,6 @@ static int prism2_bss_list_proc_show(struct seq_file *m, void *v)
> local_info_t *local = m->private;
> struct list_head *ptr = v;
> struct hostap_bss_info *bss;
> - int i;
>
> if (ptr == &local->bss_list) {
> seq_printf(m, "#BSSID\tlast_update\tcount\tcapab_info\tSSID(txt)\t"
> --
> 2.1.0
What tree are you using? In wireless-next, I still see a loop in
that function using i as an index variable.
John
--
John W. Linville Someday the world will need a hero, and you
linville@tuxdriver.com might be all we have. Be ready.
^ permalink raw reply
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