Received: by 2002:a05:7412:d8a:b0:e2:908c:2ebd with SMTP id b10csp1161799rdg; Fri, 13 Oct 2023 12:05:10 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGyA+mANKUPEhDqeIa2JRJA4R5KAVhRwdhUNKDaaMQKKjqbcINN9k9QBH4qqkuO/49TtNHe X-Received: by 2002:a05:6a20:4423:b0:15e:71c9:7d47 with SMTP id ce35-20020a056a20442300b0015e71c97d47mr33725530pzb.26.1697223910152; Fri, 13 Oct 2023 12:05:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697223910; cv=none; d=google.com; s=arc-20160816; b=MVEe/ZGnQhq3NXTw0/LFd7huD+E4uGB5wTf7ps2BROc1xTa/CrmpssR0K1+Ys8y2S/ qo7TKpOcigCibjzNCrNwCDvZ+F53mHGhtXhM3ETuJAbHsxcp6GwJgn/W7f3F03PuOX4b NCVrfhQ3ANS0MtBJtQxX582ZBt5DKnJs7H9cwhcfl+j1mFqIIzQ+8BaxP+bSosC2nblj X3AaGhL15s3RSHQLicBYlg39dr3HXCCmr9dTpgVgChDQ64++WbFjAv8v3CijX+TCfU9O QD+Cmt1NwKXR7RsAfS3rzqaFhjjpCBnVFdg2NUxJUUj7JH5gT/XnRVVgCqnrdASQC525 Rgyw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=4XvnTft2MmJ8VY609+be7Cy1Q085UedMhCWzkSGYTRU=; fh=YslCjvlXkGsdmqLq8rTUMG5flN38yHruc56T4Q8Q6OI=; b=leqkQuC96wsNa+xkXsx16F/GYZGkdpDCG9cskqMwCMvi8SL78d+staiLu69kkigM2E to2ukWlMNjAYWXVky89crdPhfNat7iXzM93pR6d5LBpLaoaW+V4KaHn08jnYMJE6PjcN vF+YwKL+CPVxgebv0vgKdG/NC7BKZq8F+iu8y7cLJ8CzLJu9cvYnIGCqEzJbJrbc3pFI NKGqkD/Fipb/ikp8j1+L7pNg6qBQiTiv5bBER0M8i6hgjuoGesp9fX9ACdM4tOYh8zyu H1KtI9XMyHK518CA16f/gwCYLhp+CUir3/Z8Q1emfDc7MJPoXqvxSWtpT4rsOawN7Q61 in4w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=TBtcE9QH; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from lipwig.vger.email (lipwig.vger.email. [23.128.96.33]) by mx.google.com with ESMTPS id i135-20020a639d8d000000b00578d0b680a8si5148591pgd.824.2023.10.13.12.05.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 13 Oct 2023 12:05:10 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) client-ip=23.128.96.33; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=TBtcE9QH; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id D7AA182B8A94; Fri, 13 Oct 2023 12:05:05 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231336AbjJMTE4 (ORCPT + 99 others); Fri, 13 Oct 2023 15:04:56 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38408 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229518AbjJMTEz (ORCPT ); Fri, 13 Oct 2023 15:04:55 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 79F3DA9 for ; Fri, 13 Oct 2023 12:04:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1697223851; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=4XvnTft2MmJ8VY609+be7Cy1Q085UedMhCWzkSGYTRU=; b=TBtcE9QH46JvR4poJuijN3KH005HjZnmH6Yil2GQTMKAAt+yMJBG8hJSunHnWgpc9atTxk k0UMwY6uClBge74NH9BwJvq8FSBOzPlhzZrLVZdUlvNQIfUCZMZ7I7UYqGCe00LtDlUdQm WYhxVCbaGsItWBjPHhiyjND/WaYuby8= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-447-eVID_ZQ_N8aIESBG-T1o-A-1; Fri, 13 Oct 2023 15:04:07 -0400 X-MC-Unique: eVID_ZQ_N8aIESBG-T1o-A-1 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 1D0CC801E62; Fri, 13 Oct 2023 19:04:07 +0000 (UTC) Received: from fedora.redhat.com (unknown [10.22.33.110]) by smtp.corp.redhat.com (Postfix) with ESMTP id D69472157F5A; Fri, 13 Oct 2023 19:04:06 +0000 (UTC) From: Audra Mitchell To: linux-mm@kvack.org Cc: raquini@redhat.com, akpm@linux-foundation.org, djakov@kernel.org, vbabka@suse.cz, linux-kernel@vger.kernel.org Subject: [PATCH 5/5] tools/mm: Update the usage output to be more organized Date: Fri, 13 Oct 2023 15:03:49 -0400 Message-ID: <20231013190350.579407-6-audra@redhat.com> In-Reply-To: <20231013190350.579407-1-audra@redhat.com> References: <20231013190350.579407-1-audra@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 3.1 on 10.11.54.6 X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lipwig.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (lipwig.vger.email [0.0.0.0]); Fri, 13 Oct 2023 12:05:06 -0700 (PDT) Organize the usage options alphabetically and improve the description of some options. Also separate the more complicated cull options from the single use compare options. Signed-off-by: Audra Mitchell --- tools/mm/page_owner_sort.c | 33 ++++++++++++++++++++------------- 1 file changed, 20 insertions(+), 13 deletions(-) diff --git a/tools/mm/page_owner_sort.c b/tools/mm/page_owner_sort.c index 5a260096ebaa..e1f264444342 100644 --- a/tools/mm/page_owner_sort.c +++ b/tools/mm/page_owner_sort.c @@ -634,19 +634,26 @@ static void print_allocator(FILE *out, int allocator) static void usage(void) { printf("Usage: ./page_owner_sort [OPTIONS] \n" - "-m\t\tSort by total memory.\n" - "-s\t\tSort by the stack trace.\n" - "-t\t\tSort by times (default).\n" - "-p\t\tSort by pid.\n" - "-P\t\tSort by tgid.\n" - "-n\t\tSort by task command name.\n" - "-a\t\tSort by memory allocate time.\n" - "-d\t\tPrint debug information.\n" - "--pid \tSelect by pid. This selects the information of blocks whose process ID numbers appear in .\n" - "--tgid \tSelect by tgid. This selects the information of blocks whose Thread Group ID numbers appear in .\n" - "--name \n\t\tSelect by command name. This selects the information of blocks whose command name appears in .\n" - "--cull \tCull by user-defined rules. is a single argument in the form of a comma-separated list with some common fields predefined\n" - "--sort \tSpecify sort order as: [+|-]key[,[+|-]key[,...]]\n" + "-a\t\t\tSort by memory allocation time.\n" + "-m\t\t\tSort by total memory.\n" + "-n\t\t\tSort by task command name.\n" + "-p\t\t\tSort by pid.\n" + "-P\t\t\tSort by tgid.\n" + "-s\t\t\tSort by the stacktrace.\n" + "-t\t\t\tSort by number of times record is seen (default).\n\n" + "--pid \t\tSelect by pid. This selects the information" + " of\n\t\t\tblocks whose process ID numbers appear in .\n" + "--tgid \tSelect by tgid. This selects the information" + " of\n\t\t\tblocks whose Thread Group ID numbers appear in " + ".\n" + "--name \tSelect by command name. This selects the" + " information\n\t\t\tof blocks whose command name appears in" + " .\n" + "--cull \t\tCull by user-defined rules. is a " + "single\n\t\t\targument in the form of a comma-separated list " + "with some\n\t\t\tcommon fields predefined (pid, tgid, comm, " + "stacktrace, allocator)\n" + "--sort \t\tSpecify sort order as: [+|-]key[,[+|-]key[,...]]\n" ); } -- 2.41.0