lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20120130142837.GA21750@localhost>
Date:	Mon, 30 Jan 2012 22:28:37 +0800
From:	Wu Fengguang <wfg@...ux.intel.com>
To:	Shaohua Li <shaohua.li@...el.com>
Cc:	Herbert Poetzl <herbert@...hfloor.at>,
	Eric Dumazet <eric.dumazet@...il.com>,
	Andrew Morton <akpm@...ux-foundation.org>,
	LKML <linux-kernel@...r.kernel.org>,
	Jens Axboe <axboe@...nel.dk>, Tejun Heo <tj@...nel.org>
Subject: Re: Bad SSD performance with recent kernels

On Mon, Jan 30, 2012 at 06:31:34PM +0800, Li, Shaohua wrote:

> Looks the 2.6.39 block plug introduces some latency here. deleting
> blk_start_plug/blk_finish_plug in generic_file_aio_read seems
> workaround
> the issue. The plug seems not good for sequential IO, because readahead
> code already has plug and has fine grained control.

Why not remove the generic_file_aio_read() plug completely? It
actually prevents unplugging immediately after the readahead IO is
submitted and in turn stalls the IO pipeline as showed by Eric's
blktrace data.

Eric, will you test this patch? Thank you.

--- linux.orig/mm/filemap.c	2012-01-30 22:27:11.000000000 +0800
+++ linux/mm/filemap.c	2012-01-30 22:27:25.000000000 +0800
@@ -1414,15 +1414,12 @@ generic_file_aio_read(struct kiocb *iocb
 	unsigned long seg = 0;
 	size_t count;
 	loff_t *ppos = &iocb->ki_pos;
-	struct blk_plug plug;
 
 	count = 0;
 	retval = generic_segment_checks(iov, &nr_segs, &count, VERIFY_WRITE);
 	if (retval)
 		return retval;
 
-	blk_start_plug(&plug);
-
 	/* coalesce the iovecs and go direct-to-BIO for O_DIRECT */
 	if (filp->f_flags & O_DIRECT) {
 		loff_t size;
@@ -1495,7 +1492,6 @@ generic_file_aio_read(struct kiocb *iocb
 			break;
 	}
 out:
-	blk_finish_plug(&plug);
 	return retval;
 }
 EXPORT_SYMBOL(generic_file_aio_read);
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ