Skip to contentSkip to conversation

Problem registering interrupt

DISCUSSION moreau francis 3 participants 3 messages Dec 22, 2004 – Jan 6, 2005 1 message not in the archive MIPS

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw
Quoted 3 lines

CPU 0 Unable to handle kernel paging request at
virtual address 00000004, epc =4

Well it suggests me that your driver is trying to
access a really nasty pointer: 0x00000004...
How did you get this address ? From user space ?

Francis

Découvrez le nouveau Yahoo! Mail : 250 Mo d'espace de stockage pour vos mails ! Créez votre Yahoo! Mail sur http://fr.mail.yahoo.com/

#2 lore raw

On Wed, 2004-12-22 11:19:06 +0100, moreau francis <[email protected]> wrote in message <[email protected]>:

Quoted 7 lines
Quoted 3 lines

CPU 0 Unable to handle kernel paging request at
virtual address 00000004, epc =4

Well it suggests me that your driver is trying to
access a really nasty pointer: 0x00000004...
How did you get this address ? From user space ?

Accesses to nearly NULL are normally structure accesses where a pointer to a given struct was supplied as a NULL pointer.

So an access to 0x00000004 is most probably an access to the second element of a struct, given/expected that all fields are usually 4-byte aligned.

From looking at ./kernel/irq/manage.c:setup_irq(), I guess that you supply NULL as the "struct irqaction *", which is the 2nd argument of setup_irq(). It's 2nd structure element is "flags" then... This is the first thing accessed by the "new" pointer in setup_irq().

MfG, JBG

Signature · 4 lines
Jan-Benedict Glaw       [email protected]    . +49-172-7608481             _ O _
"Eine Freie Meinung in  einem Freien Kopf    | Gegen Zensur | Gegen Krieg  _ _ O
 fuer einen Freien Staat voll Freier Bürger" | im Internet! |   im Irak!   O O O
ret = do_actions((curr | FREE_SPEECH) & ~(NEW_COPYRIGHT_LAW | DRM | TCPA));
#3 lore raw

So the crash is happening because the handler pointer is null in the irq_desc for interrupt 49. Is there something that I was supposed to do to setup that handler before registering my interrupt? This was working fine under 2.4, is it a change in 2.6 or just in the alchemy port specifically?

Thanks for the help and happy new years,
Sébastien

Quoted 31 lines · Jan-Benedict Glaw

On Wed, 2004-12-22 11:19:06 +0100, moreau francis <[email protected]> wrote in message <[email protected]>:

Quoted 7 lines
Quoted 3 lines

CPU 0 Unable to handle kernel paging request at
virtual address 00000004, epc =4

Well it suggests me that your driver is trying to
access a really nasty pointer: 0x00000004...
How did you get this address ? From user space ?

Accesses to nearly NULL are normally structure accesses where a pointer to a given struct was supplied as a NULL pointer.

So an access to 0x00000004 is most probably an access to the second element of a struct, given/expected that all fields are usually 4-byte aligned.

Quoted 1 line

From looking at ./kernel/irq/manage.c:setup_irq(), I guess that you

supply NULL as the "struct irqaction *", which is the 2nd argument of setup_irq(). It's 2nd structure element is "flags" then... This is the first thing accessed by the "new" pointer in setup_irq().

MfG, JBG

Signature · 6 lines
Jan-Benedict Glaw       [email protected]    . +49-172-7608481         
    _ O _
"Eine Freie Meinung in  einem Freien Kopf    | Gegen Zensur | Gegen Krieg  _ _ O
 fuer einen Freien Staat voll Freier Bürger" | im Internet! |   im 
Irak!   O O O
ret = do_actions((curr | FREE_SPEECH) & ~(NEW_COPYRIGHT_LAW | DRM | TCPA));