kernels/linux-2.4.0/arch/ia64/lib/swiotlb.c
/*
 * Statically reserve bounce buffer space and initialize bounce buffer data structures for
 * the software IO TLB used to implement the PCI DMA API.
 */
Statically reserve bounce buffer space and initialize bounce buffer data structures for
the software IO TLB used to implement the PCI DMA API.
Statically reserve bounce buffer space and initialize bounce buffer data structures for the software IO TLB used to implement the PCI DMA API .
void
swiotlb_init (void)
{
	int i;
	io_tlb_start = alloc_bootmem_low_pages(io_tlb_nslabs * (1 << IO_TLB_SHIFT));
	if (!io_tlb_start)
		BUG();
	io_tlb_end = io_tlb_start + io_tlb_nslabs * (1 << IO_TLB_SHIFT);
	io_tlb_list = alloc_bootmem(io_tlb_nslabs * sizeof(int));
	for (i = 0; i < io_tlb_nslabs; i++)
		io_tlb_list[i] = io_tlb_nslabs - i;
	io_tlb_index = 0;
	io_tlb_orig_addr = alloc_bootmem(io_tlb_nslabs * sizeof(char *));
	printk("Placing software IO TLB between 0x%p - 0x%p\n",
	       (void *) io_tlb_start, (void *) io_tlb_end);
}
void swiotlb_init ( void ) { int i ; io_tlb_start = alloc_bootmem_low_pages ( io_tlb_nslabs * ( 1 << IO_TLB_SHIFT ) ) ; if ( ! io_tlb_start ) BUG ( ) ; io_tlb_end = io_tlb_start + io_tlb_nslabs * ( 1 << IO_TLB_SHIFT ) ; io_tlb_list = alloc_bootmem ( io_tlb_nslabs * sizeof ( int ) ) ; for ( i = 0 ; i < io_tlb_nslabs ; i ++ ) io_tlb_list [ i ] = io_tlb_nslabs - i ; io_tlb_index = 0 ; io_tlb_orig_addr = alloc_bootmem ( io_tlb_nslabs * sizeof ( char * ) ) ; printk ( " \n " , ( void * ) io_tlb_start , ( void * ) io_tlb_end ) ; }
Statically reserve bounce buffer space and initialize bounce buffer data structures for
 the software IO TLB used to implement the PCI DMA API.
Statically reserve bounce buffer space and initialize bounce buffer data structures for the software IO TLB used to implement the PCI DMA API .
/*
	 * Get IO TLB memory from the low pages
	 */ /*
	 * Allocate and initialize the free list array.  This array is used
	 * to find contiguous free memory regions of size 2^IO_TLB_SHIFT between
	 * io_tlb_start and io_tlb_end.
	 */