Re: [PATCH 1/2] MN10300: Move asm-arm/cnt32_to_63.h to include/linux/

From: David Howells
Date: Mon Oct 06 2008 - 06:44:54 EST


Nicolas Pitre <nico@xxxxxxx> wrote:

> If so then you're using this interface in an inappropriate way.
>
> The _absolute_ minimum frequency with which this should be fully
> executed is once per half period of the base counter. I hope that in
> practice it happens far more often than that.

I think you're misunderstanding my contention.

If preemption is enabled, cnt32_to_63() can be called with greater than
minimum frequency and yet reversions can still happen.

The problem is that a process that's half way through executing cnt32_to_63()
can be preempted for a period of time sufficient that when it is rescheduled
and writes __m_cnt_hi, it corrupts it with an out of date value.

David

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/