From: Will Deacon <will@kernel.org>
To: Palmer Dabbelt <palmer@dabbelt.com>
Cc: Atish Patra <atishp@rivosinc.com>,
mark.rutland@arm.com, linux-kernel@vger.kernel.org,
anup.patel@wdc.com, david.abdurachmanov@sifive.com,
devicetree@vger.kernel.org, greentime.hu@sifive.com,
guoren@linux.alibaba.com, xypron.glpk@gmx.de, corbet@lwn.net,
linux-doc@vger.kernel.org, linux-perf-users@vger.kernel.org,
linux-riscv@lists.infradead.org, mick@ics.forth.gr,
Paul Walmsley <paul.walmsley@sifive.com>,
robh+dt@kernel.org, vincent.chen@sifive.com
Subject: Re: [v4 00/11] Improve RISC-V Perf support using SBI PMU and sscofpmf extension
Date: Tue, 14 Dec 2021 18:09:15 +0000 [thread overview]
Message-ID: <20211214180915.GA15780@willie-the-truck> (raw)
In-Reply-To: <mhng-b8ad045e-2022-4e7d-8e64-ab4cc09c15a7@palmer-ri-x1c9>
On Mon, Dec 13, 2021 at 05:51:28PM -0800, Palmer Dabbelt wrote:
> On Mon, 25 Oct 2021 12:53:39 PDT (-0700), Atish Patra wrote:
> > This series adds improved perf support for RISC-V based system using
> > SBI PMU extension[1] and Sscofpmf extension[2]. The SBI PMU extension allows
> > the kernel to program the counters for different events and start/stop counters
> > while the sscofpmf extension allows the counter overflow interrupt and privilege
> > mode filtering. An hardware platform can leverage SBI PMU extension without
> > the sscofpmf extension if it supports mcountinhibit and mcounteren. However,
> > the reverse is not true. With both of these extension enabled, a platform can
> > take advantage of all both event counting and sampling using perf tool.
> >
> > This series introduces a platform perf driver instead of a existing arch
> > specific implementation. The new perf implementation has adopted a modular
> > approach where most of the generic event handling is done in the core library
> > while individual PMUs need to only implement necessary features specific to
> > the PMU. This is easily extensible and any future RISC-V PMU implementation
> > can leverage this. Currently, SBI PMU driver & legacy PMU driver are implemented
> > as a part of this series.
> >
> > The legacy driver tries to reimplement the existing minimal perf under a new
> > config to maintain backward compatibility. This implementation only allows
> > monitoring of always running cycle/instruction counters. Moreover, they can
> > not be started or stopped. In general, this is very limited and not very useful.
> > That's why, I am not very keen to carry the support into the new driver.
> > However, I don't want to break perf for any existing hardware platforms.
> > If everybody agrees that we don't need legacy perf implementation for older
> > implementation, I will be happy to drop PATCH 4.
>
> IMO we should keep it for a bit, so we have a transition period. These
> extensions are pretty new so we won't be able to count on everyone having
> them yet, this way we'll avoid breaking users.
>
> This generally looks good, but I don't see any Acks from the perf
> maintainers. I'm happy to take this through the RISC-V tree, but I'd
> generally like to have at least an ack as perf isn't really my subsystem.
> MAINTAINERS seems to indicate that's Will and Mark, they're not To'd so
> maybe they just missed this?
>
> I fixed a few trivial checkpatch warnings, updated Atish's email address,
> and put this on palmer/riscv-pmu. Happy to hear any comments, if nobody
> says anything then I'll just put that on riscv/for-next whenever I get back
> to my own email.
Fine by me! Most (all?) of the other drivers under drivers/perf/ are for
arm64, so I'm more than happy for you to handle the riscv one yourself.
If I end up with something that touches all of the drivers then we can
use a shared branch or something.
Will
next prev parent reply other threads:[~2021-12-14 18:09 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-25 19:53 [v4 00/11] Improve RISC-V Perf support using SBI PMU and sscofpmf extension Atish Patra
2021-10-25 19:53 ` [v4 01/11] RISC-V: Remove the current perf implementation Atish Patra
2021-10-25 19:53 ` [v4 02/11] RISC-V: Add CSR encodings for all HPMCOUNTERS Atish Patra
2021-10-25 19:53 ` [v4 03/11] RISC-V: Add a perf core library for pmu drivers Atish Patra
2021-10-25 19:53 ` [v4 04/11] RISC-V: Add a simple platform driver for RISC-V legacy perf Atish Patra
2021-10-25 19:53 ` [v4 05/11] RISC-V: Add RISC-V SBI PMU extension definitions Atish Patra
2021-12-15 8:02 ` Nikita Shubin
2021-12-15 16:03 ` Atish Patra
2021-10-25 19:53 ` [v4 06/11] dt-binding: pmu: Add RISC-V PMU DT bindings Atish Patra
2021-10-26 18:03 ` Rob Herring
2021-10-26 18:57 ` Rob Herring
2021-10-28 20:17 ` Jessica Clarke
2021-10-25 19:53 ` [v4 07/11] RISC-V: Add perf platform driver based on SBI PMU extension Atish Patra
2021-10-25 19:53 ` [v4 08/11] RISC-V: Add interrupt support for perf Atish Patra
2021-10-25 19:53 ` [v4 09/11] Documentation: riscv: Remove the old documentation Atish Patra
2021-10-25 19:53 ` [v4 10/11] riscv: dts: fu740: Add pmu node Atish Patra
2021-10-28 20:48 ` Jessica Clarke
2021-10-28 23:37 ` Atish Patra
2021-10-29 0:07 ` Jessica Clarke
2021-10-29 6:05 ` Atish Patra
2021-10-29 12:25 ` Jessica Clarke
2021-10-25 19:53 ` [v4 11/11] MAINTAINERS: Add entry for RISC-V PMU drivers Atish Patra
2021-12-14 1:51 ` [v4 00/11] Improve RISC-V Perf support using SBI PMU and sscofpmf extension Palmer Dabbelt
2021-12-14 3:16 ` Atish Patra
2021-12-14 18:09 ` Will Deacon [this message]
2021-12-14 9:14 ` Nikita Shubin
2021-12-14 18:29 ` Atish Patra
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20211214180915.GA15780@willie-the-truck \
--to=will@kernel.org \
--cc=anup.patel@wdc.com \
--cc=atishp@rivosinc.com \
--cc=corbet@lwn.net \
--cc=david.abdurachmanov@sifive.com \
--cc=devicetree@vger.kernel.org \
--cc=greentime.hu@sifive.com \
--cc=guoren@linux.alibaba.com \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-perf-users@vger.kernel.org \
--cc=linux-riscv@lists.infradead.org \
--cc=mark.rutland@arm.com \
--cc=mick@ics.forth.gr \
--cc=palmer@dabbelt.com \
--cc=paul.walmsley@sifive.com \
--cc=robh+dt@kernel.org \
--cc=vincent.chen@sifive.com \
--cc=xypron.glpk@gmx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox