From mboxrd@z Thu Jan 1 00:00:00 1970 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 3D50BC19F32 for ; Wed, 5 Mar 2025 18:58:02 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id F17F96B0085; Wed, 5 Mar 2025 13:58:00 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id EC5B26B0088; Wed, 5 Mar 2025 13:58:00 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id DB5BD6B0089; Wed, 5 Mar 2025 13:58:00 -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 BE7436B0085 for ; Wed, 5 Mar 2025 13:58:00 -0500 (EST) Received: from smtpin23.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay05.hostedemail.com (Postfix) with ESMTP id 41BF3555C1 for ; Wed, 5 Mar 2025 18:58:01 +0000 (UTC) X-FDA: 83188407162.23.4F0C4E8 Received: from out-189.mta0.migadu.com (out-189.mta0.migadu.com [91.218.175.189]) by imf17.hostedemail.com (Postfix) with ESMTP id 5517F4000F for ; Wed, 5 Mar 2025 18:57:59 +0000 (UTC) Authentication-Results: imf17.hostedemail.com; dkim=pass header.d=linux.dev header.s=key1 header.b=BA7f1aSp; spf=pass (imf17.hostedemail.com: domain of yosry.ahmed@linux.dev designates 91.218.175.189 as permitted sender) smtp.mailfrom=yosry.ahmed@linux.dev; dmarc=pass (policy=none) header.from=linux.dev ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1741201079; 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: in-reply-to:in-reply-to:references:references:dkim-signature; bh=F/pxQm/GTBuWXpkm2E2xQcWdXz+nSd25BI4v2m4VQII=; b=vk5iI1cAQPygJzTz2I0w2juYnbnFxXZYSusmDUUcp619wHBMOIcaSaC57gvmQi53mQZwi+ 54noT5fsLWv/AuW1jcW3vKjwi2BB3jamwpR4CBsXYNsJSQL6mC3rXCfzARtbu79x2BjL3f 658X+tlEfkiIzMHLEUvOFP+vJ4CIjk0= ARC-Authentication-Results: i=1; imf17.hostedemail.com; dkim=pass header.d=linux.dev header.s=key1 header.b=BA7f1aSp; spf=pass (imf17.hostedemail.com: domain of yosry.ahmed@linux.dev designates 91.218.175.189 as permitted sender) smtp.mailfrom=yosry.ahmed@linux.dev; dmarc=pass (policy=none) header.from=linux.dev ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1741201079; a=rsa-sha256; cv=none; b=bhf9QhwhdPhJymv46UqMyDRaEoYwcdbojzdoeXxyK1/j58tKqlH6fvaFMY2zgfG3vyI7Na X9GuLlYz1FMHKFyamFRng/zfHA1ukdzCPc8HJwDed9J2qUKpvmqi0vTmEkmMGJUrkTvL/7 cHSbrkwnFVLnTnH6a4bcFWO9eddyKFQ= Date: Wed, 5 Mar 2025 18:57:51 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1741201076; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=F/pxQm/GTBuWXpkm2E2xQcWdXz+nSd25BI4v2m4VQII=; b=BA7f1aSpTqg4jihYzqWbOuaiN1vbMeL48KwQWXuCr26ejsbyzTYLvQ5r5aK2xqWVXlNur8 cM99aKZuBVUNL8WUOBfMoDgbUSc/MFgvxsUoFmnFYeyydtSSwJxFfXKV1QppPCzAYF5R3c 793wFHEsYCw2ioZMzk41wnVvEtFM0ys= X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Yosry Ahmed To: Andrew Morton Cc: Johannes Weiner , Nhat Pham , Chengming Zhou , Minchan Kim , Sergey Senozhatsky , Herbert Xu , Thomas Gleixner , Peter Zijlstra , linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH mm-unstable 4/5] mm: zsmalloc: Remove object mapping APIs and per-CPU map areas Message-ID: References: <20250305061134.4105762-1-yosry.ahmed@linux.dev> <20250305061134.4105762-5-yosry.ahmed@linux.dev> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20250305061134.4105762-5-yosry.ahmed@linux.dev> X-Migadu-Flow: FLOW_OUT X-Rspam-User: X-Rspamd-Server: rspam10 X-Rspamd-Queue-Id: 5517F4000F X-Stat-Signature: 8cpwb8c1iqf7mi5t87i8ttkj7bp3axg1 X-HE-Tag: 1741201079-209265 X-HE-Meta: U2FsdGVkX1+YOGE/LPHxsCOjuINIhFTvyHat/xYq5KwQHk0mu8qDdIBa4qt6BYZlFmfNbfBje22HmH70xPWVHHAbLYNHapd7hrPV0e3AK4NuSJEd1cLUeCLBX4VGNAKwmjy2kfMrWSRNdxJRWoOBZ1Eq+FrQtnvphTxI/TcfAz5S+RbgmQ5W1vaVCNvztRTC4JaNZ5P+bzHPAKZH16oqPVjw+Px3vFJYCYlBaP+WR5fKV3VfHXPmgcNCWPeFL/3F0K0nq91o4eW0roXJ1/UZBo1eClxQIn22DIwjgi6PaqLHzuDu3sYpUJQUxQ3DxJOokCk4dWgsfq/nH45yj/TMmouLAW3DnwjsX78jpmxIAR+0bLEg6siw2Uhc84Lq+35SFaLbEgQg4Xl1y+stO4m2U1FfwKhI0VYRsezBv86PydMyCfIf0gP16d52pU+qecgAlLNguws/INaE9rRxnRTQqQ4LcBKCRist8fFyLaahbhrfcHXeSxkEXhv7vNbY333bHj5w1WmCS29mCDAI3lFYkOip5cxqxIEZFlmvXMhlziDc9QKLoUYgBECsfbAdOwSx/bct6/aEihthOXAQDjAaVHUYQ8lT84vvClLdHZ2sq0GhaKGh9VMmuPbQqriBaNikXA0CGfVmN7AHCAOX6fCw1kNiEArSPVRnt0DsXEkoi+bb8Uw/8TTW+mC3qQFGB4bnuHZf8NF0HT9+ktWN1HJQgsItanG8cw3p6/avk3CZ7uf3BXbj1x2/f6Qst651dCgwhsVxFyWO3tiwMaStqgMUVrOvXMxPRN8uVuNYsH6q0JSG8b7MfUCWgAn6rZ5v/BPXf/rGfgq7SgxBEO8+udhYFfX7rXRIs8+Yah5M5i8lfL7d9qlV57SzYQdkZ4rW8mcnnPEIBYRBbEvIF+MM9yvLghZraWM1e09adRAoW6fAripXedyk4SEUj9aHssEejOtedhMaD5PMnZ5idlM6Ejq 8wAizCIw WOCbzQnFCei/epKv2BrZpH6SSQ0F2CbN7YWwaLl/rEV++iMn4wOZNy7HVdlLyBt3MTllsmM88SP1SruyZCliWYk0dEMwW7rMFRqMIwoQdIR5XVjck7w3z1yJajIcJ8VtJvYuUVnMVWb+Knje2fJJs5ctR1flO3HpvQFJLacCms3Z35QlxoAP+1Q1yLOeUoLyYs9/SZvoWOvk7uLsTZUnK/Roi7Q== 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: On Wed, Mar 05, 2025 at 06:11:32AM +0000, Yosry Ahmed wrote: > zs_map_object() and zs_unmap_object() are no longer used, remove them. > Since these are the only users of per-CPU mapping_areas, remove them and > the associated CPU hotplug callbacks too. > > Signed-off-by: Yosry Ahmed > --- > include/linux/cpuhotplug.h | 1 - > include/linux/zsmalloc.h | 21 ---- > mm/zsmalloc.c | 226 +------------------------------------ > 3 files changed, 1 insertion(+), 247 deletions(-) I missed updating the docs. Andrew, could you please squash the following diff in? I intentionally did not state the name of the new APIs to avoid needing to update the docs with similar changes in the future: diff --git a/Documentation/mm/zsmalloc.rst b/Documentation/mm/zsmalloc.rst index 76902835e68e9..d2bbecd78e146 100644 --- a/Documentation/mm/zsmalloc.rst +++ b/Documentation/mm/zsmalloc.rst @@ -27,9 +27,8 @@ Instead, it returns an opaque handle (unsigned long) which encodes actual location of the allocated object. The reason for this indirection is that zsmalloc does not keep zspages permanently mapped since that would cause issues on 32-bit systems where the VA region for kernel space mappings -is very small. So, before using the allocating memory, the object has to -be mapped using zs_map_object() to get a usable pointer and subsequently -unmapped using zs_unmap_object(). +is very small. So, using the allocated memory should be done through the +proper handle-based APIs. stat ====