lkml.org 
[lkml]   [2004]   [Dec]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
Subjectcan you switch between GFP_ATOMIC and GFP_KERNEL?
Hi,

I've been working on some code that puts a hook in net/core/dev.c
to intercept packets and redirect them to a module of mine, depending
on the type of packet it is....
My question is, new sk_buffs are always allocated with GFP_KERNEL
and can be swapped out. Is it possible to change the allocation status of
already-allocated memory to GFP_ATOMIC on the fly? (i.e. both the
slab-cache sk_buff header memory as well as the kmalloc'd data area).

My module keeps these packets for some time. My machine has plenty
of memory, and I'd much prefer that the memory belonging to these newly
receive packets never gets swapped out.

Thanks,
/*********************************/
Michael R. Hines
Grad Student, Florida State
Dept. Computer Science
http://www.cs.fsu.edu/~mhines/
Jusqu'a ce que le futur vienne...
/*********************************/

-
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/

\
 
 \ /
  Last update: 2005-03-22 14:09    [from the cache]
©2003-2011 Jasper Spaans