All of lore.kernel.org
 help / color / mirror / Atom feed
From: Peter Maydell <peter.maydell@linaro.org>
To: Wei Huang <wei@redhat.com>
Cc: qemu-arm <qemu-arm@nongnu.org>, Andrew Jones <drjones@redhat.com>,
	Shannon Zhao <shannon.zhao@linaro.org>,
	Andrea Bolognani <abologna@redhat.com>,
	QEMU Developers <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] [PATCH RFC 1/1] arm64: add an option to turn on/off vpmu support
Date: Fri, 29 Jul 2016 08:57:58 +0100	[thread overview]
Message-ID: <CAFEAcA_x+4KesFxPfc-B=m1BF0f-yfVg=xYQLNE-XJUiXNFh=A@mail.gmail.com> (raw)
In-Reply-To: <1469723896-28049-1-git-send-email-wei@redhat.com>

On 28 July 2016 at 17:38, Wei Huang <wei@redhat.com> wrote:
> This patch adds a pmu=[on/off] option to enable/disable vpmu support
> in guest vm. There are several reasons to justify this option. First
> vpmu can be problematic for cross-migration between different SoC as
> perf counters is architecture-dependent. It is more flexible to
> have an option to turn it on/off. Secondly it matches the -cpu pmu
> option in libivrt. This patch has been tested on both DT/ACPI modes.


What particular two systems are you trying to migrate between?
In general we don't support migrating between different CPU
types at the moment, so the PMU sholud be the same on both ends.

(If we ever do get to supporting cross-cpu-type migration
then it will probably involve a very long and detailed command
line to specify exactly a whole lot of things like pmu yes/no,
number of hw breakpoints/watchpoints, and everything else that
can differ between implementations.)

That said, I don't have any objection to making the PMU
presence controllable (especially if we have similar
control on x86).

> --- a/target-arm/cpu.h
> +++ b/target-arm/cpu.h
> @@ -579,8 +579,9 @@ struct ARMCPU {
>      bool powered_off;
>      /* CPU has security extension */
>      bool has_el3;
> -    /* CPU has PMU (Performance Monitor Unit) */
> -    bool has_pmu;
> +
> +    /* CPU has vPMU (Performance Monitor Unit) support */
> +    bool enable_pmu;

Why rename the flag? has_foo is what we use for other features,
as you can see in the context of this bit of the patch.

>
>      /* CPU has memory protection unit */
>      bool has_mpu;

thanks
-- PMM

  parent reply	other threads:[~2016-07-29  7:58 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-28 16:38 [Qemu-devel] [PATCH RFC 1/1] arm64: add an option to turn on/off vpmu support Wei Huang
2016-07-29  0:59 ` Shannon Zhao
2016-07-29  6:54 ` Andrew Jones
2016-07-29 15:07   ` Wei Huang
2016-07-29 15:29   ` Peter Maydell
2016-08-01 12:04   ` Andrea Bolognani
2016-08-01 13:08     ` Andrew Jones
2016-08-01 13:16       ` Peter Maydell
2016-08-01 13:26       ` Andrea Bolognani
2016-08-01 13:32         ` Peter Maydell
2016-08-01 14:55           ` Andrea Bolognani
2016-08-13  6:06           ` Wei Huang
2016-08-15  9:24             ` Andrea Bolognani
2016-07-29  7:57 ` Peter Maydell [this message]
2016-07-29 15:08   ` Wei Huang
2016-07-29 15:25     ` Peter Maydell

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='CAFEAcA_x+4KesFxPfc-B=m1BF0f-yfVg=xYQLNE-XJUiXNFh=A@mail.gmail.com' \
    --to=peter.maydell@linaro.org \
    --cc=abologna@redhat.com \
    --cc=drjones@redhat.com \
    --cc=qemu-arm@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    --cc=shannon.zhao@linaro.org \
    --cc=wei@redhat.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.