Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inputs needed : failure to allocate coherent buffer #93

Open
dusane opened this issue Oct 7, 2020 · 4 comments
Open

Inputs needed : failure to allocate coherent buffer #93

dusane opened this issue Oct 7, 2020 · 4 comments

Comments

@dusane
Copy link

dusane commented Oct 7, 2020

With 1.2rc3 driver i am trying to allocate 128 M of coherent memory using dma_alloc_coherent. which fails, even 64M allocation fails - at swiotlb buffer full.. (32 M works though). I have tried combos of following configs CMA configs (CONFIG_CMA_SIZE_MBYTES = 256, CONFIG_CMA_ALIGNMENT=12), high value of swiotlb=65535 in cmdline. tried explicitely setting dma_coherent_mask. But still i hit the failure. Any suggestion what i am missing ? This is with 4.4.36

@lsgunth
Copy link
Collaborator

lsgunth commented Oct 7, 2020

No Idea. That seems like a crazy large amount of memory to expect to get out of the CMA. Not sure if it supports that. There may also be bugs in the ancient kernel.

Either way this isn't really a switchtec issue... You'll probably need to dig into the CMA code to figure out what is going on.

@epilmore
Copy link

epilmore commented Oct 7, 2020 via email

@dusane
Copy link
Author

dusane commented Oct 8, 2020

@lsgunth I agree its not really a switchtec issue. I just need inputs and advice from team.
@epilmore Thanks Eric, will try these. I am booting in 64 bit mode too.

@dusane
Copy link
Author

dusane commented Oct 27, 2020

@epilmore These configs worked for me, Thanks. I am not completely sure of all its side effects though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants