Re: How to understand and turn off such a oops

From: Michal Schmidt
Date: Fri Jan 07 2005 - 07:24:18 EST


Park Lee wrote:
Hi,
Sometimes, when I call kmalloc() in Linux kernel,
the kernel always bring out a oops shown as following:


Debug: sleeping function called from invalid context
at mm/slab.c:1980
in_atomic():1, irqs_disabled():0

You're calling kmalloc in a context where sleeping is not allowed. And kmalloc with the GFP_KERNEL flag can sleep. Use GFP_ATOMIC in that context.

Michal
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/