Project Home
Project Home
Documents
Documents
Wiki
Wiki
Discussion Forums
Discussions
Project Information
Project Info
Forum Topic - looking for advice on how to manage memory( newbie): (1 Item)
   
looking for advice on how to manage memory( newbie)  
my hardware platform is a Xilinx V5-FXT PPC440 on a ML507 Eval. board. There is
1GByte of DDR2 on the board. I am using QNX 6.3.2.

My application is to capture up to ~800MB data from an optical interface, DMA it into memory and then read it out later 
over FTP.

The DMA buffer is reserved and not managed by the system. The DMA is to a physical address and this seems to be working.


I wrote a resource manager so that the DMA buffer can be accessed as a file.  I basically used the example in the 
programmers guide. 
I map the DMA buffer into the resource manager using mmap_device_io in main.
For transfers less than 128MB, it appears to work. If I set the transfer size larger than 128MB(by modifying the attr->
nbytes attribute), the system crashes sometime after the first 128MB are transferred. 

I then wrote a small test program to that opens the file, reads the data, and then closes the file. This seems to work.

If instead of reading the DMA buffer during the IO_read, I return the contents of a static buffer, the FTP works fine.

So I have concluded that I am doing something wrong with the memory management, but what? What would be the best way to 
handle this type of situation?

Thanks
Rob