Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp3006228yba; Mon, 22 Apr 2019 17:39:50 -0700 (PDT) X-Google-Smtp-Source: APXvYqy/E6ccpJ31CiyC+Q5JHi9VCfuq+RCB6PnitKBs5yDkrBdQQXicWQm9HddW7PsboEEolDSv X-Received: by 2002:a17:902:9a4c:: with SMTP id x12mr23100217plv.90.1555979990265; Mon, 22 Apr 2019 17:39:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1555979990; cv=none; d=google.com; s=arc-20160816; b=mdzVDbIYJPIqnSwOcsy/b1uDN2ZjRsGyKUc1w0OXZbtFFHICilbuwx1PoiUiPqsYG+ CdBKXRDtBe1xZDJryVY2yRdKYsfdUTBLiqqWT64TBIUQpxEssu4MndYDwvxUXoYXO9mm KDiP+lWuOcfXkbSwENYRFycJBz2TqwjFAiyrATFuHWqDudYPsJIOAPJmPaqg3GgGkCN2 8707PbwEs4fm27hx/Cs7GN290GNaakTtLpwwqIyo8RSuQ6qhA80LassTjeH+ak9bIGMu Q+2tOo/3zkgGwVdjP6k0VYa/nLbyOawNKtKIv1zK+uYjW5SQfePUtkhb4YBYc1F68hGw gh3w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:date:user-agent:message-id:to:subject :from:cc:references:in-reply-to:content-transfer-encoding :mime-version:dkim-signature; bh=/TMWryAnEXI6CDJHRuLnviBpCsojlHJyVM/ETHDow8c=; b=nO9SZfpP7YhRpY+P1VGC7DktY3+oAEEMttWhBRYGcIt3lSMEJ8GgkbAbKOMXi+jNu+ 3ZoVUOOexwOuS/T2Uljc2oIgAVcHS4/UvXZRUKSarKa2u/FK5tRxkdiumTOIZcCPCqUI z7i5MW2Uwnw9t3BIj1EnLhlEsNZvWlwUwQ2Pw/MSO5iPbqQPvUYiyPFq0VPRtveJvoj7 Y2CUxGaUCvyaqb+4bqJemcmNzHMkc5JwJrCEQB2ImpbqmGWM6cysIBtz+BmohbzdrDER j37jSH42PEMHXqunWBxcpVcOTfXG6T3jJW+AkzEGNO3ivEPrkje1CN1kJmSkUPBsWyXU 2Sfw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=nNs0xAvs; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id k16si13563789pgb.587.2019.04.22.17.39.35; Mon, 22 Apr 2019 17:39:50 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=nNs0xAvs; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729064AbfDVUWE (ORCPT + 99 others); Mon, 22 Apr 2019 16:22:04 -0400 Received: from mail.kernel.org ([198.145.29.99]:44858 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727190AbfDVUWD (ORCPT ); Mon, 22 Apr 2019 16:22:03 -0400 Received: from localhost (unknown [104.132.0.74]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 74B4B20693; Mon, 22 Apr 2019 20:22:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1555964522; bh=8SDBOoU6iDWbmlGqsA0QIbropWgQ0wcQuI8T2DvImZM=; h=In-Reply-To:References:Cc:From:Subject:To:Date:From; b=nNs0xAvsVfVUdsyEhBpsZvn6qrlUBnBWPfwUKGBDokBXdLoqU3ypNNlZ+06tCbGVN wWG2MbqgsmgBBfD2CKOfJwmji9j91JI94G2P0cxDOY6KBw2N0U7dvRO7ZJgPDF9KVn OSb8yj9ws0agEv8fBOdZhyL+isHYfpOkbMgXkn1s= Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable In-Reply-To: References: Cc: Andrew Morton , "linux-kernel@vger.kernel.org" From: Stephen Boyd Subject: Re: [PATCH 2/3] scripts/gdb: Initial clk support: lx-clk-summary To: Jan Kiszka , Kieran Bingham , Leonard Crestez Message-ID: <155596452161.15276.15842111427229300135@swboyd.mtv.corp.google.com> User-Agent: alot/0.8 Date: Mon, 22 Apr 2019 13:22:01 -0700 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Quoting Leonard Crestez (2019-04-22 01:26:57) > + > + > +class LxClkSummary(gdb.Command): > + """Print Linux kernel log buffer.""" This comment needs an update. > + > + def __init__(self): > + super(LxClkSummary, self).__init__("lx-clk-summary", gdb.COMMAND= _DATA) > + > + def show_subtree(self, clk, level): > + gdb.write("%*s%-*s %7d %8d %8d\n" % ( > + level * 3 + 1, "", > + 30 - level * 3, > + clk['name'].string(), > + clk['enable_count'], > + clk['prepare_count'], > + clk['protect_count'])) Would be nice to also print the rate, phase, etc. It's all pretty much there already so it's just dumping data out. If it's a clk that has CLK_GET_RATE_NOCACHE then I guess we have to print out '' because it relies on runtime code execution. > + > + for child in clk_core_for_each_child(clk['children']): > + self.show_subtree(child, level + 1)