Hi David !

In the recent DRMs, there is this code in agp_remap:

        phys_addr_map = agpmem->memory->memory + (offset - agpmem->bound) / PAGE_SIZE;
        for (i = 0; i < num_pages; ++i)
                page_map[i] = pfn_to_page(phys_addr_map[i] >> PAGE_SHIFT);
        addr = vmap(page_map, num_pages, VM_IOREMAP, PAGE_AGP);
        vfree(page_map);
        if (!addr)
                return NULL;

        flush_tlb_kernel_range((unsigned long) addr, (unsigned long) addr + size);

Why this flush ? I don't see why one would need to flush TLBs on a region
obtained from vmap()... vmap will give you virtual addresses that weren't
allocated before, so that shouldn't be in your tlb (if they were used by a
previous vmalloc, then vfree would have cleared them...

Ben.




-------------------------------------------------------
This SF.net email is sponsored by: VM Ware
With VMware you can run multiple operating systems on a single machine.
WITHOUT REBOOTING! Mix Linux / Windows / Novell virtual machines
at the same time. Free trial click here:http://www.vmware.com/wl/offer/358/0
_______________________________________________
Dri-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/dri-devel

Reply via email to