All of lore.kernel.org
 help / color / mirror / Atom feed
* Summary of Crash/Panic Behaviors in Linux Kernel
@ 2019-09-26 19:57 慕冬亮
  2019-09-28  0:22 ` 김동현
  0 siblings, 1 reply; 2+ messages in thread
From: 慕冬亮 @ 2019-09-26 19:57 UTC (permalink / raw)
  To: linux-kernel

Dear all,

Is there any summary of crash/panic behaviors in the Linux Kernel? For
example, GPF (general protection fault), Kernel BUG (BUG_ON).

--
My best regards to you.

     No System Is Safe!
     Dongliang Mu

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Summary of Crash/Panic Behaviors in Linux Kernel
  2019-09-26 19:57 Summary of Crash/Panic Behaviors in Linux Kernel 慕冬亮
@ 2019-09-28  0:22 ` 김동현
  0 siblings, 0 replies; 2+ messages in thread
From: 김동현 @ 2019-09-28  0:22 UTC (permalink / raw)
  To: 慕冬亮; +Cc: linux-kernel

2019년 9월 27일 (금) 오전 5:01, 慕冬亮 <mudongliangabcd@gmail.com>님이 작성:
>
> Dear all,
>
> Is there any summary of crash/panic behaviors in the Linux Kernel? For
> example, GPF (general protection fault), Kernel BUG (BUG_ON).

There are a number of blogs and material which describe the behavior
the kernel panic.

Talking about Android Linux Device, the behavior of kernel panic is as
followings:

USER DEBUG Version(Engineering version)

* On kernel panic, the device suddenly stops execution and keep on
displaying kernel log through the screen.
Below is one of the examples.
[   34.187856 01-05 13:30:49.424] Unable to handle kernel NULL pointer
dereference at virtual address 00000000
[   34.197812 01-05 13:30:49.434] pgd = e6f9c000
[   34.202275 01-05 13:30:49.438] [00000000] *pgd=00000000
[   34.207610 01-05 13:30:49.444] Internal error: Oops: 5 [#1] PREEMPT SMP ARM
[   34.214663 01-05 13:30:49.451] Modules linked in: bcmdhd(O)
[   34.220400 01-05 13:30:49.457] CPU: 0    Tainted: G        W  O
(3.4.65-gbc0bf75 #1)
[   34.228317 01-05 13:30:49.464] PC is at ext4_free_inode+0x288/0x574
[   34.234664 01-05 13:30:49.471] LR is at ext4_free_inode+0x260/0x574

Kernel engineers are able to notice what is the cause of the kernel
panic from kernel log.

USER Version(Production version)

 * When kernel panic occurs, the device suddenly stops execution and
starts rebooting again.

In addition, we can describe BUG_ON()  and exception as followings:

BUG_ON()

  * If the subsystem realizes that it is running under critical condition,
    BUG_ON() is called to cause kernel panic.

    Please be aware that BUG_ON or BUG is executed only with CONFIG_BUG enabled.
    Normally, many Linux devices are running with CONFIG_BUG enabled
*by default*.

Exception(Data abort, Prefeth abort: ARM processor)

  * If MMU cannot handle the virtual address  translation, exception occurs.
    The program counter is jumped into predefined exception vector.
    Usually panic() is called and then system is crashed.

Hope above would be helpful.

Thanks,
Austin Kim

>
> --
> My best regards to you.
>
>      No System Is Safe!
>      Dongliang Mu

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2019-09-28  0:22 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-09-26 19:57 Summary of Crash/Panic Behaviors in Linux Kernel 慕冬亮
2019-09-28  0:22 ` 김동현

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.