[PATCH 2/4] dma: make dma pool to use kmalloc_node
Yinghai Lu <[email protected]>
| Newsgroups | gmane.linux.usb.devel |
|---|---|
| Message-ID | <200707021534.59944.yinghai.lu__40441.8587372222$1183439641$gmane$org@sun.com> |
[PATCH 2/4] dma: make dma pool to use kmalloc_node Using dev_to_node(&dev->dev) to get node, and kmalloc_node to dma buffer on corresding node dma pool Signed-off-by: Yinghai Lu <[email protected]> diff --git a/drivers/base/dmapool.c b/drivers/base/dmapool.c index 91970e9..7647abf 100644 --- a/drivers/base/dmapool.c +++ b/drivers/base/dmapool.c @@ -127,7 +127,7 @@ dma_pool_create (const char *name, struct device *dev, } else if (allocation < size) return NULL; - if (!(retval = kmalloc (sizeof *retval, GFP_KERNEL))) + if (!(retval = kmalloc_node (sizeof *retval, GFP_KERNEL, dev_to_node(dev)))) return retval; strlcpy (retval->name, name, sizeof retval->name); ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ [email protected] To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel