VirtualBox

source: vbox/trunk/src/VBox/Debugger/testcase/tstDBGCStubs.cpp@ 31530

Last change on this file since 31530 was 31530, checked in by vboxsync, 14 years ago

Debugger: Updated the file headers.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 9.0 KB
Line 
1/* $Id: tstDBGCStubs.cpp 31530 2010-08-10 12:24:45Z vboxsync $ */
2/** @file
3 * DBGC Testcase - Command Parser, VMM Stub Functions.
4 */
5
6/*
7 * Copyright (C) 2006-2010 Oracle Corporation
8 *
9 * This file is part of VirtualBox Open Source Edition (OSE), as
10 * available from http://www.virtualbox.org. This file is free software;
11 * you can redistribute it and/or modify it under the terms of the GNU
12 * General Public License (GPL) as published by the Free Software
13 * Foundation, in version 2 as it comes in the "COPYING" file of the
14 * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
15 * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
16 */
17
18#include <VBox/err.h>
19#include <VBox/vm.h>
20
21
22
23#include <VBox/dbgf.h>
24VMMR3DECL(PDBGFADDRESS) DBGFR3AddrFromFlat(PVM pVM, PDBGFADDRESS pAddress, RTGCUINTPTR FlatPtr)
25{
26 return NULL;
27}
28
29VMMR3DECL(int) DBGFR3AddrFromSelOff(PVM pVM, VMCPUID idCpu, PDBGFADDRESS pAddress, RTSEL Sel, RTUINTPTR off)
30{
31 return VERR_INTERNAL_ERROR;
32}
33
34VMMR3DECL(int) DBGFR3AddrToPhys(PVM pVM, VMCPUID idCpu, PDBGFADDRESS pAddress, PRTGCPHYS pGCPhys)
35{
36 return VERR_INTERNAL_ERROR;
37}
38
39VMMR3DECL(int) DBGFR3AddrToHostPhys(PVMCPU pVCpu, PDBGFADDRESS pAddress, PRTHCPHYS pHCPhys)
40{
41 return VERR_INTERNAL_ERROR;
42}
43
44VMMR3DECL(int) DBGFR3AddrToVolatileR3Ptr(PVMCPU pVCpu, PDBGFADDRESS pAddress, bool fReadOnly, void **ppvR3Ptr)
45{
46 return VERR_INTERNAL_ERROR;
47}
48
49VMMR3DECL(int) DBGFR3Attach(PVM pVM)
50{
51 return VERR_INTERNAL_ERROR;
52}
53
54VMMR3DECL(int) DBGFR3BpClear(PVM pVM, RTUINT iBp)
55{
56 return VERR_INTERNAL_ERROR;
57}
58VMMR3DECL(int) DBGFR3BpDisable(PVM pVM, RTUINT iBp)
59{
60 return VERR_INTERNAL_ERROR;
61}
62VMMR3DECL(int) DBGFR3BpEnable(PVM pVM, RTUINT iBp)
63{
64 return VERR_INTERNAL_ERROR;
65}
66VMMR3DECL(int) DBGFR3BpEnum(PVM pVM, PFNDBGFBPENUM pfnCallback, void *pvUser)
67{
68 return VERR_INTERNAL_ERROR;
69}
70VMMR3DECL(int) DBGFR3BpSet(PVM pVM, PCDBGFADDRESS pAddress, uint64_t iHitTrigger, uint64_t iHitDisable, PRTUINT piBp)
71{
72 return VERR_INTERNAL_ERROR;
73}
74VMMR3DECL(int) DBGFR3BpSetReg(PVM pVM, PCDBGFADDRESS pAddress, uint64_t iHitTrigger, uint64_t iHitDisable,
75 uint8_t fType, uint8_t cb, PRTUINT piBp)
76{
77 return VERR_INTERNAL_ERROR;
78}
79VMMR3DECL(int) DBGFR3BpSetREM(PVM pVM, PCDBGFADDRESS pAddress, uint64_t iHitTrigger, uint64_t iHitDisable, PRTUINT piBp)
80{
81 return VERR_INTERNAL_ERROR;
82}
83VMMR3DECL(bool) DBGFR3CanWait(PVM pVM)
84{
85 return true;
86}
87VMMR3DECL(int) DBGFR3Detach(PVM pVM)
88{
89 return VERR_INTERNAL_ERROR;
90}
91VMMR3DECL(int) DBGFR3DisasInstrEx(PVM pVM, VMCPUID idCpu, RTSEL Sel, RTGCPTR GCPtr, uint32_t fFlags,
92 char *pszOutput, uint32_t cchOutput, uint32_t *pcbInstr)
93{
94 return VERR_INTERNAL_ERROR;
95}
96VMMR3DECL(int) DBGFR3EventWait(PVM pVM, RTMSINTERVAL cMillies, PCDBGFEVENT *ppEvent)
97{
98 return VERR_INTERNAL_ERROR;
99}
100VMMR3DECL(int) DBGFR3Halt(PVM pVM)
101{
102 return VERR_INTERNAL_ERROR;
103}
104VMMR3DECL(int) DBGFR3Info(PVM pVM, const char *pszName, const char *pszArgs, PCDBGFINFOHLP pHlp)
105{
106 return VERR_INTERNAL_ERROR;
107}
108VMMR3DECL(bool) DBGFR3IsHalted(PVM pVM)
109{
110 return true;
111}
112VMMR3DECL(int) DBGFR3LineByAddr(PVM pVM, RTGCUINTPTR Address, PRTGCINTPTR poffDisplacement, PDBGFLINE pLine)
113{
114 return VERR_INTERNAL_ERROR;
115}
116VMMR3DECL(int) DBGFR3LogModifyDestinations(PVM pVM, const char *pszDestSettings)
117{
118 return VERR_INTERNAL_ERROR;
119}
120VMMR3DECL(int) DBGFR3LogModifyFlags(PVM pVM, const char *pszFlagSettings)
121{
122 return VERR_INTERNAL_ERROR;
123}
124VMMR3DECL(int) DBGFR3LogModifyGroups(PVM pVM, const char *pszGroupSettings)
125{
126 return VERR_INTERNAL_ERROR;
127}
128VMMR3DECL(int) DBGFR3ModuleLoad(PVM pVM, const char *pszFilename, RTGCUINTPTR AddressDelta, const char *pszName, RTGCUINTPTR ModuleAddress, unsigned cbImage)
129{
130 return VERR_INTERNAL_ERROR;
131}
132VMMR3DECL(int) DBGFR3AsLoadImage(PVM pVM, RTDBGAS hAS, const char *pszFilename, const char *pszModName, PCDBGFADDRESS pModAddress, RTDBGSEGIDX iModSeg, uint32_t fFlags)
133{
134 return VERR_INTERNAL_ERROR;
135}
136VMMR3DECL(int) DBGFR3AsLoadMap(PVM pVM, RTDBGAS hAS, const char *pszFilename, const char *pszModName, PCDBGFADDRESS pModAddress, RTDBGSEGIDX iModSeg, RTGCUINTPTR uSubtrahend, uint32_t fFlags)
137{
138 return VERR_INTERNAL_ERROR;
139}
140VMMR3DECL(RTDBGAS) DBGFR3AsResolveAndRetain(PVM pVM, RTDBGAS hAlias)
141{
142 return NIL_RTDBGAS;
143}
144VMMR3DECL(int) DBGFR3Resume(PVM pVM)
145{
146 return VERR_INTERNAL_ERROR;
147}
148VMMR3DECL(int) DBGFR3StackWalkBegin(PVM pVM, VMCPUID idCpu, DBGFCODETYPE enmCodeType, PCDBGFSTACKFRAME *ppFirstFrame)
149{
150 return VERR_INTERNAL_ERROR;
151}
152VMMR3DECL(PCDBGFSTACKFRAME) DBGFR3StackWalkNext(PCDBGFSTACKFRAME pCurrent)
153{
154 return NULL;
155}
156VMMR3DECL(void) DBGFR3StackWalkEnd(PCDBGFSTACKFRAME pFirstFrame)
157{
158}
159VMMR3DECL(int) DBGFR3Step(PVM pVM, VMCPUID idCpu)
160{
161 return VERR_INTERNAL_ERROR;
162}
163VMMR3DECL(int) DBGFR3AsSymbolByAddr(PVM pVM, RTDBGAS hDbgAs, PCDBGFADDRESS pAddress, PRTGCINTPTR poffDisplacement, PRTDBGSYMBOL pSymbol, PRTDBGMOD phMod)
164{
165 return VERR_INTERNAL_ERROR;
166}
167VMMR3DECL(int) DBGFR3AsSymbolByName(PVM pVM, RTDBGAS hDbgAs, const char *pszSymbol, PRTDBGSYMBOL pSymbol, PRTDBGMOD phMod)
168{
169 return VERR_INTERNAL_ERROR;
170}
171VMMR3DECL(int) DBGFR3MemScan(PVM pVM, VMCPUID idCpu, PCDBGFADDRESS pAddress, RTGCUINTPTR cbRange, RTGCUINTPTR uAlign, const void *pabNeedle, size_t cbNeedle, PDBGFADDRESS pHitAddress)
172{
173 return VERR_INTERNAL_ERROR;
174}
175VMMR3DECL(int) DBGFR3MemRead(PVM pVM, VMCPUID idCpu, PCDBGFADDRESS pAddress, void *pvBuf, size_t cbRead)
176{
177 return VERR_INTERNAL_ERROR;
178}
179VMMR3DECL(int) DBGFR3MemReadString(PVM pVM, VMCPUID idCpu, PCDBGFADDRESS pAddress, char *pszBuf, size_t cchBuf)
180{
181 return VERR_INTERNAL_ERROR;
182}
183VMMR3DECL(int) DBGFR3MemWrite(PVM pVM, VMCPUID idCpu, PCDBGFADDRESS pAddress, const void *pvBuf, size_t cbRead)
184{
185 return VERR_INTERNAL_ERROR;
186}
187VMMR3DECL(int) DBGFR3RegQueryU8( PVM pVM, VMCPUID idCpu, DBGFREG enmReg, uint8_t *pu8)
188{
189 return VERR_INTERNAL_ERROR;
190}
191VMMR3DECL(int) DBGFR3RegQueryU16( PVM pVM, VMCPUID idCpu, DBGFREG enmReg, uint16_t *pu16)
192{
193 return VERR_INTERNAL_ERROR;
194}
195VMMR3DECL(int) DBGFR3RegQueryU32( PVM pVM, VMCPUID idCpu, DBGFREG enmReg, uint32_t *pu32)
196{
197 return VERR_INTERNAL_ERROR;
198}
199VMMR3DECL(int) DBGFR3RegQueryU64( PVM pVM, VMCPUID idCpu, DBGFREG enmReg, uint64_t *pu64)
200{
201 return VERR_INTERNAL_ERROR;
202}
203VMMR3DECL(PDBGFADDRESS) DBGFR3AddrFromPhys(PVM pVM, PDBGFADDRESS pAddress, RTGCPHYS PhysAddr)
204{
205 return NULL;
206}
207VMMR3DECL(int) DBGFR3AddrToHostPhys(PVM pVM, VMCPUID idCpu, PDBGFADDRESS pAddress, PRTHCPHYS pHCPhys)
208{
209 return VERR_INTERNAL_ERROR;
210}
211VMMR3DECL(int) DBGFR3AddrToVolatileR3Ptr(PVM pVM, VMCPUID idCpu, PDBGFADDRESS pAddress, bool fReadOnly, void **ppvR3Ptr)
212{
213 return VERR_INTERNAL_ERROR;
214}
215
216VMMR3DECL(int) DBGFR3OSRegister(PVM pVM, PCDBGFOSREG pReg)
217{
218 return VERR_INTERNAL_ERROR;
219}
220VMMR3DECL(int) DBGFR3OSDetect(PVM pVM, char *pszName, size_t cchName)
221{
222 return VERR_INTERNAL_ERROR;
223}
224VMMR3DECL(int) DBGFR3OSQueryNameAndVersion(PVM pVM, char *pszName, size_t cchName, char *pszVersion, size_t cchVersion)
225{
226 return VERR_INTERNAL_ERROR;
227}
228
229VMMR3DECL(int) DBGFR3SelQueryInfo(PVM pVM, VMCPUID idCpu, RTSEL Sel, uint32_t fFlags, PDBGFSELINFO pSelInfo)
230{
231 return VERR_INTERNAL_ERROR;
232}
233
234
235//////////////////////////////////////////////////////////////////////////
236// The rest should eventually be replaced by DBGF calls and eliminated. //
237/////////////////////////////////////////////////////////////////////////
238
239#include <VBox/cpum.h>
240
241VMMDECL(uint64_t) CPUMGetGuestCR3(PVMCPU pVCpu)
242{
243 return 0;
244}
245
246VMMDECL(uint64_t) CPUMGetGuestCR4(PVMCPU pVCpu)
247{
248 return 0;
249}
250
251VMMDECL(RTSEL) CPUMGetGuestCS(PVMCPU pVCpu)
252{
253 return 0;
254}
255
256VMMDECL(PCCPUMCTXCORE) CPUMGetGuestCtxCore(PVMCPU pVCpu)
257{
258 return NULL;
259}
260
261VMMDECL(uint32_t) CPUMGetGuestEIP(PVMCPU pVCpu)
262{
263 return 0;
264}
265
266VMMDECL(uint64_t) CPUMGetGuestRIP(PVMCPU pVCpu)
267{
268 return 0;
269}
270
271VMMDECL(RTGCPTR) CPUMGetGuestIDTR(PVMCPU pVCpu, uint16_t *pcbLimit)
272{
273 return 0;
274}
275
276VMMDECL(CPUMMODE) CPUMGetGuestMode(PVMCPU pVCpu)
277{
278 return CPUMMODE_INVALID;
279}
280
281VMMDECL(RTSEL) CPUMGetHyperCS(PVMCPU pVCpu)
282{
283 return 0xfff8;
284}
285
286VMMDECL(PCCPUMCTXCORE) CPUMGetHyperCtxCore(PVMCPU pVCpu)
287{
288 return NULL;
289}
290
291VMMDECL(uint32_t) CPUMGetHyperEIP(PVMCPU pVCpu)
292{
293 return 0;
294}
295
296VMMDECL(PCPUMCTX) CPUMQueryGuestCtxPtr(PVMCPU pVCpu)
297{
298 return NULL;
299}
300
301VMMDECL(int) CPUMQueryHyperCtxPtr(PVMCPU pVCpu, PCPUMCTX *ppCtx)
302{
303 return VERR_INTERNAL_ERROR;
304}
305
306
307
308#include <VBox/mm.h>
309
310VMMR3DECL(int) MMR3HCPhys2HCVirt(PVM pVM, RTHCPHYS HCPhys, void **ppv)
311{
312 return VERR_INTERNAL_ERROR;
313}
314
315
316
317
318#include <VBox/pgm.h>
319
320VMMDECL(RTHCPHYS) PGMGetHyperCR3(PVMCPU pVCpu)
321{
322 return 0;
323}
324
325VMMDECL(PGMMODE) PGMGetShadowMode(PVMCPU pVCpu)
326{
327 return PGMMODE_INVALID;
328}
329
330VMMR3DECL(int) PGMR3DbgR3Ptr2GCPhys(PVM pVM, RTR3PTR R3Ptr, PRTGCPHYS pGCPhys)
331{
332 return VERR_INTERNAL_ERROR;
333}
334
335VMMR3DECL(int) PGMR3DbgR3Ptr2HCPhys(PVM pVM, RTR3PTR R3Ptr, PRTHCPHYS pHCPhys)
336{
337 return VERR_INTERNAL_ERROR;
338}
339
340
341#include <VBox/vmm.h>
342
343VMMDECL(PVMCPU) VMMGetCpuById(PVM pVM, RTCPUID idCpu)
344{
345 return NULL;
346}
347
348VMMR3DECL(int) VMR3ReqCallWait(PVM pVm, VMCPUID idDstCpu, PFNRT pfnFunction, unsigned cArgs, ...)
349{
350 return VERR_INTERNAL_ERROR;
351}
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette