* i.MX 257 ARM-CPU: framebuffer error "division by zero"
@ 2012-11-07 14:00 Stefan Koch
2012-11-07 14:23 ` Stefan Koch
2012-11-07 20:33 ` Stefan Koch
0 siblings, 2 replies; 3+ messages in thread
From: Stefan Koch @ 2012-11-07 14:00 UTC (permalink / raw)
To: linux-fbdev
Hello,
I'm porting Linux 3.6.2 to a board with Freescale IMX 257 ARMv5-CPU.
Linux works mostly, kernel can run, and Debian can run with kernel, too.
So I can get access via UART to Debian's Linux console and install
packages via apt-get and so on.
The next step is to enable the graphics support.
This does the line "imx25_add_imx_fb(&mx25cevipro_fb_pdata);" that
enables the fb.
Linux kernel works fine when this line is commented out, but when it's
active the kernel stops working before print out the first kernel
message on serial line.
So openocd prints with general U-Boot kernel boot (with enabled fb):
WARNING: unknown debug reason: 0xf
ThumbEE -- incomplete support
target state: halted
target halted in ThumbEE state due to debug-request, current mode: System
cpsr: 0xffffffff pc: 0xfffffff9
MMU: enabled, D-Cache: enabled, I-Cache: enabled
If I use gdb for loading and step through the source beginning from
add_imx_fb(...) line then I will get these output from openocd:
Unable to set 32 bit software breakpoint at address 8057c7e0 - check
that memory is read/writable
Unable to set 32 bit software breakpoint at address 8057c7e0 - check
that memory is read/writable
breakpoint not set
> poll
background polling: on
TAP: imx25.cpu (enabled)
target state: halted
target halted in ARM state due to breakpoint, current mode: Supervisor
cpsr: 0x40000013 pc: 0x8057c7e0
MMU: enabled, D-Cache: enabled, I-Cache: enabled
pc doesn't change anymore (so there are no code steps possible after
this moment).
The board bsp (with the add_imx_fb(...) line) is this one:
http://paste.debian.net/hidden/10d828f8/
And this is based on bsp from Freescale MX25 3DS board:
http://paste.debian.net/hidden/50ada4ee/ or
arch/arm/mach-imx/mach-mx25_3ds.c in kernel tree
There a two screenshots from ddd-Debugger attached.
The on is code view, and the other the backtrace.
What could be the problem?
Could be a kernel bug?
Could be this a problem?:
"imx-sdma imx35-sdma: firmware not found" appears when booting the
kernel without enabled fb.
In FB enabled kernel's the last debugable function is
imx_add_platform_device_dmamask()
Both have "dma" in the string...
But for loading a firmware from filesystem, the kernel crashes to early,
I think.
(The display is connected via LVDS).
-------------------------
If I add "video=imxfb:SVGA-16@60" to kernel command line, then there are
new messages when init fb within BSP file:
Division by zero in kernel.
[<80019ba4>] (unwind_backtrace+0x0/0xf4) from [<8022accc>] (Ldiv0+0x8/0x10)
[<8022accc>] (Ldiv0+0x8/0x10) from [<8022ac9c>] (__aeabi_uidivmod+0x8/0x18)
[<8022ac9c>] (__aeabi_uidivmod+0x8/0x18) from [<80254198>]
(cfb_imageblit+0x1fc/0x4b0)
[<80254198>] (cfb_imageblit+0x1fc/0x4b0) from [<80251c94>]
(soft_cursor+0x158/0x1bc)
[<80251c94>] (soft_cursor+0x158/0x1bc) from [<80251664>]
(bit_cursor+0x4ac/0x4c8)
[<80251664>] (bit_cursor+0x4ac/0x4c8) from [<8024bcd8>]
(fb_flashcursor+0x108/0x124)
[<8024bcd8>] (fb_flashcursor+0x108/0x124) from [<8003cc00>]
(process_one_work+0x188/0x4fc)
[<8003cc00>] (process_one_work+0x188/0x4fc) from [<8003d458>]
(worker_thread+0x130/0x598)
[<8003d458>] (worker_thread+0x130/0x598) from [<80043ef0>]
(kthread+0x8c/0x98)
[<80043ef0>] (kthread+0x8c/0x98) from [<80015268>]
(kernel_thread_exit+0x0/0x8)
Division by zero in kernel.
Without this command line parameter the "cpsr: 0xffffffff pc:
0xfffffff9" error still occurs.
Is this a bug in the driver?
Thank you
Stefan Koch
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: i.MX 257 ARM-CPU: framebuffer error "division by zero"
2012-11-07 14:00 i.MX 257 ARM-CPU: framebuffer error "division by zero" Stefan Koch
@ 2012-11-07 14:23 ` Stefan Koch
2012-11-07 20:33 ` Stefan Koch
1 sibling, 0 replies; 3+ messages in thread
From: Stefan Koch @ 2012-11-07 14:23 UTC (permalink / raw)
To: linux-fbdev
This mail includes the described two attached screenshots from first mail:
CODE-Screenshot: http://imageshack.us/a/img23/7507/codet.png
BACKTRACE-Screenshot: http://imageshack.us/a/img21/3209/backtrace.png
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: i.MX 257 ARM-CPU: framebuffer error "division by zero"
2012-11-07 14:00 i.MX 257 ARM-CPU: framebuffer error "division by zero" Stefan Koch
2012-11-07 14:23 ` Stefan Koch
@ 2012-11-07 20:33 ` Stefan Koch
1 sibling, 0 replies; 3+ messages in thread
From: Stefan Koch @ 2012-11-07 20:33 UTC (permalink / raw)
To: linux-fbdev
The error snipped in first post is not from the beginning it's from the end.
This is from the beginning.
And there is named "imxfb", too.
For this error "video=imxfb:SVGA-16@60" is set in kernel command line:
The full messages are here: http://paste.debian.net/hidden/3d16ba27/
[<80246f78>] (register_framebuffer+0x17c/0x230) from [<80586ab8>]
(imxfb_probe+0x3c8/0x5a8)
[<80586ab8>] (imxfb_probe+0x3c8/0x5a8) from [<80286ba8>]
(platform_drv_probe+0x14/0x18)
[<80286ba8>] (platform_drv_probe+0x14/0x18) from [<802858b0>]
(driver_probe_device+0x80/0x20c)
[<802858b0>] (driver_probe_device+0x80/0x20c) from [<80285ac8>]
(__driver_attach+0x8c/0x90)
[<80285ac8>] (__driver_attach+0x8c/0x90) from [<80284230>]
(bus_for_each_dev+0x64/0x8c)
[<80284230>] (bus_for_each_dev+0x64/0x8c) from [<802849b0>]
(bus_add_driver+0xa4/0x230)
[<802849b0>] (bus_add_driver+0xa4/0x230) from [<80286098>]
(driver_register+0x78/0x140)
[<80286098>] (driver_register+0x78/0x140) from [<80286ef4>]
(platform_driver_probe+0x18/0x9c)
[<80286ef4>] (platform_driver_probe+0x18/0x9c) from [<805866d8>]
(imxfb_init+0x88/0xa0)
[<805866d8>] (imxfb_init+0x88/0xa0) from [<800087e4>]
(do_one_initcall+0x30/0x178)
[<800087e4>] (do_one_initcall+0x30/0x178) from [<80576310>]
(kernel_init+0xe4/0x1b0)
[<80576310>] (kernel_init+0xe4/0x1b0) from [<80015268>]
(kernel_thread_exit+0x0/0x8)
Division by zero in kernel.
[<80019ba4>] (unwind_backtrace+0x0/0xf4) from [<8022accc>] (Ldiv0+0x8/0x10)
[<8022accc>] (Ldiv0+0x8/0x10) from [<8022ac9c>] (__aeabi_uidivmod+0x8/0x18)
[<8022ac9c>] (__aeabi_uidivmod+0x8/0x18) from [<80254198>]
(cfb_imageblit+0x1fc/0x4b0)
[<80254198>] (cfb_imageblit+0x1fc/0x4b0) from [<80251964>]
(bit_putcs+0x2e4/0x420)
[<80251964>] (bit_putcs+0x2e4/0x420) from [<8024bde0>]
(fbcon_putcs+0xec/0x128)
[<8024bde0>] (fbcon_putcs+0xec/0x128) from [<802741f8>]
(do_update_region+0x108/0x18c)
[<802741f8>] (do_update_region+0x108/0x18c) from [<80275970>]
(update_region+0x70/0x88)
[<80275970>] (update_region+0x70/0x88) from [<8024dd08>]
(fbcon_switch+0x468/0x4bc)
[<8024dd08>] (fbcon_switch+0x468/0x4bc) from [<80276c84>]
(redraw_screen+0x15c/0x278)
[<80276c84>] (redraw_screen+0x15c/0x278) from [<80279e90>]
(take_over_console+0x2cc/0x37c)
[<80279e90>] (take_over_console+0x2cc/0x37c) from [<8024cacc>]
(fbcon_takeover+0x70/0xd4)
[<8024cacc>] (fbcon_takeover+0x70/0xd4) from [<8042541c>]
(notifier_call_chain+0x44/0x84)
[<8042541c>] (notifier_call_chain+0x44/0x84) from [<8004a2a0>]
(__blocking_notifier_call_chain+0x4c/0x64)
[<8004a2a0>] (__blocking_notifier_call_chain+0x4c/0x64) from
[<8004a2d0>] (blocking_notifier_call_chain+0x18/0x20)
[<8004a2d0>] (blocking_notifier_call_chain+0x18/0x20) from [<80246f78>]
(register_framebuffer+0x17c/0x230)
[<80246f78>] (register_framebuffer+0x17c/0x230) from [<80586ab8>]
(imxfb_probe+0x3c8/0x5a8)
[<80586ab8>] (imxfb_probe+0x3c8/0x5a8) from [<80286ba8>]
(platform_drv_probe+0x14/0x18)
[<80286ba8>] (platform_drv_probe+0x14/0x18) from [<802858b0>]
(driver_probe_device+0x80/0x20c)
[<802858b0>] (driver_probe_device+0x80/0x20c) from [<80285ac8>]
(__driver_attach+0x8c/0x90)
[<80285ac8>] (__driver_attach+0x8c/0x90) from [<80284230>]
(bus_for_each_dev+0x64/0x8c)
[<80284230>] (bus_for_each_dev+0x64/0x8c) from [<802849b0>]
(bus_add_driver+0xa4/0x230)
[<802849b0>] (bus_add_driver+0xa4/0x230) from [<80286098>]
(driver_register+0x78/0x140)
[<80286098>] (driver_register+0x78/0x140) from [<80286ef4>]
(platform_driver_probe+0x18/0x9c)
[<80286ef4>] (platform_driver_probe+0x18/0x9c) from [<805866d8>]
(imxfb_init+0x88/0xa0)
[<805866d8>] (imxfb_init+0x88/0xa0) from [<800087e4>]
(do_one_initcall+0x30/0x178)
[<800087e4>] (do_one_initcall+0x30/0x178) from [<80576310>]
(kernel_init+0xe4/0x1b0)
[<80576310>] (kernel_init+0xe4/0x1b0) from [<80015268>]
(kernel_thread_exit+0x0/0x8)
Without this setting the CPU does stop working (for JTAG debugger it has
the same effect as board is in power off state):
177772 bytes written at address 0x811ffc00
downloaded 177772 bytes in 19.548666s (8.881 KiB/s)
WARNING: unknown debug reason: 0xf
ThumbEE -- incomplete support
target state: halted
target halted in ThumbEE state due to debug-request, current mode: System
cpsr: 0xffffffff pc: 0xfffffff9
MMU: enabled, D-Cache: enabled, I-Cache: enabled
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2012-11-07 20:33 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-11-07 14:00 i.MX 257 ARM-CPU: framebuffer error "division by zero" Stefan Koch
2012-11-07 14:23 ` Stefan Koch
2012-11-07 20:33 ` Stefan Koch
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).