* how to use memory before kernel load address?
@ 2007-11-20 1:06 zhuzhenhua
2007-11-20 2:51 ` [SPAM] " Markus Gothe
2007-11-20 13:04 ` Thiemo Seufer
0 siblings, 2 replies; 5+ messages in thread
From: zhuzhenhua @ 2007-11-20 1:06 UTC (permalink / raw)
To: linux-mips
[-- Attachment #1: Type: text/plain, Size: 474 bytes --]
hello,all
i want to place my kernel loadaddr=0x81008000 and set
EBASE=0x81000000, it workes.
but there is still some memory usable before 0x81000000, for
example from 0x80100000 ~ 0x80200000
i have try to pass param as mem=1M@1M mem=16M@16M to the kernel,
it seems only take the 0x8000000 ~ kernel_end as reserved.
is there any other options to set the memory useable? ( my kernel
version is 2.6.14)
thanks for any hints
zzh
[-- Attachment #2: Type: text/html, Size: 726 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [SPAM] how to use memory before kernel load address?
2007-11-20 1:06 how to use memory before kernel load address? zhuzhenhua
@ 2007-11-20 2:51 ` Markus Gothe
2007-11-20 13:04 ` Thiemo Seufer
1 sibling, 0 replies; 5+ messages in thread
From: Markus Gothe @ 2007-11-20 2:51 UTC (permalink / raw)
To: zhuzhenhua; +Cc: linux-mips
[-- Attachment #1: Type: text/plain, Size: 622 bytes --]
Are you using a MTD, if so just create a partition there.
//Markus
On 20 Nov 2007, at 02:06, zhuzhenhua wrote:
> hello,all
> i want to place my kernel loadaddr=0x81008000 and set
> EBASE=0x81000000, it workes.
> but there is still some memory usable before 0x81000000,
> for example from 0x80100000 ~ 0x80200000
> i have try to pass param as mem=1M@1M mem=16M@16M to the
> kernel, it seems only take the 0x8000000 ~ kernel_end as reserved.
> is there any other options to set the memory useable? ( my
> kernel version is 2.6.14)
> thanks for any hints
>
>
> zzh
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 186 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: how to use memory before kernel load address?
2007-11-20 1:06 how to use memory before kernel load address? zhuzhenhua
2007-11-20 2:51 ` [SPAM] " Markus Gothe
@ 2007-11-20 13:04 ` Thiemo Seufer
2007-11-20 13:44 ` Atsushi Nemoto
2007-11-21 3:58 ` zhuzhenhua
1 sibling, 2 replies; 5+ messages in thread
From: Thiemo Seufer @ 2007-11-20 13:04 UTC (permalink / raw)
To: zhuzhenhua; +Cc: linux-mips
zhuzhenhua wrote:
> hello,all
> i want to place my kernel loadaddr=0x81008000 and set
> EBASE=0x81000000, it workes.
> but there is still some memory usable before 0x81000000, for
> example from 0x80100000 ~ 0x80200000
The obvious thing to do seems to set LOARADDR to 0x80208000.
> i have try to pass param as mem=1M@1M mem=16M@16M to the kernel,
> it seems only take the 0x8000000 ~ kernel_end as reserved.
> is there any other options to set the memory useable? ( my kernel
> version is 2.6.14)
> thanks for any hints
AFAIR the kernel assumes to occupy the lowest addresses of the usable RAM.
Thiemo
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: how to use memory before kernel load address?
2007-11-20 13:04 ` Thiemo Seufer
@ 2007-11-20 13:44 ` Atsushi Nemoto
2007-11-21 3:58 ` zhuzhenhua
1 sibling, 0 replies; 5+ messages in thread
From: Atsushi Nemoto @ 2007-11-20 13:44 UTC (permalink / raw)
To: ths; +Cc: zzh.hust, linux-mips
On Tue, 20 Nov 2007 13:04:51 +0000, Thiemo Seufer <ths@networkno.de> wrote:
> > i have try to pass param as mem=1M@1M mem=16M@16M to the kernel,
> > it seems only take the 0x8000000 ~ kernel_end as reserved.
> > is there any other options to set the memory useable? ( my kernel
> > version is 2.6.14)
> > thanks for any hints
>
> AFAIR the kernel assumes to occupy the lowest addresses of the usable RAM.
You can use prom_free_prom_memory() to give some low pages back to kernel.
---
Atsushi Nemoto
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: how to use memory before kernel load address?
2007-11-20 13:04 ` Thiemo Seufer
2007-11-20 13:44 ` Atsushi Nemoto
@ 2007-11-21 3:58 ` zhuzhenhua
1 sibling, 0 replies; 5+ messages in thread
From: zhuzhenhua @ 2007-11-21 3:58 UTC (permalink / raw)
To: Thiemo Seufer; +Cc: linux-mips
On 11/20/07, Thiemo Seufer <ths@networkno.de> wrote:
> zhuzhenhua wrote:
> > hello,all
> > i want to place my kernel loadaddr=0x81008000 and set
> > EBASE=0x81000000, it workes.
> > but there is still some memory usable before 0x81000000, for
> > example from 0x80100000 ~ 0x80200000
>
> The obvious thing to do seems to set LOARADDR to 0x80208000.
>
> > i have try to pass param as mem=1M@1M mem=16M@16M to the kernel,
> > it seems only take the 0x8000000 ~ kernel_end as reserved.
> > is there any other options to set the memory useable? ( my kernel
> > version is 2.6.14)
> > thanks for any hints
>
> AFAIR the kernel assumes to occupy the lowest addresses of the usable RAM.
>
>
> Thiemo
>
i have resolve it, by modify as follow:
in arch/mips/kernel/setup.c
static inline void bootmem_init(void)
.....
if (curr_pfn < start_pfn) // just change the judgement
curr_pfn = start_pfn;
....
/* Register lowmem ranges */
free_bootmem(PFN_PHYS(curr_pfn), PFN_PHYS(size));
thanks all.
zzh
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2007-11-21 3:58 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-11-20 1:06 how to use memory before kernel load address? zhuzhenhua
2007-11-20 2:51 ` [SPAM] " Markus Gothe
2007-11-20 13:04 ` Thiemo Seufer
2007-11-20 13:44 ` Atsushi Nemoto
2007-11-21 3:58 ` zhuzhenhua
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.