On Jul 13, 11:42am, Ying-Hung Chen wrote:
>
> My problem is for some reason, i need LARGE amount of 'FREE' memory to
>start my sound application, say, x11amp, mpeg viewer(with sound in that
>movie of course). If I have fairly small amount of 'FREE' memory, say
>less than 20-30MB, those sound applications won't even start 90% of
>time. When I read the log, it says,
>
>"Can't allocate DMA buffer" or something equivalent.
>
>Usually i have to free up LOTS of memories by killing applications
>first, or 'wait' until memory become 'free' again. (other applications
>doesn't even care....)
>
I have a little program called "purge" which I wrote to handle this.
It mallocs megabyte blocks of RAM, dirties each page, and iterates until
the malloc() fails. This has the effect of forcing a lot of things in
memory to swap out, and always clears up the DMA buffers for me. This is
a bit more polite than killing the jobs, but it might still interfere
with other processes which are malloc-ing memory, if they get the failed
malloc call instead of "purge".
I've also only ever had to do this on SMP machines, but until last
week all of my sound-capable machines were SMP, so this isn't much of a
data point.
--
Christopher Neufeld [EMAIL PROTECTED]
Home page: http://caliban.physics.utoronto.ca/neufeld/Intro.html
"Don't edit reality for the sake of simplicity"
-
Linux SMP list: FIRST see FAQ at http://www.irisa.fr/prive/mentre/smp-faq/
To Unsubscribe: send "unsubscribe linux-smp" to [EMAIL PROTECTED]