This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Problem with CMEM on OMAP3

Hallo,

I'm using a Beagleboard and try to share memory with the cmem APIs.

My ARM side code is:

CMEM_init();
myParams.type = CMEM_POOL;
myParams.flags = CMEM_NONCACHED;
 myPool_ID = CMEM_getPool(BufferSize);
myPoolAddr_virt = (Uint8*) CMEM_allocPool(myPool_ID, &myParams);

 *myPoolAddr_virt=x;  
 printf("%x\n", myPoolAddr_virt); 
 printf("%d\n", *myPoolAddr_virt); 
 myPoolAddr_phys = (Uint8*) CMEM_getPhys(myPoolAddr_virt); 
 printf("%x\n", myPoolAddr_phys); 

 status=PROC_setup (NULL) ;  
if (DSP_SUCCEEDED (status)) {
  status = PROC_attach (processorId, NULL) ;  
}
if (DSP_SUCCEEDED (status)) {
  status = PROC_load (processorId, dspExecutable,numArgs, args) ;
}
if (DSP_SUCCEEDED (status)) {
  status = PROC_start (processorId) ;  
}

 sleep(3);

 printf("%d\n", *myPoolAddr_virt);  
 printf("%d\n", *myPoolAddr_phys);

And DSP Side:


int x=321;
Uint8 * myPoolAddr_phys;

myPoolAddr_phys = (Uint8 *) 0x8d800000;
*myPoolAddr_phys=x;

I want test with this easy example to learn how to use cmem but  on ARM side I get the same value of x before and after the DSP.

What I'm doing wrong?

 

best regards

Michael