[Cluster-devel] [RFC dlm/next 12/15] fs: dlm: remove send starve
Alexander Aring
aahringo at redhat.com
Wed Jun 23 15:14:51 UTC 2021
This patch removes starve handling in case of sending to much. I think
this was introduced that it can serve some other connections when
sending to much. However we now have not an ordered workqueue anymore
and can handle multiple connection kernel_sendpage() at one time.
Signed-off-by: Alexander Aring <aahringo at redhat.com>
---
fs/dlm/lowcomms.c | 8 --------
1 file changed, 8 deletions(-)
diff --git a/fs/dlm/lowcomms.c b/fs/dlm/lowcomms.c
index 28d97f8187a5..ddf3c0c98386 100644
--- a/fs/dlm/lowcomms.c
+++ b/fs/dlm/lowcomms.c
@@ -61,7 +61,6 @@
#define NEEDED_RMEM (4*1024*1024)
/* Number of messages to send before rescheduling */
-#define MAX_SEND_MSG_COUNT 25
#define DLM_SHUTDOWN_WAIT_TIMEOUT msecs_to_jiffies(10000)
struct connection {
@@ -1464,7 +1463,6 @@ static void send_to_sock(struct connection *con)
const int msg_flags = MSG_DONTWAIT | MSG_NOSIGNAL;
struct writequeue_entry *e;
int len, offset, ret;
- int count = 0;
mutex_lock(&con->swork_lock);
if (con->sock == NULL) {
@@ -1501,12 +1499,6 @@ static void send_to_sock(struct connection *con)
} else if (ret < 0)
goto out;
- /* Don't starve people filling buffers */
- if (++count >= MAX_SEND_MSG_COUNT) {
- cond_resched();
- count = 0;
- }
-
spin_lock(&con->writequeue_lock);
writequeue_entry_complete(e, ret);
}
--
2.26.3
More information about the Cluster-devel
mailing list