Hi All,
We are using nand from micron with omap4460 as a boot device.
Nand is connected to gpmc in 8 bit mode and at cs0.
We are planning to port ubuntu 12.04 on our device and our kernel version is 3.10.12
I have configured proper pin mux for gpmc. We are not providing any CS size and base address for cs0 as somewhere on this forum i have read that size doesn't matter in the case of nand like device.
I am getting following log messages.
[ 0.361724] gpmc_l3_clk not enabled
[ 0.361724] gpmc_l3_clk not enabled
[ 0.361724] Division by zero in kernel.
[ 0.361755] CPU: 0 PID: 1 Comm: swapper/0 Not tainted 3.10.12-svn113 #1
[ 0.361785] [<c001a960>] (unwind_backtrace+0x0/0xf0) from [<c00173b0>] (show_stack+0x10/0x14)
[ 0.361816] [<c00173b0>] (show_stack+0x10/0x14) from [<c02b3134>] (Ldiv0+0x8/0x10)
[ 0.361846] [<c02b3134>] (Ldiv0+0x8/0x10) from [<c0026424>] (gpmc_calc_divider+0x24/0x40)
[ 0.361846] [<c0026424>] (gpmc_calc_divider+0x24/0x40) from [<c00264a4>] (gpmc_cs_set_timings+0x18/0x474)
[ 0.361877] [<c00264a4>] (gpmc_cs_set_timings+0x18/0x474) from [<c0039428>] (omap2_nand_gpmc_retime+0xac/0xb4)
[ 0.361907] [<c0039428>] (omap2_nand_gpmc_retime+0xac/0xb4) from [<c00394a4>] (gpmc_nand_init+0x74/0x1f4)
[ 0.361907] [<c00394a4>] (gpmc_nand_init+0x74/0x1f4) from [<c0876fd8>] (omap4_panda_init+0x3a8/0x444)
[ 0.361938] [<c0876fd8>] (omap4_panda_init+0x3a8/0x444) from [<c086871c>] (customize_machine+0x1c/0x40)
[ 0.361968] [<c086871c>] (customize_machine+0x1c/0x40) from [<c0008764>] (do_one_initcall+0x34/0x164)
[ 0.361999] [<c0008764>] (do_one_initcall+0x34/0x164) from [<c0865b74>] (kernel_init_freeable+0xfc/0x1c8)
[ 0.361999] [<c0865b74>] (kernel_init_freeable+0xfc/0x1c8) from [<c05fc1c0>] (kernel_init+0x8/0xe4)
[ 0.362030] [<c05fc1c0>] (kernel_init+0x8/0xe4) from [<c00132e8>] (ret_from_fork+0x14/0x2c)
[ 0.362060] gpmc_l3_clk not enabled
[ 0.362060] Division by zero in kernel.
[ 0.362060] CPU: 0 PID: 1 Comm: swapper/0 Not tainted 3.10.12-svn113 #1
[ 0.362091] [<c001a960>] (unwind_backtrace+0x0/0xf0) from [<c00173b0>] (show_stack+0x10/0x14)
[ 0.362121] [<c00173b0>] (show_stack+0x10/0x14) from [<c02b3134>] (Ldiv0+0x8/0x10)
[ 0.362121] [<c02b3134>] (Ldiv0+0x8/0x10) from [<c00262e8>] (set_gpmc_timing_reg+0x84/0x98)
[ 0.362152] [<c00262e8>] (set_gpmc_timing_reg+0x84/0x98) from [<c00264c8>] (gpmc_cs_set_timings+0x3c/0x474)
[ 0.362152] [<c00264c8>] (gpmc_cs_set_timings+0x3c/0x474) from [<c0039428>] (omap2_nand_gpmc_retime+0xac/0xb4)
[ 0.362182] [<c0039428>] (omap2_nand_gpmc_retime+0xac/0xb4) from [<c00394a4>] (gpmc_nand_init+0x74/0x1f4)
[ 0.362213] [<c00394a4>] (gpmc_nand_init+0x74/0x1f4) from [<c0876fd8>] (omap4_panda_init+0x3a8/0x444)
[ 0.362213] [<c0876fd8>] (omap4_panda_init+0x3a8/0x444) from [<c086871c>] (customize_machine+0x1c/0x40)
[ 0.362243] [<c086871c>] (customize_machine+0x1c/0x40) from [<c0008764>] (do_one_initcall+0x34/0x164)
[ 0.362274] [<c0008764>] (do_one_initcall+0x34/0x164) from [<c0865b74>] (kernel_init_freeable+0xfc/0x1c8)
[ 0.362274] [<c0865b74>] (kernel_init_freeable+0xfc/0x1c8) from [<c05fc1c0>] (kernel_init+0x8/0xe4)
[ 0.362304] [<c05fc1c0>] (kernel_init+0x8/0xe4) from [<c00132e8>] (ret_from_fork+0x14/0x2c)
[ 0.362304] gpmc_l3_clk not enabled
[ 0.362335] Division by zero in kernel.
[ 0.362335] CPU: 0 PID: 1 Comm: swapper/0 Not tainted 3.10.12-svn113 #1
[ 0.362365] [<c001a960>] (unwind_backtrace+0x0/0xf0) from [<c00173b0>] (show_stack+0x10/0x14)
[ 0.362365] [<c00173b0>] (show_stack+0x10/0x14) from [<c02b3134>] (Ldiv0+0x8/0x10)
[ 0.362396] [<c02b3134>] (Ldiv0+0x8/0x10) from [<c00262e8>] (set_gpmc_timing_reg+0x84/0x98)
[ 0.362396] [<c00262e8>] (set_gpmc_timing_reg+0x84/0x98) from [<c00265c4>] (gpmc_cs_set_timings+0x138/0x474)
[ 0.362426] [<c00265c4>] (gpmc_cs_set_timings+0x138/0x474) from [<c0039428>] (omap2_nand_gpmc_retime+0xac/0xb4)
[ 0.362457] [<c0039428>] (omap2_nand_gpmc_retime+0xac/0xb4) from [<c00394a4>] (gpmc_nand_init+0x74/0x1f4)
[ 0.362457] [<c00394a4>] (gpmc_nand_init+0x74/0x1f4) from [<c0876fd8>] (omap4_panda_init+0x3a8/0x444)
[ 0.362487] [<c0876fd8>] (omap4_panda_init+0x3a8/0x444) from [<c086871c>] (customize_machine+0x1c/0x40)
[ 0.362518] [<c086871c>] (customize_machine+0x1c/0x40) from [<c0008764>] (do_one_initcall+0x34/0x164)
[ 0.362518] [<c0008764>] (do_one_initcall+0x34/0x164) from [<c0865b74>] (kernel_init_freeable+0xfc/0x1c8)
[ 0.362548] [<c0865b74>] (kernel_init_freeable+0xfc/0x1c8) from [<c05fc1c0>] (kernel_init+0x8/0xe4)
[ 0.362548] [<c05fc1c0>] (kernel_init+0x8/0xe4) from [<c00132e8>] (ret_from_fork+0x14/0x2c)
[ 0.362579] gpmc_l3_clk not enabled
[ 0.362579] Division by zero in kernel.
[ 0.362579] CPU: 0 PID: 1 Comm: swapper/0 Not tainted 3.10.12-svn113 #1
[ 0.362609] [<c001a960>] (unwind_backtrace+0x0/0xf0) from [<c00173b0>] (show_stack+0x10/0x14)
[ 0.362640] [<c00173b0>] (show_stack+0x10/0x14) from [<c02b3134>] (Ldiv0+0x8/0x10)
[ 0.362640] [<c02b3134>] (Ldiv0+0x8/0x10) from [<c00262e8>] (set_gpmc_timing_reg+0x84/0x98)
[ 0.362670] [<c00262e8>] (set_gpmc_timing_reg+0x84/0x98) from [<c002660c>] (gpmc_cs_set_timings+0x180/0x474)
[ 0.362670] [<c002660c>] (gpmc_cs_set_timings+0x180/0x474) from [<c0039428>] (omap2_nand_gpmc_retime+0xac/0xb4)
[ 0.362701] [<c0039428>] (omap2_nand_gpmc_retime+0xac/0xb4) from [<c00394a4>] (gpmc_nand_init+0x74/0x1f4)
[ 0.362731] [<c00394a4>] (gpmc_nand_init+0x74/0x1f4) from [<c0876fd8>] (omap4_panda_init+0x3a8/0x444)
[ 0.362731] [<c0876fd8>] (omap4_panda_init+0x3a8/0x444) from [<c086871c>] (customize_machine+0x1c/0x40)
[ 0.362762] [<c086871c>] (customize_machine+0x1c/0x40) from [<c0008764>] (do_one_initcall+0x34/0x164)
[ 0.362762] [<c0008764>] (do_one_initcall+0x34/0x164) from [<c0865b74>] (kernel_init_freeable+0xfc/0x1c8)
[ 0.362792] [<c0865b74>] (kernel_init_freeable+0xfc/0x1c8) from [<c05fc1c0>] (kernel_init+0x8/0xe4)
[ 0.362823] [<c05fc1c0>] (kernel_init+0x8/0xe4) from [<c00132e8>] (ret_from_fork+0x14/0x2c)
[ 0.362823] gpmc_l3_clk not enabled
[ 0.362823] Division by zero in kernel.
[ 0.362854] CPU: 0 PID: 1 Comm: swapper/0 Not tainted 3.10.12-svn113 #1
[ 0.362854] [<c001a960>] (unwind_backtrace+0x0/0xf0) from [<c00173b0>] (show_stack+0x10/0x14)
[ 0.362884] [<c00173b0>] (show_stack+0x10/0x14) from [<c02b3134>] (Ldiv0+0x8/0x10)
My questions are:
How can i enable gpmc clock ?
gpmc_l3_clk not enabled
above message i am getting from gpmc.c
static unsigned long gpmc_get_fclk_period(void)
{
unsigned long rate = clk_get_rate(gpmc_l3_clk);
if (rate == 0) {
printk(KERN_WARNING "gpmc_l3_clk not enabled\n");
return 0;
}
rate /= 1000;
rate = 1000000000 / rate; /* In picoseconds */
return rate;
}
So, here we are not able to get the clock.
In, arch/arm/mach-omap2/cclock44xx_data.c file, gpmc clock is configured like.
CLK("omap-gpmc", "fck", &dummy_ck),
i think we need to write another structrure here instead of dummy_ck.
Could anyone here help me?
-------------------------------------------------------------------------------------------------------------------------------------
Thanks,
Jags Gedia