diff options
| author | Anton Blanchard <anton@samba.org> | 2002-07-24 18:54:01 -0700 |
|---|---|---|
| committer | Linus Torvalds <torvalds@home.transmeta.com> | 2002-07-24 18:54:01 -0700 |
| commit | f4f650230a65575103c6874796aa2312d8cfef94 (patch) | |
| tree | efaeccf691eb78e817814c4b94c449985793910f /include/linux | |
| parent | 866b413df71523a4c08c2d84b33ed6001c645eb3 (diff) | |
[PATCH] Missing memory barrier in pte_chain_unlock
On a ppc64 machine running 2.5.28 we were hitting this BUG in
__free_pages_ok:
BUG_ON(page->pte.chain != NULL);
In pte_chain_lock we use test_and_set_bit which implies a memory
barrier. In pte_chain_unlock we use clear_bit which has no memory
barriers so we need to add one.
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/page-flags.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/page-flags.h b/include/linux/page-flags.h index f272b7d7f465..d8e4c7779d05 100644 --- a/include/linux/page-flags.h +++ b/include/linux/page-flags.h @@ -249,6 +249,7 @@ static inline void pte_chain_lock(struct page *page) static inline void pte_chain_unlock(struct page *page) { + smp_mb__before_clear_bit(); clear_bit(PG_chainlock, &page->flags); preempt_enable(); } |
