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>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 17 Jun 2015 22:30:54 -0700
From:	"Samudrala, Sridhar" <sridhar.samudrala@...el.com>
To:	sfeldma@...il.com, netdev@...r.kernel.org
CC:	jiri@...nulli.us
Subject: Re: [PATCH net-next] switchdev: fdb filter_dev is always NULL for
 self (device), so remove check



On 6/17/2015 4:08 PM, sfeldma@...il.com wrote:
> From: Scott Feldman <sfeldma@...il.com>
>
> Remove the filter_dev check when dumping fdb entries, otherwise dump
> returns empty list.  filter_dev is always passed as NULL when dumping fdbs
> on SELF.  We want the fdbs installed on the device to be listed in the
> dump.
>
> Signed-off-by: Scott Feldman <sfeldma@...il.com>
Acked-by: Sridhar Samudrala <sridhar.samudrala@...el.com>

> Fixes: 45d4122c ("switchdev: add support for fdb add/del/dump via switchdev_port_obj ops")
> ---
>   net/switchdev/switchdev.c |    6 ------
>   1 file changed, 6 deletions(-)
>
> diff --git a/net/switchdev/switchdev.c b/net/switchdev/switchdev.c
> index a5d0f8e..7dda437 100644
> --- a/net/switchdev/switchdev.c
> +++ b/net/switchdev/switchdev.c
> @@ -657,7 +657,6 @@ struct switchdev_fdb_dump {
>   	struct switchdev_obj obj;
>   	struct sk_buff *skb;
>   	struct netlink_callback *cb;
> -	struct net_device *filter_dev;
>   	int idx;
>   };
>   
> @@ -670,14 +669,10 @@ static int switchdev_port_fdb_dump_cb(struct net_device *dev,
>   	u32 seq = dump->cb->nlh->nlmsg_seq;
>   	struct nlmsghdr *nlh;
>   	struct ndmsg *ndm;
> -	struct net_device *master = netdev_master_upper_dev_get(dev);
>   
>   	if (dump->idx < dump->cb->args[0])
>   		goto skip;
>   
> -	if (master && dump->filter_dev != master)
> -		goto skip;
> -
>   	nlh = nlmsg_put(dump->skb, portid, seq, RTM_NEWNEIGH,
>   			sizeof(*ndm), NLM_F_MULTI);
>   	if (!nlh)
> @@ -731,7 +726,6 @@ int switchdev_port_fdb_dump(struct sk_buff *skb, struct netlink_callback *cb,
>   		},
>   		.skb = skb,
>   		.cb = cb,
> -		.filter_dev = filter_dev,
>   		.idx = idx,
>   	};
>   	int err;

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists