[Linux1394-cvslog] rev 631 - trunk
Brought to you by:
aeb,
bencollins
From: SVN U. <ben...@li...> - 2002-10-21 16:15:43
|
Author: bencollins Date: 2002-10-21 12:15:40 -0400 (Mon, 21 Oct 2002) New Revision: 631 Modified: trunk/amdtp.c trunk/ieee1394_types.h trunk/ohci1394.c Log: Add compat macro for pci_pool_create change in 2.5. Modified: trunk/ohci1394.c ============================================================================== --- trunk/ohci1394.c (original) +++ trunk/ohci1394.c 2002-10-21 12:15:41.000000000 -0400 @@ -1624,7 +1624,7 @@ return -ENOMEM; } - d->prg_pool = pci_pool_create("ohci1394 rcv prg", ohci->dev, + d->prg_pool = hpsb_pci_pool_create("ohci1394 rcv prg", ohci->dev, sizeof(struct dma_cmd), 4, 0, SLAB_KERNEL); OHCI_DMA_ALLOC("dma_rcv prg pool"); @@ -1733,7 +1733,7 @@ memset(d->prg_cpu, 0, d->num_desc * sizeof(struct at_dma_prg*)); memset(d->prg_bus, 0, d->num_desc * sizeof(dma_addr_t)); - d->prg_pool = pci_pool_create("ohci1394 trm prg", ohci->dev, + d->prg_pool = hpsb_pci_pool_create("ohci1394 trm prg", ohci->dev, sizeof(struct at_dma_prg), 4, 0, SLAB_KERNEL); OHCI_DMA_ALLOC("dma_rcv prg pool"); Modified: trunk/amdtp.c ============================================================================== --- trunk/amdtp.c (original) +++ trunk/amdtp.c 2002-10-21 12:15:41.000000000 -0400 @@ -833,13 +833,9 @@ max_nevents = fraction_ceil(&s->samples_per_cycle); max_packet_size = max_nevents * s->dimension * 4 + 8; - s->packet_pool = pci_pool_create("packet pool", s->host->ohci->dev, - max_packet_size, 0, 0 -#if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,40) - ,SLAB_KERNEL); -#else - ); -#endif + s->packet_pool = hpsb_pci_pool_create("packet pool", s->host->ohci->dev, + max_packet_size, 0, 0 ,SLAB_KERNEL); + if (s->packet_pool == NULL) return -1; @@ -1023,14 +1019,9 @@ return NULL; } - s->descriptor_pool = pci_pool_create("descriptor pool", host->ohci->dev, + s->descriptor_pool = hpsb_pci_pool_create("descriptor pool", host->ohci->dev, sizeof(struct descriptor_block), - 16, 0 -#if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,40) - ,SLAB_KERNEL); -#else - ); -#endif + 16, 0 ,SLAB_KERNEL); if (s->descriptor_pool == NULL) { kfree(s->input); Modified: trunk/ieee1394_types.h ============================================================================== --- trunk/ieee1394_types.h (original) +++ trunk/ieee1394_types.h 2002-10-21 12:15:41.000000000 -0400 @@ -62,6 +62,13 @@ #define HPSB_PREPARE_WORK(x,y,z) PREPARE_WORK(x,y,z) #endif +#if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,44) +/* pci_pool_create changed. does not take the flags arg any longer */ +#define hpsb_pci_pool_create(a,b,c,d,e,f) pci_pool_create(a,b,c,d,e,f) +#else +#define hpsb_pci_pool_create(a,b,c,d,e,f) pci_pool_create(a,b,c,d,e) +#endif + /* Transaction Label handling */ struct hpsb_tlabel_pool { u64 pool; |