From: Stephen Hemminger <stephen@networkplumber.org>
To: dev@dpdk.org
Cc: Stephen Hemminger <shemming@brocade.com>
Subject: [dpdk-dev] [PATCH v2 2/2] vfio: don't build unnecessary files
Date: Thu, 9 Jul 2015 16:26:27 -0700 [thread overview]
Message-ID: <1436484387-29273-3-git-send-email-stephen@networkplumber.org> (raw)
In-Reply-To: <1436484387-29273-1-git-send-email-stephen@networkplumber.org>
From: Stephen Hemminger <shemming@brocade.com>
If VFIO is configured, it is better to just not build the source
files (rather than generating empty object files).
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
lib/librte_eal/linuxapp/eal/Makefile | 4 ++--
lib/librte_eal/linuxapp/eal/eal_pci_vfio.c | 3 ---
lib/librte_eal/linuxapp/eal/eal_pci_vfio_mp_sync.c | 3 ---
3 files changed, 2 insertions(+), 8 deletions(-)
diff --git a/lib/librte_eal/linuxapp/eal/Makefile b/lib/librte_eal/linuxapp/eal/Makefile
index 42a16fe..bc513c0 100644
--- a/lib/librte_eal/linuxapp/eal/Makefile
+++ b/lib/librte_eal/linuxapp/eal/Makefile
@@ -64,8 +64,8 @@ SRCS-$(CONFIG_RTE_LIBRTE_EAL_LINUXAPP) += eal_thread.c
SRCS-$(CONFIG_RTE_LIBRTE_EAL_LINUXAPP) += eal_log.c
SRCS-$(CONFIG_RTE_LIBRTE_EAL_LINUXAPP) += eal_pci.c
SRCS-$(CONFIG_RTE_LIBRTE_EAL_LINUXAPP) += eal_pci_uio.c
-SRCS-$(CONFIG_RTE_LIBRTE_EAL_LINUXAPP) += eal_pci_vfio.c
-SRCS-$(CONFIG_RTE_LIBRTE_EAL_LINUXAPP) += eal_pci_vfio_mp_sync.c
+SRCS-$(CONFIG_RTE_EAL_VFIO) += eal_pci_vfio.c
+SRCS-$(CONFIG_RTE_EAL_VFIO) += eal_pci_vfio_mp_sync.c
SRCS-$(CONFIG_RTE_LIBRTE_EAL_LINUXAPP) += eal_debug.c
SRCS-$(CONFIG_RTE_LIBRTE_EAL_LINUXAPP) += eal_lcore.c
SRCS-$(CONFIG_RTE_LIBRTE_EAL_LINUXAPP) += eal_timer.c
diff --git a/lib/librte_eal/linuxapp/eal/eal_pci_vfio.c b/lib/librte_eal/linuxapp/eal/eal_pci_vfio.c
index 426953a..9ba4b10 100644
--- a/lib/librte_eal/linuxapp/eal/eal_pci_vfio.c
+++ b/lib/librte_eal/linuxapp/eal/eal_pci_vfio.c
@@ -59,8 +59,6 @@
* This file is only compiled if CONFIG_RTE_EAL_VFIO is set to "y".
*/
-#ifdef VFIO_PRESENT
-
#define PAGE_SIZE (sysconf(_SC_PAGESIZE))
#define PAGE_MASK (~(PAGE_SIZE - 1))
@@ -909,4 +907,3 @@ pci_vfio_is_enabled(void)
{
return vfio_cfg.vfio_enabled;
}
-#endif
diff --git a/lib/librte_eal/linuxapp/eal/eal_pci_vfio_mp_sync.c b/lib/librte_eal/linuxapp/eal/eal_pci_vfio_mp_sync.c
index fec7080..657fc2c 100644
--- a/lib/librte_eal/linuxapp/eal/eal_pci_vfio_mp_sync.c
+++ b/lib/librte_eal/linuxapp/eal/eal_pci_vfio_mp_sync.c
@@ -62,8 +62,6 @@
* This file is only compiled if CONFIG_RTE_EAL_VFIO is set to "y".
*/
-#ifdef VFIO_PRESENT
-
#define SOCKET_PATH_FMT "%s/.%s_mp_socket"
#define CMSGLEN (CMSG_LEN(sizeof(int)))
#define FD_TO_CMSGHDR(fd, chdr) \
@@ -391,4 +389,3 @@ pci_vfio_mp_sync_setup(void)
return 0;
}
-#endif
--
2.1.4
prev parent reply other threads:[~2015-07-09 23:26 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-07-09 23:26 [dpdk-dev] [PATCH v2 0/2] vfio: build cleanups Stephen Hemminger
2015-07-09 23:26 ` [dpdk-dev] [PATCH v2 1/2] vfio: fix build if build envrionment is on old kernel Stephen Hemminger
2015-07-09 23:43 ` Thomas Monjalon
2015-07-10 17:29 ` Stephen Hemminger
2015-07-10 20:19 ` Thomas Monjalon
2015-07-10 20:44 ` Stephen Hemminger
2015-07-10 21:10 ` Thomas Monjalon
2015-07-10 10:13 ` Burakov, Anatoly
2015-07-10 15:44 ` Stephen Hemminger
2015-07-09 23:26 ` Stephen Hemminger [this message]
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=1436484387-29273-3-git-send-email-stephen@networkplumber.org \
--to=stephen@networkplumber.org \
--cc=dev@dpdk.org \
--cc=shemming@brocade.com \
/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).