[PATCH 01/11] coresight-etm4x: Adding CoreSight ETM4x driver
Linus Walleij
linus.walleij at linaro.org
Tue Apr 28 05:28:26 PDT 2015
On Thu, Apr 23, 2015 at 12:40 AM, Mathieu Poirier
<mathieu.poirier at linaro.org> wrote:
> From: Pratik Patel <pratikp at codeaurora.org>
>
> This driver manages the CoreSight ETMv4 (Embedded Trace Macrocell) IP block
> to support HW assisted tracing on ARMv7 and ARMv8 architectures.
>
> Signed-off-by: Pratik Patel <pratikp at codeaurora.org>
> Signed-off-by: Kaixu Xia <xiakaixu at huawei.com>
> Signed-off-by: Mathieu Poirier <mathieu.poirier at linaro.org>
(...)
> +/* The number of ETMv4 currently registered */
> +static int etm4_count;
> +static struct etmv4_drvdata *etmdrvdata[NR_CPUS];
Don't you need a mutex or something around etm4_count so
as to protect it? You could also make it an atomic.
Also why is it a signed int ... unsigned int?
I know, lame comments, the runtime PM stuff looks perfect now,
someone had a refcount comment but it's doing the right thing.
Yours,
Linus Walleij
More information about the linux-arm-kernel
mailing list