From patchwork Fri Feb 23 03:55:43 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kefeng Wang X-Patchwork-Id: 13568549 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 B7FE7C48BC4 for ; Fri, 23 Feb 2024 03:56:07 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id EDEB36B0074; Thu, 22 Feb 2024 22:56:06 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id E8ED46B0078; Thu, 22 Feb 2024 22:56:06 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id D7DF96B007B; Thu, 22 Feb 2024 22:56:06 -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 C6E7C6B0074 for ; Thu, 22 Feb 2024 22:56:06 -0500 (EST) Received: from smtpin12.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay09.hostedemail.com (Postfix) with ESMTP id 73B7A80F57 for ; Fri, 23 Feb 2024 03:56:06 +0000 (UTC) X-FDA: 81821705532.12.B769269 Received: from szxga02-in.huawei.com (szxga02-in.huawei.com [45.249.212.188]) by imf25.hostedemail.com (Postfix) with ESMTP id 1BA3CA0003 for ; Fri, 23 Feb 2024 03:56:03 +0000 (UTC) Authentication-Results: imf25.hostedemail.com; dkim=none; spf=pass (imf25.hostedemail.com: domain of wangkefeng.wang@huawei.com designates 45.249.212.188 as permitted sender) smtp.mailfrom=wangkefeng.wang@huawei.com; dmarc=pass (policy=quarantine) header.from=huawei.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1708660565; 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-type: content-transfer-encoding:content-transfer-encoding:in-reply-to: references; bh=9yDEpRlZD17+rx31p4P/bUMSpVB2+16VOvDhZKg4n98=; b=rBEtwLuW4TPbtTskkieKfMwOvf9OpOOCJdsroxpYO6ORx7DPZG1H2dAk2KNd/TBb1WH0Nm RzMGAlJFv7be89vBa7AvUHzlbU/PXBICcQopY6ST6a2c4gjm/UWuvMDk3HWU1CByQ7puV7 u9OAiXE8sD06KPa0eADaRTaG+V1e/GY= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1708660565; a=rsa-sha256; cv=none; b=HF4pUMR1bSgrX9LaoWWHmZjJbJAahHOGWH/fsYr2woPPpWEQcogC5BjZv/XY/ndoVD/XR7 UhpZM+VGb/HFjpNXCcGqBnmoR/icvnYMfVQf8UWZ6E1PtaApThTla1mRnkT3N8WrKzrP1c qkNK9lY6vN1R+fPh/3w/eXv2W8r32Io= ARC-Authentication-Results: i=1; imf25.hostedemail.com; dkim=none; spf=pass (imf25.hostedemail.com: domain of wangkefeng.wang@huawei.com designates 45.249.212.188 as permitted sender) smtp.mailfrom=wangkefeng.wang@huawei.com; dmarc=pass (policy=quarantine) header.from=huawei.com Received: from mail.maildlp.com (unknown [172.19.163.174]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4Tgx2f6rlfzXhG2; Fri, 23 Feb 2024 11:54:02 +0800 (CST) Received: from dggpemm100001.china.huawei.com (unknown [7.185.36.93]) by mail.maildlp.com (Postfix) with ESMTPS id 006391400CA; Fri, 23 Feb 2024 11:56:00 +0800 (CST) Received: from localhost.localdomain (10.175.112.125) by dggpemm100001.china.huawei.com (7.185.36.93) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.35; Fri, 23 Feb 2024 11:55:59 +0800 From: Kefeng Wang To: Johannes Weiner , Yosry Ahmed , Nhat Pham , Andrew Morton CC: Chengming Zhou , Huacai Chen , Minchan Kim , Sergey Senozhatsky , , , Kefeng Wang Subject: [PATCH 0/5] mm: unify default compressor algorithm for zram/zswap Date: Fri, 23 Feb 2024 11:55:43 +0800 Message-ID: <20240223035548.2591882-1-wangkefeng.wang@huawei.com> X-Mailer: git-send-email 2.27.0 MIME-Version: 1.0 X-Originating-IP: [10.175.112.125] X-ClientProxiedBy: dggems702-chm.china.huawei.com (10.3.19.179) To dggpemm100001.china.huawei.com (7.185.36.93) X-Rspamd-Queue-Id: 1BA3CA0003 X-Rspam-User: X-Stat-Signature: dfsoqae4o7mewpzc11w7og39ep5xxpe9 X-Rspamd-Server: rspam03 X-HE-Tag: 1708660563-140254 X-HE-Meta: U2FsdGVkX18XpeDj1PBpIgw4UmZ3LoZ1T9hwIBoR4Ty4z7lSdP+iN7aR+fiyvyhdaIBd+ViizsEz+P6QqNryhhXdRFNgJWhvltySKJEYQmmwRq9eduPt9NG3ob96EKZIwiqqfo50KlseDY1AKGLjzLyHBi4KdPwm7kjyYqiLPB0Mf4DFqVNtP1OYQrwx3Jva/T35dOTOJhZsUGIPNs12gIKU/30ahhvw3IqYsqDRQobh/CFuUVbDbh8F8Nx/S/PhNuhzZRX/e6n4RtI0IFbsX949H9/fCxGA9YQKlEqvZsMXM79N8HEsKj8PbDVliXPSRAJRKECEXPjtlfFk/xlBq/U6XndsJPcvkvy53E+sKHHq1LsJUI9fdItMZLixjR8bsnm0J7cUCX72aAt4vkn3GmGfsj3ISy0JYZcBwnYc2i2mTP5fnNQc+SNrlwbk6HTWl8aNkG3jGJcW5cUdEyYm86Qnw7BFqQJJ1DbFW3azaZKL8Koz+sHB2QfLcPdSSCmD6HIkOvf0kMIS9+enw1vhO/VD8guQCb6eDgNXvBZPN3d0+0CQV5cIuMQdcFsQPuT0zZPtCPoSVNLuLxByyqvch2xllkBaWtB9XjFY+LMnJPEZqSdhgzula6lIuGWtrx2dl9XMGgV0PlINV2a/0pq1c2xAn1VrhL6IJ7Hh9DL9NTAx3FpvLUeVlDlyLBPPOVWpz97/oXfPLfYYdfEUnkogRG+HrLJdMzLmitoiSBPUUpHyVMcwMLakLpaPVZI5umRdJiT4nY3LGZuF5woBxVmQGllYkJwhQgDzvjTLJbLKeSzAxu1C19SIF+/9VyFa1T2KCPYMq8y/Puvv86rNtVFzimg2Mqt9ycAO X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: Both zram and zswap are used to reduce memory usage by compressing cold page, a default compressor algorithm is selected from kinds of compressor algorithm as the default one from very similar Kconfig, also both of them could change the algorithm by sysfs interfaces, so unify the default compressor algorithm to cleanup the default algorithm chosen. Kefeng Wang (5): zram: zcomp: remove zcomp_set_max_streams() declaration zram: make zram depends on SWAP zram: support deflate compressor mm: zswap: default to lzo-rle instead of lzo mm: unify default compressor algorithm for zswap and zram Documentation/admin-guide/mm/zswap.rst | 2 +- arch/loongarch/configs/loongson3_defconfig | 2 +- drivers/block/zram/Kconfig | 44 +------ drivers/block/zram/zcomp.c | 3 + drivers/block/zram/zcomp.h | 1 - drivers/block/zram/zram_drv.c | 2 +- mm/Kconfig | 134 +++++++++++---------- mm/zswap.c | 8 +- 8 files changed, 83 insertions(+), 113 deletions(-)