Received: by 2002:ac0:a679:0:0:0:0:0 with SMTP id p54csp791619imp; Thu, 21 Feb 2019 11:15:14 -0800 (PST) X-Google-Smtp-Source: AHgI3IZE4hXmb7Fik3uMtq7ZQYuvwfTUCIEncHvOjq1RogM963E3+ZcF3YaMAc6POdlzdau1tn7h X-Received: by 2002:a65:4807:: with SMTP id h7mr79604pgs.15.1550776514896; Thu, 21 Feb 2019 11:15:14 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1550776514; cv=none; d=google.com; s=arc-20160816; b=a5j7phfJOuoLztNQtylHa+KqtKV3FkYeS+7bbX/oR0zjSnCVR3zFbiQY4WCTwLz9EZ p3kVA0tutv1omhmh4mgA383QY9UaYhy8xt1zVHeWmX6i1jlMKptnlBwFJEeOZLlUL/sX Xkq29ZVY0r8iuOg8cj1h1hDtl+n9vqgjdlc7fMwglUhr2anGBf0v35GgO1YWzfDcMHLP 7ncJi/raYp4twzx1EtbTlV/6p7aM2Z5YqM40hcMefix1cewRCvnpLvClMfdeDXnYdPl4 PFo3SYKdQvKQLT57FGT7tVafw+nc5CRdS7rCJpjnAYirL4PDjEucV/v3LDCPpkb9S9+j Q7XQ== 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:dkim-signature; bh=Iv7mye+/8/WwgzmHPYVnTClMZwsL/duFkK0PNa6uHGs=; b=OtFhEpAaZL52AOUH2+Uj9tPg3gcdihLu0p/Egd/V5LQqtgLHUSkAKvoknjLLv2r60J FqAsi7NmpadSzjBrM+2bVBZPhpf9MhrdCCqjaJ8k3OkGndnCcjS5f3L8o3eBwX5H8c4B 8/04xNB7a6EO3dMlGccLktqY56DC/s442SQ6FlPQyygXpYo7d+i6LoJAMmWkFStggN+Z +Xr4aDYbpyAou9AYa9T4Rse7IKGygHeXzjBapjzdcQV3dYkdoisJWDoIWWngC/cXkTs0 fRFxMCOJjeEmAIj55tJHty7TQzhZ+HQ+BAeHCMz8o+ZWz5BTrSeZMVRSmNRhkGUGE+JX B0JQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=ZfTpjGJk; 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 o8si4413492pfk.94.2019.02.21.11.14.59; Thu, 21 Feb 2019 11:15:14 -0800 (PST) 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; dkim=pass header.i=@kernel.org header.s=default header.b=ZfTpjGJk; 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 S1726652AbfBUTNo (ORCPT + 99 others); Thu, 21 Feb 2019 14:13:44 -0500 Received: from mail.kernel.org ([198.145.29.99]:48054 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726590AbfBUTNo (ORCPT ); Thu, 21 Feb 2019 14:13:44 -0500 Received: from localhost (5356596B.cm-6-7b.dynamic.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id CF5E320836; Thu, 21 Feb 2019 19:13:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1550776423; bh=v2s0umUHfGrPKSqbmZYJAk8ykkVYktDk12dLw+oexJE=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=ZfTpjGJkzkZP+ZGMrz/DEkkcRF0gawK0GI4N8YF8FAXYkqYAT/0+8E68JMSTg8b/J 7T5w9RFZw6A17D70SoylfQydFB+VCJWgl9eOkXBvltCS+fQgPUMrjWf5aQfZtsCzh+ /GUOsx3L74EoOmyqdU7yXKmIGqHaM/C4sspDDxrM= Date: Thu, 21 Feb 2019 20:13:40 +0100 From: Greg Kroah-Hartman To: "Mehrtens, Hauke" Cc: "linux-kernel@vger.kernel.org" , "stable@vger.kernel.org" , "David S. Miller" , "hauke@hauke-m.de" Subject: Re: [PATCH 4.9 04/20] net: Fix for_each_netdev_feature on Big endian Message-ID: <20190221191340.GA23109@kroah.com> References: <20190221125242.153179182@linuxfoundation.org> <20190221125242.858818453@linuxfoundation.org> <9231D502B07C5E4A8B32D5115C9F19991F89EFB4@IRSMSX108.ger.corp.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <9231D502B07C5E4A8B32D5115C9F19991F89EFB4@IRSMSX108.ger.corp.intel.com> User-Agent: Mutt/1.11.3 (2019-02-01) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Feb 21, 2019 at 05:26:10PM +0000, Mehrtens, Hauke wrote: > -----Original Message----- > From: Greg Kroah-Hartman [mailto:gregkh@linuxfoundation.org] > Sent: Thursday, February 21, 2019 3:36 PM > To: linux-kernel@vger.kernel.org > Cc: Greg Kroah-Hartman ; stable@vger.kernel.org; Mehrtens, Hauke ; David S. Miller > Subject: [PATCH 4.9 04/20] net: Fix for_each_netdev_feature on Big endian > > 4.9-stable review patch. If anyone has any objections, please let me know. > > ------------------ > > From: Hauke Mehrtens > > [ Upstream commit 3b89ea9c5902acccdbbdec307c85edd1bf52515e ] > > The features attribute is of type u64 and stored in the native endianes on the system. The for_each_set_bit() macro takes a pointer to a 32 bit array and goes over the bits in this area. On little Endian systems this also works with an u64 as the most significant bit is on the highest address, but on big endian the words are swapped. When we expect bit 15 here we get bit 47 (15 + 32). > > This patch converts it more or less to its own for_each_set_bit() implementation which works on 64 bit integers directly. This is then completely in host endianness and should work like expected. > > Fixes: fd867d51f ("net/core: generic support for disabling netdev features down stack") > Signed-off-by: Hauke Mehrtens > Signed-off-by: David S. Miller > Signed-off-by: Greg Kroah-Hartman > --- > include/linux/netdev_features.h | 23 +++++++++++++++++++++-- > net/core/dev.c | 4 ++-- > 2 files changed, 23 insertions(+), 4 deletions(-) > > Hi Greg, > > This commit adds a missing include, I do not know if this really causes a compile problem: > https://git.kernel.org/linus/8681ef1f3d295bd3600315325f3b3396d76d02f6 I have that patch queued up as well :) > It was also suggested to use a longer commit ID in the Fixes tag like this: > Fixes: fd867d51f889 ("net/core: generic support for disabling netdev features down stack") Yes, in the future please do that, I just took the changelog directly from what is in Linus's tree. thanks, greg k-h