From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-yb1-f180.google.com (mail-yb1-f180.google.com [209.85.219.180]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 1F849240222 for ; Mon, 13 Jan 2025 15:21:36 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.219.180 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736781698; cv=none; b=l+X8/nw8eddbakQbmFyWdVlpfcEKVjG/ara7sK61uatZU1cj29mgvrhhHyeiZwcaMK3MM1esaOsMLdiRFLJ3wYhncJt/bCS49rwAaPgppmgFsg5w18tfkMcMLG3ivHDMq/VtVGkdSXCbBLfW3bi4dfrgm15I9ICBgr10VPOTEBM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736781698; c=relaxed/simple; bh=HvUdYwE1XdRohJUVEkW4nBMDgrYoKT0vY6vbQqJpXCg=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=rwn+7B1fhFH5CUFSAbf+MkPMWRpbsyNgnL8o47etWd61Tc/SpK6ugh6EHNJKEkbLzQr6+RMX2rVEceLI7oyHJx+LFpfAaes6PT03JoScd74etSCx4Nhi2dmIIVE0yPGxAApeNjoAFj+Dlvd0PDaOhOeOCY2UOuAV7+sMor73YHU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=E942nuB1; arc=none smtp.client-ip=209.85.219.180 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="E942nuB1" Received: by mail-yb1-f180.google.com with SMTP id 3f1490d57ef6-e461015fbd4so6211524276.2 for ; Mon, 13 Jan 2025 07:21:36 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1736781696; x=1737386496; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=EItd3zJfgmeQs6GamX8dUjwzL+kw9r8hYoKvlpdsGz4=; b=E942nuB1W+NSR7V/+peZBHKF4Iz6PhMs7r4Si8EftMdkDJ8ikUBTBiW2ANL6F5D+BK jl4w8aDJxZidHKeG4LFDe4xPidkDmTCizHaUkTQM6h8tIYkqQDaTSgObaix6A0YWdKx+ hUq6k5gkWNfxrVhmfRO9WPKVlBfZ89fTJI5FE9rFtiKG9drNEH77kayCZ56MnW/kUyEX /Hv9MeRxK93o/60b8EElwGdK1EMtZfw5rhG5CDIJkF1bpTgkhH+L/nHu+3LH3A8C7/j9 d9OT7YBHTY3RiNeAcG+2WupOkF0kXM8yA5U5vSPWBGhScP5GJvIJ6H2K5f29tGLZQRKC 3yPA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1736781696; x=1737386496; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=EItd3zJfgmeQs6GamX8dUjwzL+kw9r8hYoKvlpdsGz4=; b=YgpFsDV6pe2ovOcK/NyCs+zcEx08EkMPXNQYSQrwf7r+pe2iFA29UpWS6alq58tabo etj45AYbc7ifSiQRkoWga4CPScHjVuqHUKzYGbejtg7tuCgqgw6WbdxIAPnodnPz5lGS c0tvjx/OyEOisAVsCIv+vvGV986E1nsInAP0sNuT1gvjF2hu3CtpWZBTeTNEnIVOEV/v mU+x0EA0EwPvnr5ElG4bhyGDLVeq+PnBVu3nTBy/CkMB5NXBnldIMFGoHLwvmyJYGZBJ 0Ng79MV3wVhgbdNVRZLbYsbgB7LWkSkSn2Dufh1mJxlg3ffmY6yA9HifajAfdLi0NpWN EeNA== X-Forwarded-Encrypted: i=1; AJvYcCUjNLqnhoiUIbBaltl33kfbtFpCv1xAk9Q3hOrxDFY4tECPkbvqYoWOQnR15Qlrl5c6NKSSNn8zpB31he8=@vger.kernel.org X-Gm-Message-State: AOJu0YyIBva6WedjfnXxylF4Q+IPM0h7JjooekGNSTvDc6QOMdLsrAAz RIr4QiL9xoSFEv5JPNqwb4Yz/r0rNNd+MoV7lTbkuFl2d7/qS80xB+hHfg== X-Gm-Gg: ASbGncui+84kXnQ7nYRSSZQlCZDEOpYcpoA9H8RfT4wdemaj0pz/m3pqZ0N5DN0/E9O Vr8ax4Awl2STft/i9qdLQokNhKlO/PSqXuC8gs9OBXexlwCbYhXX7mYUgvJcxITzaCKUgr5u0TD botsDaBKUITuevKHkbeScklT3Yhe1AOi+YU5o2O//wiuSLu6lwM/d58rAmNCLv59L260ecIGODi LQ2lPzuuKuGNRkG07iv/hy6fPujCm028hYI0tRWWd5yJY27NnNwb4E= X-Google-Smtp-Source: AGHT+IFJ41CkNcVYGIFsnjssiV1deK+mqGg5t2et7ElWjM6B6nSYdBn9PNbCm6u2S3+DDNgLRpHs0Q== X-Received: by 2002:a25:1ec2:0:b0:e4a:c0bb:7b25 with SMTP id 3f1490d57ef6-e54ee1daa87mr11389064276.41.1736781696005; Mon, 13 Jan 2025 07:21:36 -0800 (PST) Received: from localhost ([2a03:2880:25ff:8::]) by smtp.gmail.com with ESMTPSA id 3f1490d57ef6-e55be2487a3sm1590690276.45.2025.01.13.07.21.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 Jan 2025 07:21:35 -0800 (PST) From: Joshua Hahn To: Yosry Ahmed Cc: Johannes Weiner , Chengming Zhou , Andrew Morton , Nhat Pham , linux-kernel@vger.kernel.org, linux-mm@kvack.org, kernel-team@meta.com Subject: Re: [PATCH] mm/zswap: Remove zswap_pools_counter Date: Mon, 13 Jan 2025 07:21:29 -0800 Message-ID: <20250113152132.2372632-1-joshua.hahnjy@gmail.com> X-Mailer: git-send-email 2.43.5 In-Reply-To: References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Hi Yosry, I hope you've had a great start to 2025! (Is it too late to still be doing New Years greetings? : -)) On Fri, 10 Jan 2025 13:53:06 -0800 Yosry Ahmed wrote: > On Fri, Jan 10, 2025 at 12:33 PM Joshua Hahn wrote: > > > > Commit 8edc9c4 [1] reduced the number of pools used by zswap from 32 to 1. > > When referring to commits we use the first 12 characters in the SHA1 > and the commit subject, rather than the link (although adding the link > as well does not hurt). So this should be 'Commit 8edc9c4e72fe > ("mm/zswap: use only one pool in zswap")'. Thank you for letting me know. I grabbed the 6-character commit-ID from Github, but I'll be sure to include the first 12 characters instead in the future. > > As such, we no longer need to have unique names for zpool (zsmalloc). > > More importantly, I don't think this is accurate. zswap_pools_count > was introduced by commit 32a4e1690399 ("mm/zswap: provide unique zpool > name") long before we increased the number of concurrent zpools to 32. > It is needed because even though we used to have a single zpool per > zswap_pool (as we returned to doing after [1]), we may have multiple > zswap_pool's (e.g. if the compressor is changed, a new zswap_pool is > created). Ah, thank you for the correction. In retrospect, this was a bit of a naitve patch, it had completely passed my mind that we can still in fact have multiple pools at the same time. This could have been avoided if I had taken a look at where this code was introduced, rather than the patch that (I thought) removed the last users. Thank you for the review as always! Have a great day, Joshua