Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp3287449ybb; Tue, 31 Mar 2020 02:08:48 -0700 (PDT) X-Google-Smtp-Source: ADFU+vsOIpr0MrToahGjhOgbLz4RXn91reNK8Jx+cnlnYDBvF0xS9iKtgXrhfTcDprDxHrOyCdK3 X-Received: by 2002:a4a:9813:: with SMTP id y19mr12495321ooi.56.1585645728034; Tue, 31 Mar 2020 02:08:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1585645728; cv=none; d=google.com; s=arc-20160816; b=XDODpl/Ro56vjDYzwCkSngGR8bTcyMVEAI+/l66cShL1P+Kpp3ZF/XmEwMGIrO3ym7 9n67Kacnf2nH3YVGwuYEL8P8HiKS4BfG/dB9CeKam/AARyeEUhk9cz/KfWBnMt4n55df a+bQbZDuOp9ET23NXJRJ7ps9m+U35A8gZkT3ljNYZZUq50wU6r7HmpS4KkbPKBiKWKVX 1EEOVe39wQMkXV24w2BFB5KAVDpBz5xZD+WRsyKCnJXHnhxwB7iV73BQ7raQ4P/7+YnY dhwH+hSv3p+CWzFeBpkuEc4qyB2JDf+Y1pT9DExHTLlbQAGhVBLjDrg+2Q7PAlKNUGmZ cs3Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=4o9zdEXqrmd6KnJKTwLCFTLw9MB0UtXkqqjUb5bO7eE=; b=epTUCHxa1Nnmc+CYqkA2WXd89XczCI5M59jOR46Un4/owQFm02Wr5sVaJA8kLDic6I d8WWt5hsVuhfUQvWHcTI9a1rhcl3JLUQQM6a5fVFSz6Ljo9Lxj0kcG9S8FxJ38OK4uKA 0+0fcOoLKUqO3fPtJpPmu8u27ib/bjCQmkjTbf2po/y1tteafMGcfXWOGTSNcLbFtL6O sHIazuuo4ldzpqH/qWU5r1snTh3tqi0i9VBlyOlEirTrsBgChfzaLcSA87QokQTQx1OJ 3/bGzKSlvpNxSj8ZpdkXVrT9j/Y5FkbQP3tWT+X+oqbUdFejYpI7aNPQKIEKQdadASES xp3w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=IMTtdgO0; 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 q13si5490937otg.196.2020.03.31.02.08.35; Tue, 31 Mar 2020 02:08:48 -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; dkim=pass header.i=@kernel.org header.s=default header.b=IMTtdgO0; 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 S1731340AbgCaJIV (ORCPT + 99 others); Tue, 31 Mar 2020 05:08:21 -0400 Received: from mail.kernel.org ([198.145.29.99]:50678 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731328AbgCaJIU (ORCPT ); Tue, 31 Mar 2020 05:08:20 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.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 3B42320787; Tue, 31 Mar 2020 09:08:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1585645699; bh=cK/T867mmCzZ7jlhvqRs6wFLYHZ3QXTaeW+I16G17lY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=IMTtdgO0wPRLxRz5xYt3Zk6/G38onVQPUCyz1u4HXoKMlCYBvpDEcr+Fsu5JhOfIy o7gcUkE/bQCefVrpAr4GmslA13CgxgbHi21dadv6QL/efvYuT6fbLdq0+5U2FkFin2 PoUTPIVp2LkJCWBwtlgmccg0kFNC5tGAllyiBTz0= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Edward Cree , Pablo Neira Ayuso Subject: [PATCH 5.5 136/170] netfilter: flowtable: populate addr_type mask Date: Tue, 31 Mar 2020 10:59:10 +0200 Message-Id: <20200331085437.985463513@linuxfoundation.org> X-Mailer: git-send-email 2.26.0 In-Reply-To: <20200331085423.990189598@linuxfoundation.org> References: <20200331085423.990189598@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Edward Cree commit 15ff197237e76c4dab06b7b518afaa4ebb1c43e0 upstream. nf_flow_rule_match() sets control.addr_type in key, so needs to also set the corresponding mask. An exact match is wanted, so mask is all ones. Fixes: c29f74e0df7a ("netfilter: nf_flow_table: hardware offload support") Signed-off-by: Edward Cree Signed-off-by: Pablo Neira Ayuso Signed-off-by: Greg Kroah-Hartman --- net/netfilter/nf_flow_table_offload.c | 1 + 1 file changed, 1 insertion(+) --- a/net/netfilter/nf_flow_table_offload.c +++ b/net/netfilter/nf_flow_table_offload.c @@ -87,6 +87,7 @@ static int nf_flow_rule_match(struct nf_ default: return -EOPNOTSUPP; } + mask->control.addr_type = 0xffff; match->dissector.used_keys |= BIT(key->control.addr_type); mask->basic.n_proto = 0xffff;