2009-02-21 02:09:37     Global buffer assignment problem in 2008R1

Document created by Aaronwu Employee on Aug 13, 2013
Version 1Show Document
  • View in full screen mode

2009-02-21 02:09:37     Global buffer assignment problem in 2008R1

Rajesh R (INDIA)

Message: 69712   

 

Dear All,

 

we are facing a problem in assignment of the global buffer. Actually the value assigned to the buffer is not there, only 0's are there in the buffer.

 

Ex:

 

unsigned int Temp_Buffer[4] = {

 

0xEFEFEEFE,

 

0xEFEFEEFE,

 

0xEFEFEEFE,

 

0xEFEFEEFE,

 

};

 

But after loading the symbols we saw that valiable in memory, everything in filled with 0's.

 

Please suggest what could be the problem?

 

Thanks in advance!!!

 

Regards,

 

R Rajesh

QuoteReplyEditDelete

 

 

2009-02-21 02:17:39     Re: Global buffer assignment problem in 2008R1

Mike Frysinger (UNITED STATES)

Message: 69713   

 

show the exact code you're using to declare the buffer and refer to it, and how exactly you're compiling/linking/running the code

 

also, how exactly are you examining memory and where are you getting the addresses to read

QuoteReplyEditDelete

 

 

2009-02-21 02:31:19     Re: Global buffer assignment problem in 2008R1

Rajesh R (INDIA)

Message: 69714   

 

Dear Mike,

 

Actually we are using BF-561 based custom board.

 

We are assigning the buffer like below, it is in shared memory

 

L2_DATA unsigned int Bit_Map_44100[5] = {

0xFFDFFDFF,

0xEFFEFFEF,

0xFF7FF7FF,

0x7FF7FFBF,

0xFBFFBFFD};

 

It is declared in driver side. We are having our own audio driver. In that only the above structure is assigned.

 

"examining memory" : actually we are loading the symbol in VDSP from "linux" file from image folder of the distribution,

 

"compiling/linking/running ": for compiling we are using "make"

 

Regards,

 

R Rajesh

QuoteReplyEditDelete

 

 

2009-02-21 02:38:39     Re: Global buffer assignment problem in 2008R1

Mike Frysinger (UNITED STATES)

Message: 69715   

 

using make doesnt tell me anything about the toolchain

 

where is the buffer defined ?  in a kernel driver ?  there was no L2 support in the 2008R1.5 release.

QuoteReplyEditDelete

 

 

2009-02-21 02:52:35     Re: Global buffer assignment problem in 2008R1

Rajesh R (INDIA)

Message: 69716   

 

Mike,

 

We are using 2008R1 releases for our applications.

 

Actually we had added our own audio driver in  linux-2.6.x/drivers/561/Audio/

 

We kept the buffer in Shared Memory of BF561,

 

we had done modifactions in .lds file to allocate memory in shared region( L2) of BF561.

 

Regards,

 

R.Rajesh

 

 

QuoteReplyEditDelete

 

 

2009-02-21 03:00:17     Re: Global buffer assignment problem in 2008R1

Mike Frysinger (UNITED STATES)

Message: 69717   

 

modifying the linker script only changes how the kernel maps memory, it doesnt automatically relocate things from the LMA to the VMA.  the kernel has to do that manually during init.

QuoteReplyEditDelete

 

 

2009-02-21 03:49:52     Re: Global buffer assignment problem in 2008R1

Rajesh R (INDIA)

Message: 69718   

 

Could you please explain about LMA and VMA?

 

I hope the data's should be coiped to the global buffers in the driver init code like below...

 

void AudioDriverInit()

 

{

 

unsigned int tBit_Map_44100[5] = {

0xFFDFFDFF,

0xEFFEFFEF,

0xFF7FF7FF,

0x7FF7FFBF,

0xFBFFBFFD};

 

 

for(i=0; i<5; i++)

        Bit_Map_44100[i]=tBit_Map_44100[i];

 

}

 

Thanks Mike

Attachments

    Outcomes