Re: [BUG] vmalloc, kmalloc - 2.4.x

From: Oliver Neukum (oliver@neukum.name)
Date: Mon Feb 03 2003 - 10:19:16 EST


Am Montag, 3. Februar 2003 16:13 schrieb Grzegorz Jaskiewicz:
> few days ago i started to port driver for our hardware in company from
> windows to linux. It is simple ISA card, which gives me interrupt each
> 8ms. So i can check it state and latch some sort of watchdog on it -
> saying that i am still running (just for security, if system hangs card
> is blocking all inputs/outputs).
>
> But anyway, i was collecting all data from the card in dynamically
> allocated memory. This gives me at least 300 * 20 bytes allocated. i
> have sigle small allocation running on each interrupt.
>
> Driver is working fine under win2k even if i collect as much as 10000
> allocations, afterwards system uses loads of processor.

It seems that you are using vmalloc in an interrupt handler.
That you must not do. To allocate memory in an interrupt handler
you have to use kmalloc() with GFP_ATOMIC as a second argument.

        HTH
                Oliver

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



This archive was generated by hypermail 2b29 : Fri Feb 07 2003 - 22:00:11 EST