All of lore.kernel.org
 help / color / mirror / Atom feed
From: will.deacon@arm.com (Will Deacon)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 2/2] arm-ccn: perf: Prevent module unload while PMU is in use
Date: Fri, 3 Nov 2017 12:18:16 +0000	[thread overview]
Message-ID: <20171103121816.GC11628@arm.com> (raw)
In-Reply-To: <20171103114518.5311-2-suzuki.poulose@arm.com>

On Fri, Nov 03, 2017 at 11:45:18AM +0000, Suzuki K Poulose wrote:
> When the PMU driver is built as a module, the perf expects the
> pmu->module to be valid, so that the driver is prevented from
> being unloaded while it is in use. Fix the CCN pmu driver to
> fill in this field.
> 
> Fixes: commit a33b0daab73a0 ("bus: ARM CCN PMU driver")

nit: don't need "commit" here.

> Cc: Pawel Moll <pawel.moll@arm.com>
> Cc: Will Deacon <will.deacon@arm.com>
> Cc: Mark Rutland <mark.rutland@arm.com>
> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com>
> ---
>  drivers/bus/arm-ccn.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/bus/arm-ccn.c b/drivers/bus/arm-ccn.c
> index e8c6946fed9d..3063f5312397 100644
> --- a/drivers/bus/arm-ccn.c
> +++ b/drivers/bus/arm-ccn.c
> @@ -1276,6 +1276,7 @@ static int arm_ccn_pmu_init(struct arm_ccn *ccn)
>  
>  	/* Perf driver registration */
>  	ccn->dt.pmu = (struct pmu) {
> +		.module = THIS_MODULE,
>  		.attr_groups = arm_ccn_pmu_attr_groups,
>  		.task_ctx_nr = perf_invalid_context,
>  		.event_init = arm_ccn_pmu_event_init,

I'll pick this up since I'm taking the SPE fix via arm64 anyway.

Will

WARNING: multiple messages have this Message-ID (diff)
From: Will Deacon <will.deacon@arm.com>
To: Suzuki K Poulose <suzuki.poulose@arm.com>
Cc: linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org, Pawel Moll <pawel.moll@arm.com>,
	Mark Rutland <mark.rutland@arm.com>
Subject: Re: [PATCH 2/2] arm-ccn: perf: Prevent module unload while PMU is in use
Date: Fri, 3 Nov 2017 12:18:16 +0000	[thread overview]
Message-ID: <20171103121816.GC11628@arm.com> (raw)
In-Reply-To: <20171103114518.5311-2-suzuki.poulose@arm.com>

On Fri, Nov 03, 2017 at 11:45:18AM +0000, Suzuki K Poulose wrote:
> When the PMU driver is built as a module, the perf expects the
> pmu->module to be valid, so that the driver is prevented from
> being unloaded while it is in use. Fix the CCN pmu driver to
> fill in this field.
> 
> Fixes: commit a33b0daab73a0 ("bus: ARM CCN PMU driver")

nit: don't need "commit" here.

> Cc: Pawel Moll <pawel.moll@arm.com>
> Cc: Will Deacon <will.deacon@arm.com>
> Cc: Mark Rutland <mark.rutland@arm.com>
> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com>
> ---
>  drivers/bus/arm-ccn.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/bus/arm-ccn.c b/drivers/bus/arm-ccn.c
> index e8c6946fed9d..3063f5312397 100644
> --- a/drivers/bus/arm-ccn.c
> +++ b/drivers/bus/arm-ccn.c
> @@ -1276,6 +1276,7 @@ static int arm_ccn_pmu_init(struct arm_ccn *ccn)
>  
>  	/* Perf driver registration */
>  	ccn->dt.pmu = (struct pmu) {
> +		.module = THIS_MODULE,
>  		.attr_groups = arm_ccn_pmu_attr_groups,
>  		.task_ctx_nr = perf_invalid_context,
>  		.event_init = arm_ccn_pmu_event_init,

I'll pick this up since I'm taking the SPE fix via arm64 anyway.

Will

  reply	other threads:[~2017-11-03 12:18 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-11-03 11:45 [PATCH 1/2] perf: arm_spe: Prevent module unload while the PMU is in use Suzuki K Poulose
2017-11-03 11:45 ` Suzuki K Poulose
2017-11-03 11:45 ` [PATCH 2/2] arm-ccn: perf: Prevent module unload while " Suzuki K Poulose
2017-11-03 11:45   ` Suzuki K Poulose
2017-11-03 12:18   ` Will Deacon [this message]
2017-11-03 12:18     ` Will Deacon
2017-11-03 12:32   ` Mark Rutland
2017-11-03 12:32     ` Mark Rutland
2017-11-03 12:32 ` [PATCH 1/2] perf: arm_spe: Prevent module unload while the " Mark Rutland
2017-11-03 12:32   ` Mark Rutland

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=20171103121816.GC11628@arm.com \
    --to=will.deacon@arm.com \
    --cc=linux-arm-kernel@lists.infradead.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.