DPDK patches and discussions
 help / color / mirror / Atom feed
From: Bernard Iremonger <bernard.iremonger@intel.com>
To: dev@dpdk.org
Subject: [dpdk-dev] [PATCH v3] examples/vhost: reduce number of hugepages needed
Date: Thu, 10 Dec 2015 15:49:17 +0000	[thread overview]
Message-ID: <1449762557-28782-1-git-send-email-bernard.iremonger@intel.com> (raw)
In-Reply-To: <1449755601-25670-1-git-send-email-bernard.iremonger@intel.com>

Add #ifndef MAX_QUEUES to change MAX_QUEUES at compile time if needed.
Change MAX_QUEUES from 512 to 128 to reduce the number of hugepages
required by the vhost-switch program.

To change MAX_QUEUES add '-D MAX_QUEUES=512' to the EXTRA_CFLAGS variable,
before building the application.

Changes in v3:
Added #ifndef MAX_QUEUES line before #define MAX_QUEUES 128

Changes in v2:
remove comment added before #define MAX_QUEUES in v1 patch.

Signed-off-by: Bernard Iremonger <bernard.iremonger@intel.com>
---
 examples/vhost/main.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/examples/vhost/main.c b/examples/vhost/main.c
index b30f1bd..2dcdacb 100644
--- a/examples/vhost/main.c
+++ b/examples/vhost/main.c
@@ -1,7 +1,7 @@
 /*-
  *   BSD LICENSE
  *
- *   Copyright(c) 2010-2014 Intel Corporation. All rights reserved.
+ *   Copyright(c) 2010-2015 Intel Corporation. All rights reserved.
  *   All rights reserved.
  *
  *   Redistribution and use in source and binary forms, with or without
@@ -53,7 +53,9 @@
 
 #include "main.h"
 
-#define MAX_QUEUES 512
+#ifndef MAX_QUEUES
+#define MAX_QUEUES 128
+#endif
 
 /* the maximum number of external ports supported */
 #define MAX_SUP_PORTS 1
-- 
2.6.3

  parent reply	other threads:[~2015-12-10 15:49 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-12-10 12:19 [dpdk-dev] [PATCH] " Bernard Iremonger
2015-12-10 12:59 ` Yuanhan Liu
2015-12-10 13:26   ` Iremonger, Bernard
2015-12-10 13:34     ` Yuanhan Liu
2015-12-10 13:53 ` [dpdk-dev] [PATCH v2] " Bernard Iremonger
2015-12-10 14:50   ` Ananyev, Konstantin
2015-12-10 15:43     ` Iremonger, Bernard
2015-12-11  9:05     ` Panu Matilainen
2015-12-10 15:49   ` Bernard Iremonger [this message]
2015-12-10 16:32     ` [dpdk-dev] [PATCH v3] " Ananyev, Konstantin
2015-12-10 21:35       ` Thomas Monjalon

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=1449762557-28782-1-git-send-email-bernard.iremonger@intel.com \
    --to=bernard.iremonger@intel.com \
    --cc=dev@dpdk.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).