Update of /cvsroot/alsa/alsa-kernel/pci In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv21470/pci
Modified Files: intel8x0.c Log Message: - fixed the allocation/release of buffer descriptor table. Index: intel8x0.c =================================================================== RCS file: /cvsroot/alsa/alsa-kernel/pci/intel8x0.c,v retrieving revision 1.119 retrieving revision 1.120 diff -u -r1.119 -r1.120 --- intel8x0.c 24 Feb 2004 15:37:45 -0000 1.119 +++ intel8x0.c 2 Mar 2004 18:08:13 -0000 1.120 @@ -1450,8 +1450,8 @@ strcpy(pcm->name, chip->card->shortname); chip->pcm[device] = pcm; - snd_pcm_lib_preallocate_pci_pages_for_all(chip->pci, pcm, rec->prealloc_size, - rec->prealloc_max_size); + snd_pcm_lib_preallocate_pages_for_all(pcm, SNDRV_DMA_TYPE_PCI, chip->pci, + rec->prealloc_size, rec->prealloc_max_size); return 0; } @@ -2132,7 +2132,7 @@ if (chip->bdbars) { if (chip->fix_nocache) fill_nocache(chip->bdbars, chip->bdbars_count * sizeof(u32) * ICH_MAX_FRAGS * 2, 0); - snd_free_pci_pages(chip->pci, chip->bdbars_count * sizeof(u32) * ICH_MAX_FRAGS * 2, chip->bdbars, chip->bdbars_addr); + pci_free_consistent(chip->pci, chip->bdbars_count * sizeof(u32) * ICH_MAX_FRAGS * 2, chip->bdbars, chip->bdbars_addr); } if (chip->remap_addr) iounmap((void *) chip->remap_addr); @@ -2524,9 +2524,10 @@ /* allocate buffer descriptor lists */ /* the start of each lists must be aligned to 8 bytes */ - chip->bdbars = (u32 *)snd_malloc_pci_pages(pci, chip->bdbars_count * sizeof(u32) * ICH_MAX_FRAGS * 2, &chip->bdbars_addr); + chip->bdbars = (u32 *)pci_alloc_consistent(pci, chip->bdbars_count * sizeof(u32) * ICH_MAX_FRAGS * 2, &chip->bdbars_addr); if (chip->bdbars == NULL) { snd_intel8x0_free(chip); + snd_printk(KERN_ERR "intel8x0: cannot allocate buffer descriptors\n"); return -ENOMEM; } /* tables must be aligned to 8 bytes here, but the kernel pages ------------------------------------------------------- SF.Net is sponsored by: Speed Start Your Linux Apps Now. Build and deploy apps & Web services for Linux with a free DVD software kit from IBM. Click Now! http://ads.osdn.com/?ad_id=1356&alloc_id=3438&op=click _______________________________________________ Alsa-cvslog mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/alsa-cvslog