From: mark.rutland@arm.com (Mark Rutland)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v6 08/11] drivers: perf: hisi: use poll method to avoid L3C counter overflow
Date: Tue, 28 Mar 2017 12:09:55 +0100 [thread overview]
Message-ID: <20170328110955.GD24221@leverpostej> (raw)
In-Reply-To: <58D8B234.3020004@gmail.com>
On Mon, Mar 27, 2017 at 12:03:24PM +0530, Anurup M wrote:
> On Friday 24 March 2017 05:13 PM, Mark Rutland wrote:
> >>>How do we ensure that we don't take the interrupt in the middle of a
> >>>> >sequence of accesses to the HW?
> >>>
> >>>The L3 cache and MN PMU does not use the overflow IRQ and it does
> >>>not occur here
> >>>as the interrupt Mask register is by default masked in hardware.
> >I was referring to the timer interrupt which backs the hrtimer.
> >
> >i.e. how do we guarantee that hisi_hrtimer_callback() is not called
> >while we are in the middle of a RMW sequence? Are interrupts disabled
> >for all of those seqeunces?
>
> The HW access via djtag read and write are protected by spin_lock_irqsave.
Thanks for the explanation.
I mistakenly thought that there were sequences that would need to make
several hisi_djtag_{read,writel}() calls that might conflict with the
overflow handler, but that is not the case, so the spin_lock_irqsave()
does appear to be sufficient.
Thanks,
Mark.
WARNING: multiple messages have this Message-ID (diff)
From: Mark Rutland <mark.rutland@arm.com>
To: Anurup M <anurupvasu@gmail.com>
Cc: will.deacon@arm.com, linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org, anurup.m@huawei.com,
zhangshaokun@hisilicon.com, tanxiaojun@huawei.com,
xuwei5@hisilicon.com, sanil.kumar@hisilicon.com,
john.garry@huawei.com, gabriele.paoloni@huawei.com,
shiju.jose@huawei.com, huangdaode@hisilicon.com,
linuxarm@huawei.com, dikshit.n@huawei.com, shyju.pv@huawei.com
Subject: Re: [PATCH v6 08/11] drivers: perf: hisi: use poll method to avoid L3C counter overflow
Date: Tue, 28 Mar 2017 12:09:55 +0100 [thread overview]
Message-ID: <20170328110955.GD24221@leverpostej> (raw)
In-Reply-To: <58D8B234.3020004@gmail.com>
On Mon, Mar 27, 2017 at 12:03:24PM +0530, Anurup M wrote:
> On Friday 24 March 2017 05:13 PM, Mark Rutland wrote:
> >>>How do we ensure that we don't take the interrupt in the middle of a
> >>>> >sequence of accesses to the HW?
> >>>
> >>>The L3 cache and MN PMU does not use the overflow IRQ and it does
> >>>not occur here
> >>>as the interrupt Mask register is by default masked in hardware.
> >I was referring to the timer interrupt which backs the hrtimer.
> >
> >i.e. how do we guarantee that hisi_hrtimer_callback() is not called
> >while we are in the middle of a RMW sequence? Are interrupts disabled
> >for all of those seqeunces?
>
> The HW access via djtag read and write are protected by spin_lock_irqsave.
Thanks for the explanation.
I mistakenly thought that there were sequences that would need to make
several hisi_djtag_{read,writel}() calls that might conflict with the
overflow handler, but that is not the case, so the spin_lock_irqsave()
does appear to be sufficient.
Thanks,
Mark.
next prev parent reply other threads:[~2017-03-28 11:09 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-10 6:28 [PATCH v6 08/11] drivers: perf: hisi: use poll method to avoid L3C counter overflow Anurup M
2017-03-10 6:28 ` Anurup M
2017-03-21 17:16 ` Mark Rutland
2017-03-21 17:16 ` Mark Rutland
2017-03-24 6:43 ` Anurup M
2017-03-24 6:43 ` Anurup M
2017-03-24 11:43 ` Mark Rutland
2017-03-24 11:43 ` Mark Rutland
2017-03-27 6:33 ` Anurup M
2017-03-27 6:33 ` Anurup M
2017-03-28 11:09 ` Mark Rutland [this message]
2017-03-28 11:09 ` 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=20170328110955.GD24221@leverpostej \
--to=mark.rutland@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.