allocating memory at boot
From: Philip Downer <hidden>
Date: 2011-02-21 13:33:13
sk.syed2 wrote:
quoted
I have looked at the code for dma_alloc_coherent etc and it seems to me that it's returning null because there isn't the space available to allocate the requested memory.You might have to increase the consistent(or dma) memory size. In recent kernels its defined by CONSISTENT_DMA_SIZE (ach/arm/include/asm/memory.h). Which kernel version are you using? You might have to override this value to match your needs. Are there any other drivers that allocate using dma_alloc_coherent?
Oh, awesome! This was it, I'm using kernel version 2.6.37 and changing CONSISTENT_DMA_SIZE for arm has allowed me to allocate enough memory using dma_alloc_coherent so I can use the original code which I had working on x86. Is there any reason why this isn't a kconfig option? Thanks for the help. Phil