* Allocalting > 4M
@ 2006-09-27 20:34 Rune Torgersen
2006-09-27 20:58 ` Roger Larsson
2006-09-27 21:00 ` Arnd Bergmann
0 siblings, 2 replies; 4+ messages in thread
From: Rune Torgersen @ 2006-09-27 20:34 UTC (permalink / raw)
To: linuxppc-embedded
We have an embedded board with 1G of memory.
Is there any way, short of using mem=3D on kernel command line and
reserving memory, to allocate more than 4M of contigous physical memory?
We're trying to allocalte a 8M buffer for use in some DMA transfers for
a bank of DSP's.
We were using get_Free_pages to allocate the meory before we made the
buffer bigger. It seems that get_free_pages cannot allocate more than
2^10 pages (4M on ppc)
I also tried alloc_bootmem, but it fails also.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Allocalting > 4M
2006-09-27 20:34 Allocalting > 4M Rune Torgersen
@ 2006-09-27 20:58 ` Roger Larsson
2006-09-27 21:00 ` Arnd Bergmann
1 sibling, 0 replies; 4+ messages in thread
From: Roger Larsson @ 2006-09-27 20:58 UTC (permalink / raw)
To: linuxppc-embedded
On Wednesday 27 September 2006 22:34, Rune Torgersen wrote:
> We have an embedded board with 1G of memory.
>
> Is there any way, short of using mem= on kernel command line and
> reserving memory, to allocate more than 4M of contigous physical memory?
> We're trying to allocalte a 8M buffer for use in some DMA transfers for
> a bank of DSP's.
> We were using get_Free_pages to allocate the meory before we made the
> buffer bigger. It seems that get_free_pages cannot allocate more than
> 2^10 pages (4M on ppc)
> I also tried alloc_bootmem, but it fails also.
There is a 'bigphysmem' patch for 2.4 that might help. There might be
alternative solutions to this problem, they should refere to bigphysmem
- might help when googling...
/RogerL
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Allocalting > 4M
2006-09-27 20:34 Allocalting > 4M Rune Torgersen
2006-09-27 20:58 ` Roger Larsson
@ 2006-09-27 21:00 ` Arnd Bergmann
2006-09-27 21:29 ` Rune Torgersen
1 sibling, 1 reply; 4+ messages in thread
From: Arnd Bergmann @ 2006-09-27 21:00 UTC (permalink / raw)
To: linuxppc-embedded
Am Wednesday 27 September 2006 22:34 schrieb Rune Torgersen:
> Is there any way, short of using mem= on kernel command line and
> reserving memory, to allocate more than 4M of contigous physical memory?
> We're trying to allocalte a 8M buffer for use in some DMA transfers for
> a bank of DSP's.
> We were using get_Free_pages to allocate the meory before we made the
> buffer bigger. It seems that get_free_pages cannot allocate more than
> 2^10 pages (4M on ppc)
> I also tried alloc_bootmem, but it fails also.
alloc_bootmem is supposed to handle this case, but you can only call
that very early in your code, before the buddy allocator kicks in
(free_all_bootmem()). Maybe you should just check why it fails for you.
Arnd <><
^ permalink raw reply [flat|nested] 4+ messages in thread
* RE: Allocalting > 4M
2006-09-27 21:00 ` Arnd Bergmann
@ 2006-09-27 21:29 ` Rune Torgersen
0 siblings, 0 replies; 4+ messages in thread
From: Rune Torgersen @ 2006-09-27 21:29 UTC (permalink / raw)
To: Arnd Bergmann, linuxppc-embedded
=20
> -----Original Message-----
> From: Arnd Bergmann [mailto:arnd@arndb.de]=20
> alloc_bootmem is supposed to handle this case, but you can only call
> that very early in your code, before the buddy allocator kicks in
> (free_all_bootmem()). Maybe you should just check why it=20
> fails for you.
I was calling it in the wrong board init function.=20
m82xx_board_init was too early, and our platform_init was too late.
It works now.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2006-09-27 21:30 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-09-27 20:34 Allocalting > 4M Rune Torgersen
2006-09-27 20:58 ` Roger Larsson
2006-09-27 21:00 ` Arnd Bergmann
2006-09-27 21:29 ` Rune Torgersen
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox