Advice on how to map very large buffers & obtain addresses for processor and dma
I am a new to linux and would like to use linux in a data acquisition application. I would like to have a very large buffer area that is filled directly by the d/a dma controller. Once the buffer is full, the acquisition is over and the application will write the data to disk. If done properly, I would think that the processor would be near idle w/ the dma controllers for the d/a & disk doing most of the work.
I think I would like to reserve a pile of (high?) memory and map them via hugetlbs via parameters to the linux load line. This should allow the application to efficiently access this area (?). I have access to the d/a driver and expect I should be able to convert the virtual address from the application to something useful for the dma hardware. It is unclear to me if virt_to_phys() is appropriate.
Comments & suggestions on how implement this is greatly appreciated.