[Linux1394-cvslog] rev 854 - branches/linux-2.4
Brought to you by:
aeb,
bencollins
From: SVN U. <ben...@li...> - 2003-04-06 15:23:14
|
Author: bencollins Date: 2003-04-06 11:22:33 -0400 (Sun, 06 Apr 2003) New Revision: 854 Modified: branches/linux-2.4/ieee1394_core.c Log: Patch pulled from AC tree to alleviate sleep while in atomic context. Modified: branches/linux-2.4/ieee1394_core.c ============================================================================== --- branches/linux-2.4/ieee1394_core.c (original) +++ branches/linux-2.4/ieee1394_core.c 2003-04-06 11:22:35.000000000 -0400 @@ -127,9 +127,8 @@ { struct hpsb_packet *packet = NULL; void *data = NULL; - int kmflags = in_interrupt() ? GFP_ATOMIC : GFP_KERNEL; - packet = kmem_cache_alloc(hpsb_packet_cache, kmflags); + packet = kmem_cache_alloc(hpsb_packet_cache, GFP_ATOMIC); if (packet == NULL) return NULL; @@ -137,7 +136,7 @@ packet->header = packet->embedded_header; if (data_size) { - data = kmalloc(data_size + 8, kmflags); + data = kmalloc(data_size + 8, GFP_ATOMIC); if (data == NULL) { kmem_cache_free(hpsb_packet_cache, packet); return NULL; @@ -472,8 +471,7 @@ quadlet_t *data; size_t size=packet->data_size+packet->header_size; - int kmflags = in_interrupt() ? GFP_ATOMIC : GFP_KERNEL; - data = kmalloc(packet->header_size + packet->data_size, kmflags); + data = kmalloc(packet->header_size + packet->data_size, GFP_ATOMIC); if (!data) { HPSB_ERR("unable to allocate memory for concatenating header and data"); return 0; |