From: Arnd Bergmann <arnd@arndb.de>
To: Doug Ledford <dledford@redhat.com>, Jason Gunthorpe <jgg@ziepe.ca>
Cc: Arnd Bergmann <arnd@arndb.de>,
Leon Romanovsky <leonro@mellanox.com>,
Sagi Grimberg <sagi@grimberg.me>,
Bart Van Assche <bart.vanassche@sandisk.com>,
linux-rdma@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [PATCH] RDMA/core: reduce IB_POLL_BATCH constant
Date: Tue, 20 Feb 2018 21:59:09 +0100 [thread overview]
Message-ID: <20180220205924.2035765-1-arnd@arndb.de> (raw)
The ib_wc structure has grown to much that putting 16 of them on the stack
hits the warning limit for dangerous kernel stack consumption:
drivers/infiniband/core/cq.c: In function 'ib_process_cq_direct':
drivers/infiniband/core/cq.c:78:1: error: the frame size of 1032 bytes is larger than 1024 bytes [-Werror=frame-larger-than=]
Using half that number brings us comfortably below that limit again.
Fixes: 02d8883f520e ("RDMA/restrack: Add general infrastructure to track RDMA resources")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
drivers/infiniband/core/cq.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/infiniband/core/cq.c b/drivers/infiniband/core/cq.c
index bc79ca8215d7..2626adbb978e 100644
--- a/drivers/infiniband/core/cq.c
+++ b/drivers/infiniband/core/cq.c
@@ -16,7 +16,7 @@
#include <rdma/ib_verbs.h>
/* # of WCs to poll for with a single call to ib_poll_cq */
-#define IB_POLL_BATCH 16
+#define IB_POLL_BATCH 8
/* # of WCs to iterate over before yielding */
#define IB_POLL_BUDGET_IRQ 256
--
2.9.0
next reply other threads:[~2018-02-20 20:59 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-02-20 20:59 Arnd Bergmann [this message]
2018-02-20 21:14 ` Parav Pandit
2018-02-20 21:54 ` Arnd Bergmann
2018-02-20 21:14 ` Bart Van Assche
2018-02-20 21:47 ` Chuck Lever
2018-02-21 9:47 ` Max Gurtovoy
2018-02-21 13:44 ` Sagi Grimberg
2018-02-21 14:45 ` Max Gurtovoy
2018-02-22 15:39 ` Sagi Grimberg
2018-02-27 22:09 ` Jason Gunthorpe
2018-02-27 22:15 ` Max Gurtovoy
2018-02-28 0:21 ` Bart Van Assche
2018-02-28 9:50 ` Max Gurtovoy
2018-02-28 18:55 ` Doug Ledford
2018-03-01 9:36 ` Max Gurtovoy
2018-02-21 15:10 ` Chuck Lever
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=20180220205924.2035765-1-arnd@arndb.de \
--to=arnd@arndb.de \
--cc=bart.vanassche@sandisk.com \
--cc=dledford@redhat.com \
--cc=jgg@ziepe.ca \
--cc=leonro@mellanox.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rdma@vger.kernel.org \
--cc=sagi@grimberg.me \
/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
all inboxes | Powered by JetHome®