Linux MIPS Architecture development
 help / color / mirror / Atom feed
* Ooops in kmalloc from request_region
@ 2001-02-14  4:00 Liam Davies
  2001-02-14 13:16 ` Steve Johnson
  0 siblings, 1 reply; 3+ messages in thread
From: Liam Davies @ 2001-02-14  4:00 UTC (permalink / raw)
  To: linux-mips


I am currently at the stage of calling request_region in my irq_setup 
function.
The call to request_region does a kmalloc which oops. The box has 256Mb Ram.

Is this the right stage to be doing this call? Is there something that I 
have missed
in setting up the memory regions or paging?


Thanks
Liam Davies



Unable to handle kernel paging request at virtual address 10003278, epc 
== 80035314, ra == 800a1d60
Oops in fault.c:do_page_fault, line 172:


static void __init cobalt_irq_setup(void)
{
       set_cp0_status(ST0_IM, 0);

       set_except_vector(0, cobalt_handle_int);

---->> request_region(0xb0000020, 0x20, "pic1");
       request_region(0xb00000A0, 0x20, "pic2");
...

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

* Re: Ooops in kmalloc from request_region
  2001-02-14  4:00 Ooops in kmalloc from request_region Liam Davies
@ 2001-02-14 13:16 ` Steve Johnson
  2001-02-14 13:19   ` Geert Uytterhoeven
  0 siblings, 1 reply; 3+ messages in thread
From: Steve Johnson @ 2001-02-14 13:16 UTC (permalink / raw)
  To: ldavies; +Cc: linux-mips

Liam,

    You can't call kmalloc that early in the startup process.  Look at main.c,
and init_IRQ comes before any of the memory initialization.

    Steve

Liam Davies wrote:

> I am currently at the stage of calling request_region in my irq_setup
> function.
> The call to request_region does a kmalloc which oops. The box has 256Mb Ram.
>
> Is this the right stage to be doing this call? Is there something that I
> have missed
> in setting up the memory regions or paging?
>

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

* Re: Ooops in kmalloc from request_region
  2001-02-14 13:16 ` Steve Johnson
@ 2001-02-14 13:19   ` Geert Uytterhoeven
  0 siblings, 0 replies; 3+ messages in thread
From: Geert Uytterhoeven @ 2001-02-14 13:19 UTC (permalink / raw)
  To: Steve Johnson; +Cc: ldavies, linux-mips

On Wed, 14 Feb 2001, Steve Johnson wrote:
>     You can't call kmalloc that early in the startup process.  Look at main.c,
> and init_IRQ comes before any of the memory initialization.
> 
>     Steve
> 
> Liam Davies wrote:
> 
> > I am currently at the stage of calling request_region in my irq_setup
> > function.
> > The call to request_region does a kmalloc which oops. The box has 256Mb Ram.
> >
> > Is this the right stage to be doing this call? Is there something that I
> > have missed
> > in setting up the memory regions or paging?

Hence use request_resource() while passing a statically allocated and
initialized struct resource instead.

Gr{oetje,eeting}s,

						Geert

--
Geert Uytterhoeven ------------- Sony Software Development Center Europe (SDCE)
Geert.Uytterhoeven@sonycom.com ------------------- Sint-Stevens-Woluwestraat 55
Voice +32-2-7248626 Fax +32-2-7262686 ---------------- B-1130 Brussels, Belgium

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

end of thread, other threads:[~2001-02-14 13:21 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2001-02-14  4:00 Ooops in kmalloc from request_region Liam Davies
2001-02-14 13:16 ` Steve Johnson
2001-02-14 13:19   ` Geert Uytterhoeven

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