Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c039a777 authored by Sahitya Tummala's avatar Sahitya Tummala Committed by Gerrit - the friendly Code Review server
Browse files

Revert "aio: only use blk plugs for > 2 depth submissions"



This reverts commit a79d40e9.
This is to fix the performance regression of storage tests
observed with fio benchmark.

Change-Id: I914bae800d6c7483639551d0ed7f6094b866fa12
Signed-off-by: default avatarSahitya Tummala <stummala@codeaurora.org>
parent 20fbe1a9
Loading
Loading
Loading
Loading
+4 −14
Original line number Diff line number Diff line
@@ -71,12 +71,6 @@ struct aio_ring {
	struct io_event		io_events[0];
}; /* 128 bytes + ring size */

/*
 * Plugging is meant to work with larger batches of IOs. If we don't
 * have more than the below, then don't bother setting up a plug.
 */
#define AIO_PLUG_THRESHOLD	2

#define AIO_RING_PAGES	8

struct kioctx_table {
@@ -1932,7 +1926,6 @@ SYSCALL_DEFINE3(io_submit, aio_context_t, ctx_id, long, nr,
	if (nr > ctx->nr_events)
		nr = ctx->nr_events;

	if (nr > AIO_PLUG_THRESHOLD)
	blk_start_plug(&plug);
	for (i = 0; i < nr; i++) {
		struct iocb __user *user_iocb;
@@ -1946,7 +1939,6 @@ SYSCALL_DEFINE3(io_submit, aio_context_t, ctx_id, long, nr,
		if (ret)
			break;
	}
	if (nr > AIO_PLUG_THRESHOLD)
	blk_finish_plug(&plug);

	percpu_ref_put(&ctx->users);
@@ -1974,7 +1966,6 @@ COMPAT_SYSCALL_DEFINE3(io_submit, compat_aio_context_t, ctx_id,
	if (nr > ctx->nr_events)
		nr = ctx->nr_events;

	if (nr > AIO_PLUG_THRESHOLD)
	blk_start_plug(&plug);
	for (i = 0; i < nr; i++) {
		compat_uptr_t user_iocb;
@@ -1988,7 +1979,6 @@ COMPAT_SYSCALL_DEFINE3(io_submit, compat_aio_context_t, ctx_id,
		if (ret)
			break;
	}
	if (nr > AIO_PLUG_THRESHOLD)
	blk_finish_plug(&plug);

	percpu_ref_put(&ctx->users);