Re: [PATCH] updated low-latency zap_page_range
From: Andrew Morton <hidden>
Date: 2002-07-25 00:44:41
Also in:
lkml
From: Andrew Morton <hidden>
Date: 2002-07-25 00:44:41
Also in:
lkml
Robert Love wrote:
...
+static inline void cond_resched_lock(spinlock_t * lock)
+{
+ if (need_resched() && preempt_count() == 1) {
+ _raw_spin_unlock(lock);
+ preempt_enable_no_resched();
+ __cond_resched();
+ spin_lock(lock);
+ }
+}Maybe I'm being thick. How come a simple spin_unlock() in here won't do the right thing? And this won't _really_ compile to nothing with CONFIG_PREEMPT=n, will it? It just does nothing because preempt_count() is zero? - -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@kvack.org. For more info on Linux MM, see: http://www.linux-mm.org/