Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions | Variables
dynamic_debug.c File Reference
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/moduleparam.h>
#include <linux/kallsyms.h>
#include <linux/types.h>
#include <linux/mutex.h>
#include <linux/proc_fs.h>
#include <linux/seq_file.h>
#include <linux/list.h>
#include <linux/sysctl.h>
#include <linux/ctype.h>
#include <linux/string.h>
#include <linux/uaccess.h>
#include <linux/dynamic_debug.h>
#include <linux/debugfs.h>
#include <linux/slab.h>
#include <linux/jump_label.h>
#include <linux/hardirq.h>
#include <linux/sched.h>
#include <linux/device.h>
#include <linux/netdevice.h>

Go to the source code of this file.

Data Structures

struct  ddebug_table
 
struct  ddebug_query
 
struct  ddebug_iter
 

Macros

#define pr_fmt(fmt)   KBUILD_MODNAME ":%s: " fmt, __func__
 
#define vpr_info(fmt,...)   if (verbose) do { pr_info(fmt, ##__VA_ARGS__); } while (0)
 
#define vpr_info_dq(q, msg)
 
#define isodigit(c)   ((c) >= '0' && (c) <= '7')
 
#define MAXWORDS   9
 
#define PREFIX_SIZE   64
 
#define DDEBUG_STRING_SIZE   1024
 
#define USER_BUF_PAGE   4096
 

Functions

 module_param (verbose, int, 0644)
 
int __dynamic_pr_debug (struct _ddebug *descriptor, const char *fmt,...)
 
 EXPORT_SYMBOL (__dynamic_pr_debug)
 
int __dynamic_dev_dbg (struct _ddebug *descriptor, const struct device *dev, const char *fmt,...)
 
 EXPORT_SYMBOL (__dynamic_dev_dbg)
 
 __setup ("ddebug_query=", ddebug_setup_query)
 
int ddebug_add_module (struct _ddebug *tab, unsigned int n, const char *name)
 
 EXPORT_SYMBOL_GPL (ddebug_add_module)
 
int ddebug_dyndbg_module_param_cb (char *param, char *val, const char *module)
 
int ddebug_remove_module (const char *mod_name)
 
 EXPORT_SYMBOL_GPL (ddebug_remove_module)
 
 early_initcall (dynamic_debug_init)
 
 fs_initcall (dynamic_debug_init_debugfs)
 

Variables

struct _ddebug __start___verbose []
 
struct _ddebug __stop___verbose []
 

Macro Definition Documentation

#define DDEBUG_STRING_SIZE   1024

Definition at line 647 of file dynamic_debug.c.

#define isodigit (   c)    ((c) >= '0' && (c) <= '7')

Definition at line 275 of file dynamic_debug.c.

#define MAXWORDS   9
#define pr_fmt (   fmt)    KBUILD_MODNAME ":%s: " fmt, __func__

Definition at line 13 of file dynamic_debug.c.

#define PREFIX_SIZE   64

Definition at line 510 of file dynamic_debug.c.

#define USER_BUF_PAGE   4096

Definition at line 666 of file dynamic_debug.c.

#define vpr_info (   fmt,
  ... 
)    if (verbose) do { pr_info(fmt, ##__VA_ARGS__); } while (0)

Definition at line 110 of file dynamic_debug.c.

#define vpr_info_dq (   q,
  msg 
)
Value:
do { \
/* trim last char off format print */ \
vpr_info("%s: func=\"%s\" file=\"%s\" " \
"module=\"%s\" format=\"%.*s\" " \
"lineno=%u-%u", \
msg, \
q->function ? q->function : "", \
q->filename ? q->filename : "", \
q->module ? q->module : "", \
(int)(q->format ? strlen(q->format) - 1 : 0), \
q->format ? q->format : "", \
q->first_lineno, q->last_lineno); \
} while (0)

Definition at line 113 of file dynamic_debug.c.

Function Documentation

int __dynamic_dev_dbg ( struct _ddebug descriptor,
const struct device dev,
const char fmt,
  ... 
)

Definition at line 575 of file dynamic_debug.c.

int __dynamic_pr_debug ( struct _ddebug descriptor,
const char fmt,
  ... 
)

Definition at line 551 of file dynamic_debug.c.

__setup ( )
int ddebug_add_module ( struct _ddebug tab,
unsigned int  n,
const char name 
)

Definition at line 872 of file dynamic_debug.c.

int ddebug_dyndbg_module_param_cb ( char param,
char val,
const char module 
)

Definition at line 933 of file dynamic_debug.c.

int ddebug_remove_module ( const char mod_name)

Definition at line 950 of file dynamic_debug.c.

early_initcall ( dynamic_debug_init  )
EXPORT_SYMBOL ( __dynamic_pr_debug  )
EXPORT_SYMBOL ( __dynamic_dev_dbg  )
EXPORT_SYMBOL_GPL ( ddebug_add_module  )
EXPORT_SYMBOL_GPL ( ddebug_remove_module  )
fs_initcall ( dynamic_debug_init_debugfs  )
module_param ( verbose  ,
int  ,
0644   
)

Variable Documentation

struct _ddebug __start___verbose[]
struct _ddebug __stop___verbose[]
unsigned flag

Definition at line 83 of file dynamic_debug.c.

char opt_char

Definition at line 83 of file dynamic_debug.c.