[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <F38DEABE0E171746B133C1ABBD142D9706325502@radmail.Radstone.Local>
Date: Wed, 7 Feb 2007 16:47:20 -0000
From: "Martyn Welch" <martyn.welch@...stone.co.uk>
To: "Asgard" <dubalom@...il.com>, <linux-kernel@...r.kernel.org>
Subject: RE: alloc_bootmem - Kernel panic
Hi Asgard,
Thank you for your reply.
> I don't sure, that linux performs to allocate bootmem after kernel already booted.
> As I know, bootmem allocator "destroyed" when kernel initializes buddy allocator.
> Indeed you can look at arch/i385/mm/init.c, mem_init routine.
> kernel passes all bootmem pages to buddy system, so bootmem allocator can't be used after it.
That explains why I can't use alloc_bootmem. It'd assumed that do_initcalls and hence functions labelled with module_init() were called early enough, mainly because LDD3 suggests using alloc_bootmem. It seems the vt driver uses console_init() instead, which is called much earlier.
Which leads me to the question: what is the best method to reserve a large (~4MB) coherent buffer for DMA transfers?
Is there any way of using alloc_bootmem from a driver (compiled into the kernel) without delving further into kernel code?
Martyn
________________________________________________________________________
This e-mail has been scanned for all viruses by Star.The service is powered by MessageLabs.
________________________________________________________________________
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists