From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Miller Subject: Re: [PATCH net] multicast: do not restore deleted record source filter mode to new one Date: Sat, 21 Jul 2018 22:59:32 -0700 (PDT) Message-ID: <20180721.225932.2009460010852969132.davem@davemloft.net> References: <1532066667-11389-1-git-send-email-liuhangbin@gmail.com> Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: netdev@vger.kernel.org, xiyou.wangcong@gmail.com, hideaki.yoshifuji@miraclelinux.com, daniel@iogearbox.net To: liuhangbin@gmail.com Return-path: Received: from shards.monkeyblade.net ([23.128.96.9]:49990 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725940AbeGVGzC (ORCPT ); Sun, 22 Jul 2018 02:55:02 -0400 In-Reply-To: <1532066667-11389-1-git-send-email-liuhangbin@gmail.com> Sender: netdev-owner@vger.kernel.org List-ID: From: Hangbin Liu Date: Fri, 20 Jul 2018 14:04:27 +0800 > There are two scenarios that we will restore deleted records. The first is > when device down and up(or unmap/remap). In this scenario the new filter > mode is same with previous one. Because we get it from in_dev->mc_list and > we do not touch it during device down and up. > > The other scenario is when a new socket join a group which was just delete > and not finish sending status reports. In this scenario, we should use the > current filter mode instead of restore old one. Here are 4 cases in total. > > old_socket new_socket before_fix after_fix > IN(A) IN(A) ALLOW(A) ALLOW(A) > IN(A) EX( ) TO_IN( ) TO_EX( ) > EX( ) IN(A) TO_EX( ) ALLOW(A) > EX( ) EX( ) TO_EX( ) TO_EX( ) > > Fixes: 24803f38a5c0b (igmp: do not remove igmp souce list info when set link down) > Fixes: 1666d49e1d416 (mld: do not remove mld souce list info when set link down) > Signed-off-by: Hangbin Liu Applied and queued up for -stable, thank you.