Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp2562535imm; Sun, 5 Aug 2018 07:04:17 -0700 (PDT) X-Google-Smtp-Source: AAOMgpcvgqelUiQhIXkddaMb7OOlCIXZqudPMefaDNty/G9NBvAZUzG5QGCSSxEul9lx3uOE76Jr X-Received: by 2002:a65:5581:: with SMTP id j1-v6mr11356786pgs.203.1533477857570; Sun, 05 Aug 2018 07:04:17 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1533477857; cv=none; d=google.com; s=arc-20160816; b=QOsCOjyMCK5lCR7AfXf1sYJUrCvfVY24joINEm0FDAM/RB8EwduUOt9AmAGl2Ot6VD 2difEQ+t89VruIYdA3cunKpwdkQ3p4gCXGruhlKkuSFpGdG4PN5hSn0M63u6cYHMR7mG UdNK7uLrJOq0dQhPetuIPNDa1qMAPG5iJGal78nlXiHeisogwNTQR5dNWvb8cim8Jchd HUGbLhxlMzQuTIxQ4EXp46DNornnU06qGx/Hi73K5HiQBe7XoT1uDjAVQlFeRG4EeCkQ 5MY8ON0IbnyrpGEUEAXnfp90ZGB+XkWWcDWQq7TJOaaANxVzkaHhD+rRp64/GZnXqYB7 UkGw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=Ws9lwz3MQ24Qcfwy3bzZUA4MyawHSe9kt3UBvR24AiA=; b=Hff32j+Cu3y2+OPImm3FWPIXgR8y7J0RupIIjFJeHIeUhtVG3yR9WmJznwa0jpple8 EZBoLsHVTryQpSKCgA9J0/rZL7NOXaZ8tki+bfYmyF08BRCl3xKLNo1HTqXGrTgA1bsX pUPgXjncF5GMaZYF5oD1Cz5yBy6WwlNQ2yV7mK+Jm9TPtn4bmSmmO3DaEUsbqxl1q6Gk sSLoQq8GSUVaKVJlG79MZLTOX51+NqzvZtZNEeTKYw0eMlpEg0Sj46K82x4PdjslFTpD EO4DMmMP33UBlIgyXCPWF7pqMvgSZ1t5sJ3lTsccntqzlqwAtQYn4Yj7bYeHTaU4a05p 7Anw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id r7-v6si9882111pgl.1.2018.08.05.07.04.00; Sun, 05 Aug 2018 07:04:17 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726330AbeHEQHs (ORCPT + 99 others); Sun, 5 Aug 2018 12:07:48 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:35454 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726112AbeHEQHs (ORCPT ); Sun, 5 Aug 2018 12:07:48 -0400 Received: from localhost (unknown [89.188.5.116]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id 9A2DA40B; Sun, 5 Aug 2018 14:03:05 +0000 (UTC) Date: Sun, 5 Aug 2018 16:03:01 +0200 From: Greg Kroah-Hartman To: Nathan Chancellor Cc: linux-kernel@vger.kernel.org, stable@vger.kernel.org, "David S. Miller" , Herbert Xu , Steffen Klassert , netdev@vger.kernel.org, Dmitry Safonov Subject: Re: [PATCH 4.4 106/124] netlink: Do not subscribe to non-existent groups Message-ID: <20180805140301.GA17056@kroah.com> References: <20180804082702.434482435@linuxfoundation.org> <20180804082706.427556290@linuxfoundation.org> <20180804180734.GA25546@flashbox> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180804180734.GA25546@flashbox> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Aug 04, 2018 at 11:07:34AM -0700, Nathan Chancellor wrote: > On Sat, Aug 04, 2018 at 11:01:35AM +0200, Greg Kroah-Hartman wrote: > > 4.4-stable review patch. If anyone has any objections, please let me know. > > > > ------------------ > > > > From: Dmitry Safonov > > > > [ Upstream commit 7acf9d4237c46894e0fa0492dd96314a41742e84 ] > > > > Make ABI more strict about subscribing to group > ngroups. > > Code doesn't check for that and it looks bogus. > > (one can subscribe to non-existing group) > > Still, it's possible to bind() to all possible groups with (-1) > > > > Cc: "David S. Miller" > > Cc: Herbert Xu > > Cc: Steffen Klassert > > Cc: netdev@vger.kernel.org > > Signed-off-by: Dmitry Safonov > > Signed-off-by: David S. Miller > > Signed-off-by: Greg Kroah-Hartman > > --- > > net/netlink/af_netlink.c | 1 + > > 1 file changed, 1 insertion(+) > > > > --- a/net/netlink/af_netlink.c > > +++ b/net/netlink/af_netlink.c > > @@ -983,6 +983,7 @@ static int netlink_bind(struct socket *s > > if (err) > > return err; > > } > > + groups &= (1UL << nlk->ngroups) - 1; > > > > bound = nlk->bound; > > if (bound) { > > > > > > Hi Greg, > > I am so sorry I didn't catch this in my initial report but this commit > along with ba7aaf93ef2f ("netlink: Don't shift with UB on nlk->ngroups") > breaks mobile data on both the Pixel 2 XL and OnePlus 6. There is signal > but it just never connects to 3G/LTE. Reverting those two commits fixes > the issue. > > Nothing stands out to me in dmesg unfortunately and iven neither device > is running a vanilla kernel, I cannot say if this is a problem in mainline > or not but I just wanted to make you aware of it. Many thanks for catching this. I'll go drop this patch from the trees for now, and will queue it up later with the fixup patch when that lands in Linus's tree. thanks, greg k-h