qemu-arm
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-arm] kernel has No master clock, no CPU clock, when running in emu


From: Jiahuan Zhang
Subject: [Qemu-arm] kernel has No master clock, no CPU clock, when running in emulated HW
Date: Mon, 9 Jan 2017 16:20:42 +0100


Hi All,

Happy new year!

Is here the right place to present the problem I meet with while emulating? If not, please tell me because I am still expecting some feedback from the seniors here.

I am running the emulated at91sam board with a Linux kernel, but the booting message says "Clocks: CPU 0 MHz, master 0 MHz, main 10.000 MHz".

When running the same kernel on the real at91sam9261 board, the booting message says "Clocks: CPU 200 MHz, master 100 MHz, main 10.000 MHz".

And I have the "Division by zero in kernel" error for the uart clock. It should be also caused by the clock problem.

The "MCK" master clock is generated by Power Menagement Controller and used by the other peripherals through a global parameter. However, whatever value I set to "MCK", there is no impact on the clock of the kernel.

The whole booting message is in the following.

How does the emulated HW give clock value to the kernel running on top of it?
Or how does QEMU give clock to the kernel running on top of its emulated HW?

Best regards,
Jiahuan

================================================================================================

$ ~/test/qemu/build/arm-softmmu/qemu-system-arm -initrd initramfs_new -M at91sam9261 -kernel zImage_at91sam9261-nographic -serial stdio -serial stdio -serial stdio -serial stdio -append "console=ttyS0"

QEMU 2.7.50 monitor - type 'help' for more information

(qemu) Uncompressing Linux... done, booting the kernel.

Linux version 3.0.85 (address@hidden) (gcc version 4.9.3 20141031 (prerelease) (Linaro GCC 2014.11) ) #3 Tue Nov 22 15:50:56 CET 2016

CPU: ARM926EJ-S [41069265] revision 5 (ARMv5TEJ), cr=00093177

CPU: VIVT data cache, VIVT instruction cache

Machine: Atmel AT91SAM9261-EK

Memory policy: ECC disabled, Data cache writeback

Clocks: CPU 0 MHz, master 0 MHz, main 18.432 MHz

Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 32512

Kernel command line: console=ttyS0

PID hash table entries: 512 (order: -1, 2048 bytes)

Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)

Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)

Memory: 128MB = 128MB total

Memory: 125668k/125668k available, 5404k reserved, 0K highmem

Virtual kernel memory layout:

    vector  : 0xffff0000 - 0xffff1000   (   4 kB)

    fixmap  : 0xfff00000 - 0xfffe0000   ( 896 kB)

    DMA     : 0xffc00000 - 0xffe00000   (   2 MB)

    vmalloc : 0xc8800000 - 0xfee00000   ( 870 MB)

    lowmem  : 0xc0000000 - 0xc8000000   ( 128 MB)

    modules : 0xbf000000 - 0xc0000000   (  16 MB)

      .init : 0xc0008000 - 0xc0028000   ( 128 kB)

      .text : 0xc0028000 - 0xc03e88c8   (3843 kB)

      .data : 0xc03ea000 - 0xc040e9c0   ( 147 kB)

       .bss : 0xc040e9e4 - 0xc04221ac   (  78 kB)

NR_IRQS:192

AT91: 96 gpio irqs in 3 banks

Console: colour dummy device 80x30

------------[ cut here ]------------

WARNING: at drivers/tty/serial/serial_core.c:401 uart_get_baud_rate+0xe8/0x158()

Modules linked in:

[<c0031bb4>] (unwind_backtrace+0x0/0xec) from [<c003cbe4>] (warn_slowpath_common+0x4c/0x64)

[<c003cbe4>] (warn_slowpath_common+0x4c/0x64) from [<c003cc98>] (warn_slowpath_null+0x1c/0x24)

[<c003cc98>] (warn_slowpath_null+0x1c/0x24) from [<c018a830>] (uart_get_baud_rate+0xe8/0x158)

[<c018a830>] (uart_get_baud_rate+0xe8/0x158) from [<c018d548>] (atmel_set_termios+0x2c/0x200)

[<c018d548>] (atmel_set_termios+0x2c/0x200) from [<c018a9ec>] (uart_set_options+0xd4/0x118)

[<c018a9ec>] (uart_set_options+0xd4/0x118) from [<c0016b10>] (atmel_console_setup+0x130/0x140)

[<c0016b10>] (atmel_console_setup+0x130/0x140) from [<c003db04>] (register_console+0x21c/0x344)

[<c003db04>] (register_console+0x21c/0x344) from [<c00169c8>] (atmel_console_init+0x44/0x5c)

[<c00169c8>] (atmel_console_init+0x44/0x5c) from [<c0015cbc>] (console_init+0x20/0x30)

[<c0015cbc>] (console_init+0x20/0x30) from [<c0008824>] (start_kernel+0x1b8/0x270)

[<c0008824>] (start_kernel+0x1b8/0x270) from [<00008040>] (0x8040)

---[ end trace 1b75b31a2719ed1c ]---

Division by zero in kernel.

[<c0031bb4>] (unwind_backtrace+0x0/0xec) from [<c014b294>] (Ldiv0+0x8/0x10)

[<c014b294>] (Ldiv0+0x8/0x10) from [<c018a134>] (uart_get_divisor+0x20/0x44)

[<c018a134>] (uart_get_divisor+0x20/0x44) from [<c018d558>] (atmel_set_termios+0x3c/0x200)

[<c018d558>] (atmel_set_termios+0x3c/0x200) from [<c018a9ec>] (uart_set_options+0xd4/0x118)

[<c018a9ec>] (uart_set_options+0xd4/0x118) from [<c0016b10>] (atmel_console_setup+0x130/0x140)

[<c0016b10>] (atmel_console_setup+0x130/0x140) from [<c003db04>] (register_console+0x21c/0x344)

[<c003db04>] (register_console+0x21c/0x344) from [<c00169c8>] (atmel_console_init+0x44/0x5c)

[<c00169c8>] (atmel_console_init+0x44/0x5c) from [<c0015cbc>] (console_init+0x20/0x30)

[<c0015cbc>] (console_init+0x20/0x30) from [<c0008824>] (start_kernel+0x1b8/0x270)

[<c0008824>] (start_kernel+0x1b8/0x270) from [<00008040>] (0x8040)

Division by zero in kernel.

[<c0031bb4>] (unwind_backtrace+0x0/0xec) from [<c014b294>] (Ldiv0+0x8/0x10)

[<c014b294>] (Ldiv0+0x8/0x10) from [<c018a108>] (uart_update_timeout+0x5c/0x68)

[<c018a108>] (uart_update_timeout+0x5c/0x68) from [<c018d664>] (atmel_set_termios+0x148/0x200)

[<c018d664>] (atmel_set_termios+0x148/0x200) from [<c018a9ec>] (uart_set_options+0xd4/0x118)

[<c018a9ec>] (uart_set_options+0xd4/0x118) from [<c0016b10>] (atmel_console_setup+0x130/0x140)

[<c0016b10>] (atmel_console_setup+0x130/0x140) from [<c003db04>] (register_console+0x21c/0x344)

[<c003db04>] (register_console+0x21c/0x344) from [<c00169c8>] (atmel_console_init+0x44/0x5c)

[<c00169c8>] (atmel_console_init+0x44/0x5c) from [<c0015cbc>] (console_init+0x20/0x30)

[<c0015cbc>] (console_init+0x20/0x30) from [<c0008824>] (start_kernel+0x1b8/0x270)

[<c0008824>] (start_kernel+0x1b8/0x270) from [<00008040>] (0x8040)

console [ttyS0] enabled

Calibrating delay loop...


reply via email to

[Prev in Thread] Current Thread [Next in Thread]