The Design and Implementation of the FreeBSD Operating System, Second Edition
Now available: The Design and Implementation of the FreeBSD Operating System (Second Edition)


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]

FreeBSD/Linux Kernel Cross Reference
sys/ddb/db_break.h

Version: -  FREEBSD  -  FREEBSD-13-STABLE  -  FREEBSD-13-0  -  FREEBSD-12-STABLE  -  FREEBSD-12-0  -  FREEBSD-11-STABLE  -  FREEBSD-11-0  -  FREEBSD-10-STABLE  -  FREEBSD-10-0  -  FREEBSD-9-STABLE  -  FREEBSD-9-0  -  FREEBSD-8-STABLE  -  FREEBSD-8-0  -  FREEBSD-7-STABLE  -  FREEBSD-7-0  -  FREEBSD-6-STABLE  -  FREEBSD-6-0  -  FREEBSD-5-STABLE  -  FREEBSD-5-0  -  FREEBSD-4-STABLE  -  FREEBSD-3-STABLE  -  FREEBSD22  -  l41  -  OPENBSD  -  linux-2.6  -  MK84  -  PLAN9  -  xnu-8792 
SearchContext: -  none  -  3  -  10 

    1 /* 
    2  * Mach Operating System
    3  * Copyright (c) 1991,1990 Carnegie Mellon University
    4  * All Rights Reserved.
    5  * 
    6  * Permission to use, copy, modify and distribute this software and its
    7  * documentation is hereby granted, provided that both the copyright
    8  * notice and this permission notice appear in all copies of the
    9  * software, derivative works or modified versions, and any portions
   10  * thereof, and that both notices appear in supporting documentation.
   11  * 
   12  * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS"
   13  * CONDITION.  CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR
   14  * ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
   15  * 
   16  * Carnegie Mellon requests users of this software to return to
   17  * 
   18  *  Software Distribution Coordinator  or  Software.Distribution@CS.CMU.EDU
   19  *  School of Computer Science
   20  *  Carnegie Mellon University
   21  *  Pittsburgh PA 15213-3890
   22  * 
   23  * any improvements or extensions that they make and grant Carnegie Mellon
   24  * the rights to redistribute these changes.
   25  */
   26 /*
   27  * HISTORY
   28  * $Log:        db_break.h,v $
   29  * Revision 2.7  93/01/14  17:24:37  danner
   30  *      64bit cleanup. Enabled prototypes.
   31  *      [92/11/30            af]
   32  * 
   33  * Revision 2.6  91/10/09  15:58:03  af
   34  *      Added db_thread_breakpoint structure, and added task and threads
   35  *      field to db_breakpoint structure.  Some status flags were also
   36  *      added to keep track user space break point correctly.
   37  *      [91/08/29            tak]
   38  * 
   39  * Revision 2.5  91/05/14  15:32:35  mrt
   40  *      Correcting copyright
   41  * 
   42  * Revision 2.4  91/02/05  17:06:06  mrt
   43  *      Changed to new Mach copyright
   44  *      [91/01/31  16:17:10  mrt]
   45  * 
   46  * Revision 2.3  90/10/25  14:43:40  rwd
   47  *      Added map field to breakpoints.
   48  *      [90/10/18            rpd]
   49  * 
   50  * Revision 2.2  90/08/27  21:50:00  dbg
   51  *      Modularized typedef names.
   52  *      [90/08/20            af]
   53  *      Add external defintions.
   54  *      [90/08/07            dbg]
   55  *      Created.
   56  *      [90/07/25            dbg]
   57  * 
   58  */
   59 /*
   60  *      Author: David B. Golub, Carnegie Mellon University
   61  *      Date:   7/90
   62  */
   63 #ifndef _DDB_DB_BREAK_H_
   64 #define _DDB_DB_BREAK_H_
   65 
   66 #include <machine/db_machdep.h>
   67 #include <kern/thread.h>
   68 #include <kern/task.h>
   69 #include <mach/boolean.h>
   70 
   71 /*
   72  * thread list at the same breakpoint address
   73  */
   74 struct db_thread_breakpoint {
   75         vm_offset_t tb_task_thd;                /* target task or thread */
   76         boolean_t tb_is_task;                   /* task qualified */
   77         short    tb_number;                     /* breakpoint number */
   78         short    tb_init_count;                 /* skip count(initial value) */
   79         short    tb_count;                      /* current skip count */
   80         short    tb_cond;                       /* break condition */
   81         struct   db_thread_breakpoint *tb_next; /* next chain */
   82 };
   83 
   84 typedef struct db_thread_breakpoint *db_thread_breakpoint_t;
   85 
   86 /*
   87  * Breakpoint.
   88  */
   89 
   90 struct db_breakpoint {
   91         task_t    task;                 /* target task */
   92         db_addr_t address;              /* set here */
   93         db_thread_breakpoint_t threads; /* thread */
   94         int     flags;                  /* flags: */
   95 #define BKPT_SINGLE_STEP        0x2     /* to simulate single step */
   96 #define BKPT_TEMP               0x4     /* temporary */
   97 #define BKPT_USR_GLOBAL         0x8     /* global user space break point */
   98 #define BKPT_SET_IN_MEM         0x10    /* break point is set in memory */
   99 #define BKPT_1ST_SET            0x20    /* 1st time set of user global bkpt */
  100         vm_size_t       bkpt_inst;      /* saved instruction at bkpt */
  101         struct db_breakpoint *link;     /* link in in-use or free chain */
  102 };
  103 
  104 typedef struct db_breakpoint *db_breakpoint_t;
  105 
  106 extern db_breakpoint_t  db_find_breakpoint( task_t task, db_addr_t addr);
  107 extern boolean_t        db_find_breakpoint_here( task_t task, db_addr_t addr);
  108 extern void             db_set_breakpoints();
  109 extern void             db_clear_breakpoints();
  110 extern db_thread_breakpoint_t   db_find_thread_breakpoint_here
  111                                         ( task_t task, db_addr_t addr );
  112 extern db_thread_breakpoint_t   db_find_breakpoint_number
  113                                         ( int num, db_breakpoint_t *bkptp);
  114 
  115 extern db_breakpoint_t  db_set_temp_breakpoint( task_t task, db_addr_t addr);
  116 extern void             db_delete_temp_breakpoint
  117                                         ( task_t task, db_breakpoint_t bkpt);
  118 
  119 #endif  _DDB_DB_BREAK_H_

Cache object: 498de0b7f90810ca3c5100b8422d21ac


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]


This page is part of the FreeBSD/Linux Linux Kernel Cross-Reference, and was automatically generated using a modified version of the LXR engine.