[openib-general] kmap_atomic slot collision

Michael S. Tsirkin mst at mellanox.co.il
Thu Dec 15 09:33:53 PST 2005


Hi!
I'm trying to use kmap_atomic from both interrupt and task context.
My idea was to do local_irq_save and then use KM_IRQ0/KM_IRQ1:
since I'm disabling interrupts I assumed that this should be safe.
The relevant code is here:
https://openib.org/svn/gen2/trunk/src/linux-kernel/infiniband/ulp/sdp/sdp_iocb.c

However, under stress I see errors from arch/i386/mm/highmem.c:42
        if (!pte_none(*(kmap_pte-idx)))
                BUG();

Apparently, my routine, running from a task context, races with
some other kernel code, and so I'm trying to use a slot that was not
yet unmapped.

Anyone has an idea on what I could be doing wrong?

Thanks,
-- 
MST



More information about the general mailing list