From: Masahiro Yamada <masahiroy@kernel.org>
To: netdev@vger.kernel.org
Cc: Masahiro Yamada <masahiroy@kernel.org>,
"David S. Miller" <davem@davemloft.net>,
Ivan Vecera <ivecera@redhat.com>,
Jakub Kicinski <kuba@kernel.org>, Jiri Pirko <jiri@resnulli.us>,
linux-kernel@vger.kernel.org
Subject: [PATCH 3/4] net: switchdev: use obj-$(CONFIG_NET_SWITCHDEV) form in net/Makefile
Date: Tue, 26 Jan 2021 08:16:57 +0900 [thread overview]
Message-ID: <20210125231659.106201-3-masahiroy@kernel.org> (raw)
In-Reply-To: <20210125231659.106201-1-masahiroy@kernel.org>
CONFIG_NET_SWITCHDEV is a bool option. Change the ifeq conditional to
the standard obj-$(CONFIG_NET_SWITCHDEV) form.
Use obj-y in net/switchdev/Makefile because Kbuild visits this Makefile
only when CONFIG_NET_SWITCHDEV=y.
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
---
net/Makefile | 4 +---
net/switchdev/Makefile | 2 +-
2 files changed, 2 insertions(+), 4 deletions(-)
diff --git a/net/Makefile b/net/Makefile
index a7e38bd463a4..a18547c97cbb 100644
--- a/net/Makefile
+++ b/net/Makefile
@@ -72,9 +72,7 @@ obj-$(CONFIG_VSOCKETS) += vmw_vsock/
obj-$(CONFIG_MPLS) += mpls/
obj-$(CONFIG_NET_NSH) += nsh/
obj-$(CONFIG_HSR) += hsr/
-ifneq ($(CONFIG_NET_SWITCHDEV),)
-obj-y += switchdev/
-endif
+obj-$(CONFIG_NET_SWITCHDEV) += switchdev/
ifneq ($(CONFIG_NET_L3_MASTER_DEV),)
obj-y += l3mdev/
endif
diff --git a/net/switchdev/Makefile b/net/switchdev/Makefile
index bd69a3136e76..c5561d7f3a7c 100644
--- a/net/switchdev/Makefile
+++ b/net/switchdev/Makefile
@@ -3,4 +3,4 @@
# Makefile for the Switch device API
#
-obj-$(CONFIG_NET_SWITCHDEV) += switchdev.o
+obj-y += switchdev.o
--
2.27.0
next prev parent reply other threads:[~2021-01-25 23:22 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-01-25 23:16 [PATCH 1/4] net: move CONFIG_NET guard to top Makefile Masahiro Yamada
2021-01-25 23:16 ` [PATCH 2/4] net: dcb: use obj-$(CONFIG_DCB) form in net/Makefile Masahiro Yamada
2021-01-25 23:16 ` Masahiro Yamada [this message]
2021-01-25 23:16 ` [PATCH 4/4] net: l3mdev: use obj-$(CONFIG_NET_L3_MASTER_DEV) " Masahiro Yamada
2021-01-26 3:44 ` David Ahern
2021-01-28 1:10 ` [PATCH 1/4] net: move CONFIG_NET guard to top Makefile patchwork-bot+netdevbpf
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210125231659.106201-3-masahiroy@kernel.org \
--to=masahiroy@kernel.org \
--cc=davem@davemloft.net \
--cc=ivecera@redhat.com \
--cc=jiri@resnulli.us \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).