public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* increasing memory alloted for 'init' during kernel boot.
@ 2010-08-31  6:49 Prabhu Chawandi
  2010-08-31  8:22 ` Jiri Slaby
  0 siblings, 1 reply; 5+ messages in thread
From: Prabhu Chawandi @ 2010-08-31  6:49 UTC (permalink / raw)
  To: linux-kernel, linux-mips

Hi all,

   Whenever the kernel starts booting, I am getting the bellow log :

Memory: 110080k/262144k available (2566k kernel code, 151952k
reserved, 561k data, 15328k init, 0k highmem).

For 'init' on what bases this amount of memory is decided ?

Anyways I can alter it?

Thanks in advance,
Prabhu

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: increasing memory alloted for 'init' during kernel boot.
  2010-08-31  6:49 increasing memory alloted for 'init' during kernel boot Prabhu Chawandi
@ 2010-08-31  8:22 ` Jiri Slaby
  2010-08-31  8:43   ` Prabhu Chawandi
  0 siblings, 1 reply; 5+ messages in thread
From: Jiri Slaby @ 2010-08-31  8:22 UTC (permalink / raw)
  To: Prabhu Chawandi; +Cc: linux-kernel, linux-mips

On 08/31/2010 08:49 AM, Prabhu Chawandi wrote:
> Hi all,
> 
>    Whenever the kernel starts booting, I am getting the bellow log :
> 
> Memory: 110080k/262144k available (2566k kernel code, 151952k
> reserved, 561k data, 15328k init, 0k highmem).
> 
> For 'init' on what bases this amount of memory is decided ?
> 
> Anyways I can alter it?

Nope. It's code and data inside .init, .exit and similar sections. Those
are marked by __init, __exit etc. in the code. This memory is freed
after the kernel is up and running, since this memory (code and data) is
not needed anymore.

regards,
-- 
js

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: increasing memory alloted for 'init' during kernel boot.
  2010-08-31  8:22 ` Jiri Slaby
@ 2010-08-31  8:43   ` Prabhu Chawandi
  2010-08-31 12:51     ` Jiri Slaby
  0 siblings, 1 reply; 5+ messages in thread
From: Prabhu Chawandi @ 2010-08-31  8:43 UTC (permalink / raw)
  To: Jiri Slaby; +Cc: linux-kernel, linux-mips, listar

Hi ,

Thanks for the info...

Problem I am facing is, I have two bootloaders, when I boot from one
loader booting happens properly.

but when I try to load from other loader, kernel does not boot, it
crashes. When i saw the boot logs, I saw that I memory allocated to
'init' section in case of crash is short by almost 5MB to the normal
boot log.

I am using mips processor.

Any idea, why this might be happening ?

thanks,
Prabhu

On Tue, Aug 31, 2010 at 1:52 PM, Jiri Slaby <jirislaby@gmail.com> wrote:
> On 08/31/2010 08:49 AM, Prabhu Chawandi wrote:
>> Hi all,
>>
>>    Whenever the kernel starts booting, I am getting the bellow log :
>>
>> Memory: 110080k/262144k available (2566k kernel code, 151952k
>> reserved, 561k data, 15328k init, 0k highmem).
>>
>> For 'init' on what bases this amount of memory is decided ?
>>
>> Anyways I can alter it?
>
> Nope. It's code and data inside .init, .exit and similar sections. Those
> are marked by __init, __exit etc. in the code. This memory is freed
> after the kernel is up and running, since this memory (code and data) is
> not needed anymore.
>
> regards,
> --
> js
>

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: increasing memory alloted for 'init' during kernel boot.
  2010-08-31  8:43   ` Prabhu Chawandi
@ 2010-08-31 12:51     ` Jiri Slaby
  2010-08-31 12:58       ` Sam Ravnborg
  0 siblings, 1 reply; 5+ messages in thread
From: Jiri Slaby @ 2010-08-31 12:51 UTC (permalink / raw)
  To: Prabhu Chawandi; +Cc: linux-kernel, listar

On 08/31/2010 10:43 AM, Prabhu Chawandi wrote:
> Hi ,
> 
> Thanks for the info...
> 
> Problem I am facing is, I have two bootloaders, when I boot from one
> loader booting happens properly.
> 
> but when I try to load from other loader, kernel does not boot, it
> crashes. When i saw the boot logs, I saw that I memory allocated to
> 'init' section in case of crash is short by almost 5MB to the normal
> boot log.
> 
> I am using mips processor.
> 
> Any idea, why this might be happening ?

The bad loader probably loads the image wrong (incorrect data or not
whole image).

regards,
-- 
js

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: increasing memory alloted for 'init' during kernel boot.
  2010-08-31 12:51     ` Jiri Slaby
@ 2010-08-31 12:58       ` Sam Ravnborg
  0 siblings, 0 replies; 5+ messages in thread
From: Sam Ravnborg @ 2010-08-31 12:58 UTC (permalink / raw)
  To: Jiri Slaby; +Cc: Prabhu Chawandi, linux-kernel, listar

On Tue, Aug 31, 2010 at 02:51:54PM +0200, Jiri Slaby wrote:
> On 08/31/2010 10:43 AM, Prabhu Chawandi wrote:
> > Hi ,
> > 
> > Thanks for the info...
> > 
> > Problem I am facing is, I have two bootloaders, when I boot from one
> > loader booting happens properly.
> > 
> > but when I try to load from other loader, kernel does not boot, it
> > crashes. When i saw the boot logs, I saw that I memory allocated to
> > 'init' section in case of crash is short by almost 5MB to the normal
> > boot log.
> > 
> > I am using mips processor.
> > 
> > Any idea, why this might be happening ?
> 
> The bad loader probably loads the image wrong (incorrect data or not
> whole image).

Shmulik just posted a patch that may be related.
See: "MIPS: Calculate VMLINUZ_LOAD_ADDRESS based on the length of vmlinux.bin"

Looks like a bug I have introduced btw :-(

	Sam

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2010-08-31 12:58 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-08-31  6:49 increasing memory alloted for 'init' during kernel boot Prabhu Chawandi
2010-08-31  8:22 ` Jiri Slaby
2010-08-31  8:43   ` Prabhu Chawandi
2010-08-31 12:51     ` Jiri Slaby
2010-08-31 12:58       ` Sam Ravnborg

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox