From ca8a24a8727d8170c81d54e25d55804b59f5ea12 Mon Sep 17 00:00:00 2001 From: Christoph Lameter Date: Wed, 3 Oct 2007 20:42:45 -0700 Subject: [PATCH] vcompound: bit waitqueue support If bit waitqueue is passed a virtual address then it must use virt_to_head_page instead of virt_to_page. Signed-off-by: Christoph Lameter --- kernel/wait.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/kernel/wait.c b/kernel/wait.c index c275c56..7b9ec0c 100644 --- a/kernel/wait.c +++ b/kernel/wait.c @@ -245,7 +245,7 @@ EXPORT_SYMBOL(wake_up_bit); wait_queue_head_t *bit_waitqueue(void *word, int bit) { const int shift = BITS_PER_LONG == 32 ? 5 : 6; - const struct zone *zone = page_zone(virt_to_page(word)); + const struct zone *zone = page_zone(virt_to_head_page(word)); unsigned long val = (unsigned long)word << shift | bit; return &zone->wait_table[hash_long(val, zone->wait_table_bits)]; -- 1.5.4.1