VirtualBox

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

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

VMMDev: added VMMDevReqWriteCoreDump. VMM/DBGFCoreWrite: remove unused parameter.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 9.3 KB
Line 
1/* $Id: tstDBGCStubs.cpp 32313 2010-09-08 11:46:16Z 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}
187VMMDECL(int) DBGFR3PagingDumpEx(PVM pVM, VMCPUID idCpu, uint32_t fFlags, uint64_t cr3, uint64_t u64FirstAddr,
188 uint64_t u64LastAddr, uint32_t cMaxDepth, PCDBGFINFOHLP pHlp)
189{
190 return VERR_INTERNAL_ERROR;
191}
192VMMR3DECL(int) DBGFR3RegQueryU8( PVM pVM, VMCPUID idCpu, DBGFREG enmReg, uint8_t *pu8)
193{
194 return VERR_INTERNAL_ERROR;
195}
196VMMR3DECL(int) DBGFR3RegQueryU16( PVM pVM, VMCPUID idCpu, DBGFREG enmReg, uint16_t *pu16)
197{
198 return VERR_INTERNAL_ERROR;
199}
200VMMR3DECL(int) DBGFR3RegQueryU32( PVM pVM, VMCPUID idCpu, DBGFREG enmReg, uint32_t *pu32)
201{
202 return VERR_INTERNAL_ERROR;
203}
204VMMR3DECL(int) DBGFR3RegQueryU64( PVM pVM, VMCPUID idCpu, DBGFREG enmReg, uint64_t *pu64)
205{
206 return VERR_INTERNAL_ERROR;
207}
208VMMR3DECL(PDBGFADDRESS) DBGFR3AddrFromPhys(PVM pVM, PDBGFADDRESS pAddress, RTGCPHYS PhysAddr)
209{
210 return NULL;
211}
212VMMR3DECL(int) DBGFR3AddrToHostPhys(PVM pVM, VMCPUID idCpu, PDBGFADDRESS pAddress, PRTHCPHYS pHCPhys)
213{
214 return VERR_INTERNAL_ERROR;
215}
216VMMR3DECL(int) DBGFR3AddrToVolatileR3Ptr(PVM pVM, VMCPUID idCpu, PDBGFADDRESS pAddress, bool fReadOnly, void **ppvR3Ptr)
217{
218 return VERR_INTERNAL_ERROR;
219}
220
221VMMR3DECL(int) DBGFR3OSRegister(PVM pVM, PCDBGFOSREG pReg)
222{
223 return VERR_INTERNAL_ERROR;
224}
225VMMR3DECL(int) DBGFR3OSDetect(PVM pVM, char *pszName, size_t cchName)
226{
227 return VERR_INTERNAL_ERROR;
228}
229VMMR3DECL(int) DBGFR3OSQueryNameAndVersion(PVM pVM, char *pszName, size_t cchName, char *pszVersion, size_t cchVersion)
230{
231 return VERR_INTERNAL_ERROR;
232}
233
234VMMR3DECL(int) DBGFR3SelQueryInfo(PVM pVM, VMCPUID idCpu, RTSEL Sel, uint32_t fFlags, PDBGFSELINFO pSelInfo)
235{
236 return VERR_INTERNAL_ERROR;
237}
238
239VMMR3DECL(int) DBGFR3CoreWrite(PVM pVM, const char *pszDumpPath)
240{
241 return VERR_INTERNAL_ERROR;
242}
243
244
245//////////////////////////////////////////////////////////////////////////
246// The rest should eventually be replaced by DBGF calls and eliminated. //
247/////////////////////////////////////////////////////////////////////////
248
249#include <VBox/cpum.h>
250
251VMMDECL(uint64_t) CPUMGetGuestCR3(PVMCPU pVCpu)
252{
253 return 0;
254}
255
256VMMDECL(uint64_t) CPUMGetGuestCR4(PVMCPU pVCpu)
257{
258 return 0;
259}
260
261VMMDECL(RTSEL) CPUMGetGuestCS(PVMCPU pVCpu)
262{
263 return 0;
264}
265
266VMMDECL(PCCPUMCTXCORE) CPUMGetGuestCtxCore(PVMCPU pVCpu)
267{
268 return NULL;
269}
270
271VMMDECL(uint32_t) CPUMGetGuestEIP(PVMCPU pVCpu)
272{
273 return 0;
274}
275
276VMMDECL(uint64_t) CPUMGetGuestRIP(PVMCPU pVCpu)
277{
278 return 0;
279}
280
281VMMDECL(RTGCPTR) CPUMGetGuestIDTR(PVMCPU pVCpu, uint16_t *pcbLimit)
282{
283 return 0;
284}
285
286VMMDECL(CPUMMODE) CPUMGetGuestMode(PVMCPU pVCpu)
287{
288 return CPUMMODE_INVALID;
289}
290
291VMMDECL(RTSEL) CPUMGetHyperCS(PVMCPU pVCpu)
292{
293 return 0xfff8;
294}
295
296VMMDECL(PCCPUMCTXCORE) CPUMGetHyperCtxCore(PVMCPU pVCpu)
297{
298 return NULL;
299}
300
301VMMDECL(uint32_t) CPUMGetHyperEIP(PVMCPU pVCpu)
302{
303 return 0;
304}
305
306VMMDECL(PCPUMCTX) CPUMQueryGuestCtxPtr(PVMCPU pVCpu)
307{
308 return NULL;
309}
310
311VMMDECL(int) CPUMQueryHyperCtxPtr(PVMCPU pVCpu, PCPUMCTX *ppCtx)
312{
313 return VERR_INTERNAL_ERROR;
314}
315
316
317
318#include <VBox/mm.h>
319
320VMMR3DECL(int) MMR3HCPhys2HCVirt(PVM pVM, RTHCPHYS HCPhys, void **ppv)
321{
322 return VERR_INTERNAL_ERROR;
323}
324
325
326
327
328#include <VBox/pgm.h>
329
330VMMDECL(RTHCPHYS) PGMGetHyperCR3(PVMCPU pVCpu)
331{
332 return 0;
333}
334
335VMMDECL(PGMMODE) PGMGetShadowMode(PVMCPU pVCpu)
336{
337 return PGMMODE_INVALID;
338}
339
340VMMR3DECL(int) PGMR3DbgR3Ptr2GCPhys(PVM pVM, RTR3PTR R3Ptr, PRTGCPHYS pGCPhys)
341{
342 return VERR_INTERNAL_ERROR;
343}
344
345VMMR3DECL(int) PGMR3DbgR3Ptr2HCPhys(PVM pVM, RTR3PTR R3Ptr, PRTHCPHYS pHCPhys)
346{
347 return VERR_INTERNAL_ERROR;
348}
349
350
351#include <VBox/vmm.h>
352
353VMMDECL(PVMCPU) VMMGetCpuById(PVM pVM, RTCPUID idCpu)
354{
355 return NULL;
356}
357
358VMMR3DECL(int) VMR3ReqCallWait(PVM pVm, VMCPUID idDstCpu, PFNRT pfnFunction, unsigned cArgs, ...)
359{
360 return VERR_INTERNAL_ERROR;
361}
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