Messages in this thread Patch in this message |  | | | Date | Mon, 9 Aug 2004 13:58:39 -0700 | | From | Andrew Vasquez <> | | Subject | Re: 2.6.8-rc3-mm2: Debug: sleeping function called from invalid context at mm/mempool.c:197 | |
On Mon, 09 Aug 2004, Janet Morgan wrote:
> Andrew Vasquez wrote:
>
> >
> >This allocation should be done with GFP_ATOMIC flags. The attached
> >patch should apply cleanly to any recent kernel
> >
> >
> >
>
> and seems to work fine.
>
James,
I hope this patch can make it before 2.6.8, please apply.
Thanks,
Andrew Vasquez
===== drivers/scsi/qla2xxx/qla_os.c 1.39 vs edited =====
--- 1.39/drivers/scsi/qla2xxx/qla_os.c 2004-07-12 09:54:49 -07:00
+++ edited/drivers/scsi/qla2xxx/qla_os.c 2004-08-09 16:48:29 -07:00
@@ -3590,7 +3590,7 @@
{
srb_t *sp;
- sp = mempool_alloc(ha->srb_mempool, GFP_KERNEL);
+ sp = mempool_alloc(ha->srb_mempool, GFP_ATOMIC);
if (sp)
atomic_set(&sp->ref_count, 1);
return (sp); |  |