lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <20150518133911.0b420f4f@canb.auug.org.au>
Date:	Mon, 18 May 2015 13:39:11 +1000
From:	Stephen Rothwell <sfr@...b.auug.org.au>
To:	David Miller <davem@...emloft.net>, <netdev@...r.kernel.org>
Cc:	linux-next@...r.kernel.org, linux-kernel@...r.kernel.org,
	Roopa Prabhu <roopa@...ulusnetworks.com>,
	Jiri Pirko <jiri@...nulli.us>,
	Scott Feldman <sfeldma@...il.com>
Subject: linux-next: manual merge of the net-next tree with the net tree

Hi all,

Today's linux-next merge of the net-next tree got a conflict in
net/switchdev/switchdev.c between commit eea39946a1f3 ("rename
RTNH_F_EXTERNAL to RTNH_F_OFFLOAD") from the net tree and various
commits from the net-next tree.

I fixed it up (see below) and can carry the fix as necessary (no action
is required).

-- 
Cheers,
Stephen Rothwell                    sfr@...b.auug.org.au

diff --cc net/switchdev/switchdev.c
index 055453d48668,0409f9b5bdbc..000000000000
--- a/net/switchdev/switchdev.c
+++ b/net/switchdev/switchdev.c
@@@ -328,18 -670,13 +670,13 @@@ int switchdev_fib_ipv4_add(u32 dst, in
  	if (fi->fib_net->ipv4.fib_offload_disabled)
  		return 0;
  
- 	dev = netdev_switch_get_dev_by_nhs(fi);
+ 	dev = switchdev_get_dev_by_nhs(fi);
  	if (!dev)
  		return 0;
- 	ops = dev->swdev_ops;
- 
- 	if (ops->swdev_fib_ipv4_add) {
- 		err = ops->swdev_fib_ipv4_add(dev, htonl(dst), dst_len,
- 					      fi, tos, type, nlflags,
- 					      tb_id);
- 		if (!err)
- 			fi->fib_flags |= RTNH_F_OFFLOAD;
- 	}
+ 
+ 	err = switchdev_port_obj_add(dev, &fib_obj);
+ 	if (!err)
 -		fi->fib_flags |= RTNH_F_EXTERNAL;
++		fi->fib_flags |= RTNH_F_OFFLOAD;
  
  	return err;
  }
@@@ -357,27 -694,34 +694,34 @@@ EXPORT_SYMBOL_GPL(switchdev_fib_ipv4_ad
   *
   *	Delete IPv4 route entry from switch device.
   */
- int netdev_switch_fib_ipv4_del(u32 dst, int dst_len, struct fib_info *fi,
- 			       u8 tos, u8 type, u32 tb_id)
+ int switchdev_fib_ipv4_del(u32 dst, int dst_len, struct fib_info *fi,
+ 			   u8 tos, u8 type, u32 tb_id)
  {
+ 	struct switchdev_obj fib_obj = {
+ 		.id = SWITCHDEV_OBJ_IPV4_FIB,
+ 		.u.ipv4_fib = {
+ 			.dst = dst,
+ 			.dst_len = dst_len,
+ 			.fi = fi,
+ 			.tos = tos,
+ 			.type = type,
+ 			.nlflags = 0,
+ 			.tb_id = tb_id,
+ 		},
+ 	};
  	struct net_device *dev;
- 	const struct swdev_ops *ops;
  	int err = 0;
  
 -	if (!(fi->fib_flags & RTNH_F_EXTERNAL))
 +	if (!(fi->fib_flags & RTNH_F_OFFLOAD))
  		return 0;
  
- 	dev = netdev_switch_get_dev_by_nhs(fi);
+ 	dev = switchdev_get_dev_by_nhs(fi);
  	if (!dev)
  		return 0;
- 	ops = dev->swdev_ops;
  
- 	if (ops->swdev_fib_ipv4_del) {
- 		err = ops->swdev_fib_ipv4_del(dev, htonl(dst), dst_len,
- 					      fi, tos, type, tb_id);
- 		if (!err)
- 			fi->fib_flags &= ~RTNH_F_OFFLOAD;
- 	}
+ 	err = switchdev_port_obj_del(dev, &fib_obj);
+ 	if (!err)
 -		fi->fib_flags &= ~RTNH_F_EXTERNAL;
++		fi->fib_flags &= ~RTNH_F_OFFLOAD;
  
  	return err;
  }

Content of type "application/pgp-signature" skipped

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ