[PATCH 2.5] SB16: fix kmalloc params

From: Pablo Menichini (pablo@menichini.com.ar)
Date: Wed Apr 09 2003 - 22:15:10 EST


This patch swaps the arguments of kmalloc, and relax the type
of allocation to GFP_KERNEL as others PnP functions do.

Pablo

--- linux-2.5.67/sound/isa/sb/sb16.c Tue Apr 8 15:24:31 2003
+++ linux-local/sound/isa/sb/sb16.c Tue Apr 8 15:24:52 2003
@@ -261,7 +261,7 @@
                                        const struct pnp_card_device_id *id)
 {
         struct pnp_dev *pdev;
- struct pnp_resource_table * cfg = kmalloc(GFP_ATOMIC, sizeof(struct pnp_resource_table));
+ struct pnp_resource_table *cfg = kmalloc(sizeof(*cfg), GFP_KERNEL);
         int err;

         if (!cfg)

-
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 : Tue Apr 15 2003 - 22:00:20 EST