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] [day] [month] [year] [list]
Message-Id: <20191011143231.e338e0ef337492e83233ad39@linux-foundation.org>
Date:   Fri, 11 Oct 2019 14:32:31 -0700
From:   Andrew Morton <akpm@...ux-foundation.org>
To:     Johannes Weiner <hannes@...xchg.org>
Cc:     Minchan Kim <minchan@...nel.org>, linux-mm <linux-mm@...ck.org>,
        LKML <linux-kernel@...r.kernel.org>,
        Sahkeel Butt <shakeelb@...gle.com>,
        Minchan Kim <minchan@...gle.com>
Subject: Re: [PATCH] mm: annotate refault stalls from swap_readpage

On Thu, 10 Oct 2019 15:17:47 -0400 Johannes Weiner <hannes@...xchg.org> wrote:

> On Thu, Oct 10, 2019 at 08:21:34AM -0700, Minchan Kim wrote:
> > From: Minchan Kim <minchan@...gle.com>
> > 
> > If block device supports rw_page operation, it doesn't submit bio
> > so annotation in submit_bio for refault stall doesn't work.
> > It happens with zram in android, especially swap read path which
> > could consume CPU cycle for decompress. It is also a problem for
> > zswap which uses frontswap.
> > 
> > Annotate swap_readpage() to account the synchronous IO overhead
> > to prevent underreport memory pressure.
> > 
> > Cc: Johannes Weiner <hannes@...xchg.org>
> > Signed-off-by: Minchan Kim <minchan@...gle.com>
> 
> Acked-by: Johannes Weiner <hannes@...xchg.org>
> 
> Can you please add a comment to the caller? Lifted from submit_bio():
> 
> 	/*
> 	 * Count submission time as memory stall. When the device is
> 	 * congested, or the submitting cgroup IO-throttled,
> 	 * submission can be a significant part of overall IO time.
> 	 */

This?

--- a/mm/page_io.c~mm-annotate-refault-stalls-from-swap_readpage-fix
+++ a/mm/page_io.c
@@ -361,6 +361,11 @@ int swap_readpage(struct page *page, boo
 	VM_BUG_ON_PAGE(!PageLocked(page), page);
 	VM_BUG_ON_PAGE(PageUptodate(page), page);
 
+	/*
+	 * Count submission time as memory stall. When the device is congested,
+	 * or the submitting cgroup IO-throttled, submission can be a
+	 * significant part of overall IO time.
+	 */
 	psi_memstall_enter(&pflags);
 
 	if (frontswap_load(page) == 0) {
_

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ