From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 820BEC3A5A7 for ; Tue, 6 Dec 2022 23:54:38 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229621AbiLFXyh (ORCPT ); Tue, 6 Dec 2022 18:54:37 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49470 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229554AbiLFXyg (ORCPT ); Tue, 6 Dec 2022 18:54:36 -0500 Received: from mail.netfilter.org (mail.netfilter.org [217.70.188.207]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 8E5AB30574 for ; Tue, 6 Dec 2022 15:54:35 -0800 (PST) Date: Wed, 7 Dec 2022 00:54:31 +0100 From: Pablo Neira Ayuso To: Xin Long Cc: network dev , dev@openvswitch.org, davem@davemloft.net, kuba@kernel.org, Eric Dumazet , Paolo Abeni , Pravin B Shelar , Jamal Hadi Salim , Cong Wang , Jiri Pirko , Florian Westphal , Marcelo Ricardo Leitner , Davide Caratti , Oz Shlomo , Paul Blakey , Ilya Maximets , Eelco Chaudron , Aaron Conole , Saeed Mahameed Subject: Re: [PATCHv3 net-next 5/5] net: move the nat function to nf_nat_ovs for ovs and tc Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org On Tue, Dec 06, 2022 at 06:31:16PM -0500, Xin Long wrote: [...] > diff --git a/net/netfilter/Makefile b/net/netfilter/Makefile > index 1d4db1943936..0976d34b1e5f 100644 > --- a/net/netfilter/Makefile > +++ b/net/netfilter/Makefile > @@ -54,6 +54,12 @@ obj-$(CONFIG_NF_CONNTRACK_TFTP) += nf_conntrack_tftp.o > > nf_nat-y := nf_nat_core.o nf_nat_proto.o nf_nat_helper.o > > +ifdef CONFIG_OPENVSWITCH > +nf_nat-y += nf_nat_ovs.o > +else ifdef CONFIG_NET_ACT_CT > +nf_nat-y += nf_nat_ovs.o > +endif Maybe add CONFIG_NF_NAT_OVS and select it from OPENVSWITCH Kconfig (select is a hammer, but it should be fine in this case since OPENVSWITCH already depends on NF_NAT?). Then in Makefile: nf_nat-$(CONFIG_NF_NAT_OVS) += nf_nat_ovs.o And CONFIG_NF_NAT_OVS depends on OPENVSWITCH. > obj-$(CONFIG_NF_LOG_SYSLOG) += nf_log_syslog.o > > obj-$(CONFIG_NF_NAT) += nf_nat.o