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: <20151015120601.7560df35@canb.auug.org.au>
Date:	Thu, 15 Oct 2015 12:06:01 +1100
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,
	Nikolay Aleksandrov <nikolay@...ulusnetworks.com>,
	Jiri Pirko <jiri@...lanox.com>,
	Vivien Didelot <vivien.didelot@...oirfairelinux.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:

  87aaf2caed84 ("switchdev: check if the vlan id is in the proper vlan range")

from the net tree and commits:

  7ea6eb3f56f4 ("switchdev: introduce transaction item queue for attr_set and obj_add")
  ab0690023018 ("net: switchdev: abstract object in add/del ops"

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 77f5d17e2612,b8aaf820ef65..000000000000
--- a/net/switchdev/switchdev.c
+++ b/net/switchdev/switchdev.c
@@@ -16,7 -16,7 +16,8 @@@
  #include <linux/notifier.h>
  #include <linux/netdevice.h>
  #include <linux/if_bridge.h>
 +#include <linux/if_vlan.h>
+ #include <linux/list.h>
  #include <net/ip_fib.h>
  #include <net/switchdev.h>
  
@@@ -635,32 -722,33 +723,35 @@@ static int switchdev_port_br_afspec(str
  		if (nla_len(attr) != sizeof(struct bridge_vlan_info))
  			return -EINVAL;
  		vinfo = nla_data(attr);
 +		if (!vinfo->vid || vinfo->vid >= VLAN_VID_MASK)
 +			return -EINVAL;
- 		vlan->flags = vinfo->flags;
+ 		vlan.flags = vinfo->flags;
  		if (vinfo->flags & BRIDGE_VLAN_INFO_RANGE_BEGIN) {
- 			if (vlan->vid_begin)
+ 			if (vlan.vid_begin)
+ 				return -EINVAL;
+ 			vlan.vid_begin = vinfo->vid;
+ 			/* don't allow range of pvids */
+ 			if (vlan.flags & BRIDGE_VLAN_INFO_PVID)
  				return -EINVAL;
- 			vlan->vid_begin = vinfo->vid;
  		} else if (vinfo->flags & BRIDGE_VLAN_INFO_RANGE_END) {
- 			if (!vlan->vid_begin)
+ 			if (!vlan.vid_begin)
  				return -EINVAL;
- 			vlan->vid_end = vinfo->vid;
- 			if (vlan->vid_end <= vlan->vid_begin)
+ 			vlan.vid_end = vinfo->vid;
+ 			if (vlan.vid_end <= vlan.vid_begin)
  				return -EINVAL;
- 			err = f(dev, &obj);
+ 			err = f(dev, &vlan.obj);
  			if (err)
  				return err;
- 			memset(vlan, 0, sizeof(*vlan));
+ 			memset(&vlan, 0, sizeof(vlan));
  		} else {
- 			if (vlan->vid_begin)
+ 			if (vlan.vid_begin)
  				return -EINVAL;
- 			vlan->vid_begin = vinfo->vid;
- 			vlan->vid_end = vinfo->vid;
- 			err = f(dev, &obj);
+ 			vlan.vid_begin = vinfo->vid;
+ 			vlan.vid_end = vinfo->vid;
+ 			err = f(dev, &vlan.obj);
  			if (err)
  				return err;
- 			memset(vlan, 0, sizeof(*vlan));
+ 			memset(&vlan, 0, sizeof(vlan));
  		}
  	}
  
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ