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 8DFA6C48BF6 for ; Thu, 29 Feb 2024 18:40:23 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id E86766B00A3; Thu, 29 Feb 2024 13:40:22 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id E36A06B00A4; Thu, 29 Feb 2024 13:40:22 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id CFD1B6B00A5; Thu, 29 Feb 2024 13:40:22 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0013.hostedemail.com [216.40.44.13]) by kanga.kvack.org (Postfix) with ESMTP id BDB1C6B00A3 for ; Thu, 29 Feb 2024 13:40:22 -0500 (EST) Received: from smtpin15.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay04.hostedemail.com (Postfix) with ESMTP id 8E7ED1A11F1 for ; Thu, 29 Feb 2024 18:40:22 +0000 (UTC) X-FDA: 81845706684.15.13D2BD7 Received: from sin.source.kernel.org (sin.source.kernel.org [145.40.73.55]) by imf13.hostedemail.com (Postfix) with ESMTP id 612FD20022 for ; Thu, 29 Feb 2024 18:40:19 +0000 (UTC) Authentication-Results: imf13.hostedemail.com; dkim=pass header.d=linux-foundation.org header.s=korg header.b=gZvtYW5R; spf=pass (imf13.hostedemail.com: domain of akpm@linux-foundation.org designates 145.40.73.55 as permitted sender) smtp.mailfrom=akpm@linux-foundation.org; dmarc=none ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1709232020; a=rsa-sha256; cv=none; b=xWo7EhBzon469VcTEZKjzsrKxzUlI/8IyuHF2T6lKqyfCp0uaiphkPQomsl+iOfpmPiJv4 QteauiRXcWl7+7SOVYDY/eZnOxkcvgP5kctCJcu+iK3LUKXOny59N5zELiUMD7vWx+yvF0 FoPDEOHftF8LWw1ril1ekVBsqX8e46c= ARC-Authentication-Results: i=1; imf13.hostedemail.com; dkim=pass header.d=linux-foundation.org header.s=korg header.b=gZvtYW5R; spf=pass (imf13.hostedemail.com: domain of akpm@linux-foundation.org designates 145.40.73.55 as permitted sender) smtp.mailfrom=akpm@linux-foundation.org; dmarc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1709232020; 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:in-reply-to:references:references:dkim-signature; bh=4W1E8EHWCM4qfZunAxGtwFfKYJHDus1Bf19FBUaX0Ec=; b=eggek7GEzt4A+pnK+KXG65dqEqWp+loT8MG3wVwmXpUiElaKOT/vjDfjKjwlG8Ys4ggzeb BA9EJ0fGbbolBCI9ebm6ghsq1nzebny+TNw3F4wlhRX9Geh4RPw8/C4QjudSnmAGE561bE HC+vE6a2qo/WPgguqV2U3y6Y9HTpQ0c= Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by sin.source.kernel.org (Postfix) with ESMTP id D05ADCE1A35; Thu, 29 Feb 2024 18:40:14 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id D8B82C433F1; Thu, 29 Feb 2024 18:40:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linux-foundation.org; s=korg; t=1709232014; bh=G39x9X/r8wD8EZNMCjKX99fVjL/JmQl3/uLDdbycsUw=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=gZvtYW5RjwYGvMOcS1OD4p/NBFNkCvv+69I/19wQJojZcno1nDd8S9x6ufT9/b74c hrtO5sy9ttg1Enx/clLC3kgJM+v4EpMSxjvvkSPcfJxrZTOqz8FNt52Fus1uBgV5hG wdx/0gzpkwkSj4llp4f4J9CYk6lUE4gu9noxwvvA= Date: Thu, 29 Feb 2024 10:40:13 -0800 From: Andrew Morton To: Hao Ge Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org, gehao618@163.com Subject: Re: [PATCH v2] mm/vmstat: Add order's information for extfrag_index and unusable_index Message-Id: <20240229104013.5ed8c1ca9c2dbd0bd5fb571f@linux-foundation.org> In-Reply-To: <20240229141443.99408-1-gehao@kylinos.cn> References: <20240229141443.99408-1-gehao@kylinos.cn> X-Mailer: Sylpheed 3.8.0beta1 (GTK+ 2.24.33; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Server: rspam08 X-Rspamd-Queue-Id: 612FD20022 X-Stat-Signature: kuk5rfsin64msc5mqstw3ash58893hiy X-Rspam-User: X-HE-Tag: 1709232019-546196 X-HE-Meta: U2FsdGVkX189DgjNzo4VkyWIEzP9qK0eEzk3tCvrgz9h78j+Pbec0AMns+2ulFPrj30EB7ph/qXr9WtOlfNMYDRf7qDvpLd3mkQOly5bo6QdX8+qt3iSvnnbdf6f86rqhhBPkwBcnUqUpDwOrv6EmdLv7F8/EZXpj0vPeVWmjTZM35oDPRHE/deeXZJYgmt7B2Ue9+6I8DkPLnu3Z3SxpYIHvsaeXBGS5eEN4ugiCL/7BoXfJ34xTF1iCwy2gOSFvFRarvxmj02YTqL73BIe679YNMnvCym2ovh8tagwzP37NEF9E7S2D0Wccrss9b/4u0H4sL5w4G7scFZqX5o759kL6VF1TYkkribkSDWk8684NUvoWrOrLCgjeRGP5GnKU1cyVJDbpzJTl7I4FPWpocpI9F+RqbTtQZUVIDd0ECktpFxLXBGN/kURBhjfgLD1lVjtBO/UPKlbVNjYK68vxGmewRvltS01JiLPTNd4Md1J9kfIsfPyhtOwisBwWfHwEoIawf7/eW/SFVsJxTW0yQ8b5W4uvKShN1SPQ+Jd4R/ITscjafxxzQvZMd0zLujrDi10K3GeyDWsZEjf95JqOjZIleqKzPf2aWhFDUc12FgCivN56YrTk8Ax6QQbHXK3YYFOe3f+RDQg2c3xFTVKm4SBi69dvdKfaWFt8v2AHKrp7ANVUa+kzHzO9FCJkAiCCBr6GxMn6sn2Lng6zTYaf4xyj8sbSXs4FRBtZFT7hUScB/nTXYjXxDcZmIO3B2k32u6i/Npyfsj+No7oc+o/gdSR2U6gV1arHndqbPBEIPXWf/I3OZnAjZanwdOpbmEf4GPatrhMgOsCrVmMDj/pTfSGZbZ+f2qYmHvlsyHHoE2RjqtNjS0tXIVtQkjSLR1KTAj01LFNsBfDxZgLdvucZjhYFc+G5y2xYCa5x61IhVdIozMDl2aLsxDXNU52Ye922t57SDz/eppe9VD7IMK jvccrVwf drBAI/8mIsB3z1Z7uP2iGpCOpe3TR9dkvPPjsiRuh27GkesGotSx6IJh7CpC+cXgXJETKZmSu0T9Mu1xFGVC6nIHUnwiTAkaISXokYL72H1mCACviIcW6zxpc/WbJyt4KEaGq8SeoPG7HTMi6P2lXb1UvxjwAKJNVMsJ4ZrGyHRF8atoB849raThb5HizYiJt/LwAe6XZJoTyGzvyIrdUwG++IrG5xEwiDUbybdgVfw076z05QsIN6cEsRkjIVTZc/91MPFrYnJiuMvG2qsgzu7OowQ== 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 Thu, 29 Feb 2024 22:14:43 +0800 Hao Ge wrote: > Current cat /sys/kernel/debug/extfrag/extfrag_index and > /sys/kernel/debug/extfrag/unusable_index is not friendly to userspace. > > We should add order's information so that users can clearly understand > the situation of each order at a glance like pagetypeinfo. > > before: > cat /sys/kernel/debug/extfrag/extfrag_index: > Node 0, zone DMA32 ...... ...... ...... ...... > Node 0, zone Normal ...... ...... ...... ...... > > cat /sys/kernel/debug/extfrag/unusable_index: > Node 0, zone DMA32 ..... ..... ..... ..... > Node 0, zone Normal ..... ..... ..... ..... > > after: > cat /sys/kernel/debug/extfrag/extfrag_index: > Extfrag index at order: 0 1 2 3 > Node 0, zone DMA ...... ...... ...... ...... > Node 0, zone Normal ...... ...... ...... ...... > > cat /sys/kernel/debug/extfrag/unusable_index: > Unusable index at order: 0 1 2 3 > Node 0, zone DMA ..... ..... ..... ..... > Node 0, zone Normal ..... ..... ..... ..... > This may break existing parsers of this file. And that would be allowed if these files were under debugfs. But they're under sysfs/debug, where the rules are less clear. Still, it's unclear to me that the benefit is worth this risk. What do others think?