Quiz based on chapter-4 of book linux device drivers 3rd ed

Quiz on chapter-4 of book linux device drivers 3rd ed body {margin: 10px;} Quiz on chapter-4 of book linux device drivers 3rd ed Which of the following config options need to be enabled to be able to debug kernel.
CONFIG_DEBUG_KERNEL
CONFIG_USB
CONFIG_EXT4
CONFIG_DBG

The first argument passed to printk specifies the
loglevel for the message to be printed
terminal number for the message to be printed
userid of the current user
line number in which the message has to be printed

The command that can be used to view the kernel logs from user space is
kmesg
dmesg
kmsg
dmsg

The function create_proc_read_entry returns a pointer to
struct proc_dir
struct proc_entry
struct proc_dir_entry
struct proc

The seq file interface is used for
logging errors in kernel space
Creating a /proc entry
Passing user information to kernel
Passing kernel information to user space

output of strace shows
The function calls made by user applications
The system calls made by a user appliction
The kernel modules used by a user application
The various applications running in the user space.

In a kernel oops message EIP points to
The address of the faulty instruction
The faulty instruction
The faulty line in the user code
The faulty user application

While using gdb for kernel debugging the kernel core file used passed to gdb is
/proc/core
/proc/kcore
/dev/core
/dev/kcore

Which of the following keys will launch the kdb
sysrq
pause
shift
del

To use kgdb we need two systems connected by a serial cable
True
False
depends on kernel version
depends on kgdb version


Tags: ,
Copyright 2017. All rights reserved.

Posted August 3, 2013 by Tux Think in category "Linux