From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754155AbdCFTDR (ORCPT ); Mon, 6 Mar 2017 14:03:17 -0500 Received: from shadbolt.e.decadent.org.uk ([88.96.1.126]:43555 "EHLO shadbolt.e.decadent.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754182AbdCFTDL (ORCPT ); Mon, 6 Mar 2017 14:03:11 -0500 Message-ID: <1488826841.2953.14.camel@decadent.org.uk> Subject: Re: [PATCH 3.2 086/126] igmp: do not remove igmp souce list info when set link down From: Ben Hutchings To: Hangbin Liu Cc: linux-kernel@vger.kernel.org, stable@vger.kernel.org, akpm@linux-foundation.org, "David S. Miller" Date: Mon, 06 Mar 2017 19:00:41 +0000 In-Reply-To: References: Content-Type: multipart/signed; micalg="pgp-sha512"; protocol="application/pgp-signature"; boundary="=-JEsdDDmiZPFIEOypzR2z" X-Mailer: Evolution 3.22.5-1 Mime-Version: 1.0 X-SA-Exim-Connect-IP: 2a02:8011:400e:2:6f00:88c8:c921:d332 X-SA-Exim-Mail-From: ben@decadent.org.uk X-SA-Exim-Scanned: No (on shadbolt.decadent.org.uk); SAEximRunCond expanded to false Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --=-JEsdDDmiZPFIEOypzR2z Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Thu, 2017-02-16 at 09:42 +0800, Hangbin Liu wrote: > > 2017-02-16 6:41 GMT+08:00 Ben Hutchings : > > 3.2.85-rc1 review patch.=C2=A0=C2=A0If anyone has any objections, pleas= e let me know. > >=20 > > ------------------ > >=20 > > From: Hangbin Liu > >=20 > > commit 24803f38a5c0b6c57ed800b47e695f9ce474bc3a upstream. > >=20 > > In commit 24cf3af3fed5 ("igmp: call ip_mc_clear_src..."), we forgot to = remove > > igmpv3_clear_delrec() in ip_mc_down(), which also called ip_mc_clear_sr= c(). > > This make us clear all IGMPv3 source filter info after NETDEV_DOWN. > > Move igmpv3_clear_delrec() to ip_mc_destroy_dev() and then no need > > ip_mc_clear_src() in ip_mc_destroy_dev(). > >=20 > > On the other hand, we should restore back instead of free all source fi= lter > > info in igmpv3_del_delrec(). Or we will not able to restore IGMPv3 sour= ce > > filter info after NETDEV_UP and NETDEV_POST_TYPE_CHANGE. > >=20 > > Fixes: 24cf3af3fed5 ("igmp: call ip_mc_clear_src() only when ...") > > Signed-off-by: Hangbin Liu > > Signed-off-by: David S. Miller > > [bwh: Backported to 3.2: > > =C2=A0- Use IGMP_Unsolicited_Report_Count instead of sysctl_igmp_qrv > > =C2=A0- Adjust context] > > Signed-off-by: Ben Hutchings >=20 > Hi Ben, >=20 > There is a bug fix for this patch, please consider drop this patch or > include the fix. >=20 > commit 9c8bb163ae784be4f79ae504e78c862806087c54 > Author: Hangbin Liu > Date:=C2=A0=C2=A0=C2=A0Wed Feb 8 21:16:45 2017 +0800 >=20 > =C2=A0=C2=A0=C2=A0=C2=A0igmp, mld: Fix memory leak in igmpv3/mld_del_delr= ec() >=20 > =C2=A0=C2=A0=C2=A0=C2=A0In function igmpv3/mld_add_delrec() we allocate p= mc and put it in > =C2=A0=C2=A0=C2=A0=C2=A0idev->mc_tomb, so we should free it when we don't= need it in del_delrec(). > =C2=A0=C2=A0=C2=A0=C2=A0But I removed kfree(pmc) incorrectly in latest tw= o patches. Now fix it. >=20 > =C2=A0=C2=A0=C2=A0=C2=A0Fixes: 24803f38a5c0 ("igmp: do not remove igmp so= uce list info when ...") > =C2=A0=C2=A0=C2=A0=C2=A0Fixes: 1666d49e1d41 ("mld: do not remove mld souc= e list info when ...") [...] I've now queued up all 3 fixes for the next updates to 3.2 and 3.16. Ben. --=20 Ben Hutchings Unix is many things to many people, but it's never been everything to anybody. --=-JEsdDDmiZPFIEOypzR2z Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEErCspvTSmr92z9o8157/I7JWGEQkFAli9sdkACgkQ57/I7JWG EQnk2Q//Zr0lZEv/qQuywR9nn9qikWZII2cfyL5YL39T9nO4KUaHz1zK5CTSvniK YRW8y2kHhkpvPVGATGiLyDG2oCN41CNf3WYkL8iltxWQsaSUDp42Hv6FX/nvp4Yp 1FyBUeOlOnuoI18cz9Zf6EYEitqXbdWrCp87Bixk4xD4O3fnXDAE6xOu/Yu7gg3L MD9uVF3DfUPfaCxhxVvGAD3UTvDDiGLCAr8IE+TP30JKpgsWGUX16Ky8xNXb7O9D 2p3xw3pvzFufQ1zujLJ1LcyNFhCKbBJnDqLVvO7G2ud1n2ZGJ+4d2wMeFeXUc/vc sxrUkHvCGj9Hl5eLkMUhyF8lrywCov2PMjmcnS1j1GfEcNXBUgYDm877Sk08gFi2 /k7JTS74uwf2XFzVd+o/yj94vPzg0YZiUkUHJOSEEgtmc9JGjCMstwycpkzuvRC3 WPHFiATp0Y7nJgIMmDosb/5II2JJT4gkCJbIyrGOHeEA6r34ZFqoTx2XInYxVDeq iYMz2zxcaTd2XugAibIf2xjv4fuvqGUGRgUGyTtZujSBiVY+FFinGzHkatZ2j3cC oja4I1tapf9+KooOF5jD74Qjc7JbHdvezNsBqwwfC/PwVAPeBBp0TvdVLM4R+u8/ ss8eZwinhHdmZ84Yefih7WFBs6qCw1ucv0gfvD++9gpu725+3k8= =flaW -----END PGP SIGNATURE----- --=-JEsdDDmiZPFIEOypzR2z--