From patchwork Mon Feb 5 22:56:05 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nhat Pham X-Patchwork-Id: 13546371 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4EC4AC4828D for ; Mon, 5 Feb 2024 22:56:13 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id D85C26B007B; Mon, 5 Feb 2024 17:56:12 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id D36206B007D; Mon, 5 Feb 2024 17:56:12 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id BD6ED6B0080; Mon, 5 Feb 2024 17:56:12 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0017.hostedemail.com [216.40.44.17]) by kanga.kvack.org (Postfix) with ESMTP id AA03B6B007B for ; Mon, 5 Feb 2024 17:56:12 -0500 (EST) Received: from smtpin05.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay05.hostedemail.com (Postfix) with ESMTP id 4DAA8408C7 for ; Mon, 5 Feb 2024 22:56:12 +0000 (UTC) X-FDA: 81759260184.05.43D230A Received: from mail-qv1-f50.google.com (mail-qv1-f50.google.com [209.85.219.50]) by imf27.hostedemail.com (Postfix) with ESMTP id 909C440019 for ; Mon, 5 Feb 2024 22:56:10 +0000 (UTC) Authentication-Results: imf27.hostedemail.com; dkim=pass header.d=gmail.com header.s=20230601 header.b=HGX9DyyN; spf=pass (imf27.hostedemail.com: domain of nphamcs@gmail.com designates 209.85.219.50 as permitted sender) smtp.mailfrom=nphamcs@gmail.com; dmarc=pass (policy=none) header.from=gmail.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1707173770; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-transfer-encoding:content-transfer-encoding: in-reply-to:references:dkim-signature; bh=TGdyPa7Pf/Y7EOUem+E2iwIgjOxOpmm5HyY7qygEzks=; b=mVpjhEOKPoRZpL0uOf2pRrcJAUj9OhPcqNVUTarhnTCVXI+tHN5j0QvLycur3EWKjo2+7f r+4ATmj5TOY9bT3h/A6Vscs8ps0fcS/ZaipSgPFyqDe6tK0csI/9DKjEhtr5JRdi49Vs4H Js6knd6B2W6cVoqw48P208b/Xoq1DUk= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1707173770; a=rsa-sha256; cv=none; b=QPxRuPm2wVlonRZx01fgFtDkQQDgAnhIJePqleO8H70fZ4QpF6p50nBoa8KlQOsWusnY+l q8xJexAz2e9WIYrnztsCIQ2LVzXTO3OPMycufO2UNLtcQKuyTNFZJSLf4ZFCvNaqaCt/En HJfgFngG40BWN+0XAzjdCukVWnF2li4= ARC-Authentication-Results: i=1; imf27.hostedemail.com; dkim=pass header.d=gmail.com header.s=20230601 header.b=HGX9DyyN; spf=pass (imf27.hostedemail.com: domain of nphamcs@gmail.com designates 209.85.219.50 as permitted sender) smtp.mailfrom=nphamcs@gmail.com; dmarc=pass (policy=none) header.from=gmail.com Received: by mail-qv1-f50.google.com with SMTP id 6a1803df08f44-68c8d3c445fso10909736d6.1 for ; Mon, 05 Feb 2024 14:56:10 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1707173769; x=1707778569; darn=kvack.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=TGdyPa7Pf/Y7EOUem+E2iwIgjOxOpmm5HyY7qygEzks=; b=HGX9DyyN3PkqTqxMHAuhPu0ntH/GYzMc4fGUk6H6nQ32wKHwq1Glfu17plP+sIFVoZ lV9J1ROjk0pZt9e4Yxi2iYwNV2YpgbRFTg+Y6o60ITWa982Z4dB8GE8/HO9Yl1nnxygo +T3VNx9EJE84+ciqKfiF5v2VbSl0mLknd4zS6/op2T1klE1MqXIRAHP161LDLyW4ajnt EpKSKXHnr52wG/qFW/ChfbXnk2cWHRE1tZhviIpQpZwAkX4HXzWFfAMCGOHam3OMZfAJ hHtn0XoilRbaMDTsKvzQ0hlrvsvD8fkEh/xW1lvhuNyNpPmojjRwSUB3IfveiJNVdPOb d22g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707173769; x=1707778569; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=TGdyPa7Pf/Y7EOUem+E2iwIgjOxOpmm5HyY7qygEzks=; b=H2WsiZA3hiu+YPJShs4WaOBfWadat4ALZsAgxrFWBTH2G1f3o4NRkpzk6lfM6IJ+Sl zM9wILISu6spjPlNn6L5oklXoXzCx/6VLJg0QNgdkvRj2nnekicCxuimcOCIkI/vRGSt oudR6xAD0LgGzTTR2cWvJsW2Xu3m9UEQATbQ+g2Xh7s66GVlwPJkXSRSnNzb0O40ZWCp MX6WmMDHx6WPwn6525jwUMSJVYLa8hoeKbi5x2zGVGrWk0BroAvSwxVWjG3h0jQLT1OY ReBS76lF2OIVxSdVHeXhnm1HEEUA++1I36QRIzvSu0BpHubBujetjb9pAawt3N1KsyuI eObQ== X-Gm-Message-State: AOJu0YzVdLVGB7uF3C56HUpXiC6iZOt4WU/fs7G975LxzMCnKLv+E+S1 Qp57ngJHPX9BEWTc66MC7aMWHp5rz0GMEQ1XsFCjyHgxaY/oJeTP X-Google-Smtp-Source: AGHT+IGfKgXtdhTde5jttlEus/aYY1VrLcbaT3SzAbrDsR2jr1jMh14fzNUl3l8jyMk7UlYIteSyoA== X-Received: by 2002:a05:6214:20a8:b0:68c:9307:3021 with SMTP id 8-20020a05621420a800b0068c93073021mr995244qvd.47.1707173769636; Mon, 05 Feb 2024 14:56:09 -0800 (PST) X-Forwarded-Encrypted: i=0; AJvYcCW7v8PF1XGBVOPoV/mq8PqMOogCMRrSc680TooUNtMA8rTz/Bsl7IMunpZ1x0OfJtfBnYBMT5FPPrEzwlDkYiPJOgEwvLjmeHj+ufIsoHk3REU1CulcwJ+JHFl8sPgLs9RMcQB9bwrMLy+OH4Ao5nNoinytQ84nQa8zQyDVp9JFjeVnXA5OrTlgVz9lP3etUHSgsDOSonjCLd1q74MFSgHgW36WPbWt+3exSlO2jV4GX2aWn3Y0yL0OgdsIlDeT5UTOi9uWSp2SAiNwOFSfvCelGTz8qqg8M/y82EuTI7aVHIxC+OLZPGq4XjoPt8amG4yXftmCC+vHaIJExAFnUh8I7ZxoWpBJp+jWpcDNWGFNsP9xAHrdRopUqPcLe/AkQkO70XUw/NuJxxhNTE6i5CQ= Received: from localhost (fwdproxy-nao-006.fbsv.net. [2a03:2880:23ff:6::face:b00c]) by smtp.gmail.com with ESMTPSA id ez4-20020ad45904000000b0068ca41d6c26sm421459qvb.78.2024.02.05.14.56.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 05 Feb 2024 14:56:09 -0800 (PST) From: Nhat Pham To: akpm@linux-foundation.org Cc: riel@surriel.com, shuah@kernel.org, hannes@cmpxchg.org, yosryahmed@google.com, tj@kernel.org, lizefan.x@bytedance.com, roman.gushchin@linux.dev, linux-mm@kvack.org, kernel-team@meta.com, linux-kernel@vger.kernel.org, cgroups@vger.kernel.org, linux-kselftest@vger.kernel.org Subject: [PATCH v3 0/3] fix and extend zswap kselftests Date: Mon, 5 Feb 2024 14:56:05 -0800 Message-Id: <20240205225608.3083251-1-nphamcs@gmail.com> X-Mailer: git-send-email 2.39.3 MIME-Version: 1.0 X-Rspamd-Queue-Id: 909C440019 X-Rspam-User: X-Rspamd-Server: rspam11 X-Stat-Signature: sc5sktka473ydfckw79mskdodqf94egu X-HE-Tag: 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Vh1sgWROlIh28DZcXY2BL43k4nc9aEQIyJQIMbvtcdfDzeEer18TJ6kkteDDiM2XpvOtuoKa6yXS/V48KPDH9r0lqf5v0iwbUuh3bHIYcq9LyIBMdUGzKiu8p8Y1JvQ89QWkZOI1202nS9rFjlbBt64avVdMpJgcctXmLgvhJATYwZVFin4NerW3ueC0nxkvuMZ+9ClDLORMtjn7jp2GyY7A77CzfY5rEhrobobOMya2rqYdg6a7whyUtyj0nSFDoYrQo8v7kKclUlPGRrtdJ+0jfO+RvgiFpUc5lRwv4Z0jXjlynYW/k0Mw2oq853/lzoT6Knt5UPVe8C+9sbOgwpPmw== X-Bogosity: Ham, tests=bogofilter, spamicity=0.009630, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: Changelog: v3: * More cleanup (patch 3) (suggested by Yosry Ahmed). * Check swap peak in swapin test v2: * Make the swapin test also checks for zswap usage (patch 3) (suggested by Yosry Ahmed) * Some test simplifications/cleanups (patch 3) (suggested by Yosry Ahmed). Fix a broken zswap kselftest due to cgroup zswap writeback counter renaming, and add 2 zswap kselftests, one to cover the (z)swapin case, and another to check that no zswapping happens when the cgroup limit is 0. Also, add the zswap kselftest file to zswap maintainer entry so that get_maintainers script can find zswap maintainers. Nhat Pham (3): selftests: zswap: add zswap selftest file to zswap maintainer entry selftests: fix the zswap invasive shrink test selftests: add zswapin and no zswap tests MAINTAINERS | 1 + tools/testing/selftests/cgroup/test_zswap.c | 122 +++++++++++++++++++- 2 files changed, 121 insertions(+), 2 deletions(-) base-commit: 91f3daa1765ee4e0c89987dc25f72c40f07af34d