[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAKEwX=N5ruUdkzfvwpXMZWQByCkqP4WJFsJzKVAWkTm8osHeUg@mail.gmail.com>
Date: Mon, 17 Jul 2023 15:58:45 -0700
From: Nhat Pham <nphamcs@...il.com>
To: Johannes Weiner <hannes@...xchg.org>
Cc: Matthew Wilcox <willy@...radead.org>,
Vlastimil Babka <vbabka@...e.cz>,
Andrew Morton <akpm@...ux-foundation.org>,
Yosry Ahmed <yosryahmed@...gle.com>,
Christoph Hellwig <hch@...radead.org>,
Domenico Cerasuolo <cerasuolodomenico@...il.com>,
konrad.wilk@...cle.com, vitaly.wool@...sulko.com,
linux-mm@...ck.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] mm: kill frontswap
On Mon, Jul 17, 2023 at 2:51 PM Johannes Weiner <hannes@...xchg.org> wrote:
>
> On Mon, Jul 17, 2023 at 05:07:46PM +0100, Matthew Wilcox wrote:
> > On Mon, Jul 17, 2023 at 12:02:27PM -0400, Johannes Weiner wrote:
> > > - pr_info("Adding %uk swap on %s. Priority:%d extents:%d across:%lluk %s%s%s%s%s\n",
> > > + pr_info("Adding %uk swap on %s. Priority:%d extents:%d across:%lluk %s%s%s%s\n",
> > > p->pages<<(PAGE_SHIFT-10), name->name, p->prio,
> > > nr_extents, (unsigned long long)span<<(PAGE_SHIFT-10),
> > > (p->flags & SWP_SOLIDSTATE) ? "SS" : "",
> > > (p->flags & SWP_DISCARDABLE) ? "D" : "",
> > > (p->flags & SWP_AREA_DISCARD) ? "s" : "",
> > > - (p->flags & SWP_PAGE_DISCARD) ? "c" : "",
> > > - (frontswap_map) ? "FS" : "");
> > > + (p->flags & SWP_PAGE_DISCARD) ? "c" : "");
> >
> > Is it useful information (to the sysadmin) that zswap is enabled? If so,
> > we might want to print a "Z" instead of a "FS" here (would need to
> > know whether enabling zswap succeeded ...)
>
> I don't think it is needed in this particular place.
>
> zswap prints to dmesg when it is initialized. And it's easy to runtime
> check in sysfs or in /proc/meminfo if it's enabled - that's where I
> would look first if I checked a system that's showing zswap issues -
> not in the dmesg that may have long wrapped since swapon.
+1
I always use /sys/kernel/debug/* and /sys/module/zswap/parameters/*
for debugging zswap issues too.
>
> There is also a warning to dmesg if zswap fails to enable for a given
> swapfile. But with the current page allocator implementation this
> can't actually fail.
Powered by blists - more mailing lists