Netdev List
 help / color / mirror / Atom feed
* [PATCH net-next 3/4] net: ipv6: Plumb extack through route add functions
From: David Ahern @ 2017-05-21 16:12 UTC (permalink / raw)
  To: netdev; +Cc: David Ahern
In-Reply-To: <20170521161205.36720-1-dsahern@gmail.com>

Plumb extack argument down to route add functions.

Signed-off-by: David Ahern <dsahern@gmail.com>
---
 include/net/ip6_fib.h   |  3 ++-
 include/net/ip6_route.h |  2 +-
 net/ipv6/addrconf.c     |  4 ++--
 net/ipv6/ip6_fib.c      | 14 +++++++-----
 net/ipv6/route.c        | 57 +++++++++++++++++++++++++++----------------------
 5 files changed, 46 insertions(+), 34 deletions(-)

diff --git a/include/net/ip6_fib.h b/include/net/ip6_fib.h
index c979c878df1c..aa50e2e6fa2a 100644
--- a/include/net/ip6_fib.h
+++ b/include/net/ip6_fib.h
@@ -277,7 +277,8 @@ void fib6_clean_all(struct net *net, int (*func)(struct rt6_info *, void *arg),
 		    void *arg);
 
 int fib6_add(struct fib6_node *root, struct rt6_info *rt,
-	     struct nl_info *info, struct mx6_config *mxc);
+	     struct nl_info *info, struct mx6_config *mxc,
+	     struct netlink_ext_ack *extack);
 int fib6_del(struct rt6_info *rt, struct nl_info *info);
 
 void inet6_rt_notify(int event, struct rt6_info *rt, struct nl_info *info,
diff --git a/include/net/ip6_route.h b/include/net/ip6_route.h
index f5e625f53367..f3da9dd2a8db 100644
--- a/include/net/ip6_route.h
+++ b/include/net/ip6_route.h
@@ -90,7 +90,7 @@ void ip6_route_cleanup(void);
 
 int ipv6_route_ioctl(struct net *net, unsigned int cmd, void __user *arg);
 
-int ip6_route_add(struct fib6_config *cfg);
+int ip6_route_add(struct fib6_config *cfg, struct netlink_ext_ack *extack);
 int ip6_ins_rt(struct rt6_info *);
 int ip6_del_rt(struct rt6_info *);
 
diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c
index 6a4fb1e629fb..25443fd946a8 100644
--- a/net/ipv6/addrconf.c
+++ b/net/ipv6/addrconf.c
@@ -2280,7 +2280,7 @@ addrconf_prefix_route(struct in6_addr *pfx, int plen, struct net_device *dev,
 		cfg.fc_flags |= RTF_NONEXTHOP;
 #endif
 
-	ip6_route_add(&cfg);
+	ip6_route_add(&cfg, NULL);
 }
 
 
@@ -2335,7 +2335,7 @@ static void addrconf_add_mroute(struct net_device *dev)
 
 	ipv6_addr_set(&cfg.fc_dst, htonl(0xFF000000), 0, 0, 0);
 
-	ip6_route_add(&cfg);
+	ip6_route_add(&cfg, NULL);
 }
 
 static struct inet6_dev *addrconf_add_dev(struct net_device *dev)
diff --git a/net/ipv6/ip6_fib.c b/net/ipv6/ip6_fib.c
index d4bf2c68a545..c1197e167d3e 100644
--- a/net/ipv6/ip6_fib.c
+++ b/net/ipv6/ip6_fib.c
@@ -473,7 +473,8 @@ static int inet6_dump_fib(struct sk_buff *skb, struct netlink_callback *cb)
 static struct fib6_node *fib6_add_1(struct fib6_node *root,
 				     struct in6_addr *addr, int plen,
 				     int offset, int allow_create,
-				     int replace_required, int sernum)
+				     int replace_required, int sernum,
+				     struct netlink_ext_ack *extack)
 {
 	struct fib6_node *fn, *in, *ln;
 	struct fib6_node *pn = NULL;
@@ -964,7 +965,8 @@ void fib6_force_start_gc(struct net *net)
  */
 
 int fib6_add(struct fib6_node *root, struct rt6_info *rt,
-	     struct nl_info *info, struct mx6_config *mxc)
+	     struct nl_info *info, struct mx6_config *mxc,
+	     struct netlink_ext_ack *extack)
 {
 	struct fib6_node *fn, *pn = NULL;
 	int err = -ENOMEM;
@@ -987,7 +989,7 @@ int fib6_add(struct fib6_node *root, struct rt6_info *rt,
 
 	fn = fib6_add_1(root, &rt->rt6i_dst.addr, rt->rt6i_dst.plen,
 			offsetof(struct rt6_info, rt6i_dst), allow_create,
-			replace_required, sernum);
+			replace_required, sernum, extack);
 	if (IS_ERR(fn)) {
 		err = PTR_ERR(fn);
 		fn = NULL;
@@ -1028,7 +1030,8 @@ int fib6_add(struct fib6_node *root, struct rt6_info *rt,
 			sn = fib6_add_1(sfn, &rt->rt6i_src.addr,
 					rt->rt6i_src.plen,
 					offsetof(struct rt6_info, rt6i_src),
-					allow_create, replace_required, sernum);
+					allow_create, replace_required, sernum,
+					extack);
 
 			if (IS_ERR(sn)) {
 				/* If it is failed, discard just allocated
@@ -1047,7 +1050,8 @@ int fib6_add(struct fib6_node *root, struct rt6_info *rt,
 			sn = fib6_add_1(fn->subtree, &rt->rt6i_src.addr,
 					rt->rt6i_src.plen,
 					offsetof(struct rt6_info, rt6i_src),
-					allow_create, replace_required, sernum);
+					allow_create, replace_required, sernum,
+					extack);
 
 			if (IS_ERR(sn)) {
 				err = PTR_ERR(sn);
diff --git a/net/ipv6/route.c b/net/ipv6/route.c
index dc61b0b5e64e..ca754ec4054a 100644
--- a/net/ipv6/route.c
+++ b/net/ipv6/route.c
@@ -938,14 +938,15 @@ EXPORT_SYMBOL(rt6_lookup);
  */
 
 static int __ip6_ins_rt(struct rt6_info *rt, struct nl_info *info,
-			struct mx6_config *mxc)
+			struct mx6_config *mxc,
+			struct netlink_ext_ack *extack)
 {
 	int err;
 	struct fib6_table *table;
 
 	table = rt->rt6i_table;
 	write_lock_bh(&table->tb6_lock);
-	err = fib6_add(&table->tb6_root, rt, info, mxc);
+	err = fib6_add(&table->tb6_root, rt, info, mxc, extack);
 	write_unlock_bh(&table->tb6_lock);
 
 	return err;
@@ -956,7 +957,7 @@ int ip6_ins_rt(struct rt6_info *rt)
 	struct nl_info info = {	.nl_net = dev_net(rt->dst.dev), };
 	struct mx6_config mxc = { .mx = NULL, };
 
-	return __ip6_ins_rt(rt, &info, &mxc);
+	return __ip6_ins_rt(rt, &info, &mxc, NULL);
 }
 
 static struct rt6_info *ip6_rt_cache_alloc(struct rt6_info *ort,
@@ -1844,7 +1845,8 @@ static struct rt6_info *ip6_nh_lookup_table(struct net *net,
 	return rt;
 }
 
-static struct rt6_info *ip6_route_info_create(struct fib6_config *cfg)
+static struct rt6_info *ip6_route_info_create(struct fib6_config *cfg,
+					      struct netlink_ext_ack *extack)
 {
 	struct net *net = cfg->fc_nlinfo.nl_net;
 	struct rt6_info *rt = NULL;
@@ -2111,13 +2113,14 @@ static struct rt6_info *ip6_route_info_create(struct fib6_config *cfg)
 	return ERR_PTR(err);
 }
 
-int ip6_route_add(struct fib6_config *cfg)
+int ip6_route_add(struct fib6_config *cfg,
+		  struct netlink_ext_ack *extack)
 {
 	struct mx6_config mxc = { .mx = NULL, };
 	struct rt6_info *rt;
 	int err;
 
-	rt = ip6_route_info_create(cfg);
+	rt = ip6_route_info_create(cfg, extack);
 	if (IS_ERR(rt)) {
 		err = PTR_ERR(rt);
 		rt = NULL;
@@ -2128,7 +2131,7 @@ int ip6_route_add(struct fib6_config *cfg)
 	if (err)
 		goto out;
 
-	err = __ip6_ins_rt(rt, &cfg->fc_nlinfo, &mxc);
+	err = __ip6_ins_rt(rt, &cfg->fc_nlinfo, &mxc, extack);
 
 	kfree(mxc.mx);
 
@@ -2222,7 +2225,8 @@ static int __ip6_del_rt_siblings(struct rt6_info *rt, struct fib6_config *cfg)
 	return err;
 }
 
-static int ip6_route_del(struct fib6_config *cfg)
+static int ip6_route_del(struct fib6_config *cfg,
+			 struct netlink_ext_ack *extack)
 {
 	struct fib6_table *table;
 	struct fib6_node *fn;
@@ -2483,7 +2487,7 @@ static struct rt6_info *rt6_add_route_info(struct net *net,
 	if (!prefixlen)
 		cfg.fc_flags |= RTF_DEFAULT;
 
-	ip6_route_add(&cfg);
+	ip6_route_add(&cfg, NULL);
 
 	return rt6_get_route_info(net, prefix, prefixlen, gwaddr, dev);
 }
@@ -2529,7 +2533,7 @@ struct rt6_info *rt6_add_dflt_router(const struct in6_addr *gwaddr,
 
 	cfg.fc_gateway = *gwaddr;
 
-	if (!ip6_route_add(&cfg)) {
+	if (!ip6_route_add(&cfg, NULL)) {
 		struct fib6_table *table;
 
 		table = fib6_get_table(dev_net(dev), cfg.fc_table);
@@ -2622,10 +2626,10 @@ int ipv6_route_ioctl(struct net *net, unsigned int cmd, void __user *arg)
 		rtnl_lock();
 		switch (cmd) {
 		case SIOCADDRT:
-			err = ip6_route_add(&cfg);
+			err = ip6_route_add(&cfg, NULL);
 			break;
 		case SIOCDELRT:
-			err = ip6_route_del(&cfg);
+			err = ip6_route_del(&cfg, NULL);
 			break;
 		default:
 			err = -EINVAL;
@@ -2903,7 +2907,8 @@ static const struct nla_policy rtm_ipv6_policy[RTA_MAX+1] = {
 };
 
 static int rtm_to_fib6_config(struct sk_buff *skb, struct nlmsghdr *nlh,
-			      struct fib6_config *cfg)
+			      struct fib6_config *cfg,
+			      struct netlink_ext_ack *extack)
 {
 	struct rtmsg *rtm;
 	struct nlattr *tb[RTA_MAX+1];
@@ -3097,7 +3102,8 @@ static void ip6_route_mpath_notify(struct rt6_info *rt,
 		inet6_rt_notify(RTM_NEWROUTE, rt, info, nlflags);
 }
 
-static int ip6_route_multipath_add(struct fib6_config *cfg)
+static int ip6_route_multipath_add(struct fib6_config *cfg,
+				   struct netlink_ext_ack *extack)
 {
 	struct rt6_info *rt_notif = NULL, *rt_last = NULL;
 	struct nl_info *info = &cfg->fc_nlinfo;
@@ -3145,7 +3151,7 @@ static int ip6_route_multipath_add(struct fib6_config *cfg)
 				r_cfg.fc_encap_type = nla_get_u16(nla);
 		}
 
-		rt = ip6_route_info_create(&r_cfg);
+		rt = ip6_route_info_create(&r_cfg, extack);
 		if (IS_ERR(rt)) {
 			err = PTR_ERR(rt);
 			rt = NULL;
@@ -3170,7 +3176,7 @@ static int ip6_route_multipath_add(struct fib6_config *cfg)
 	err_nh = NULL;
 	list_for_each_entry(nh, &rt6_nh_list, next) {
 		rt_last = nh->rt6_info;
-		err = __ip6_ins_rt(nh->rt6_info, info, &nh->mxc);
+		err = __ip6_ins_rt(nh->rt6_info, info, &nh->mxc, extack);
 		/* save reference to first route for notification */
 		if (!rt_notif && !err)
 			rt_notif = nh->rt6_info;
@@ -3212,7 +3218,7 @@ static int ip6_route_multipath_add(struct fib6_config *cfg)
 	list_for_each_entry(nh, &rt6_nh_list, next) {
 		if (err_nh == nh)
 			break;
-		ip6_route_del(&nh->r_cfg);
+		ip6_route_del(&nh->r_cfg, extack);
 	}
 
 cleanup:
@@ -3227,7 +3233,8 @@ static int ip6_route_multipath_add(struct fib6_config *cfg)
 	return err;
 }
 
-static int ip6_route_multipath_del(struct fib6_config *cfg)
+static int ip6_route_multipath_del(struct fib6_config *cfg,
+				   struct netlink_ext_ack *extack)
 {
 	struct fib6_config r_cfg;
 	struct rtnexthop *rtnh;
@@ -3254,7 +3261,7 @@ static int ip6_route_multipath_del(struct fib6_config *cfg)
 				r_cfg.fc_flags |= RTF_GATEWAY;
 			}
 		}
-		err = ip6_route_del(&r_cfg);
+		err = ip6_route_del(&r_cfg, extack);
 		if (err)
 			last_err = err;
 
@@ -3270,15 +3277,15 @@ static int inet6_rtm_delroute(struct sk_buff *skb, struct nlmsghdr *nlh,
 	struct fib6_config cfg;
 	int err;
 
-	err = rtm_to_fib6_config(skb, nlh, &cfg);
+	err = rtm_to_fib6_config(skb, nlh, &cfg, extack);
 	if (err < 0)
 		return err;
 
 	if (cfg.fc_mp)
-		return ip6_route_multipath_del(&cfg);
+		return ip6_route_multipath_del(&cfg, extack);
 	else {
 		cfg.fc_delete_all_nh = 1;
-		return ip6_route_del(&cfg);
+		return ip6_route_del(&cfg, extack);
 	}
 }
 
@@ -3288,14 +3295,14 @@ static int inet6_rtm_newroute(struct sk_buff *skb, struct nlmsghdr *nlh,
 	struct fib6_config cfg;
 	int err;
 
-	err = rtm_to_fib6_config(skb, nlh, &cfg);
+	err = rtm_to_fib6_config(skb, nlh, &cfg, extack);
 	if (err < 0)
 		return err;
 
 	if (cfg.fc_mp)
-		return ip6_route_multipath_add(&cfg);
+		return ip6_route_multipath_add(&cfg, extack);
 	else
-		return ip6_route_add(&cfg);
+		return ip6_route_add(&cfg, extack);
 }
 
 static size_t rt6_nlmsg_size(struct rt6_info *rt)
-- 
2.11.0 (Apple Git-81)

^ permalink raw reply related

* Re: [net-next] net: ipv6: fix code style error and warning of ndisc.c
From: David Ahern @ 2017-05-21 16:16 UTC (permalink / raw)
  To: yuan linyu, netdev; +Cc: David S . Miller, yuan linyu
In-Reply-To: <1495253813-17168-1-git-send-email-cugyly@163.com>

On 5/19/17 10:16 PM, yuan linyu wrote:
> @@ -240,13 +240,15 @@ struct ndisc_options *ndisc_parse_options(const struct net_device *dev,
>  					  "%s: duplicated ND6 option found: type=%d\n",
>  					  __func__, nd_opt->nd_opt_type);
>  			} else {
> -				ndopts->nd_opt_array[nd_opt->nd_opt_type] = nd_opt;
> +				ndopts->nd_opt_array[nd_opt->nd_opt_type] =
> +					nd_opt;
>  			}
>  			break;
>  		case ND_OPT_PREFIX_INFO:
>  			ndopts->nd_opts_pi_end = nd_opt;
>  			if (!ndopts->nd_opt_array[nd_opt->nd_opt_type])
> -				ndopts->nd_opt_array[nd_opt->nd_opt_type] = nd_opt;
> +				ndopts->nd_opt_array[nd_opt->nd_opt_type] =
> +					nd_opt;
>  			break;
>  #ifdef CONFIG_IPV6_ROUTE_INFO
>  		case ND_OPT_ROUTE_INFO:

This makes the code less readable. Readability needs to trump rigid
80-column coding style.


> @@ -512,7 +513,8 @@ void ndisc_send_na(struct net_device *dev, const struct in6_addr *daddr,
>  		in6_ifa_put(ifp);
>  	} else {
>  		if (ipv6_dev_get_saddr(dev_net(dev), dev, daddr,
> -				       inet6_sk(dev_net(dev)->ipv6.ndisc_sk)->srcprefs,
> +				       inet6_sk(dev_net(dev)->ipv6.ndisc_sk)->
> +						srcprefs,

again here


I did not finish out this really long patch, but in general the
80-column rule can not be applied so rigidly.

^ permalink raw reply

* Re: [PATCH net-next v5] net: ipv6: fix code style error and warning of ndisc.c
From: David Ahern @ 2017-05-21 16:17 UTC (permalink / raw)
  To: Joe Perches, yuan linyu, netdev; +Cc: David S . Miller, yuan linyu
In-Reply-To: <1495382708.2093.10.camel@perches.com>

On 5/21/17 10:05 AM, Joe Perches wrote:
> But really, why bother?
> 
> Just because checkpatch bleats some message doesn't
> mean it _has_ to be fixed.
> 
> Please strive to make the code more readable and
> intelligible for _humans_.  Compilers don't care.

+1

broad cleanups like this make 'git blame' harder to use to find root causes.

^ permalink raw reply

* brcmfmac firmware issue on NanoPi K2
From: Andreas Färber @ 2017-05-21 16:20 UTC (permalink / raw)
  To: linux-wireless, brcm80211-dev-list.pdl
  Cc: netdev, technicalsupport, Arend Van Spriel, linux-amlogic

Hello,

The NanoPi K2 has an Ampak AP6212 SDIO module. brcmfmac driver loads
brcmfmac43430-sdio.bin.

When using the firmware file from linux-firmware.git that openSUSE ships
I get the following errors on 4.11.0 and next-20170519:

[ 2103.618716] brcmfmac: brcmf_sdio_htclk: HT Avail timeout (1000000):
clkctl 0x50
[ 2104.668746] brcmfmac: brcmf_sdio_htclk: HT Avail timeout (1000000):
clkctl 0x50
[ 2105.678677] brcmfmac: brcmf_sdio_htclk: HT Avail timeout (1000000):
clkctl 0x50

If I overwrite /lib/firmware/brcm/bcm43430-sdio.bin with
fw_bcm43438a0.bin from FriendlyARM's Android repository it suddenly works:

[  +0.157738] brcmfmac: brcmf_c_preinit_dcmds: Firmware version = wl0:
Jun  6 2014 14:50:39 version 7.10.226.49 (r) FWID 01-8962686a
[  +0.160108] brcmfmac: brcmf_cfg80211_reg_notifier: not a ISO3166 code
(0x30 0x30)

I recall using the linux-firmware.git brcmfmac43430-sdio.bin file
successfully on the Raspberry Pi 3 with a downstream (Leap 42.2) kernel.

I've tested both nvram_ap6212.txt and nvram_ap6212a.txt, the latter has
the following diff to nvram.txt:

--- nvram_ap6212.txt    2017-05-21 04:24:40.372113426 +0200
+++ nvram_ap6212a.txt   2017-05-21 04:24:49.852116599 +0200
@@ -1,4 +1,4 @@
-#AP6212_NVRAM_V1.0_20140603
+#AP6212_NVRAM_V1.0.1_20160606
 # 2.4 GHz, 20 MHz BW mode

 # The following parameter values are just placeholders, need to be updated.
@@ -51,4 +51,4 @@
 muxenab=0x10
 # CLDO PWM voltage settings - 0x4 - 1.1 volt
 #cldo_pwm=0x4
-
+glitch_based_crsmin=1

https://github.com/friendlyarm/android_hardware_amlogic_wifi/tree/l-amlogic-gx-sync/bcm_ampak/config/6212

* Does the linux-firmware.git brcmfmac43430-sdio.bin need a fix for AP6212?
https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git/tree/brcm

* Does the brcmfmac driver need to distinguish revisions in sdio.c as
done for 43241, plus a separate firmware file?
	BRCMF_FW_NVRAM_ENTRY(BRCM_CC_43430_CHIP_ID, 0xFFFFFFFF, 43430),

* Any other ideas?

Thanks,
Andreas

-- 
SUSE Linux GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Felix Imendörffer, Jane Smithard, Graham Norton
HRB 21284 (AG Nürnberg)

^ permalink raw reply

* Re: [PATCH net-next v5] net: ipv6: fix code style error and warning of ndisc.c
From: David Miller @ 2017-05-21 16:54 UTC (permalink / raw)
  To: dsahern; +Cc: joe, cugyly, netdev, Linyu.Yuan
In-Reply-To: <77510dfe-4fc7-4446-9f1a-aea52342ecd1@gmail.com>

From: David Ahern <dsahern@gmail.com>
Date: Sun, 21 May 2017 10:17:47 -0600

> On 5/21/17 10:05 AM, Joe Perches wrote:
>> But really, why bother?
>> 
>> Just because checkpatch bleats some message doesn't
>> mean it _has_ to be fixed.
>> 
>> Please strive to make the code more readable and
>> intelligible for _humans_.  Compilers don't care.
> 
> +1
> 
> broad cleanups like this make 'git blame' harder to use to find root causes.

I agree, and I'm pretty much going to ignore these ndisc.c cleanup
changes.

Sorry.

^ permalink raw reply

* Re: [PATCH 00/12] Netfilter/IPVS fixes for net
From: David Miller @ 2017-05-21 17:00 UTC (permalink / raw)
  To: pablo; +Cc: netfilter-devel, netdev
In-Reply-To: <1495182833-2272-1-git-send-email-pablo@netfilter.org>

From: Pablo Neira Ayuso <pablo@netfilter.org>
Date: Fri, 19 May 2017 10:33:41 +0200

> The following patchset contains Netfilter/IPVS fixes for your net tree,
> they are:
 ...
> You can pull these changes from:
> 
>   git://git.kernel.org/pub/scm/linux/kernel/git/pablo/nf.git

Pulled, thanks Pablo.

^ permalink raw reply

* Re: [PATCH net-next 00/10] qed/qede updates
From: David Miller @ 2017-05-21 17:01 UTC (permalink / raw)
  To: Yuval.Mintz; +Cc: netdev
In-Reply-To: <1495357860-28280-1-git-send-email-Yuval.Mintz@cavium.com>

From: Yuval Mintz <Yuval.Mintz@cavium.com>
Date: Sun, 21 May 2017 12:10:51 +0300

> This series contains some general minor fixes and enhancements:
> 
>  - #1, #2 and #9 correct small missing ethtool functionality.
>  - #3, #6  and #8 correct minor issues in driver, but those are either
>    print-related or unexposed in existing code.
>  - #4 adds proper support to TLB mode bonding.
>  - #10 is meant to improve performance on varying cache-line sizes.
> 
> Dave,
> 
> Please consider applying this to `net-next'.

Series applied, thank you.

^ permalink raw reply

* Re: [PATCH net-next 05/13] nfp: introduce very minimal nfp_app
From: David Miller @ 2017-05-21 17:23 UTC (permalink / raw)
  To: jakub.kicinski; +Cc: netdev, kubakici, oss-drivers
In-Reply-To: <20170519220155.27857-6-jakub.kicinski@netronome.com>

From: Jakub Kicinski <jakub.kicinski@netronome.com>
Date: Fri, 19 May 2017 15:01:47 -0700

> Introduce a concept of an application.  For now it's just grouping
> pointers and serving as a layer of indirection.  It will help us
> weaken the dependency on nfp_net in ethtool code.  Later series
> will flesh out support for different apps in the driver.
> 
> Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com>
> Reviewed-by: Simon Horman <simon.horman@netronome.com>
 ...
> +struct nfp_cpp *nfp_app_cpp(struct nfp_app *app)
> +{
> +	return app->cpp;
> +}
> +
> +struct nfp_pf *nfp_app_pf(struct nfp_app *app)
> +{
> +	return app->pf;
> +}

Don't create real function calls just to dereference pointers
like this.

Instead, if you absolutely _must_ do stuff like this, put it into
inline functions in a header file so that there is no overhead.

But honestly I would just make the core dereference the struct members
directly in the code and do away with these helpers.

Thanks.

^ permalink raw reply

* Re: [PATCH net] tcp: initialize rcv_mss to TCP_MIN_MSS instead of 0
From: David Miller @ 2017-05-21 17:25 UTC (permalink / raw)
  To: weiwan; +Cc: netdev, ycheng, ncardwell, edumazet
In-Reply-To: <20170518182233.100933-1-tracywwnj@gmail.com>

From: Wei Wang <weiwan@google.com>
Date: Thu, 18 May 2017 11:22:33 -0700

> From: Wei Wang <weiwan@google.com>
> 
> When tcp_disconnect() is called, inet_csk_delack_init() sets
> icsk->icsk_ack.rcv_mss to 0.
> This could potentially cause tcp_recvmsg() => tcp_cleanup_rbuf() =>
> __tcp_select_window() call path to have division by 0 issue.
> So this patch initializes rcv_mss to TCP_MIN_MSS instead of 0.
> 
> Reported-by: Andrey Konovalov  <andreyknvl@google.com>
> Signed-off-by: Wei Wang <weiwan@google.com>
> Signed-off-by: Eric Dumazet <edumazet@google.com>
> Signed-off-by: Neal Cardwell <ncardwell@google.com>
> Signed-off-by: Yuchung Cheng <ycheng@google.com>

Applied, thanks.

^ permalink raw reply

* Re: [PATCH v2 0/4] arp: always override existing neigh entries with gratuitous ARP
From: David Miller @ 2017-05-21 17:27 UTC (permalink / raw)
  To: ihrachys; +Cc: ja, netdev
In-Reply-To: <cover.1495136258.git.ihrachys@redhat.com>

From: Ihar Hrachyshka <ihrachys@redhat.com>
Date: Thu, 18 May 2017 12:41:17 -0700

> This patchset is spurred by discussion started at
> https://patchwork.ozlabs.org/patch/760372/ where we figured that there is no
> real reason for enforcing override by gratuitous ARP packets only when
> arp_accept is 1. Same should happen when it's 0 (the default value).
> 
> changelog v2: handled review comments by Julian Anastasov
> - fixed a mistake in a comment;
> - postponed addr_type calculation to as late as possible.

Series applied, thanks.

Please address the feedback from Julian about the ieee1394 change
you put into ARP earlier.

Thanks.

^ permalink raw reply

* Re: [PATCH 1/4] net-next: stmmac: Convert new_state to bool
From: David Miller @ 2017-05-21 17:28 UTC (permalink / raw)
  To: clabbe.montjoie; +Cc: peppe.cavallaro, alexandre.torgue, netdev, linux-kernel
In-Reply-To: <20170519070335.1604-2-clabbe.montjoie@gmail.com>

From: Corentin Labbe <clabbe.montjoie@gmail.com>
Date: Fri, 19 May 2017 09:03:32 +0200

> This patch convert new_state from int to bool since it store only 1 or 0
> 
> Signed-off-by: Corentin Labbe <clabbe.montjoie@gmail.com>

You must also change it to use the values "true" and "false" as well.

Thanks.

^ permalink raw reply

* Re: [PATCH net-next v2] ibmveth: Support to enable LSO/CSO for Trunk VEA.
From: David Miller @ 2017-05-21 17:29 UTC (permalink / raw)
  To: ksiva
  Cc: netdev, tlfalcon, benh, paulus, mpe, linuxppc-dev, linux-kernel,
	brking, seroyer, bryantly
In-Reply-To: <1495186238-19058-1-git-send-email-ksiva@linux.vnet.ibm.com>

From: Sivakumar Krishnasamy <ksiva@linux.vnet.ibm.com>
Date: Fri, 19 May 2017 05:30:38 -0400

 ...
> Signed-off-by: Sivakumar Krishnasamy <ksiva@linux.vnet.ibm.com>

Applied, thanks for the more detailed commit message.

^ permalink raw reply

* Re: [PATCH net-next] cxgb4 : retrieve port information from firmware
From: David Miller @ 2017-05-21 17:30 UTC (permalink / raw)
  To: ganeshgr; +Cc: netdev, nirranjan, indranil, leedom
In-Reply-To: <1495196415-22234-1-git-send-email-ganeshgr@chelsio.com>

From: Ganesh Goudar <ganeshgr@chelsio.com>
Date: Fri, 19 May 2017 17:50:15 +0530

> issue get port information command to firmware to retrieve port
> information and update if it is different from what was last
> recorded and also add indication for supported link modes for
> firmware port types FW_PORT_TYPE_SFP28, FW_PORT_TYPE_KR_SFP28,
> FW_PORT_TYPE_CR4_QSFP.
> 
> Based on the original work by Casey Leedom <leedom@chelsio.com>
> 
> Signed-off-by: Casey Leedom <leedom@chelsio.com>
> Signed-off-by: Ganesh Goudar <ganeshgr@chelsio.com>

Applied.

^ permalink raw reply

* Re: [PATCH v2 net] smsc95xx: Support only IPv4 TCP/UDP csum offload
From: David Miller @ 2017-05-21 17:32 UTC (permalink / raw)
  To: Nisar.Sayed; +Cc: netdev, UNGLinuxDriver, steve.glendinning, popcornmix
In-Reply-To: <CE371C1263339941885964188A0225FA308E06@CHN-SV-EXMX03.mchp-main.com>

From: <Nisar.Sayed@microchip.com>
Date: Fri, 19 May 2017 14:00:25 +0000

> From: Nisar Sayed <Nisar.Sayed@microchip.com>
> 
> When TX checksum offload is used, if the computed checksum is 0 the
> LAN95xx device do not alter the checksum to 0xffff.  In the case of ipv4
> UDP checksum, it indicates to receiver that no checksum is calculated.
> Under ipv6, UDP checksum yields a result of zero must be changed to
> 0xffff. Hence disabling checksum offload for ipv6 packets.
> 
> Signed-off-by: Nisar Sayed <Nisar.Sayed@microchip.com>
> 
> Reported-by: popcorn mix <popcornmix@gmail.com>

Appied, thanks.

^ permalink raw reply

* Re: [PATCH net] bridge: start hello_timer when enabling KERNEL_STP in br_stp_start
From: David Miller @ 2017-05-21 17:34 UTC (permalink / raw)
  To: lucien.xin; +Cc: netdev, nikolay, cera
In-Reply-To: <6e78bfea3969ca1a937b37e28e796a3047b82615.1495203629.git.lucien.xin@gmail.com>

From: Xin Long <lucien.xin@gmail.com>
Date: Fri, 19 May 2017 22:20:29 +0800

> Since commit 76b91c32dd86 ("bridge: stp: when using userspace stp stop
> kernel hello and hold timers"), bridge would not start hello_timer if
> stp_enabled is not KERNEL_STP when br_dev_open.
> 
> The problem is even if users set stp_enabled with KERNEL_STP later,
> the timer will still not be started. It causes that KERNEL_STP can
> not really work. Users have to re-ifup the bridge to avoid this.
> 
> This patch is to fix it by starting br->hello_timer when enabling
> KERNEL_STP in br_stp_start.
> 
> As an improvement, it's also to start hello_timer again only when
> br->stp_enabled is KERNEL_STP in br_hello_timer_expired, there is
> no reason to start the timer again when it's NO_STP.
> 
> Fixes: 76b91c32dd86 ("bridge: stp: when using userspace stp stop kernel hello and hold timers")
> Reported-by: Haidong Li <haili@redhat.com>
> Signed-off-by: Xin Long <lucien.xin@gmail.com>

Applied and queued up for -stable, thanks.

^ permalink raw reply

* Re: [PATCH v6 net-next 0/7] Extend socket timestamping API
From: David Miller @ 2017-05-21 17:38 UTC (permalink / raw)
  To: mlichvar; +Cc: netdev, richardcochran, willemb
In-Reply-To: <20170519155241.15817-1-mlichvar@redhat.com>

From: Miroslav Lichvar <mlichvar@redhat.com>
Date: Fri, 19 May 2017 17:52:34 +0200

> This patchset adds new options to the timestamping API that will be
> useful for NTP implementations and possibly other applications.
> 
> The first patch specifies a timestamp filter for NTP packets. The second
> patch updates drivers that can timestamp all packets, or need to list
> the filter as unsupported. There is no attempt to add the support to the
> phyter driver.
> 
> The third patch adds two helper functions working with NAPI ID, which is
> needed by the next patch. The fourth patch adds a new option to get a
> new control message with the L2 length and interface index for incoming
> packets with hardware timestamps.
> 
> The fifth patch fixes documentation on number of non-zero fields in
> scm_timestamping and warns about false software timestamps when
> SO_TIMESTAMP(NS) is combined with SCM_TIMESTAMPING.
> 
> The sixth patch adds a new option to request both software and hardware
> timestamps for outgoing packets. The seventh patch updates drivers that
> assumed software timestamping cannot be used together with hardware
> timestamping.
> 
> The patches have been tested on x86_64 machines with igb and e1000e
> drivers.

Series applied, thanks.

^ permalink raw reply

* [PATCH net-next] tcp: fix tcp_probe_timer() for TCP_USER_TIMEOUT
From: Eric Dumazet @ 2017-05-21 17:39 UTC (permalink / raw)
  To: David Miller; +Cc: netdev, Soheil Hassas Yeganeh

From: Eric Dumazet <edumazet@google.com>

TCP_USER_TIMEOUT is still converted to jiffies value in
icsk_user_timeout

So we need to make a conversion for the cases HZ != 1000 

Fixes: 9a568de4818d ("tcp: switch TCP TS option (RFC 7323) to 1ms clock")
Signed-off-by: Eric Dumazet <edumazet@google.com>
---
 net/ipv4/tcp_timer.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/net/ipv4/tcp_timer.c b/net/ipv4/tcp_timer.c
index 27a667bce8060e6b2290fe636c27a79d0d593b48..c4a35ba7f8ed0dac573c864900b081b4847927d8 100644
--- a/net/ipv4/tcp_timer.c
+++ b/net/ipv4/tcp_timer.c
@@ -341,7 +341,8 @@ static void tcp_probe_timer(struct sock *sk)
 	if (!start_ts)
 		tcp_send_head(sk)->skb_mstamp = tp->tcp_mstamp;
 	else if (icsk->icsk_user_timeout &&
-		 (s32)(tcp_time_stamp(tp) - start_ts) > icsk->icsk_user_timeout)
+		 (s32)(tcp_time_stamp(tp) - start_ts) >
+		 jiffies_to_msecs(icsk->icsk_user_timeout))
 		goto abort;
 
 	max_probes = sock_net(sk)->ipv4.sysctl_tcp_retries2;

^ permalink raw reply related

* Re: [PATCH net-next 1/9] dcb: enforce minimum length on IEEE_APPS attribute
From: David Miller @ 2017-05-21 17:42 UTC (permalink / raw)
  To: stephen; +Cc: netdev, sthemmin
In-Reply-To: <20170519165556.483-2-sthemmin@microsoft.com>

From: Stephen Hemminger <stephen@networkplumber.org>
Date: Fri, 19 May 2017 09:55:48 -0700

> Found by reviewing the warning about unused policy table.
> The code implies that it meant to check for size, but since
> it unrolled the loop for attribute validation that is never used.
> Instead do explicit check for attribute.
> 
> Compile tested only. Needs review by original author.
> 
> Signed-off-by: Stephen Hemminger <sthemmin@microsoft.com>

Applied.

^ permalink raw reply

* Re: [PATCH net-next 2/9] ila: propagate error code in ila_output
From: David Miller @ 2017-05-21 17:43 UTC (permalink / raw)
  To: stephen; +Cc: netdev, sthemmin
In-Reply-To: <20170519165556.483-3-sthemmin@microsoft.com>

From: Stephen Hemminger <stephen@networkplumber.org>
Date: Fri, 19 May 2017 09:55:49 -0700

> This warning:
> net/ipv6/ila/ila_lwt.c: In function ‘ila_output’:
> net/ipv6/ila/ila_lwt.c:42:6: warning: variable ‘err’ set but not used [-Wunused-but-set-variable]
> 
> It looks like the code attempts to set propagate different error
> values, but always returned -EINVAL.
> 
> Compile tested only. Needs review by original author.
> 
> Signed-off-by: Stephen Hemminger <sthemmin@microsoft.com>

Applied.

^ permalink raw reply

* Re: [PATCH net-next 3/9] udp: make local function static
From: David Miller @ 2017-05-21 17:43 UTC (permalink / raw)
  To: stephen; +Cc: netdev, sthemmin
In-Reply-To: <20170519165556.483-4-sthemmin@microsoft.com>

From: Stephen Hemminger <stephen@networkplumber.org>
Date: Fri, 19 May 2017 09:55:50 -0700

> udp_queue_rcv_skb was global but only used in one file.
> Identified by this warning:
> net/ipv4/udp.c:1775:5: warning: no previous prototype for ‘udp_queue_rcv_skb’ [-Wmissing-prototypes]
>  int udp_queue_rcv_skb(struct sock *sk, struct sk_buff *skb)
> 
> Signed-off-by: Stephen Hemminger <sthemmin@microsoft.com>

Already fixed in net-next, please generate patches against
current sources.

^ permalink raw reply

* Re: [PATCH net-next 4/9] inet: fix warning about missing prototype
From: David Miller @ 2017-05-21 17:43 UTC (permalink / raw)
  To: stephen; +Cc: netdev, sthemmin
In-Reply-To: <20170519165556.483-5-sthemmin@microsoft.com>

From: Stephen Hemminger <stephen@networkplumber.org>
Date: Fri, 19 May 2017 09:55:51 -0700

> The prototype for inet_rcv_saddr_equal was not being included.
> 
> Signed-off-by: Stephen Hemminger <sthemmin@microsoft.com>

Applied.

^ permalink raw reply

* Re: [PATCH net-next 5/9] tcpnv: do not export local function
From: David Miller @ 2017-05-21 17:43 UTC (permalink / raw)
  To: stephen; +Cc: netdev, sthemmin
In-Reply-To: <20170519165556.483-6-sthemmin@microsoft.com>

From: Stephen Hemminger <stephen@networkplumber.org>
Date: Fri, 19 May 2017 09:55:52 -0700

> The TCP New Vegas congestion control was exporting an internal
> function tcpnv_get_info which is not used by any other in tree
> kernel code. Make it static.
> 
> Signed-off-by: Stephen Hemminger <sthemmin@microsoft.com>

Applied.

^ permalink raw reply

* Re: [PATCH net-next 6/9] xfrm: make xfrm_dev_register static
From: David Miller @ 2017-05-21 17:43 UTC (permalink / raw)
  To: stephen; +Cc: netdev, sthemmin
In-Reply-To: <20170519165556.483-7-sthemmin@microsoft.com>

From: Stephen Hemminger <stephen@networkplumber.org>
Date: Fri, 19 May 2017 09:55:53 -0700

> This function is only used in this file and should not be global.
> 
> Signed-off-by: Stephen Hemminger <sthemmin@microsoft.com>

Steffen said he already took this.

^ permalink raw reply

* Re: [PATCH net-next 7/9] fou: make local function static
From: David Miller @ 2017-05-21 17:43 UTC (permalink / raw)
  To: stephen; +Cc: netdev, sthemmin
In-Reply-To: <20170519165556.483-8-sthemmin@microsoft.com>

From: Stephen Hemminger <stephen@networkplumber.org>
Date: Fri, 19 May 2017 09:55:54 -0700

> The build header functions are not used by any other code.
> 
> net/ipv6/fou6.c:36:5: warning: no previous prototype for ‘fou6_build_header’ [-Wmissing-prototypes]
> net/ipv6/fou6.c:54:5: warning: no previous prototype for ‘gue6_build_header’ [-Wmissing-prototypes]
> 
> Need to do some code rearranging to satisfy different Kconfig possiblities.
> 
> Signed-off-by: Stephen Hemminger <sthemmin@microsoft.com>

Applied.

^ permalink raw reply

* Re: [PATCH net-next 8/9] ipv6: drop unused variables in seg6_genl_dumphac
From: David Miller @ 2017-05-21 17:43 UTC (permalink / raw)
  To: stephen; +Cc: netdev, sthemmin
In-Reply-To: <20170519165556.483-9-sthemmin@microsoft.com>

From: Stephen Hemminger <stephen@networkplumber.org>
Date: Fri, 19 May 2017 09:55:55 -0700

> THe seg6_pernet_data variable was set but never used.
> 
> Signed-off-by: Stephen Hemminger <sthemmin@microsoft.com>

Applied.

^ permalink raw reply


This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox