[DRBD-user] Re: kernel oops drbd 8.0_pre2 on Fedora Core 5 and RHEL4

Ard van Breemen ard at kwaak.net
Thu Apr 20 03:02:37 CEST 2006

Note: "permalinks" may not be as permanent as we would like,
direct links of old sources may well be a few messages off.


On Thu, Apr 20, 2006 at 02:31:50AM +0200, Ard van Breemen wrote:
<snip>
> when rewritten to:
>         printk(KERN_ERR "drbd bef b->bm=%p,page_nr=%d\n",(char*)(b->bm),page_nr);
>         page = virt_to_page((char*)(b->bm) + (PAGE_SIZE*page_nr));
>         printk(KERN_ERR "drbd aft b->bm=%p,page_nr=%d\n",(char*)(b->bm),page_nr);
<snip>
> (looking further up into the code, unless philip finds it first ;-) )
b->bm=vmalloced()

According to some googling vmalloced memory cannot be virt_to_page. Instead one
should use vmalloc_to_page for that, or allocate the memory with kmalloc.
After changing that piece of code:
        printk(KERN_ERR "drbd bef b->bm=%p,page_nr=%d\n",(char*)(b->bm),page_nr);
        page = vmalloc_to_page((char*)(b->bm) + (PAGE_SIZE*page_nr));
        //page = virt_to_page((char*)(b->bm) + (PAGE_SIZE*page_nr));
        printk(KERN_ERR "drbd aft b->bm=%p,page_nr=%d\n",(char*)(b->bm),page_nr);

I get:

drbd bef b->bm=ffffc200005ba000,page_nr=2947
drbd aft b->bm=ffffc200005ba000,page_nr=2947
drbd bef b->bm=ffffc200005ba000,page_nr=2948
drbd aft b->bm=ffffc200005ba000,page_nr=2948
drbd0: reading of bitmap took 2374 jiffies
drbd0: recounting of set bits took additional 2 jiffies
drbd0: 368 GB marked out-of-sync by on disk bit-map.
drbd0: No usable activity log found.
drbd0: disk( Attaching -> Inconsistent ) 
drbd0: BUG! md_sync_timer expired! Worker calls drbd_md_sync().
drbd0: Writing meta data super block now.
drbd0: BUG! md_sync_timer expired! Worker calls drbd_md_sync().

I guess in this case vmalloc_to_page is ok, since on opteron hardware with
IOMMU there is no highmem (in other words: memory is always DMA-able).
-- 
begin  LOVE-LETTER-FOR-YOU.txt.vbs
I am a signature virus. Distribute me until the bitter
end



More information about the drbd-user mailing list