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 7B56CC282C5 for ; Fri, 28 Feb 2025 22:50:18 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 96AD2280002; Fri, 28 Feb 2025 17:50:17 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 91A5B280001; Fri, 28 Feb 2025 17:50:17 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 7E20F280002; Fri, 28 Feb 2025 17:50:17 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0010.hostedemail.com [216.40.44.10]) by kanga.kvack.org (Postfix) with ESMTP id 5F530280001 for ; Fri, 28 Feb 2025 17:50:17 -0500 (EST) Received: from smtpin02.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay05.hostedemail.com (Postfix) with ESMTP id BA2FF51046 for ; Fri, 28 Feb 2025 22:50:16 +0000 (UTC) X-FDA: 83170848432.02.90564CD Received: from tor.source.kernel.org (tor.source.kernel.org [172.105.4.254]) by imf11.hostedemail.com (Postfix) with ESMTP id 1DCA94000B for ; Fri, 28 Feb 2025 22:50:14 +0000 (UTC) Authentication-Results: imf11.hostedemail.com; dkim=none; dmarc=none; spf=pass (imf11.hostedemail.com: domain of "SRS0=QpPI=VT=goodmis.org=rostedt@kernel.org" designates 172.105.4.254 as permitted sender) smtp.mailfrom="SRS0=QpPI=VT=goodmis.org=rostedt@kernel.org" ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1740783015; a=rsa-sha256; cv=none; b=pQaN2bcRaajd87WNRfS7hxm6RZ/zQTeu7sdOHcEYXkVQ2/mHW90lhOIXe9FPbbn+Zz3wIw BQZJ3D8DcbXuKpt+NTOLIwmdx3oYf+cQ6IBW0jEiK8qgWX/RC/UBgdeFaAAC0Unfw1bOM8 W+tdPyCAmSNktA30hmIKH72T8i4DMGg= ARC-Authentication-Results: i=1; imf11.hostedemail.com; dkim=none; dmarc=none; spf=pass (imf11.hostedemail.com: domain of "SRS0=QpPI=VT=goodmis.org=rostedt@kernel.org" designates 172.105.4.254 as permitted sender) smtp.mailfrom="SRS0=QpPI=VT=goodmis.org=rostedt@kernel.org" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1740783015; 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; bh=rp09kD99uGSQWQqSv/ewh4te2CIkhzCqKmYD0EXUflU=; b=vHtPrWzaCLWj1DkNzgi75drj18YttGFVNo35KSgtpemVj+iCOjJeTZ6DI9uoBjEiPxLjFW hQ7qYbOSbyQX0qSUm0CFSfjfplp0PihZNTWxfNPBedlmKwTdJa+s6AXkMtFhV6Wo50tru8 ojUhfM5Y5qGgVfxk7hK0Qno2nTS7MUU= Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by tor.source.kernel.org (Postfix) with ESMTP id E5BE061160; Fri, 28 Feb 2025 22:50:05 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 1873AC4CED6; Fri, 28 Feb 2025 22:50:13 +0000 (UTC) Date: Fri, 28 Feb 2025 17:50:58 -0500 From: Steven Rostedt To: LKML , Linux Trace Kernel , linux-mm@kvack.org Cc: Masami Hiramatsu , Mathieu Desnoyers , Andrew Morton , Michael Petlan , Veronika Molnarova , Suren Baghdasaryan , Linus Torvalds Subject: Re: [RESEND][PATCH] tracing: gfp: Remove duplication of recording GFP flags Message-ID: <20250228175058.28db2b08@gandalf.local.home> In-Reply-To: <20250225135611.1942b65c@gandalf.local.home> References: <20250225135611.1942b65c@gandalf.local.home> X-Mailer: Claws Mail 3.20.0git84 (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: 1DCA94000B X-Stat-Signature: 6m3aasmn6m59qqfzh1uw1suqbarx6npu X-Rspam-User: X-HE-Tag: 1740783014-556720 X-HE-Meta: U2FsdGVkX1/hdHfVjAWaq1SD6JVhdahhyOxrIPyv2uWNYAzK/FGFaQCJuGYNNFnN4DfNerTG89/xAAfJ8bQd4vFnyYMQ7yghuYbOK/9TsZ/9jkTsmvLWEYLCJSBHBnXj9rOe10MrdGbFak5DvpD0V5jX4fAqKqJpTCKNodzmtTE9PJuviJULq6fyU25MK6DV5PMHQ1lsn5yT4qfWgzNC/24shtPMBR9Ge7zaqeNZCw47weFqIf6WPYfdB5kHb48OpvTDSIWsEnWPyMcruQ/PLT5Wp+iS1VWpbCJMw3YfdgR8okJvjowshL5LdvNqIVQJLMn41O1kukA4yzZxGa6G86pFb8tRfwjQz7kOv8wSXWNbULVtk0mcxViHRijDYkKx1OdepxTOf+NJSHK7MZIfEfBvjXroVc5vJE4oe0xaQSVd93ulSbhLEgLoD4ibZDK/NrOCXZ2oW932fUQRrQheBn+LuAOvcWZRC+5G8mApj2+lS2ROGkVk5qPB6YQ0M4fhUumxF2ME84NdcTXwTLy/KdQMykZ3iB/kYCP73/ZQ33Jvxr5vvrV4kJxS/4FREBY570o8hJqChnPu8qOyN6QyxBGkGxh2iFvI+8OOcdbHQwzKxBRWvwBFKWYJvghj2tZ4jyVTWd8crPtoq06mgajTJT20qhKUxfDOTxMSGmvAB23RYSBgy1Cbu6fKT77lNCrHUyn3Ju3+AmSAs1ZRVsbmUoxQLawU7xMkov6+mSoj0S8v0edeseeGxVcGYVRopGOmUnK46k2ookDvcDR7zm9z07ifBVd2DOZss9M16RnNEu4cWKiYwfgiKqHRyKJYDZewdWcsNCQB4LQevUTAx9/WtGZqbA9ymZL/gQ73iadOo2fhB0JbegcQTxTENg6DEyJIDS7nXRib/VdhNoZ5F2oG8D8eJ3avyv8i5dibPBGG/vDhs38rshwFWZd8mI0Q/v6ITaAuyRDWOhsQEJRwDd/ eoiN3U74 0MqMkg3v0iBNvBwMrHQ+KrZ7tZ/pKPz+5hi0hhiZRgKlFtZ98xSrdHGL9nLl9waTjQx/iPNVEM3Y0I2Jaf/Sc0Bs7trgpLwGdgcjG6xUlhKadq1MhfxNF0BMgqG1PbKVnS/mhvh8xdHtnDb4XkPh4aB6PoFV5AF814wPwUA7pOx3C5zBbvrJduh+i9FbdsM6psJKCwy4v43cfyNyA2AWOJBMbuY/bST2g/ne0LFfqldbCzYy6uMuSmfmEQUf/Y3cvp/kiKvfIwQ/HpeXFYHj9KpeV1/1RHbjVslVby8PpRAVxV3024dLvnfEQ8Q== 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: Since I hear only crickets on this. I'm going to apply it and push it to linux-next and see if anyone notices. It only affects the output of the memory trace events. -- Steve On Tue, 25 Feb 2025 13:56:11 -0500 Steven Rostedt wrote: > From: Steven Rostedt > > The gfp_flags when recorded in the trace require being converted from > their numbers to values. Various macros are used to help facilitate this, > but there's two sets of macros that need to keep track of the same GFP > flags to stay in sync. > > Commit 60295b944ff68 ("tracing: gfp: Fix the GFP enum values shown for > user space tracing tools") added a TRACE_GFP_FLAGS macro that holds the > enum ___GFP_*_BIT defined bits, and creates the TRACE_DEFINE_ENUM() > wrapper around them. > > The __def_gfpflag_names() macro creates the mapping of various flags or > multiple flags to give them human readable names via the __print_flags() > tracing helper macro. > > As the TRACE_GFP_FLAGS is a subset of the __def_gfpflags_names(), it can > be used to cover the individual bit names, by redefining the internal > macro TRACE_GFP_EM(): > > #undef TRACE_GFP_EM > #define TRACE_GFP_EM(a) gfpflag_string(__GFP_##a), > > This will remove the bits that are duplicate between the two macros. If a > new bit is created, only the TRACE_GFP_FLAGS needs to be updated and that > will also update the __def_gfpflags_names() macro. > > Signed-off-by: Steven Rostedt (Google)