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]
Message-ID: <20140529035131.GA12648@z.redhat.com>
Date:	Thu, 29 May 2014 11:51:31 +0800
From:	Amos Kong <akong@...hat.com>
To:	Wang Weidong <wangweidong1@...wei.com>
Cc:	David Miller <davem@...emloft.net>, stephen@...workplumber.org,
	bridge@...ts.linux-foundation.org, netdev <netdev@...r.kernel.org>,
	vyasevic@...hat.com
Subject: Re: [PATCH net-next] bridge: fix the unbalanced promiscuous count
 when add_if failed

On Thu, May 29, 2014 at 10:15:30AM +0800, Wang Weidong wrote:
> As commit 2796d0c648c94("bridge: Automatically manage port
> promiscuous mode."), make the add_if use dev_set_allmulti
> instead of dev_set_promiscuous, so when add_if failed, we
> should do dev_set_allmulti(dev, -1).
> 
> Signed-off-by: Wang Weidong <wangweidong1@...wei.com>
> ---
>  net/bridge/br_if.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/net/bridge/br_if.c b/net/bridge/br_if.c
> index 104a811..a08d2b8 100644
> --- a/net/bridge/br_if.c
> +++ b/net/bridge/br_if.c
> @@ -528,7 +528,7 @@ err2:
>  	kobject_put(&p->kobj);
>  	p = NULL; /* kobject_put frees */
>  err1:
> -	dev_set_promiscuity(dev, -1);
> +	dev_set_allmulti(dev, -1);

Right fix.

Reviewed-by: Amos Kong <akong@...hat.com>

>  put_back:
>  	dev_put(dev);
>  	kfree(p);
> -- 
> 1.8.4
> 
> 
> --
> 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

-- 
			Amos.
--
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ