* [U-Boot] Prefetch abort exception @ 2014-01-13 13:30 Parimala Baggiri 2014-01-14 6:00 ` Albert ARIBAUD 0 siblings, 1 reply; 4+ messages in thread From: Parimala Baggiri @ 2014-01-13 13:30 UTC (permalink / raw) To: u-boot Hello, I have added interrupt support for armv7 platform, by implementing the do_irq and irq_install_handler and arch_interrupt_init functions. Initially default_isr is the handler function installed for all the interrupts. ^ permalink raw reply [flat|nested] 4+ messages in thread
* [U-Boot] Prefetch abort exception 2014-01-13 13:30 [U-Boot] Prefetch abort exception Parimala Baggiri @ 2014-01-14 6:00 ` Albert ARIBAUD 2014-01-16 12:25 ` Parimala Baggiri 0 siblings, 1 reply; 4+ messages in thread From: Albert ARIBAUD @ 2014-01-14 6:00 UTC (permalink / raw) To: u-boot Hi Parimala, On Mon, 13 Jan 2014 19:00:04 +0530, Parimala Baggiri <baggiriparimala@gmail.com> wrote: > Hello, > > I have added interrupt support for armv7 platform, by implementing the > do_irq and irq_install_handler and arch_interrupt_init functions. > > Initially default_isr is the handler function installed for all the > interrupts. > > From my standalone application, I am enabling the interrupts and installing > the handler to be called for my peripheral interrupt. > > If I don't install my handler, U-Boot executes default_isr successfully. > > If I use my handler, when the interrupt occurs I am getting the prefetch > abort exception with the following dump > prefetch abort > pc : [<ebd78002>] lr : [<bff8f720>] > sp : bfeef200 ip : bfeef358 fp : bfef1d48 > r10: bfef1d78 r9 : 00000002 r8 : bfeeff58 > r7 : bffac284 r6 : 60000153 r5 : bffbb5c0 r4 : 00000000 > r3 : bffab29c r2 : 00000000 r1 : 000003e8 r0 : 8500178c > Flags: nZCv IRQs off FIQs off Mode IRQ_32 > Resetting CPU ... > > resetting ... > > U-Boot SPL 2013.01.-rc1-00003-g43ee87a-dirty (Jan 10 2014 - 16:04:35) > OMAP4460 ES1.1 > OMAP SD/MMC: 0 > reading u-boot.img > reading u-boot.img > > Can any one please help me to solve this? You're the best suited to tell, since you're the only one who can read or test the code, so the following question is just a wild guess: does the interrupt handler properly save (and restore) the interrupted context, and does it properly establish (and dispose of) its own context? Amicalement, -- Albert. ^ permalink raw reply [flat|nested] 4+ messages in thread
* [U-Boot] Prefetch abort exception 2014-01-14 6:00 ` Albert ARIBAUD @ 2014-01-16 12:25 ` Parimala Baggiri 2014-01-16 13:20 ` Albert ARIBAUD 0 siblings, 1 reply; 4+ messages in thread From: Parimala Baggiri @ 2014-01-16 12:25 UTC (permalink / raw) To: u-boot Hello, On Tue, Jan 14, 2014 at 11:30 AM, Albert ARIBAUD <albert.u.boot@aribaud.net>wrote: > Hi Parimala, > > On Mon, 13 Jan 2014 19:00:04 +0530, Parimala Baggiri > <baggiriparimala@gmail.com> wrote: > > > Hello, > > > > I have added interrupt support for armv7 platform, by implementing the > > do_irq and irq_install_handler and arch_interrupt_init functions. > > > > Initially default_isr is the handler function installed for all the > > interrupts. > > > > From my standalone application, I am enabling the interrupts and > installing > > the handler to be called for my peripheral interrupt. > > > > If I don't install my handler, U-Boot executes default_isr successfully. > > > > If I use my handler, when the interrupt occurs I am getting the prefetch > > abort exception with the following dump > > prefetch abort > > pc : [<ebd78002>] lr : [<bff8f720>] > > sp : bfeef200 ip : bfeef358 fp : bfef1d48 > > r10: bfef1d78 r9 : 00000002 r8 : bfeeff58 > > r7 : bffac284 r6 : 60000153 r5 : bffbb5c0 r4 : 00000000 > > r3 : bffab29c r2 : 00000000 r1 : 000003e8 r0 : 8500178c > > Flags: nZCv IRQs off FIQs off Mode IRQ_32 > > Resetting CPU ... > > > > resetting ... > > > > U-Boot SPL 2013.01.-rc1-00003-g43ee87a-dirty (Jan 10 2014 - 16:04:35) > > OMAP4460 ES1.1 > > OMAP SD/MMC: 0 > > reading u-boot.img > > reading u-boot.img > > > > Can any one please help me to solve this? > > You're the best suited to tell, since you're the only one who can read > or test the code, so the following question is just a wild guess: does > the interrupt handler properly save (and restore) the interrupted > context, and does it properly establish (and dispose of) its own > context? > > Thank you all for the suggestions I found that, using "printf" statement within my ISR is causing the prefetch abort. Regards, Parimala ^ permalink raw reply [flat|nested] 4+ messages in thread
* [U-Boot] Prefetch abort exception 2014-01-16 12:25 ` Parimala Baggiri @ 2014-01-16 13:20 ` Albert ARIBAUD 0 siblings, 0 replies; 4+ messages in thread From: Albert ARIBAUD @ 2014-01-16 13:20 UTC (permalink / raw) To: u-boot Hi Parimala, On Thu, 16 Jan 2014 17:55:10 +0530, Parimala Baggiri <baggiriparimala@gmail.com> wrote: > Hello, > > On Tue, Jan 14, 2014 at 11:30 AM, Albert ARIBAUD > <albert.u.boot@aribaud.net>wrote: > > > Hi Parimala, > > > > On Mon, 13 Jan 2014 19:00:04 +0530, Parimala Baggiri > > <baggiriparimala@gmail.com> wrote: > > > > > Hello, > > > > > > I have added interrupt support for armv7 platform, by implementing the > > > do_irq and irq_install_handler and arch_interrupt_init functions. > > > > > > Initially default_isr is the handler function installed for all the > > > interrupts. > > > > > > From my standalone application, I am enabling the interrupts and > > installing > > > the handler to be called for my peripheral interrupt. > > > > > > If I don't install my handler, U-Boot executes default_isr successfully. > > > > > > If I use my handler, when the interrupt occurs I am getting the prefetch > > > abort exception with the following dump > > > prefetch abort > > > pc : [<ebd78002>] lr : [<bff8f720>] > > > sp : bfeef200 ip : bfeef358 fp : bfef1d48 > > > r10: bfef1d78 r9 : 00000002 r8 : bfeeff58 > > > r7 : bffac284 r6 : 60000153 r5 : bffbb5c0 r4 : 00000000 > > > r3 : bffab29c r2 : 00000000 r1 : 000003e8 r0 : 8500178c > > > Flags: nZCv IRQs off FIQs off Mode IRQ_32 > > > Resetting CPU ... > > > > > > resetting ... > > > > > > U-Boot SPL 2013.01.-rc1-00003-g43ee87a-dirty (Jan 10 2014 - 16:04:35) > > > OMAP4460 ES1.1 > > > OMAP SD/MMC: 0 > > > reading u-boot.img > > > reading u-boot.img > > > > > > Can any one please help me to solve this? > > > > You're the best suited to tell, since you're the only one who can read > > or test the code, so the following question is just a wild guess: does > > the interrupt handler properly save (and restore) the interrupted > > context, and does it properly establish (and dispose of) its own > > context? > > > > Thank you all for the suggestions > I found that, using "printf" statement within my ISR is causing the > prefetch abort. Well, it usually isn't a good idea to try and use such functions as printf() within an interrupt handler, if only because you might have interrupted a call to printf(), and printf() might not be re-entrant, which could explain the abort you see. Besides, even with a re-entrant printf() implementation, interrupting printf() to do a printf() will propably result in mangled output. > Regards, > Parimala Amicalement, -- Albert. ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2014-01-16 13:20 UTC | newest] Thread overview: 4+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2014-01-13 13:30 [U-Boot] Prefetch abort exception Parimala Baggiri 2014-01-14 6:00 ` Albert ARIBAUD 2014-01-16 12:25 ` Parimala Baggiri 2014-01-16 13:20 ` Albert ARIBAUD
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox