L4Re Operating System Framework
Interface and Usage Documentation
Loading...
Searching...
No Matches
Kernel Debugger

Kernel debugger related functionality. More...

+ Collaboration diagram for Kernel Debugger:

Files

file  kdebug.h
 Functionality for invoking the kernel debugger.
 

Functions

l4_msgtag_t l4_debugger_set_object_name (l4_cap_idx_t cap, const char *name) L4_NOTHROW
 Set the name of a kernel object.
 
l4_msgtag_t l4_debugger_get_object_name (l4_cap_idx_t cap, unsigned id, char *name, unsigned size) L4_NOTHROW
 Get name of the kernel object with Id id.
 
unsigned long l4_debugger_global_id (l4_cap_idx_t cap) L4_NOTHROW
 Get the globally unique ID of the object behind a capability.
 
unsigned long l4_debugger_kobj_to_id (l4_cap_idx_t cap, l4_addr_t kobjp) L4_NOTHROW
 Get the globally unique ID of the object behind the kobject pointer.
 
long l4_debugger_query_log_typeid (l4_cap_idx_t cap, const char *name, unsigned idx) L4_NOTHROW
 Query the log-id for a log type.
 
long l4_debugger_query_log_name (l4_cap_idx_t cap, unsigned idx, char *name, unsigned namelen, char *shortname, unsigned shortnamelen) L4_NOTHROW
 Query the name of a log type given the ID.
 
l4_msgtag_t l4_debugger_switch_log (l4_cap_idx_t cap, const char *name, int on_off) L4_NOTHROW
 Set or unset log.
 
l4_msgtag_t l4_debugger_add_image_info (l4_cap_idx_t cap, l4_addr_t base, const char *name) L4_NOTHROW
 Add loaded image information for a task.
 

Detailed Description

Kernel debugger related functionality.

Attention
This API is subject to change!

This is a debugging facility, any call to any function might be invalid. Do not rely on it in any real code.

Include File
#include <l4/sys/debugger.h>
Debugger related definitions.

Function Documentation

◆ l4_debugger_add_image_info()

l4_msgtag_t l4_debugger_add_image_info ( l4_cap_idx_t  cap,
l4_addr_t  base,
const char *  name 
)
inline

Add loaded image information for a task.

Parameters
capCapability which refers to the task object.
baseLoad base address of image.
nameImage base name.

This is a debugging facility, the call might be invalid.

Definition at line 428 of file debugger.h.

References l4_utcb().

+ Here is the call graph for this function:

◆ l4_debugger_get_object_name()

l4_msgtag_t l4_debugger_get_object_name ( l4_cap_idx_t  cap,
unsigned  id,
char *  name,
unsigned  size 
)
inline

Get name of the kernel object with Id id.

Parameters
capCapability of the debugger object.
idGlobal id of the object whose name is asked.
[out]nameBuffer to copy the name into. The buffer must be allocated by the caller.
sizeLength of the name buffer.
Returns
Syscall return tag

Definition at line 421 of file debugger.h.

References l4_utcb().

+ Here is the call graph for this function:

◆ l4_debugger_global_id()

unsigned long l4_debugger_global_id ( l4_cap_idx_t  cap)
inline

Get the globally unique ID of the object behind a capability.

Parameters
capCapability
Return values
~0ULCapability is not valid.
otherwiseGlobal debugger id.

This is a debugging facility, the call might be invalid.

Definition at line 386 of file debugger.h.

References l4_utcb().

+ Here is the call graph for this function:

◆ l4_debugger_kobj_to_id()

unsigned long l4_debugger_kobj_to_id ( l4_cap_idx_t  cap,
l4_addr_t  kobjp 
)
inline

Get the globally unique ID of the object behind the kobject pointer.

Parameters
capCapability
kobjpKobject pointer
Return values
~0ULThe capability or the kobject pointer are invalid.
otherwiseThe globally unique id.

This is a debugging facility, the call might be invalid.

Definition at line 392 of file debugger.h.

References l4_utcb().

+ Here is the call graph for this function:

◆ l4_debugger_query_log_name()

long l4_debugger_query_log_name ( l4_cap_idx_t  cap,
unsigned  idx,
char *  name,
unsigned  namelen,
char *  shortname,
unsigned  shortnamelen 
)
inline

Query the name of a log type given the ID.

Parameters
capDebugger capability.
idxID to query.
nameBuffer to copy name to.
namelenBuffer length of name.
shortnameBuffer to copy shortname to.
shortnamelenBuffer length of shortname.
Return values
0Success
<0Error

This is a debugging facility, the call might be invalid.

Definition at line 405 of file debugger.h.

References l4_utcb().

+ Here is the call graph for this function:

◆ l4_debugger_query_log_typeid()

long l4_debugger_query_log_typeid ( l4_cap_idx_t  cap,
const char *  name,
unsigned  idx 
)
inline

Query the log-id for a log type.

Parameters
capDebugger capability
nameName to query for.
idxIdx to start searching, start with 0
Returns
positive ID, or negative error code

This is a debugging facility, the call might be invalid.

Definition at line 398 of file debugger.h.

References l4_utcb().

+ Here is the call graph for this function:

◆ l4_debugger_set_object_name()

l4_msgtag_t l4_debugger_set_object_name ( l4_cap_idx_t  cap,
const char *  name 
)
inline

Set the name of a kernel object.

Parameters
capCapability which refers to the kernel object.
nameName of the kernel object that is e.g. displayed in the kernel debugger.

This is a debugging facility, the call might be invalid.

Examples
examples/libs/shmc/prodcons.c, and examples/sys/aliens/main.c.

Definition at line 379 of file debugger.h.

References l4_utcb().

+ Here is the call graph for this function:

◆ l4_debugger_switch_log()

l4_msgtag_t l4_debugger_switch_log ( l4_cap_idx_t  cap,
const char *  name,
int  on_off 
)
inline

Set or unset log.

Parameters
capDebugger object.
nameName of the log type.
on_off1: turn log on, 0: turn log off
Returns
Syscall return tag

Definition at line 414 of file debugger.h.

References l4_utcb().

+ Here is the call graph for this function: