:pserver:cvsanon@mok.lvcm.com:/CVS/ReactOS reactos
[reactos.git] / apps / utils / pice / module / bp.h
1 /*++
2
3 Copyright (c) 1998-2001 Klaus P. Gerlicher
4
5 Module Name:
6
7     bp.h
8
9 Abstract:
10
11     HEADER for bp.c
12
13 Environment:
14
15     LINUX 2.2.X
16     Kernel mode only
17
18 Author:
19
20     Klaus P. Gerlicher
21
22 Revision History:
23
24     15-Nov-2000:    general cleanup of source files
25
26 Copyright notice:
27
28   This file may be distributed under the terms of the GNU Public License.
29
30 --*/
31 typedef struct _SW_BP
32 {
33     ULONG ulAddress;
34     ULONG ulNextInstr;
35     UCHAR ucOriginalOpcode;
36     BOOLEAN bUsed;
37     BOOLEAN bInstalled;
38     BOOLEAN bPermanent;
39     BOOLEAN bVirtual;
40     char szModName[128];
41     char szFunctionName[128];
42     void (*Callback)(void);
43 }SW_BP,*PSW_BP;
44
45 BOOLEAN InstallSWBreakpoint(ULONG ulAddress,BOOLEAN bPermanent,void (*SWBreakpointCallback)(void));
46 BOOLEAN InstallVirtualSWBreakpoint(LPSTR ModName,LPSTR Function);
47 void TryToInstallVirtualSWBreakpoints(void);
48 BOOLEAN DeInstallSWBreakpoint(ULONG ulAddress);
49 BOOLEAN RemoveSWBreakpoint(ULONG ulAddress);
50 BOOLEAN NeedToReInstallSWBreakpoints(ULONG ulAddress,BOOLEAN bUseAddress);
51 BOOLEAN ReInstallSWBreakpoint(ULONG ulAddress);
52 BOOLEAN RemoveAllSWBreakpoints(BOOLEAN bEvenPermanents);
53 PSW_BP IsPermanentSWBreakpoint(ULONG ulAddress);
54 void ListSWBreakpoints(void);
55 PSW_BP FindSwBp(ULONG ulAddress);
56 BOOLEAN IsSwBpAtAddress(ULONG ulAddress);
57 BOOLEAN IsSwBpAtAddressInstalled(ULONG ulAddress);
58 void RevirtualizeBreakpointsForModule(PDEBUG_MODULE pMod);
59
60 void InstallInt3Hook(void);
61 void DeInstallInt3Hook(void);
62