Messages in this thread | | | Date | Mon, 6 Dec 2004 08:12:58 +1100 | From | Paul Mackerras <> | Subject | Re: [PATCH][PPC32[NEWBIE] enhancement to virt_to_bus/bus_to_virt (try 2) |
| |
Linh Dang writes:
> I wrote a DMA engine (to used by other drivers) that (would like to) accept > all kind of buffers as input (vmalloced, dual-access shared RAM mapped > by BATs, etc). The DMA engine has to decode the virtual address of the > input buffer to (possibly multiple) physical address(es). virt_to_phys() > has the right name for the job except it only works for the kernel virtual > addresses initially mapped at KERNELBASE
Have you read Documentation/DMA-API.txt? It explains the official kernel API for DMA, and drivers should use it in order to be portable to more than just one architecture.
If you want to create a competing DMA API, you'll have to show us at least one driver that really needs your new API.
Also, please don't change the existing virt_to_*/*_to_virt functions. Instead define your own functions (with different names) in the same source file as your other new code.
Paul.
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |