From: Andrew Cooper <andrew.cooper3@citrix.com>
To: Doug Goldstein <cardoe@cardoe.com>, xen-devel@lists.xen.org
Cc: Keir Fraser <keir@xen.org>, Jan Beulich <jbeulich@suse.com>
Subject: Re: [PATCH v3 2/3] xenoprof: fix up ability to disable it
Date: Wed, 17 Feb 2016 14:55:08 +0000 [thread overview]
Message-ID: <56C489CC.7070704@citrix.com> (raw)
In-Reply-To: <1455719856-20465-3-git-send-email-cardoe@cardoe.com>
On 17/02/16 14:37, Doug Goldstein wrote:
> diff --git a/xen/include/asm-x86/xenoprof.h b/xen/include/asm-x86/xenoprof.h
> index b006ddc..c78e8cf 100644
> --- a/xen/include/asm-x86/xenoprof.h
> +++ b/xen/include/asm-x86/xenoprof.h
> @@ -67,9 +67,33 @@ void xenoprof_backtrace(struct vcpu *, const struct cpu_user_regs *,
> "xenoprof/x86 with autotranslated mode enabled" \
> "isn't supported yet\n"); \
> } while (0)
> +
> +#ifdef CONFIG_XENOPROF
> int passive_domain_do_rdmsr(unsigned int msr, uint64_t *msr_content);
> int passive_domain_do_wrmsr(unsigned int msr, uint64_t msr_content);
> void passive_domain_destroy(struct vcpu *v);
> +#else
> +static inline int passive_domain_do_rdmsr(unsigned int msr,
> + uint64_t *msr_content)
> +{
> + (void)msr;
> + (void)msr_content;
You don't need these inside a static inline. The callsite of the static
inline will cause the parameters to be evaluated.
They are needed for macros, as macros end up being a transformation of
the text at the callsite itself.
~Andrew
> + return 0;
> +}
> +
> +static inline int passive_domain_do_wrmsr(unsigned int msr,
> + uint64_t *msr_content)
> +{
> + (void)msr;
> + (void)msr_content;
> + return 0;
> +}
> +
> +static inline void passive_domain_destroy(struct vcpu *v)
> +{
> + (void)v;
> +}
> +#endif
>
> #endif /* __ASM_X86_XENOPROF_H__ */
>
next prev parent reply other threads:[~2016-02-17 14:55 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-02-17 14:37 [PATCH v3 1/3] PMU: make {acquire, release}_pmu_ownership names consistent Doug Goldstein
2016-02-17 14:37 ` Doug Goldstein
2016-02-17 14:37 ` [PATCH v3 2/3] xenoprof: fix up ability to disable it Doug Goldstein
2016-02-17 14:55 ` Andrew Cooper [this message]
2016-02-17 14:37 ` Doug Goldstein
2016-02-17 14:37 ` [PATCH v3 3/3] build: convert xenoprof to Kconfig Doug Goldstein
2016-02-17 14:37 ` Doug Goldstein
2016-02-17 15:14 ` Jan Beulich
2016-02-17 14:50 ` [PATCH v3 1/3] PMU: make {acquire, release}_pmu_ownership names consistent Andrew Cooper
2016-02-17 14:52 ` Boris Ostrovsky
2016-02-18 6:36 ` Tian, Kevin
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=56C489CC.7070704@citrix.com \
--to=andrew.cooper3@citrix.com \
--cc=cardoe@cardoe.com \
--cc=jbeulich@suse.com \
--cc=keir@xen.org \
--cc=xen-devel@lists.xen.org \
/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.