Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp631547pxu; Thu, 3 Dec 2020 08:52:39 -0800 (PST) X-Google-Smtp-Source: ABdhPJw2WV5/at4mJBjpzhNqtEAc8cbATteMAeQ/eBJrffPs+1RT0fP2w+s5jN7/tl8C58RBmqMx X-Received: by 2002:a17:906:c097:: with SMTP id f23mr3479371ejz.136.1607014359351; Thu, 03 Dec 2020 08:52:39 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1607014359; cv=none; d=google.com; s=arc-20160816; b=XIPNdo/APLiWFl6fuWjmTERZlrKVtvNyJ8e2Z4/fcfAmlXszXkjLBIYNgQoDllWJCH UfKEIT5/Fg+31/IQEPJDLSIGtPyK63PzQT8XcIuVMQUfYsd855xHbOegXcO2gysesQUX gsn0ZvVdeDMjSSpJTdsei1/bZZ8Km5UNRUMU0FCioOSZfR9CdfszLI0cx7p+jQkrOqZ0 FYVFdD0ShzvWJQ0Uy2kjC/dYleYZLUtkGAKdo5bRpQ9xlQPUicPZW5Zntt/h0399yiZ7 58hMRMSPQPn3UrWAV9xeel6S4zQ7nhbgxFy24Sc2NZiTl443elypGTyxldtHjfgM61pH TEPQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:dkim-signature :date; bh=xtn9xK3t4x8YZCHUA87miNSmOS7u/VJeRPPzzwuSQ2E=; b=q1AwK2Ln1JW5M1m1Bt7pr0BJ8DopzZWzx6Z2Onfqx8JMNVUGwfiumhLLhgJBRRwVDG CEJjRxQuE8JUn4oHND2QN4QHg+tzFhlTO/gO9MIrI4/x5ehABSeO6+0z0WFtO51bQeMo 6NFa1g8DZmkQTC9NwN3p7e7zls87yt6xYJSsyZoWZqiRcrY0cl+30UObQJf7i6qfvr9t QUk/bTX3KGZaSGFAJn4NhCcoiCL8tC/rwmXHnB5mW/rRwI75C+qeZZM4kL/YoDOyndFG oJFBsY27KioYfTzr9cHyEzLyPToAVu5iLaZjE4QfKETJame1fHb/j9Lr5PA9zBZB7/Px SJ/A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="JwB/MUid"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id v6si1250089edj.204.2020.12.03.08.52.14; Thu, 03 Dec 2020 08:52:39 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="JwB/MUid"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728092AbgLCQup (ORCPT + 99 others); Thu, 3 Dec 2020 11:50:45 -0500 Received: from mail.kernel.org ([198.145.29.99]:56794 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726026AbgLCQuo (ORCPT ); Thu, 3 Dec 2020 11:50:44 -0500 Date: Thu, 3 Dec 2020 08:50:01 -0800 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1607014203; bh=YHfuCjdtDnHU2kz0MrlrIr2AWgOYTlJneLrx1j97NQc=; h=From:To:Cc:Subject:In-Reply-To:References:From; b=JwB/MUidaGtf2zBZaB4b5wK3fFxbydy1DlLoXypQliapRImVuMFO7e4naf72ARwGo 9kIU9RvdpbkeKXd6pokZD5grCOJU9rvdMwKj7Xf0j2hpBasSxHG3p2/a/OhOH6fDa2 OJ5B/u8ewOAso41Kxals4f7jjlH0giGmW61TQ3YdQSlTJg+GDyWADz1ZrZEeJA9ztX RM5Cz/V9nNy6bUb5qW6eUUgWFbQuZ210AJs/K4usniPVQwujEc1IQMxfdkG2yi9qMq MJyWs8rRvhtNXQMIZeIQbsHZ1Gs7CkkO/nGMyLsBeti1X3DnQJnbYRV4iv9FKpAIh/ cbKKiHESqR0Rw== From: Jakub Kicinski To: Jarod Wilson Cc: linux-kernel@vger.kernel.org, Ivan Vecera , Jay Vosburgh , Veaceslav Falico , Andy Gospodarek , "David S. Miller" , Thomas Davis , netdev@vger.kernel.org Subject: Re: [PATCH net v3] bonding: fix feature flag setting at init time Message-ID: <20201203085001.4901c97f@kicinski-fedora-pc1c0hjn.DHCP.thefacebook.com> In-Reply-To: <20201203004357.3125-1-jarod@redhat.com> References: <20201202173053.13800-1-jarod@redhat.com> <20201203004357.3125-1-jarod@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 2 Dec 2020 19:43:57 -0500 Jarod Wilson wrote: > bond_dev->hw_features |= NETIF_F_GSO_ENCAP_ALL | NETIF_F_GSO_UDP_L4; > -#ifdef CONFIG_XFRM_OFFLOAD > - bond_dev->hw_features |= BOND_XFRM_FEATURES; > -#endif /* CONFIG_XFRM_OFFLOAD */ > bond_dev->features |= bond_dev->hw_features; > bond_dev->features |= NETIF_F_HW_VLAN_CTAG_TX | NETIF_F_HW_VLAN_STAG_TX; > #ifdef CONFIG_XFRM_OFFLOAD > - /* Disable XFRM features if this isn't an active-backup config */ > - if (BOND_MODE(bond) != BOND_MODE_ACTIVEBACKUP) > - bond_dev->features &= ~BOND_XFRM_FEATURES; > + bond_dev->hw_features |= BOND_XFRM_FEATURES; > + /* Only enable XFRM features if this is an active-backup config */ > + if (BOND_MODE(bond) == BOND_MODE_ACTIVEBACKUP) > + bond_dev->features |= BOND_XFRM_FEATURES; > #endif /* CONFIG_XFRM_OFFLOAD */ This makes no functional change, or am I reading it wrong?