cvs commit: src/sys/conf files src/sys/ddb db_command.c db_command.h db_lex.c db_lex.h db_main.c db_script.c ddb.h

Robert Watson rwatson at FreeBSD.org
Wed Dec 26 01:33:19 PST 2007


rwatson     2007-12-26 09:33:19 UTC

  FreeBSD src repository

  Modified files:
    sys/conf             files 
    sys/ddb              db_command.c db_command.h db_lex.c 
                         db_lex.h db_main.c ddb.h 
  Added files:
    sys/ddb              db_script.c 
  Log:
  Add a simple scripting facility to DDB(4), allowing the user to
  define a set of named scripts.  Each script consists of a list of DDB
  commands separated by ";"s that will be executed verbatim.  No higher
  level language constructs, such as branching, are provided for:
  scripts are executed by sequentially injecting commands into the DDB
  input buffer.
  
  Four new commands are present in DDB: "run" to run a specific script,
  "script" to define or print a script, "scripts" to list currently
  defined scripts, and "unscript" to delete a script, modeled on shell
  alias commands.  Scripts may also be manipulated using sysctls in the
  debug.ddb.scripting MIB space, although users will prefer to use the
  soon-to-be-added ddb(8) tool for usability reasons.
  
  Scripts with certain names are automatically executed on various DDB
  events, such as entering the debugger via a panic, a witness error,
  watchdog, breakpoint, sysctl, serial break, etc, allowing customized
  handling.
  
  MFC after:      3 months
  
  Revision  Changes    Path
  1.1259    +1 -0      src/sys/conf/files
  1.75      +31 -5     src/sys/ddb/db_command.c
  1.14      +1 -0      src/sys/ddb/db_command.h
  1.23      +30 -1     src/sys/ddb/db_lex.c
  1.15      +7 -4      src/sys/ddb/db_lex.h
  1.7       +3 -0      src/sys/ddb/db_main.c
  1.1       +564 -0    src/sys/ddb/db_script.c (new)
  1.45      +29 -0     src/sys/ddb/ddb.h


More information about the cvs-src mailing list