1 | /* $Id: tstDevicePdmDevHlp.cpp 69183 2017-10-23 18:47:18Z vboxsync $ */
|
---|
2 | /** @file
|
---|
3 | * tstDevice - Test framework for PDM devices/drivers, PDM helper implementation.
|
---|
4 | */
|
---|
5 |
|
---|
6 | /*
|
---|
7 | * Copyright (C) 2017 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 |
|
---|
19 | /*********************************************************************************************************************************
|
---|
20 | * Header Files *
|
---|
21 | *********************************************************************************************************************************/
|
---|
22 | #define LOG_GROUP LOG_GROUP_DEFAULT /** @todo */
|
---|
23 | #include <VBox/types.h>
|
---|
24 | #include <VBox/version.h>
|
---|
25 | #include <VBox/vmm/pdmpci.h>
|
---|
26 |
|
---|
27 | #include <iprt/assert.h>
|
---|
28 | #include <iprt/mem.h>
|
---|
29 |
|
---|
30 | #include "tstDeviceInternal.h"
|
---|
31 |
|
---|
32 | /*********************************************************************************************************************************
|
---|
33 | * Defined Constants And Macros *
|
---|
34 | *********************************************************************************************************************************/
|
---|
35 |
|
---|
36 | /** @def PDMDEV_ASSERT_DEVINS
|
---|
37 | * Asserts the validity of the device instance.
|
---|
38 | */
|
---|
39 | #ifdef VBOX_STRICT
|
---|
40 | # define PDMDEV_ASSERT_DEVINS(pDevIns) \
|
---|
41 | do { \
|
---|
42 | AssertPtr(pDevIns); \
|
---|
43 | Assert(pDevIns->u32Version == PDM_DEVINS_VERSION); \
|
---|
44 | Assert(pDevIns->CTX_SUFF(pvInstanceData) == (void *)&pDevIns->achInstanceData[0]); \
|
---|
45 | } while (0)
|
---|
46 | #else
|
---|
47 | # define PDMDEV_ASSERT_DEVINS(pDevIns) do { } while (0)
|
---|
48 | #endif
|
---|
49 |
|
---|
50 |
|
---|
51 | /*********************************************************************************************************************************
|
---|
52 | * Structures and Typedefs *
|
---|
53 | *********************************************************************************************************************************/
|
---|
54 |
|
---|
55 |
|
---|
56 |
|
---|
57 | /*********************************************************************************************************************************
|
---|
58 | * Global Variables *
|
---|
59 | *********************************************************************************************************************************/
|
---|
60 |
|
---|
61 |
|
---|
62 |
|
---|
63 | /*********************************************************************************************************************************
|
---|
64 | * Internal Functions *
|
---|
65 | *********************************************************************************************************************************/
|
---|
66 |
|
---|
67 |
|
---|
68 |
|
---|
69 | /** @interface_method_impl{PDMDEVHLPR3,pfnIOPortRegister} */
|
---|
70 | static DECLCALLBACK(int) pdmR3DevHlp_IOPortRegister(PPDMDEVINS pDevIns, RTIOPORT Port, RTIOPORT cPorts, RTHCPTR pvUser, PFNIOMIOPORTOUT pfnOut, PFNIOMIOPORTIN pfnIn,
|
---|
71 | PFNIOMIOPORTOUTSTRING pfnOutStr, PFNIOMIOPORTINSTRING pfnInStr, const char *pszDesc)
|
---|
72 | {
|
---|
73 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
74 | LogFlow(("pdmR3DevHlp_IOPortRegister: caller='%s'/%d: Port=%#x cPorts=%#x pvUser=%p pfnOut=%p pfnIn=%p pfnOutStr=%p pfnInStr=%p p32_tszDesc=%p:{%s}\n",
|
---|
75 | pDevIns->pReg->szName, pDevIns->iInstance, Port, cPorts, pvUser, pfnOut, pfnIn, pfnOutStr, pfnInStr, pszDesc, pszDesc));
|
---|
76 |
|
---|
77 | /** @todo: Verify there is no overlapping. */
|
---|
78 |
|
---|
79 | RT_NOREF(pszDesc);
|
---|
80 | int rc = VINF_SUCCESS;
|
---|
81 | PRTDEVDUTIOPORT pIoPort = (PRTDEVDUTIOPORT)RTMemAllocZ(sizeof(RTDEVDUTIOPORT));
|
---|
82 | if (RT_LIKELY(pIoPort))
|
---|
83 | {
|
---|
84 | pIoPort->PortStart = Port;
|
---|
85 | pIoPort->cPorts = cPorts;
|
---|
86 | pIoPort->pvUserR3 = pvUser;
|
---|
87 | pIoPort->pfnOutR3 = pfnOut;
|
---|
88 | pIoPort->pfnInR3 = pfnIn;
|
---|
89 | pIoPort->pfnOutStrR3 = pfnOutStr;
|
---|
90 | pIoPort->pfnInStrR3 = pfnInStr;
|
---|
91 | RTListAppend(&pDevIns->Internal.s.pDut->LstIoPorts, &pIoPort->NdIoPorts);
|
---|
92 | }
|
---|
93 | else
|
---|
94 | rc = VERR_NO_MEMORY;
|
---|
95 |
|
---|
96 | LogFlow(("pdmR3DevHlp_IOPortRegister: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
97 | return rc;
|
---|
98 | }
|
---|
99 |
|
---|
100 |
|
---|
101 | /** @interface_method_impl{PDMDEVHLPR3,pfnIOPortRegisterRC} */
|
---|
102 | static DECLCALLBACK(int) pdmR3DevHlp_IOPortRegisterRC(PPDMDEVINS pDevIns, RTIOPORT Port, RTIOPORT cPorts, RTRCPTR pvUser,
|
---|
103 | const char *pszOut, const char *pszIn,
|
---|
104 | const char *pszOutStr, const char *pszInStr, const char *pszDesc)
|
---|
105 | {
|
---|
106 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
107 | LogFlow(("pdmR3DevHlp_IOPortRegisterRC: caller='%s'/%d: Port=%#x cPorts=%#x pvUser=%p pszOut=%p:{%s} pszIn=%p:{%s} pszOutStr=%p:{%s} pszInStr=%p:{%s} pszDesc=%p:{%s}\n",
|
---|
108 | pDevIns->pReg->szName, pDevIns->iInstance, Port, cPorts, pvUser, pszOut, pszOut, pszIn, pszIn, pszOutStr, pszOutStr, pszInStr, pszInStr, pszDesc, pszDesc));
|
---|
109 |
|
---|
110 | /** @todo */
|
---|
111 | int rc = VINF_SUCCESS;
|
---|
112 | //AssertFailed();
|
---|
113 |
|
---|
114 | LogFlow(("pdmR3DevHlp_IOPortRegisterRC: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
115 | return rc;
|
---|
116 | }
|
---|
117 |
|
---|
118 |
|
---|
119 | /** @interface_method_impl{PDMDEVHLPR3,pfnIOPortRegisterR0} */
|
---|
120 | static DECLCALLBACK(int) pdmR3DevHlp_IOPortRegisterR0(PPDMDEVINS pDevIns, RTIOPORT Port, RTIOPORT cPorts, RTR0PTR pvUser,
|
---|
121 | const char *pszOut, const char *pszIn,
|
---|
122 | const char *pszOutStr, const char *pszInStr, const char *pszDesc)
|
---|
123 | {
|
---|
124 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
125 | LogFlow(("pdmR3DevHlp_IOPortRegisterR0: caller='%s'/%d: Port=%#x cPorts=%#x pvUser=%p pszOut=%p:{%s} pszIn=%p:{%s} pszOutStr=%p:{%s} pszInStr=%p:{%s} pszDesc=%p:{%s}\n",
|
---|
126 | pDevIns->pReg->szName, pDevIns->iInstance, Port, cPorts, pvUser, pszOut, pszOut, pszIn, pszIn, pszOutStr, pszOutStr, pszInStr, pszInStr, pszDesc, pszDesc));
|
---|
127 |
|
---|
128 | PTSTDEVDUTINT pThis = pDevIns->Internal.s.pDut;
|
---|
129 | PRTDEVDUTIOPORT pIoPort;
|
---|
130 | int rc = VERR_NOT_FOUND;
|
---|
131 | RTListForEach(&pThis->LstIoPorts, pIoPort, RTDEVDUTIOPORT, NdIoPorts)
|
---|
132 | {
|
---|
133 | /** @todo: Support overlapping port ranges. */
|
---|
134 | if ( pIoPort->PortStart == Port
|
---|
135 | && pIoPort->cPorts == cPorts)
|
---|
136 | {
|
---|
137 | rc = VINF_SUCCESS;
|
---|
138 | pIoPort->pvUserR0 = (void *)pvUser;
|
---|
139 | if (pszOut)
|
---|
140 | rc = tstDevPdmLdrGetSymbol(pThis, pDevIns->pReg->szR0Mod, TSTDEVPDMMODTYPE_R0, pszOut, (PFNRT *)&pIoPort->pfnOutR0);
|
---|
141 | if (RT_SUCCESS(rc) && pszIn)
|
---|
142 | rc = tstDevPdmLdrGetSymbol(pThis, pDevIns->pReg->szR0Mod, TSTDEVPDMMODTYPE_R0, pszIn, (PFNRT *)&pIoPort->pfnInR0);
|
---|
143 | if (RT_SUCCESS(rc) && pszOutStr)
|
---|
144 | rc = tstDevPdmLdrGetSymbol(pThis, pDevIns->pReg->szR0Mod, TSTDEVPDMMODTYPE_R0, pszOutStr, (PFNRT *)&pIoPort->pfnOutStrR0);
|
---|
145 | if (RT_SUCCESS(rc) && pszInStr)
|
---|
146 | rc = tstDevPdmLdrGetSymbol(pThis, pDevIns->pReg->szR0Mod, TSTDEVPDMMODTYPE_R0, pszInStr, (PFNRT *)&pIoPort->pfnInStrR0);
|
---|
147 | break;
|
---|
148 | }
|
---|
149 | }
|
---|
150 |
|
---|
151 | LogFlow(("pdmR3DevHlp_IOPortRegisterR0: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
152 | return rc;
|
---|
153 | }
|
---|
154 |
|
---|
155 |
|
---|
156 | /** @interface_method_impl{PDMDEVHLPR3,pfnIOPortDeregister} */
|
---|
157 | static DECLCALLBACK(int) pdmR3DevHlp_IOPortDeregister(PPDMDEVINS pDevIns, RTIOPORT Port, RTIOPORT cPorts)
|
---|
158 | {
|
---|
159 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
160 | LogFlow(("pdmR3DevHlp_IOPortDeregister: caller='%s'/%d: Port=%#x cPorts=%#x\n",
|
---|
161 | pDevIns->pReg->szName, pDevIns->iInstance, Port, cPorts));
|
---|
162 |
|
---|
163 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
164 | AssertFailed();
|
---|
165 |
|
---|
166 | LogFlow(("pdmR3DevHlp_IOPortDeregister: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
167 | return rc;
|
---|
168 | }
|
---|
169 |
|
---|
170 |
|
---|
171 | /** @interface_method_impl{PDMDEVHLPR3,pfnMMIORegister} */
|
---|
172 | static DECLCALLBACK(int) pdmR3DevHlp_MMIORegister(PPDMDEVINS pDevIns, RTGCPHYS GCPhysStart, RTGCPHYS cbRange, RTHCPTR pvUser,
|
---|
173 | PFNIOMMMIOWRITE pfnWrite, PFNIOMMMIOREAD pfnRead, PFNIOMMMIOFILL pfnFill,
|
---|
174 | uint32_t fFlags, const char *pszDesc)
|
---|
175 | {
|
---|
176 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
177 | LogFlow(("pdmR3DevHlp_MMIORegister: caller='%s'/%d: GCPhysStart=%RGp cbRange=%RGp pvUser=%p pfnWrite=%p pfnRead=%p pfnFill=%p fFlags=%#x pszDesc=%p:{%s}\n",
|
---|
178 | pDevIns->pReg->szName, pDevIns->iInstance, GCPhysStart, cbRange, pvUser, pfnWrite, pfnRead, pfnFill, pszDesc, fFlags, pszDesc));
|
---|
179 |
|
---|
180 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
181 | AssertFailed();
|
---|
182 |
|
---|
183 | LogFlow(("pdmR3DevHlp_MMIORegister: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
184 | return rc;
|
---|
185 | }
|
---|
186 |
|
---|
187 |
|
---|
188 | /** @interface_method_impl{PDMDEVHLPR3,pfnMMIORegisterRC} */
|
---|
189 | static DECLCALLBACK(int) pdmR3DevHlp_MMIORegisterRC(PPDMDEVINS pDevIns, RTGCPHYS GCPhysStart, RTGCPHYS cbRange, RTRCPTR pvUser,
|
---|
190 | const char *pszWrite, const char *pszRead, const char *pszFill)
|
---|
191 | {
|
---|
192 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
193 | LogFlow(("pdmR3DevHlp_MMIORegisterRC: caller='%s'/%d: GCPhysStart=%RGp cbRange=%RGp pvUser=%p pszWrite=%p:{%s} pszRead=%p:{%s} pszFill=%p:{%s}\n",
|
---|
194 | pDevIns->pReg->szName, pDevIns->iInstance, GCPhysStart, cbRange, pvUser, pszWrite, pszWrite, pszRead, pszRead, pszFill, pszFill));
|
---|
195 |
|
---|
196 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
197 | AssertFailed();
|
---|
198 |
|
---|
199 | LogFlow(("pdmR3DevHlp_MMIORegisterRC: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
200 | return rc;
|
---|
201 | }
|
---|
202 |
|
---|
203 | /** @interface_method_impl{PDMDEVHLPR3,pfnMMIORegisterR0} */
|
---|
204 | static DECLCALLBACK(int) pdmR3DevHlp_MMIORegisterR0(PPDMDEVINS pDevIns, RTGCPHYS GCPhysStart, RTGCPHYS cbRange, RTR0PTR pvUser,
|
---|
205 | const char *pszWrite, const char *pszRead, const char *pszFill)
|
---|
206 | {
|
---|
207 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
208 | LogFlow(("pdmR3DevHlp_MMIORegisterHC: caller='%s'/%d: GCPhysStart=%RGp cbRange=%RGp pvUser=%p pszWrite=%p:{%s} pszRead=%p:{%s} pszFill=%p:{%s}\n",
|
---|
209 | pDevIns->pReg->szName, pDevIns->iInstance, GCPhysStart, cbRange, pvUser, pszWrite, pszWrite, pszRead, pszRead, pszFill, pszFill));
|
---|
210 |
|
---|
211 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
212 | AssertFailed();
|
---|
213 |
|
---|
214 | LogFlow(("pdmR3DevHlp_MMIORegisterR0: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
215 | return rc;
|
---|
216 | }
|
---|
217 |
|
---|
218 |
|
---|
219 | /** @interface_method_impl{PDMDEVHLPR3,pfnMMIODeregister} */
|
---|
220 | static DECLCALLBACK(int) pdmR3DevHlp_MMIODeregister(PPDMDEVINS pDevIns, RTGCPHYS GCPhysStart, RTGCPHYS cbRange)
|
---|
221 | {
|
---|
222 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
223 | LogFlow(("pdmR3DevHlp_MMIODeregister: caller='%s'/%d: GCPhysStart=%RGp cbRange=%RGp\n",
|
---|
224 | pDevIns->pReg->szName, pDevIns->iInstance, GCPhysStart, cbRange));
|
---|
225 |
|
---|
226 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
227 | AssertFailed();
|
---|
228 |
|
---|
229 | LogFlow(("pdmR3DevHlp_MMIODeregister: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
230 | return rc;
|
---|
231 | }
|
---|
232 |
|
---|
233 |
|
---|
234 | /**
|
---|
235 | * @copydoc PDMDEVHLPR3::pfnMMIO2Register
|
---|
236 | */
|
---|
237 | static DECLCALLBACK(int) pdmR3DevHlp_MMIO2Register(PPDMDEVINS pDevIns, PPDMPCIDEV pPciDev, uint32_t iRegion, RTGCPHYS cb,
|
---|
238 | uint32_t fFlags, void **ppv, const char *pszDesc)
|
---|
239 | {
|
---|
240 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
241 | LogFlow(("pdmR3DevHlp_MMIO2Register: caller='%s'/%d: pPciDev=%p (%#x) iRegion=%#x cb=%#RGp fFlags=%RX32 ppv=%p pszDescp=%p:{%s}\n",
|
---|
242 | pDevIns->pReg->szName, pDevIns->iInstance, pPciDev, pPciDev ? pPciDev->uDevFn : UINT32_MAX, iRegion,
|
---|
243 | cb, fFlags, ppv, pszDesc, pszDesc));
|
---|
244 | //AssertReturn(!pPciDev || pPciDev->Int.s.pDevInsR3 == pDevIns, VERR_INVALID_PARAMETER);
|
---|
245 |
|
---|
246 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
247 | AssertFailed();
|
---|
248 |
|
---|
249 | LogFlow(("pdmR3DevHlp_MMIO2Register: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
250 | return rc;
|
---|
251 | }
|
---|
252 |
|
---|
253 |
|
---|
254 | /**
|
---|
255 | * @interface_method_impl{PDMDEVHLPR3,pfnMMIOExPreRegister}
|
---|
256 | */
|
---|
257 | static DECLCALLBACK(int)
|
---|
258 | pdmR3DevHlp_MMIOExPreRegister(PPDMDEVINS pDevIns, PPDMPCIDEV pPciDev, uint32_t iRegion, RTGCPHYS cbRegion, uint32_t fFlags,
|
---|
259 | const char *pszDesc,
|
---|
260 | RTHCPTR pvUser, PFNIOMMMIOWRITE pfnWrite, PFNIOMMMIOREAD pfnRead, PFNIOMMMIOFILL pfnFill,
|
---|
261 | RTR0PTR pvUserR0, const char *pszWriteR0, const char *pszReadR0, const char *pszFillR0,
|
---|
262 | RTRCPTR pvUserRC, const char *pszWriteRC, const char *pszReadRC, const char *pszFillRC)
|
---|
263 | {
|
---|
264 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
265 | LogFlow(("pdmR3DevHlp_MMIOExPreRegister: caller='%s'/%d: pPciDev=%p:{%#x} iRegion=%#x cbRegion=%#RGp fFlags=%RX32 pszDesc=%p:{%s}\n"
|
---|
266 | " pvUser=%p pfnWrite=%p pfnRead=%p pfnFill=%p\n"
|
---|
267 | " pvUserR0=%p pszWriteR0=%s pszReadR0=%s pszFillR0=%s\n"
|
---|
268 | " pvUserRC=%p pszWriteRC=%s pszReadRC=%s pszFillRC=%s\n",
|
---|
269 | pDevIns->pReg->szName, pDevIns->iInstance, pPciDev, pPciDev ? pPciDev->uDevFn : UINT32_MAX, iRegion, cbRegion,
|
---|
270 | fFlags, pszDesc, pszDesc,
|
---|
271 | pvUser, pfnWrite, pfnRead, pfnFill,
|
---|
272 | pvUserR0, pszWriteR0, pszReadR0, pszFillR0,
|
---|
273 | pvUserRC, pszWriteRC, pszReadRC, pszFillRC));
|
---|
274 | //AssertReturn(!pPciDev || pPciDev->Int.s.pDevInsR3 == pDevIns, VERR_INVALID_PARAMETER);
|
---|
275 |
|
---|
276 | /*
|
---|
277 | * Resolve the functions.
|
---|
278 | */
|
---|
279 | AssertLogRelReturn( (!pszWriteR0 && !pszReadR0 && !pszFillR0)
|
---|
280 | || (pDevIns->pReg->szR0Mod[0] && (pDevIns->pReg->fFlags & PDM_DEVREG_FLAGS_R0)),
|
---|
281 | VERR_INVALID_PARAMETER);
|
---|
282 | AssertLogRelReturn( (!pszWriteRC && !pszReadRC && !pszFillRC)
|
---|
283 | || (pDevIns->pReg->szRCMod[0] && (pDevIns->pReg->fFlags & PDM_DEVREG_FLAGS_RC)),
|
---|
284 | VERR_INVALID_PARAMETER);
|
---|
285 |
|
---|
286 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
287 | AssertFailed();
|
---|
288 |
|
---|
289 | LogFlow(("pdmR3DevHlp_MMIOExPreRegister: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
290 | return rc;
|
---|
291 | }
|
---|
292 |
|
---|
293 |
|
---|
294 | /**
|
---|
295 | * @copydoc PDMDEVHLPR3::pfnMMIOExDeregister
|
---|
296 | */
|
---|
297 | static DECLCALLBACK(int) pdmR3DevHlp_MMIOExDeregister(PPDMDEVINS pDevIns, PPDMPCIDEV pPciDev, uint32_t iRegion)
|
---|
298 | {
|
---|
299 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
300 | LogFlow(("pdmR3DevHlp_MMIOExDeregister: caller='%s'/%d: pPciDev=%p:{%#x} iRegion=%#x\n",
|
---|
301 | pDevIns->pReg->szName, pDevIns->iInstance, pPciDev, pPciDev ? pPciDev->uDevFn : UINT32_MAX, iRegion));
|
---|
302 |
|
---|
303 | AssertReturn(iRegion <= UINT8_MAX || iRegion == UINT32_MAX, VERR_INVALID_PARAMETER);
|
---|
304 | //AssertReturn(!pPciDev || pPciDev->Int.s.pDevInsR3 == pDevIns, VERR_INVALID_PARAMETER);
|
---|
305 |
|
---|
306 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
307 | AssertFailed();
|
---|
308 |
|
---|
309 | LogFlow(("pdmR3DevHlp_MMIOExDeregister: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
310 | return rc;
|
---|
311 | }
|
---|
312 |
|
---|
313 |
|
---|
314 | /**
|
---|
315 | * @copydoc PDMDEVHLPR3::pfnMMIOExMap
|
---|
316 | */
|
---|
317 | static DECLCALLBACK(int) pdmR3DevHlp_MMIOExMap(PPDMDEVINS pDevIns, PPDMPCIDEV pPciDev, uint32_t iRegion, RTGCPHYS GCPhys)
|
---|
318 | {
|
---|
319 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
320 | LogFlow(("pdmR3DevHlp_MMIOExMap: caller='%s'/%d: pPciDev=%p:{%#x} iRegion=%#x GCPhys=%#RGp\n",
|
---|
321 | pDevIns->pReg->szName, pDevIns->iInstance, pPciDev, pPciDev ? pPciDev->uDevFn : UINT32_MAX, iRegion, GCPhys));
|
---|
322 | //AssertReturn(!pPciDev || pPciDev->Int.s.pDevInsR3 != NULL, VERR_INVALID_PARAMETER);
|
---|
323 |
|
---|
324 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
325 | AssertFailed();
|
---|
326 |
|
---|
327 | LogFlow(("pdmR3DevHlp_MMIOExMap: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
328 | return rc;
|
---|
329 | }
|
---|
330 |
|
---|
331 |
|
---|
332 | /**
|
---|
333 | * @copydoc PDMDEVHLPR3::pfnMMIOExUnmap
|
---|
334 | */
|
---|
335 | static DECLCALLBACK(int) pdmR3DevHlp_MMIOExUnmap(PPDMDEVINS pDevIns, PPDMPCIDEV pPciDev, uint32_t iRegion, RTGCPHYS GCPhys)
|
---|
336 | {
|
---|
337 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
338 | LogFlow(("pdmR3DevHlp_MMIOExUnmap: caller='%s'/%d: pPciDev=%p:{%#x} iRegion=%#x GCPhys=%#RGp\n",
|
---|
339 | pDevIns->pReg->szName, pDevIns->iInstance, pPciDev, pPciDev ? pPciDev->uDevFn : UINT32_MAX, iRegion, GCPhys));
|
---|
340 | //AssertReturn(!pPciDev || pPciDev->Int.s.pDevInsR3 != NULL, VERR_INVALID_PARAMETER);
|
---|
341 |
|
---|
342 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
343 | AssertFailed();
|
---|
344 |
|
---|
345 | LogFlow(("pdmR3DevHlp_MMIOExUnmap: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
346 | return rc;
|
---|
347 | }
|
---|
348 |
|
---|
349 |
|
---|
350 | /**
|
---|
351 | * @copydoc PDMDEVHLPR3::pfnMMIOExReduce
|
---|
352 | */
|
---|
353 | static DECLCALLBACK(int) pdmR3DevHlp_MMIOExReduce(PPDMDEVINS pDevIns, PPDMPCIDEV pPciDev, uint32_t iRegion, RTGCPHYS cbRegion)
|
---|
354 | {
|
---|
355 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
356 | LogFlow(("pdmR3DevHlp_MMIOExReduce: caller='%s'/%d: pPciDev=%p:{%#x} iRegion=%#x cbRegion=%RGp\n",
|
---|
357 | pDevIns->pReg->szName, pDevIns->iInstance, pPciDev, pPciDev ? pPciDev->uDevFn : UINT32_MAX, iRegion, cbRegion));
|
---|
358 | //AssertReturn(!pPciDev || pPciDev->Int.s.pDevInsR3 != NULL, VERR_INVALID_PARAMETER);
|
---|
359 |
|
---|
360 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
361 | AssertFailed();
|
---|
362 |
|
---|
363 | LogFlow(("pdmR3DevHlp_MMIOExReduce: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
364 | return rc;
|
---|
365 | }
|
---|
366 |
|
---|
367 |
|
---|
368 | /**
|
---|
369 | * @copydoc PDMDEVHLPR3::pfnMMHyperMapMMIO2
|
---|
370 | */
|
---|
371 | static DECLCALLBACK(int) pdmR3DevHlp_MMHyperMapMMIO2(PPDMDEVINS pDevIns, PPDMPCIDEV pPciDev, uint32_t iRegion, RTGCPHYS off,
|
---|
372 | RTGCPHYS cb, const char *pszDesc, PRTRCPTR pRCPtr)
|
---|
373 | {
|
---|
374 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
375 | LogFlow(("pdmR3DevHlp_MMHyperMapMMIO2: caller='%s'/%d: pPciDev=%p:{%#x} iRegion=%#x off=%RGp cb=%RGp pszDesc=%p:{%s} pRCPtr=%p\n",
|
---|
376 | pDevIns->pReg->szName, pDevIns->iInstance, pPciDev, pPciDev ? pPciDev->uDevFn : UINT32_MAX, iRegion, off, cb, pszDesc, pszDesc, pRCPtr));
|
---|
377 | //AssertReturn(!pPciDev || pPciDev->Int.s.pDevInsR3 == pDevIns, VERR_INVALID_PARAMETER);
|
---|
378 |
|
---|
379 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
380 | AssertFailed();
|
---|
381 |
|
---|
382 | LogFlow(("pdmR3DevHlp_MMHyperMapMMIO2: caller='%s'/%d: returns %Rrc *pRCPtr=%RRv\n", pDevIns->pReg->szName, pDevIns->iInstance, rc, *pRCPtr));
|
---|
383 | return rc;
|
---|
384 | }
|
---|
385 |
|
---|
386 |
|
---|
387 | /**
|
---|
388 | * @copydoc PDMDEVHLPR3::pfnMMIO2MapKernel
|
---|
389 | */
|
---|
390 | static DECLCALLBACK(int) pdmR3DevHlp_MMIO2MapKernel(PPDMDEVINS pDevIns, PPDMPCIDEV pPciDev, uint32_t iRegion, RTGCPHYS off,
|
---|
391 | RTGCPHYS cb,const char *pszDesc, PRTR0PTR pR0Ptr)
|
---|
392 | {
|
---|
393 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
394 | LogFlow(("pdmR3DevHlp_MMIO2MapKernel: caller='%s'/%d: pPciDev=%p:{%#x} iRegion=%#x off=%RGp cb=%RGp pszDesc=%p:{%s} pR0Ptr=%p\n",
|
---|
395 | pDevIns->pReg->szName, pDevIns->iInstance, pPciDev, pPciDev ? pPciDev->uDevFn : UINT32_MAX, iRegion, off, cb, pszDesc, pszDesc, pR0Ptr));
|
---|
396 | //AssertReturn(!pPciDev || pPciDev->Int.s.pDevInsR3 == pDevIns, VERR_INVALID_PARAMETER);
|
---|
397 |
|
---|
398 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
399 | AssertFailed();
|
---|
400 |
|
---|
401 | LogFlow(("pdmR3DevHlp_MMIO2MapKernel: caller='%s'/%d: returns %Rrc *pR0Ptr=%RHv\n", pDevIns->pReg->szName, pDevIns->iInstance, rc, *pR0Ptr));
|
---|
402 | return rc;
|
---|
403 | }
|
---|
404 |
|
---|
405 |
|
---|
406 | /** @interface_method_impl{PDMDEVHLPR3,pfnROMRegister} */
|
---|
407 | static DECLCALLBACK(int) pdmR3DevHlp_ROMRegister(PPDMDEVINS pDevIns, RTGCPHYS GCPhysStart, uint32_t cbRange,
|
---|
408 | const void *pvBinary, uint32_t cbBinary, uint32_t fFlags, const char *pszDesc)
|
---|
409 | {
|
---|
410 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
411 | LogFlow(("pdmR3DevHlp_ROMRegister: caller='%s'/%d: GCPhysStart=%RGp cbRange=%#x pvBinary=%p cbBinary=%#x fFlags=%#RX32 pszDesc=%p:{%s}\n",
|
---|
412 | pDevIns->pReg->szName, pDevIns->iInstance, GCPhysStart, cbRange, pvBinary, cbBinary, fFlags, pszDesc, pszDesc));
|
---|
413 |
|
---|
414 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
415 | AssertFailed();
|
---|
416 |
|
---|
417 | LogFlow(("pdmR3DevHlp_ROMRegister: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
418 | return rc;
|
---|
419 | }
|
---|
420 |
|
---|
421 |
|
---|
422 | /** @interface_method_impl{PDMDEVHLPR3,pfnROMProtectShadow} */
|
---|
423 | static DECLCALLBACK(int) pdmR3DevHlp_ROMProtectShadow(PPDMDEVINS pDevIns, RTGCPHYS GCPhysStart, uint32_t cbRange, PGMROMPROT enmProt)
|
---|
424 | {
|
---|
425 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
426 | LogFlow(("pdmR3DevHlp_ROMProtectShadow: caller='%s'/%d: GCPhysStart=%RGp cbRange=%#x enmProt=%d\n",
|
---|
427 | pDevIns->pReg->szName, pDevIns->iInstance, GCPhysStart, cbRange, enmProt));
|
---|
428 |
|
---|
429 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
430 | AssertFailed();
|
---|
431 |
|
---|
432 | LogFlow(("pdmR3DevHlp_ROMProtectShadow: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
433 | return rc;
|
---|
434 | }
|
---|
435 |
|
---|
436 |
|
---|
437 | /** @interface_method_impl{PDMDEVHLPR3,pfnSSMRegister} */
|
---|
438 | static DECLCALLBACK(int) pdmR3DevHlp_SSMRegister(PPDMDEVINS pDevIns, uint32_t uVersion, size_t cbGuess, const char *pszBefore,
|
---|
439 | PFNSSMDEVLIVEPREP pfnLivePrep, PFNSSMDEVLIVEEXEC pfnLiveExec, PFNSSMDEVLIVEVOTE pfnLiveVote,
|
---|
440 | PFNSSMDEVSAVEPREP pfnSavePrep, PFNSSMDEVSAVEEXEC pfnSaveExec, PFNSSMDEVSAVEDONE pfnSaveDone,
|
---|
441 | PFNSSMDEVLOADPREP pfnLoadPrep, PFNSSMDEVLOADEXEC pfnLoadExec, PFNSSMDEVLOADDONE pfnLoadDone)
|
---|
442 | {
|
---|
443 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
444 | LogFlow(("pdmR3DevHlp_SSMRegister: caller='%s'/%d: uVersion=%#x cbGuess=%#x pszBefore=%p:{%s}\n"
|
---|
445 | " pfnLivePrep=%p pfnLiveExec=%p pfnLiveVote=%p pfnSavePrep=%p pfnSaveExec=%p pfnSaveDone=%p pszLoadPrep=%p pfnLoadExec=%p pfnLoadDone=%p\n",
|
---|
446 | pDevIns->pReg->szName, pDevIns->iInstance, uVersion, cbGuess, pszBefore, pszBefore,
|
---|
447 | pfnLivePrep, pfnLiveExec, pfnLiveVote,
|
---|
448 | pfnSavePrep, pfnSaveExec, pfnSaveDone,
|
---|
449 | pfnLoadPrep, pfnLoadExec, pfnLoadDone));
|
---|
450 |
|
---|
451 | /** @todo */
|
---|
452 | int rc = VINF_SUCCESS;
|
---|
453 | //AssertFailed();
|
---|
454 |
|
---|
455 | LogFlow(("pdmR3DevHlp_SSMRegister: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
456 | return rc;
|
---|
457 | }
|
---|
458 |
|
---|
459 |
|
---|
460 | /** @interface_method_impl{PDMDEVHLPR3,pfnTMTimerCreate} */
|
---|
461 | static DECLCALLBACK(int) pdmR3DevHlp_TMTimerCreate(PPDMDEVINS pDevIns, TMCLOCK enmClock, PFNTMTIMERDEV pfnCallback, void *pvUser,
|
---|
462 | uint32_t fFlags, const char *pszDesc, PPTMTIMERR3 ppTimer)
|
---|
463 | {
|
---|
464 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
465 | LogFlow(("pdmR3DevHlp_TMTimerCreate: caller='%s'/%d: enmClock=%d pfnCallback=%p pvUser=%p fFlags=%#x pszDesc=%p:{%s} ppTimer=%p\n",
|
---|
466 | pDevIns->pReg->szName, pDevIns->iInstance, enmClock, pfnCallback, pvUser, fFlags, pszDesc, pszDesc, ppTimer));
|
---|
467 |
|
---|
468 | int rc = VINF_SUCCESS;
|
---|
469 | PTMTIMERR3 pTimer = (PTMTIMERR3)RTMemAllocZ(sizeof(TMTIMER));
|
---|
470 | if (RT_LIKELY(pTimer))
|
---|
471 | {
|
---|
472 | pTimer->pVmmCallbacks = pDevIns->Internal.s.pVmmCallbacks;
|
---|
473 | pTimer->enmClock = enmClock;
|
---|
474 | pTimer->pfnCallbackDev = pfnCallback;
|
---|
475 | pTimer->pvUser = pvUser;
|
---|
476 | pTimer->fFlags = fFlags;
|
---|
477 | RTListAppend(&pDevIns->Internal.s.pDut->LstTimers, &pTimer->NdDevTimers);
|
---|
478 | *ppTimer = pTimer;
|
---|
479 | }
|
---|
480 | else
|
---|
481 | rc = VERR_NO_MEMORY;
|
---|
482 |
|
---|
483 | LogFlow(("pdmR3DevHlp_TMTimerCreate: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
484 | return rc;
|
---|
485 | }
|
---|
486 |
|
---|
487 |
|
---|
488 | /** @interface_method_impl{PDMDEVHLPR3,pfnTMUtcNow} */
|
---|
489 | static DECLCALLBACK(PRTTIMESPEC) pdmR3DevHlp_TMUtcNow(PPDMDEVINS pDevIns, PRTTIMESPEC pTime)
|
---|
490 | {
|
---|
491 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
492 | LogFlow(("pdmR3DevHlp_TMUtcNow: caller='%s'/%d: pTime=%p\n",
|
---|
493 | pDevIns->pReg->szName, pDevIns->iInstance, pTime));
|
---|
494 |
|
---|
495 | AssertFailed();
|
---|
496 |
|
---|
497 | LogFlow(("pdmR3DevHlp_TMUtcNow: caller='%s'/%d: returns %RU64\n", pDevIns->pReg->szName, pDevIns->iInstance, RTTimeSpecGetNano(pTime)));
|
---|
498 | return pTime;
|
---|
499 | }
|
---|
500 |
|
---|
501 |
|
---|
502 | /** @interface_method_impl{PDMDEVHLPR3,pfnTMTimeVirtGet} */
|
---|
503 | static DECLCALLBACK(uint64_t) pdmR3DevHlp_TMTimeVirtGet(PPDMDEVINS pDevIns)
|
---|
504 | {
|
---|
505 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
506 | LogFlow(("pdmR3DevHlp_TMTimeVirtGet: caller='%s'/%d\n",
|
---|
507 | pDevIns->pReg->szName, pDevIns->iInstance));
|
---|
508 |
|
---|
509 | uint64_t u64Time = 0;
|
---|
510 | AssertFailed();
|
---|
511 |
|
---|
512 | LogFlow(("pdmR3DevHlp_TMTimeVirtGet: caller='%s'/%d: returns %RU64\n", pDevIns->pReg->szName, pDevIns->iInstance, u64Time));
|
---|
513 | return u64Time;
|
---|
514 | }
|
---|
515 |
|
---|
516 |
|
---|
517 | /** @interface_method_impl{PDMDEVHLPR3,pfnTMTimeVirtGetFreq} */
|
---|
518 | static DECLCALLBACK(uint64_t) pdmR3DevHlp_TMTimeVirtGetFreq(PPDMDEVINS pDevIns)
|
---|
519 | {
|
---|
520 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
521 | LogFlow(("pdmR3DevHlp_TMTimeVirtGetFreq: caller='%s'/%d\n",
|
---|
522 | pDevIns->pReg->szName, pDevIns->iInstance));
|
---|
523 |
|
---|
524 | uint64_t u64Freq = 0;
|
---|
525 | AssertFailed();
|
---|
526 |
|
---|
527 | LogFlow(("pdmR3DevHlp_TMTimeVirtGetFreq: caller='%s'/%d: returns %RU64\n", pDevIns->pReg->szName, pDevIns->iInstance, u64Freq));
|
---|
528 | return u64Freq;
|
---|
529 | }
|
---|
530 |
|
---|
531 |
|
---|
532 | /** @interface_method_impl{PDMDEVHLPR3,pfnTMTimeVirtGetNano} */
|
---|
533 | static DECLCALLBACK(uint64_t) pdmR3DevHlp_TMTimeVirtGetNano(PPDMDEVINS pDevIns)
|
---|
534 | {
|
---|
535 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
536 | LogFlow(("pdmR3DevHlp_TMTimeVirtGetNano: caller='%s'/%d\n",
|
---|
537 | pDevIns->pReg->szName, pDevIns->iInstance));
|
---|
538 |
|
---|
539 | uint64_t u64Nano = 0;
|
---|
540 | AssertFailed();
|
---|
541 |
|
---|
542 | LogFlow(("pdmR3DevHlp_TMTimeVirtGetNano: caller='%s'/%d: returns %RU64\n", pDevIns->pReg->szName, pDevIns->iInstance, u64Nano));
|
---|
543 | return u64Nano;
|
---|
544 | }
|
---|
545 |
|
---|
546 |
|
---|
547 | /** @interface_method_impl{PDMDEVHLPR3,pfnGetSupDrvSession} */
|
---|
548 | static DECLCALLBACK(PSUPDRVSESSION) pdmR3DevHlp_GetSupDrvSession(PPDMDEVINS pDevIns)
|
---|
549 | {
|
---|
550 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
551 | LogFlow(("pdmR3DevHlp_GetSupDrvSession: caller='%s'/%d\n",
|
---|
552 | pDevIns->pReg->szName, pDevIns->iInstance));
|
---|
553 |
|
---|
554 | PTSTDEVDUTINT pThis = TSTDEV_PDMDEVINS_2_DUT(pDevIns);
|
---|
555 | PSUPDRVSESSION pSession = TSTDEV_PTSTDEVSUPDRVSESSION_2_PSUPDRVSESSION(&pThis->SupSession);
|
---|
556 |
|
---|
557 | LogFlow(("pdmR3DevHlp_GetSupDrvSession: caller='%s'/%d: returns %#p\n", pDevIns->pReg->szName, pDevIns->iInstance, pSession));
|
---|
558 | return pSession;
|
---|
559 | }
|
---|
560 |
|
---|
561 |
|
---|
562 | /** @interface_method_impl{PDMDEVHLPR3,pfnQueryGenericUserObject} */
|
---|
563 | static DECLCALLBACK(void *) pdmR3DevHlp_QueryGenericUserObject(PPDMDEVINS pDevIns, PCRTUUID pUuid)
|
---|
564 | {
|
---|
565 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
566 | LogFlow(("pdmR3DevHlp_QueryGenericUserObject: caller='%s'/%d: pUuid=%p:%RTuuid\n",
|
---|
567 | pDevIns->pReg->szName, pDevIns->iInstance, pUuid, pUuid));
|
---|
568 |
|
---|
569 | void *pvRet = NULL;
|
---|
570 |
|
---|
571 | LogRel(("pdmR3DevHlp_QueryGenericUserObject: caller='%s'/%d: returns %#p for %RTuuid\n",
|
---|
572 | pDevIns->pReg->szName, pDevIns->iInstance, pvRet, pUuid));
|
---|
573 | return pvRet;
|
---|
574 | }
|
---|
575 |
|
---|
576 |
|
---|
577 | /** @interface_method_impl{PDMDEVHLPR3,pfnPhysRead} */
|
---|
578 | static DECLCALLBACK(int) pdmR3DevHlp_PhysRead(PPDMDEVINS pDevIns, RTGCPHYS GCPhys, void *pvBuf, size_t cbRead)
|
---|
579 | {
|
---|
580 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
581 | LogFlow(("pdmR3DevHlp_PhysRead: caller='%s'/%d: GCPhys=%RGp pvBuf=%p cbRead=%#x\n",
|
---|
582 | pDevIns->pReg->szName, pDevIns->iInstance, GCPhys, pvBuf, cbRead));
|
---|
583 |
|
---|
584 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
585 | AssertFailed();
|
---|
586 |
|
---|
587 | Log(("pdmR3DevHlp_PhysRead: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
588 | return rc;
|
---|
589 | }
|
---|
590 |
|
---|
591 |
|
---|
592 | /** @interface_method_impl{PDMDEVHLPR3,pfnPhysWrite} */
|
---|
593 | static DECLCALLBACK(int) pdmR3DevHlp_PhysWrite(PPDMDEVINS pDevIns, RTGCPHYS GCPhys, const void *pvBuf, size_t cbWrite)
|
---|
594 | {
|
---|
595 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
596 | LogFlow(("pdmR3DevHlp_PhysWrite: caller='%s'/%d: GCPhys=%RGp pvBuf=%p cbWrite=%#x\n",
|
---|
597 | pDevIns->pReg->szName, pDevIns->iInstance, GCPhys, pvBuf, cbWrite));
|
---|
598 |
|
---|
599 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
600 | AssertFailed();
|
---|
601 |
|
---|
602 | Log(("pdmR3DevHlp_PhysWrite: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
603 | return rc;
|
---|
604 | }
|
---|
605 |
|
---|
606 |
|
---|
607 | /** @interface_method_impl{PDMDEVHLPR3,pfnPhysGCPhys2CCPtr} */
|
---|
608 | static DECLCALLBACK(int) pdmR3DevHlp_PhysGCPhys2CCPtr(PPDMDEVINS pDevIns, RTGCPHYS GCPhys, uint32_t fFlags, void **ppv, PPGMPAGEMAPLOCK pLock)
|
---|
609 | {
|
---|
610 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
611 | LogFlow(("pdmR3DevHlp_PhysGCPhys2CCPtr: caller='%s'/%d: GCPhys=%RGp fFlags=%#x ppv=%p pLock=%p\n",
|
---|
612 | pDevIns->pReg->szName, pDevIns->iInstance, GCPhys, fFlags, ppv, pLock));
|
---|
613 | AssertReturn(!fFlags, VERR_INVALID_PARAMETER);
|
---|
614 |
|
---|
615 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
616 | AssertFailed();
|
---|
617 |
|
---|
618 | Log(("pdmR3DevHlp_PhysGCPhys2CCPtr: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
619 | return rc;
|
---|
620 | }
|
---|
621 |
|
---|
622 |
|
---|
623 | /** @interface_method_impl{PDMDEVHLPR3,pfnPhysGCPhys2CCPtrReadOnly} */
|
---|
624 | static DECLCALLBACK(int) pdmR3DevHlp_PhysGCPhys2CCPtrReadOnly(PPDMDEVINS pDevIns, RTGCPHYS GCPhys, uint32_t fFlags, const void **ppv, PPGMPAGEMAPLOCK pLock)
|
---|
625 | {
|
---|
626 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
627 | LogFlow(("pdmR3DevHlp_PhysGCPhys2CCPtrReadOnly: caller='%s'/%d: GCPhys=%RGp fFlags=%#x ppv=%p pLock=%p\n",
|
---|
628 | pDevIns->pReg->szName, pDevIns->iInstance, GCPhys, fFlags, ppv, pLock));
|
---|
629 | AssertReturn(!fFlags, VERR_INVALID_PARAMETER);
|
---|
630 |
|
---|
631 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
632 | AssertFailed();
|
---|
633 |
|
---|
634 | Log(("pdmR3DevHlp_PhysGCPhys2CCPtrReadOnly: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
635 | return rc;
|
---|
636 | }
|
---|
637 |
|
---|
638 |
|
---|
639 | /** @interface_method_impl{PDMDEVHLPR3,pfnPhysReleasePageMappingLock} */
|
---|
640 | static DECLCALLBACK(void) pdmR3DevHlp_PhysReleasePageMappingLock(PPDMDEVINS pDevIns, PPGMPAGEMAPLOCK pLock)
|
---|
641 | {
|
---|
642 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
643 | LogFlow(("pdmR3DevHlp_PhysReleasePageMappingLock: caller='%s'/%d: pLock=%p\n",
|
---|
644 | pDevIns->pReg->szName, pDevIns->iInstance, pLock));
|
---|
645 |
|
---|
646 | AssertFailed();
|
---|
647 |
|
---|
648 | Log(("pdmR3DevHlp_PhysReleasePageMappingLock: caller='%s'/%d: returns void\n", pDevIns->pReg->szName, pDevIns->iInstance));
|
---|
649 | }
|
---|
650 |
|
---|
651 |
|
---|
652 | /** @interface_method_impl{PDMDEVHLPR3,pfnPhysReadGCVirt} */
|
---|
653 | static DECLCALLBACK(int) pdmR3DevHlp_PhysReadGCVirt(PPDMDEVINS pDevIns, void *pvDst, RTGCPTR GCVirtSrc, size_t cb)
|
---|
654 | {
|
---|
655 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
656 | LogFlow(("pdmR3DevHlp_PhysReadGCVirt: caller='%s'/%d: pvDst=%p GCVirt=%RGv cb=%#x\n",
|
---|
657 | pDevIns->pReg->szName, pDevIns->iInstance, pvDst, GCVirtSrc, cb));
|
---|
658 |
|
---|
659 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
660 | AssertFailed();
|
---|
661 |
|
---|
662 | LogFlow(("pdmR3DevHlp_PhysReadGCVirt: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
663 |
|
---|
664 | return rc;
|
---|
665 | }
|
---|
666 |
|
---|
667 |
|
---|
668 | /** @interface_method_impl{PDMDEVHLPR3,pfnPhysWriteGCVirt} */
|
---|
669 | static DECLCALLBACK(int) pdmR3DevHlp_PhysWriteGCVirt(PPDMDEVINS pDevIns, RTGCPTR GCVirtDst, const void *pvSrc, size_t cb)
|
---|
670 | {
|
---|
671 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
672 | LogFlow(("pdmR3DevHlp_PhysWriteGCVirt: caller='%s'/%d: GCVirtDst=%RGv pvSrc=%p cb=%#x\n",
|
---|
673 | pDevIns->pReg->szName, pDevIns->iInstance, GCVirtDst, pvSrc, cb));
|
---|
674 |
|
---|
675 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
676 | AssertFailed();
|
---|
677 |
|
---|
678 | LogFlow(("pdmR3DevHlp_PhysWriteGCVirt: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
679 |
|
---|
680 | return rc;
|
---|
681 | }
|
---|
682 |
|
---|
683 |
|
---|
684 | /** @interface_method_impl{PDMDEVHLPR3,pfnPhysGCPtr2GCPhys} */
|
---|
685 | static DECLCALLBACK(int) pdmR3DevHlp_PhysGCPtr2GCPhys(PPDMDEVINS pDevIns, RTGCPTR GCPtr, PRTGCPHYS pGCPhys)
|
---|
686 | {
|
---|
687 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
688 | LogFlow(("pdmR3DevHlp_PhysGCPtr2GCPhys: caller='%s'/%d: GCPtr=%RGv pGCPhys=%p\n",
|
---|
689 | pDevIns->pReg->szName, pDevIns->iInstance, GCPtr, pGCPhys));
|
---|
690 |
|
---|
691 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
692 | AssertFailed();
|
---|
693 |
|
---|
694 | LogFlow(("pdmR3DevHlp_PhysGCPtr2GCPhys: caller='%s'/%d: returns %Rrc *pGCPhys=%RGp\n", pDevIns->pReg->szName, pDevIns->iInstance, rc, *pGCPhys));
|
---|
695 |
|
---|
696 | return rc;
|
---|
697 | }
|
---|
698 |
|
---|
699 |
|
---|
700 | /** @interface_method_impl{PDMDEVHLPR3,pfnMMHeapAlloc} */
|
---|
701 | static DECLCALLBACK(void *) pdmR3DevHlp_MMHeapAlloc(PPDMDEVINS pDevIns, size_t cb)
|
---|
702 | {
|
---|
703 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
704 | LogFlow(("pdmR3DevHlp_MMHeapAlloc: caller='%s'/%d: cb=%#x\n", pDevIns->pReg->szName, pDevIns->iInstance, cb));
|
---|
705 |
|
---|
706 | PTSTDEVDUTINT pThis = TSTDEV_PDMDEVINS_2_DUT(pDevIns);
|
---|
707 |
|
---|
708 | void *pv = NULL;
|
---|
709 | PTSTDEVMMHEAPALLOC pHeapAlloc = (PTSTDEVMMHEAPALLOC)RTMemAllocZ(cb + sizeof(TSTDEVMMHEAPALLOC) - 1);
|
---|
710 | if (pHeapAlloc)
|
---|
711 | {
|
---|
712 | /* Poison */
|
---|
713 | memset(&pHeapAlloc->abAlloc[0], 0xfe, cb);
|
---|
714 | pHeapAlloc->cbAlloc = cb;
|
---|
715 | pHeapAlloc->pVmmCallbacks = pDevIns->Internal.s.pVmmCallbacks;
|
---|
716 | pHeapAlloc->pDut = pThis;
|
---|
717 |
|
---|
718 | tstDevDutLockExcl(pThis);
|
---|
719 | RTListAppend(&pThis->LstMmHeap, &pHeapAlloc->NdMmHeap);
|
---|
720 | tstDevDutUnlockExcl(pThis);
|
---|
721 |
|
---|
722 | pv = &pHeapAlloc->abAlloc[0];
|
---|
723 | }
|
---|
724 |
|
---|
725 | LogFlow(("pdmR3DevHlp_MMHeapAlloc: caller='%s'/%d: returns %p\n", pDevIns->pReg->szName, pDevIns->iInstance, pv));
|
---|
726 | return pv;
|
---|
727 | }
|
---|
728 |
|
---|
729 |
|
---|
730 | /** @interface_method_impl{PDMDEVHLPR3,pfnMMHeapAllocZ} */
|
---|
731 | static DECLCALLBACK(void *) pdmR3DevHlp_MMHeapAllocZ(PPDMDEVINS pDevIns, size_t cb)
|
---|
732 | {
|
---|
733 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
734 | LogFlow(("pdmR3DevHlp_MMHeapAllocZ: caller='%s'/%d: cb=%#x\n", pDevIns->pReg->szName, pDevIns->iInstance, cb));
|
---|
735 |
|
---|
736 | void *pv = pdmR3DevHlp_MMHeapAlloc(pDevIns, cb);
|
---|
737 | if (VALID_PTR(pv))
|
---|
738 | memset(pv, 0, cb);
|
---|
739 |
|
---|
740 | LogFlow(("pdmR3DevHlp_MMHeapAllocZ: caller='%s'/%d: returns %p\n", pDevIns->pReg->szName, pDevIns->iInstance, pv));
|
---|
741 | return pv;
|
---|
742 | }
|
---|
743 |
|
---|
744 |
|
---|
745 | /** @interface_method_impl{PDMDEVHLPR3,pfnMMHeapFree} */
|
---|
746 | static DECLCALLBACK(void) pdmR3DevHlp_MMHeapFree(PPDMDEVINS pDevIns, void *pv)
|
---|
747 | {
|
---|
748 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
749 | LogFlow(("pdmR3DevHlp_MMHeapFree: caller='%s'/%d: pv=%p\n", pDevIns->pReg->szName, pDevIns->iInstance, pv));
|
---|
750 |
|
---|
751 | MMR3HeapFree(pv);
|
---|
752 |
|
---|
753 | LogFlow(("pdmR3DevHlp_MMHeapAlloc: caller='%s'/%d: returns void\n", pDevIns->pReg->szName, pDevIns->iInstance));
|
---|
754 | }
|
---|
755 |
|
---|
756 |
|
---|
757 | /** @interface_method_impl{PDMDEVHLPR3,pfnVMState} */
|
---|
758 | static DECLCALLBACK(VMSTATE) pdmR3DevHlp_VMState(PPDMDEVINS pDevIns)
|
---|
759 | {
|
---|
760 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
761 |
|
---|
762 | VMSTATE enmVMState = VMSTATE_CREATING;
|
---|
763 | AssertFailed();
|
---|
764 |
|
---|
765 | LogFlow(("pdmR3DevHlp_VMState: caller='%s'/%d: returns %d\n", pDevIns->pReg->szName, pDevIns->iInstance,
|
---|
766 | enmVMState));
|
---|
767 | return enmVMState;
|
---|
768 | }
|
---|
769 |
|
---|
770 |
|
---|
771 | /** @interface_method_impl{PDMDEVHLPR3,pfnVMTeleportedAndNotFullyResumedYet} */
|
---|
772 | static DECLCALLBACK(bool) pdmR3DevHlp_VMTeleportedAndNotFullyResumedYet(PPDMDEVINS pDevIns)
|
---|
773 | {
|
---|
774 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
775 |
|
---|
776 | bool fRc = false;
|
---|
777 | AssertFailed();
|
---|
778 |
|
---|
779 | LogFlow(("pdmR3DevHlp_VMState: caller='%s'/%d: returns %RTbool\n", pDevIns->pReg->szName, pDevIns->iInstance,
|
---|
780 | fRc));
|
---|
781 | return fRc;
|
---|
782 | }
|
---|
783 |
|
---|
784 |
|
---|
785 | /** @interface_method_impl{PDMDEVHLPR3,pfnVMSetError} */
|
---|
786 | static DECLCALLBACK(int) pdmR3DevHlp_VMSetError(PPDMDEVINS pDevIns, int rc, RT_SRC_POS_DECL, const char *pszFormat, ...)
|
---|
787 | {
|
---|
788 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
789 | RT_NOREF(rc, pszFile, iLine, pszFunction, pszFormat);
|
---|
790 | rc = VERR_NOT_IMPLEMENTED;
|
---|
791 | AssertFailed();
|
---|
792 | return rc;
|
---|
793 | }
|
---|
794 |
|
---|
795 |
|
---|
796 | /** @interface_method_impl{PDMDEVHLPR3,pfnVMSetErrorV} */
|
---|
797 | static DECLCALLBACK(int) pdmR3DevHlp_VMSetErrorV(PPDMDEVINS pDevIns, int rc, RT_SRC_POS_DECL, const char *pszFormat, va_list va)
|
---|
798 | {
|
---|
799 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
800 | RT_NOREF(rc, pszFile, iLine, pszFunction, pszFormat, va);
|
---|
801 | rc = VERR_NOT_IMPLEMENTED;
|
---|
802 | AssertFailed();
|
---|
803 | return rc;
|
---|
804 | }
|
---|
805 |
|
---|
806 |
|
---|
807 | /** @interface_method_impl{PDMDEVHLPR3,pfnVMSetRuntimeError} */
|
---|
808 | static DECLCALLBACK(int) pdmR3DevHlp_VMSetRuntimeError(PPDMDEVINS pDevIns, uint32_t fFlags, const char *pszErrorId, const char *pszFormat, ...)
|
---|
809 | {
|
---|
810 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
811 | RT_NOREF(fFlags, pszErrorId, pszFormat);
|
---|
812 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
813 | AssertFailed();
|
---|
814 | return rc;
|
---|
815 | }
|
---|
816 |
|
---|
817 |
|
---|
818 | /** @interface_method_impl{PDMDEVHLPR3,pfnVMSetRuntimeErrorV} */
|
---|
819 | static DECLCALLBACK(int) pdmR3DevHlp_VMSetRuntimeErrorV(PPDMDEVINS pDevIns, uint32_t fFlags, const char *pszErrorId, const char *pszFormat, va_list va)
|
---|
820 | {
|
---|
821 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
822 | RT_NOREF(fFlags, pszErrorId, pszFormat, va);
|
---|
823 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
824 | AssertFailed();
|
---|
825 | return rc;
|
---|
826 | }
|
---|
827 |
|
---|
828 |
|
---|
829 | /** @interface_method_impl{PDMDEVHLPR3,pfnDBGFStopV} */
|
---|
830 | static DECLCALLBACK(int) pdmR3DevHlp_DBGFStopV(PPDMDEVINS pDevIns, const char *pszFile, unsigned iLine, const char *pszFunction, const char *pszFormat, va_list args)
|
---|
831 | {
|
---|
832 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
833 | #ifdef LOG_ENABLED
|
---|
834 | va_list va2;
|
---|
835 | va_copy(va2, args);
|
---|
836 | LogFlow(("pdmR3DevHlp_DBGFStopV: caller='%s'/%d: pszFile=%p:{%s} iLine=%d pszFunction=%p:{%s} pszFormat=%p:{%s} (%N)\n",
|
---|
837 | pDevIns->pReg->szName, pDevIns->iInstance, pszFile, pszFile, iLine, pszFunction, pszFunction, pszFormat, pszFormat, pszFormat, &va2));
|
---|
838 | va_end(va2);
|
---|
839 | #endif
|
---|
840 |
|
---|
841 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
842 | AssertFailed();
|
---|
843 |
|
---|
844 | LogFlow(("pdmR3DevHlp_DBGFStopV: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
845 | return rc;
|
---|
846 | }
|
---|
847 |
|
---|
848 |
|
---|
849 | /** @interface_method_impl{PDMDEVHLPR3,pfnDBGFInfoRegister} */
|
---|
850 | static DECLCALLBACK(int) pdmR3DevHlp_DBGFInfoRegister(PPDMDEVINS pDevIns, const char *pszName, const char *pszDesc, PFNDBGFHANDLERDEV pfnHandler)
|
---|
851 | {
|
---|
852 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
853 | LogFlow(("pdmR3DevHlp_DBGFInfoRegister: caller='%s'/%d: pszName=%p:{%s} pszDesc=%p:{%s} pfnHandler=%p\n",
|
---|
854 | pDevIns->pReg->szName, pDevIns->iInstance, pszName, pszName, pszDesc, pszDesc, pfnHandler));
|
---|
855 |
|
---|
856 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
857 | AssertFailed();
|
---|
858 |
|
---|
859 | LogFlow(("pdmR3DevHlp_DBGFInfoRegister: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
860 | return rc;
|
---|
861 | }
|
---|
862 |
|
---|
863 |
|
---|
864 | /** @interface_method_impl{PDMDEVHLPR3,pfnDBGFRegRegister} */
|
---|
865 | static DECLCALLBACK(int) pdmR3DevHlp_DBGFRegRegister(PPDMDEVINS pDevIns, PCDBGFREGDESC paRegisters)
|
---|
866 | {
|
---|
867 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
868 | LogFlow(("pdmR3DevHlp_DBGFRegRegister: caller='%s'/%d: paRegisters=%p\n",
|
---|
869 | pDevIns->pReg->szName, pDevIns->iInstance, paRegisters));
|
---|
870 |
|
---|
871 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
872 | AssertFailed();
|
---|
873 |
|
---|
874 | LogFlow(("pdmR3DevHlp_DBGFRegRegister: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
875 | return rc;
|
---|
876 | }
|
---|
877 |
|
---|
878 |
|
---|
879 | /** @interface_method_impl{PDMDEVHLPR3,pfnDBGFTraceBuf} */
|
---|
880 | static DECLCALLBACK(RTTRACEBUF) pdmR3DevHlp_DBGFTraceBuf(PPDMDEVINS pDevIns)
|
---|
881 | {
|
---|
882 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
883 | RTTRACEBUF hTraceBuf = NULL;
|
---|
884 | AssertFailed();
|
---|
885 | LogFlow(("pdmR3DevHlp_DBGFTraceBuf: caller='%s'/%d: returns %p\n", pDevIns->pReg->szName, pDevIns->iInstance, hTraceBuf));
|
---|
886 | return hTraceBuf;
|
---|
887 | }
|
---|
888 |
|
---|
889 |
|
---|
890 | /** @interface_method_impl{PDMDEVHLPR3,pfnSTAMRegister} */
|
---|
891 | static DECLCALLBACK(void) pdmR3DevHlp_STAMRegister(PPDMDEVINS pDevIns, void *pvSample, STAMTYPE enmType, const char *pszName,
|
---|
892 | STAMUNIT enmUnit, const char *pszDesc)
|
---|
893 | {
|
---|
894 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
895 | RT_NOREF(pvSample, enmType, pszName, enmUnit, pszDesc);
|
---|
896 | AssertFailed();
|
---|
897 | }
|
---|
898 |
|
---|
899 |
|
---|
900 |
|
---|
901 | /** @interface_method_impl{PDMDEVHLPR3,pfnSTAMRegisterF} */
|
---|
902 | static DECLCALLBACK(void) pdmR3DevHlp_STAMRegisterF(PPDMDEVINS pDevIns, void *pvSample, STAMTYPE enmType, STAMVISIBILITY enmVisibility,
|
---|
903 | STAMUNIT enmUnit, const char *pszDesc, const char *pszName, ...)
|
---|
904 | {
|
---|
905 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
906 | RT_NOREF(pvSample, enmType, enmVisibility, enmUnit, pszDesc, pszName);
|
---|
907 | AssertFailed();
|
---|
908 | }
|
---|
909 |
|
---|
910 |
|
---|
911 | /** @interface_method_impl{PDMDEVHLPR3,pfnSTAMRegisterV} */
|
---|
912 | static DECLCALLBACK(void) pdmR3DevHlp_STAMRegisterV(PPDMDEVINS pDevIns, void *pvSample, STAMTYPE enmType, STAMVISIBILITY enmVisibility,
|
---|
913 | STAMUNIT enmUnit, const char *pszDesc, const char *pszName, va_list args)
|
---|
914 | {
|
---|
915 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
916 | RT_NOREF(pvSample, enmType, enmVisibility, enmUnit, pszDesc, pszName, args);
|
---|
917 | AssertFailed();
|
---|
918 | }
|
---|
919 |
|
---|
920 |
|
---|
921 | /**
|
---|
922 | * @interface_method_impl{PDMDEVHLPR3,pfnPCIRegister}
|
---|
923 | */
|
---|
924 | static DECLCALLBACK(int) pdmR3DevHlp_PCIRegister(PPDMDEVINS pDevIns, PPDMPCIDEV pPciDev, uint32_t idxDevCfg, uint32_t fFlags,
|
---|
925 | uint8_t uPciDevNo, uint8_t uPciFunNo, const char *pszName)
|
---|
926 | {
|
---|
927 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
928 | LogFlow(("pdmR3DevHlp_PCIRegister: caller='%s'/%d: pPciDev=%p:{.config={%#.256Rhxs} idxDevCfg=%d fFlags=%#x uPciDevNo=%#x uPciFunNo=%#x pszName=%p:{%s}\n",
|
---|
929 | pDevIns->pReg->szName, pDevIns->iInstance, pPciDev, pPciDev->abConfig, idxDevCfg, fFlags, uPciDevNo, uPciFunNo, pszName, pszName ? pszName : ""));
|
---|
930 |
|
---|
931 | /*
|
---|
932 | * Validate input.
|
---|
933 | */
|
---|
934 | AssertLogRelMsgReturn(RT_VALID_PTR(pPciDev),
|
---|
935 | ("'%s'/%d: Invalid pPciDev value: %p\n", pDevIns->pReg->szName, pDevIns->iInstance, pPciDev),
|
---|
936 | VERR_INVALID_POINTER);
|
---|
937 | AssertLogRelMsgReturn(PDMPciDevGetVendorId(pPciDev),
|
---|
938 | ("'%s'/%d: Vendor ID is not set!\n", pDevIns->pReg->szName, pDevIns->iInstance),
|
---|
939 | VERR_INVALID_POINTER);
|
---|
940 | AssertLogRelMsgReturn(idxDevCfg < 256 || idxDevCfg == PDMPCIDEVREG_CFG_NEXT,
|
---|
941 | ("'%s'/%d: Invalid config selector: %#x\n", pDevIns->pReg->szName, pDevIns->iInstance, idxDevCfg),
|
---|
942 | VERR_OUT_OF_RANGE);
|
---|
943 | AssertLogRelMsgReturn( uPciDevNo < 32
|
---|
944 | || uPciDevNo == PDMPCIDEVREG_DEV_NO_FIRST_UNUSED
|
---|
945 | || uPciDevNo == PDMPCIDEVREG_DEV_NO_SAME_AS_PREV,
|
---|
946 | ("'%s'/%d: Invalid PCI device number: %#x\n", pDevIns->pReg->szName, pDevIns->iInstance, uPciDevNo),
|
---|
947 | VERR_INVALID_PARAMETER);
|
---|
948 | AssertLogRelMsgReturn( uPciFunNo < 8
|
---|
949 | || uPciFunNo == PDMPCIDEVREG_FUN_NO_FIRST_UNUSED,
|
---|
950 | ("'%s'/%d: Invalid PCI funcion number: %#x\n", pDevIns->pReg->szName, pDevIns->iInstance, uPciFunNo),
|
---|
951 | VERR_INVALID_PARAMETER);
|
---|
952 | AssertLogRelMsgReturn(!(fFlags & ~PDMPCIDEVREG_F_VALID_MASK),
|
---|
953 | ("'%s'/%d: Invalid flags: %#x\n", pDevIns->pReg->szName, pDevIns->iInstance, fFlags),
|
---|
954 | VERR_INVALID_FLAGS);
|
---|
955 | int rc = VINF_SUCCESS;
|
---|
956 | pDevIns->Internal.s.pDut->pPciDev = pPciDev;
|
---|
957 |
|
---|
958 | LogFlow(("pdmR3DevHlp_PCIRegister: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
959 | return rc;
|
---|
960 | }
|
---|
961 |
|
---|
962 |
|
---|
963 | /** @interface_method_impl{PDMDEVHLPR3,pfnPCIRegisterMsi} */
|
---|
964 | static DECLCALLBACK(int) pdmR3DevHlp_PCIRegisterMsi(PPDMDEVINS pDevIns, PPDMPCIDEV pPciDev, PPDMMSIREG pMsiReg)
|
---|
965 | {
|
---|
966 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
967 | LogFlow(("pdmR3DevHlp_PCIRegisterMsi: caller='%s'/%d: pPciDev=%p:{%#x} pMsgReg=%p:{cMsiVectors=%d, cMsixVectors=%d}\n",
|
---|
968 | pDevIns->pReg->szName, pDevIns->iInstance, pPciDev, pPciDev->uDevFn, pMsiReg, pMsiReg->cMsiVectors, pMsiReg->cMsixVectors));
|
---|
969 |
|
---|
970 | int rc = VERR_NOT_SUPPORTED; /** @todo */
|
---|
971 |
|
---|
972 | LogFlow(("pdmR3DevHlp_PCIRegisterMsi: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
973 | return rc;
|
---|
974 | }
|
---|
975 |
|
---|
976 |
|
---|
977 | /** @interface_method_impl{PDMDEVHLPR3,pfnPCIIORegionRegister} */
|
---|
978 | static DECLCALLBACK(int) pdmR3DevHlp_PCIIORegionRegister(PPDMDEVINS pDevIns, PPDMPCIDEV pPciDev, uint32_t iRegion,
|
---|
979 | RTGCPHYS cbRegion, PCIADDRESSSPACE enmType, PFNPCIIOREGIONMAP pfnCallback)
|
---|
980 | {
|
---|
981 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
982 | LogFlow(("pdmR3DevHlp_PCIIORegionRegister: caller='%s'/%d: pPciDev=%p:{%#x} iRegion=%d cbRegion=%RGp enmType=%d pfnCallback=%p\n",
|
---|
983 | pDevIns->pReg->szName, pDevIns->iInstance, pPciDev, pPciDev->uDevFn, iRegion, cbRegion, enmType, pfnCallback));
|
---|
984 |
|
---|
985 | AssertLogRelMsgReturn(iRegion < VBOX_PCI_NUM_REGIONS,
|
---|
986 | ("Region %u exceeds maximum region index %u\n", iRegion, VBOX_PCI_NUM_REGIONS),
|
---|
987 | VERR_INVALID_PARAMETER);
|
---|
988 |
|
---|
989 | int rc = VINF_SUCCESS;
|
---|
990 | PTSTDEVDUTINT pThis = TSTDEV_PDMDEVINS_2_DUT(pDevIns);
|
---|
991 | PTSTDEVDUTPCIREGION pRegion = &pThis->aPciRegions[iRegion];
|
---|
992 | pRegion->cbRegion = cbRegion;
|
---|
993 | pRegion->enmType = enmType;
|
---|
994 | pRegion->pfnRegionMap = pfnCallback;
|
---|
995 |
|
---|
996 | LogFlow(("pdmR3DevHlp_PCIIORegionRegister: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
997 | return rc;
|
---|
998 | }
|
---|
999 |
|
---|
1000 |
|
---|
1001 | /** @interface_method_impl{PDMDEVHLPR3,pfnPCISetConfigCallbacks} */
|
---|
1002 | static DECLCALLBACK(void) pdmR3DevHlp_PCISetConfigCallbacks(PPDMDEVINS pDevIns, PPDMPCIDEV pPciDev, PFNPCICONFIGREAD pfnRead, PPFNPCICONFIGREAD ppfnReadOld,
|
---|
1003 | PFNPCICONFIGWRITE pfnWrite, PPFNPCICONFIGWRITE ppfnWriteOld)
|
---|
1004 | {
|
---|
1005 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1006 | LogFlow(("pdmR3DevHlp_PCISetConfigCallbacks: caller='%s'/%d: pPciDev=%p pfnRead=%p ppfnReadOld=%p pfnWrite=%p ppfnWriteOld=%p\n",
|
---|
1007 | pDevIns->pReg->szName, pDevIns->iInstance, pPciDev, pfnRead, ppfnReadOld, pfnWrite, ppfnWriteOld));
|
---|
1008 |
|
---|
1009 | /*
|
---|
1010 | * Validate input and resolve defaults.
|
---|
1011 | */
|
---|
1012 | AssertPtr(pfnRead);
|
---|
1013 | AssertPtr(pfnWrite);
|
---|
1014 | AssertPtrNull(ppfnReadOld);
|
---|
1015 | AssertPtrNull(ppfnWriteOld);
|
---|
1016 | AssertPtrNull(pPciDev);
|
---|
1017 |
|
---|
1018 | AssertFailed();
|
---|
1019 |
|
---|
1020 | LogFlow(("pdmR3DevHlp_PCISetConfigCallbacks: caller='%s'/%d: returns void\n", pDevIns->pReg->szName, pDevIns->iInstance));
|
---|
1021 | }
|
---|
1022 |
|
---|
1023 |
|
---|
1024 | /** @interface_method_impl{PDMDEVHLPR3,pfnPCIPhysRead} */
|
---|
1025 | static DECLCALLBACK(int) pdmR3DevHlp_PCIPhysRead(PPDMDEVINS pDevIns, PPDMPCIDEV pPciDev, RTGCPHYS GCPhys, void *pvBuf, size_t cbRead)
|
---|
1026 | {
|
---|
1027 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1028 | RT_NOREF(pPciDev);
|
---|
1029 | return pDevIns->pHlpR3->pfnPhysRead(pDevIns, GCPhys, pvBuf, cbRead);
|
---|
1030 | }
|
---|
1031 |
|
---|
1032 |
|
---|
1033 | /** @interface_method_impl{PDMDEVHLPR3,pfnPCIPhysWrite} */
|
---|
1034 | static DECLCALLBACK(int)
|
---|
1035 | pdmR3DevHlp_PCIPhysWrite(PPDMDEVINS pDevIns, PPDMPCIDEV pPciDev, RTGCPHYS GCPhys, const void *pvBuf, size_t cbWrite)
|
---|
1036 | {
|
---|
1037 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1038 | RT_NOREF(pPciDev);
|
---|
1039 | return pDevIns->pHlpR3->pfnPhysWrite(pDevIns, GCPhys, pvBuf, cbWrite);
|
---|
1040 | }
|
---|
1041 |
|
---|
1042 |
|
---|
1043 | /** @interface_method_impl{PDMDEVHLPR3,pfnPCISetIrq} */
|
---|
1044 | static DECLCALLBACK(void) pdmR3DevHlp_PCISetIrq(PPDMDEVINS pDevIns, PPDMPCIDEV pPciDev, int iIrq, int iLevel)
|
---|
1045 | {
|
---|
1046 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1047 | LogFlow(("pdmR3DevHlp_PCISetIrq: caller='%s'/%d: pPciDev=%p:{%#x} iIrq=%d iLevel=%d\n",
|
---|
1048 | pDevIns->pReg->szName, pDevIns->iInstance, pPciDev, pPciDev->uDevFn, iIrq, iLevel));
|
---|
1049 |
|
---|
1050 | AssertFailed();
|
---|
1051 |
|
---|
1052 | LogFlow(("pdmR3DevHlp_PCISetIrq: caller='%s'/%d: returns void\n", pDevIns->pReg->szName, pDevIns->iInstance));
|
---|
1053 | }
|
---|
1054 |
|
---|
1055 |
|
---|
1056 | /** @interface_method_impl{PDMDEVHLPR3,pfnPCISetIrqNoWait} */
|
---|
1057 | static DECLCALLBACK(void) pdmR3DevHlp_PCISetIrqNoWait(PPDMDEVINS pDevIns, PPDMPCIDEV pPciDev, int iIrq, int iLevel)
|
---|
1058 | {
|
---|
1059 | pdmR3DevHlp_PCISetIrq(pDevIns, pPciDev, iIrq, iLevel);
|
---|
1060 | }
|
---|
1061 |
|
---|
1062 |
|
---|
1063 | /** @interface_method_impl{PDMDEVHLPR3,pfnISASetIrq} */
|
---|
1064 | static DECLCALLBACK(void) pdmR3DevHlp_ISASetIrq(PPDMDEVINS pDevIns, int iIrq, int iLevel)
|
---|
1065 | {
|
---|
1066 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1067 | LogFlow(("pdmR3DevHlp_ISASetIrq: caller='%s'/%d: iIrq=%d iLevel=%d\n", pDevIns->pReg->szName, pDevIns->iInstance, iIrq, iLevel));
|
---|
1068 |
|
---|
1069 | //AssertFailed();
|
---|
1070 |
|
---|
1071 | LogFlow(("pdmR3DevHlp_ISASetIrq: caller='%s'/%d: returns void\n", pDevIns->pReg->szName, pDevIns->iInstance));
|
---|
1072 | }
|
---|
1073 |
|
---|
1074 |
|
---|
1075 | /** @interface_method_impl{PDMDEVHLPR3,pfnISASetIrqNoWait} */
|
---|
1076 | static DECLCALLBACK(void) pdmR3DevHlp_ISASetIrqNoWait(PPDMDEVINS pDevIns, int iIrq, int iLevel)
|
---|
1077 | {
|
---|
1078 | pdmR3DevHlp_ISASetIrq(pDevIns, iIrq, iLevel);
|
---|
1079 | }
|
---|
1080 |
|
---|
1081 |
|
---|
1082 | /** @interface_method_impl{PDMDEVHLPR3,pfnIoApicSendMsi} */
|
---|
1083 | static DECLCALLBACK(void) pdmR3DevHlp_IoApicSendMsi(PPDMDEVINS pDevIns, RTGCPHYS GCPhys, uint32_t uValue)
|
---|
1084 | {
|
---|
1085 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1086 | LogFlow(("pdmR3DevHlp_IoApicSendMsi: caller='%s'/%d: GCPhys=%RGp uValue=%#x\n", pDevIns->pReg->szName, pDevIns->iInstance, GCPhys, uValue));
|
---|
1087 |
|
---|
1088 | /*
|
---|
1089 | * Validate input.
|
---|
1090 | */
|
---|
1091 | Assert(GCPhys != 0);
|
---|
1092 | Assert(uValue != 0);
|
---|
1093 | AssertFailed();
|
---|
1094 |
|
---|
1095 | LogFlow(("pdmR3DevHlp_IoApicSendMsi: caller='%s'/%d: returns void\n", pDevIns->pReg->szName, pDevIns->iInstance));
|
---|
1096 | }
|
---|
1097 |
|
---|
1098 |
|
---|
1099 | /** @interface_method_impl{PDMDEVHLPR3,pfnDriverAttach} */
|
---|
1100 | static DECLCALLBACK(int) pdmR3DevHlp_DriverAttach(PPDMDEVINS pDevIns, uint32_t iLun, PPDMIBASE pBaseInterface, PPDMIBASE *ppBaseInterface, const char *pszDesc)
|
---|
1101 | {
|
---|
1102 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1103 | LogFlow(("pdmR3DevHlp_DriverAttach: caller='%s'/%d: iLun=%d pBaseInterface=%p ppBaseInterface=%p pszDesc=%p:{%s}\n",
|
---|
1104 | pDevIns->pReg->szName, pDevIns->iInstance, iLun, pBaseInterface, ppBaseInterface, pszDesc, pszDesc));
|
---|
1105 |
|
---|
1106 | /** @todo */
|
---|
1107 | int rc = VERR_PDM_NO_ATTACHED_DRIVER;
|
---|
1108 | //AssertFailed();
|
---|
1109 |
|
---|
1110 | LogFlow(("pdmR3DevHlp_DriverAttach: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
1111 | return rc;
|
---|
1112 | }
|
---|
1113 |
|
---|
1114 |
|
---|
1115 | /** @interface_method_impl{PDMDEVHLPR3,pfnDriverDetach} */
|
---|
1116 | static DECLCALLBACK(int) pdmR3DevHlp_DriverDetach(PPDMDEVINS pDevIns, PPDMDRVINS pDrvIns, uint32_t fFlags)
|
---|
1117 | {
|
---|
1118 | PDMDEV_ASSERT_DEVINS(pDevIns); RT_NOREF_PV(pDevIns);
|
---|
1119 | LogFlow(("pdmR3DevHlp_DriverDetach: caller='%s'/%d: pDrvIns=%p\n",
|
---|
1120 | pDevIns->pReg->szName, pDevIns->iInstance, pDrvIns));
|
---|
1121 |
|
---|
1122 | RT_NOREF(fFlags);
|
---|
1123 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1124 | AssertFailed();
|
---|
1125 |
|
---|
1126 | LogFlow(("pdmR3DevHlp_DriverDetach: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
1127 | return rc;
|
---|
1128 | }
|
---|
1129 |
|
---|
1130 |
|
---|
1131 | /** @interface_method_impl{PDMDEVHLPR3,pfnQueueCreate} */
|
---|
1132 | static DECLCALLBACK(int) pdmR3DevHlp_QueueCreate(PPDMDEVINS pDevIns, size_t cbItem, uint32_t cItems, uint32_t cMilliesInterval,
|
---|
1133 | PFNPDMQUEUEDEV pfnCallback, bool fRZEnabled, const char *pszName, PPDMQUEUE *ppQueue)
|
---|
1134 | {
|
---|
1135 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1136 | LogFlow(("pdmR3DevHlp_QueueCreate: caller='%s'/%d: cbItem=%#x cItems=%#x cMilliesInterval=%u pfnCallback=%p fRZEnabled=%RTbool pszName=%p:{%s} ppQueue=%p\n",
|
---|
1137 | pDevIns->pReg->szName, pDevIns->iInstance, cbItem, cItems, cMilliesInterval, pfnCallback, fRZEnabled, pszName, pszName, ppQueue));
|
---|
1138 |
|
---|
1139 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1140 | AssertFailed();
|
---|
1141 |
|
---|
1142 | LogFlow(("pdmR3DevHlp_QueueCreate: caller='%s'/%d: returns %Rrc *ppQueue=%p\n", pDevIns->pReg->szName, pDevIns->iInstance, rc, *ppQueue));
|
---|
1143 | return rc;
|
---|
1144 | }
|
---|
1145 |
|
---|
1146 |
|
---|
1147 | /** @interface_method_impl{PDMDEVHLPR3,pfnCritSectInit} */
|
---|
1148 | static DECLCALLBACK(int) pdmR3DevHlp_CritSectInit(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect, RT_SRC_POS_DECL,
|
---|
1149 | const char *pszNameFmt, va_list va)
|
---|
1150 | {
|
---|
1151 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1152 | LogFlow(("pdmR3DevHlp_CritSectInit: caller='%s'/%d: pCritSect=%p pszNameFmt=%p:{%s}\n",
|
---|
1153 | pDevIns->pReg->szName, pDevIns->iInstance, pCritSect, pszNameFmt, pszNameFmt));
|
---|
1154 |
|
---|
1155 | RT_NOREF(RT_SRC_POS_ARGS, pszNameFmt, pCritSect, va);
|
---|
1156 | int rc = RTCritSectInit(&pCritSect->s.CritSect);
|
---|
1157 | if (RT_SUCCESS(rc))
|
---|
1158 | pCritSect->s.pVmmCallbacks = pDevIns->Internal.s.pVmmCallbacks;
|
---|
1159 |
|
---|
1160 | LogFlow(("pdmR3DevHlp_CritSectInit: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
1161 | return rc;
|
---|
1162 | }
|
---|
1163 |
|
---|
1164 |
|
---|
1165 | /** @interface_method_impl{PDMDEVHLPR3,pfnCritSectGetNop} */
|
---|
1166 | static DECLCALLBACK(PPDMCRITSECT) pdmR3DevHlp_CritSectGetNop(PPDMDEVINS pDevIns)
|
---|
1167 | {
|
---|
1168 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1169 |
|
---|
1170 | AssertFailed();
|
---|
1171 | PPDMCRITSECT pCritSect = NULL;
|
---|
1172 |
|
---|
1173 | LogFlow(("pdmR3DevHlp_CritSectGetNop: caller='%s'/%d: return %p\n",
|
---|
1174 | pDevIns->pReg->szName, pDevIns->iInstance, pCritSect));
|
---|
1175 | return pCritSect;
|
---|
1176 | }
|
---|
1177 |
|
---|
1178 |
|
---|
1179 | /** @interface_method_impl{PDMDEVHLPR3,pfnCritSectGetNopR0} */
|
---|
1180 | static DECLCALLBACK(R0PTRTYPE(PPDMCRITSECT)) pdmR3DevHlp_CritSectGetNopR0(PPDMDEVINS pDevIns)
|
---|
1181 | {
|
---|
1182 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1183 |
|
---|
1184 | R0PTRTYPE(PPDMCRITSECT) pCritSect = 0;
|
---|
1185 | AssertFailed();
|
---|
1186 |
|
---|
1187 | LogFlow(("pdmR3DevHlp_CritSectGetNopR0: caller='%s'/%d: return %RHv\n",
|
---|
1188 | pDevIns->pReg->szName, pDevIns->iInstance, pCritSect));
|
---|
1189 | return pCritSect;
|
---|
1190 | }
|
---|
1191 |
|
---|
1192 |
|
---|
1193 | /** @interface_method_impl{PDMDEVHLPR3,pfnCritSectGetNopRC} */
|
---|
1194 | static DECLCALLBACK(RCPTRTYPE(PPDMCRITSECT)) pdmR3DevHlp_CritSectGetNopRC(PPDMDEVINS pDevIns)
|
---|
1195 | {
|
---|
1196 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1197 |
|
---|
1198 | RCPTRTYPE(PPDMCRITSECT) pCritSect = 0;
|
---|
1199 | AssertFailed();
|
---|
1200 |
|
---|
1201 | LogFlow(("pdmR3DevHlp_CritSectGetNopRC: caller='%s'/%d: return %RRv\n",
|
---|
1202 | pDevIns->pReg->szName, pDevIns->iInstance, pCritSect));
|
---|
1203 | return pCritSect;
|
---|
1204 | }
|
---|
1205 |
|
---|
1206 |
|
---|
1207 | /** @interface_method_impl{PDMDEVHLPR3,pfnSetDeviceCritSect} */
|
---|
1208 | static DECLCALLBACK(int) pdmR3DevHlp_SetDeviceCritSect(PPDMDEVINS pDevIns, PPDMCRITSECT pCritSect)
|
---|
1209 | {
|
---|
1210 | /*
|
---|
1211 | * Validate input.
|
---|
1212 | *
|
---|
1213 | * Note! We only allow the automatically created default critical section
|
---|
1214 | * to be replaced by this API.
|
---|
1215 | */
|
---|
1216 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1217 | AssertPtrReturn(pCritSect, VERR_INVALID_POINTER);
|
---|
1218 | LogFlow(("pdmR3DevHlp_SetDeviceCritSect: caller='%s'/%d: pCritSect=%p\n",
|
---|
1219 | pDevIns->pReg->szName, pDevIns->iInstance, pCritSect));
|
---|
1220 |
|
---|
1221 | /** @todo: Implement default atomatic critical section. */
|
---|
1222 | pDevIns->pCritSectRoR3 = pCritSect;
|
---|
1223 |
|
---|
1224 | LogFlow(("pdmR3DevHlp_SetDeviceCritSect: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, VINF_SUCCESS));
|
---|
1225 | return VINF_SUCCESS;
|
---|
1226 | }
|
---|
1227 |
|
---|
1228 |
|
---|
1229 | /** @interface_method_impl{PDMDEVHLPR3,pfnThreadCreate} */
|
---|
1230 | static DECLCALLBACK(int) pdmR3DevHlp_ThreadCreate(PPDMDEVINS pDevIns, PPPDMTHREAD ppThread, void *pvUser, PFNPDMTHREADDEV pfnThread,
|
---|
1231 | PFNPDMTHREADWAKEUPDEV pfnWakeup, size_t cbStack, RTTHREADTYPE enmType, const char *pszName)
|
---|
1232 | {
|
---|
1233 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1234 | LogFlow(("pdmR3DevHlp_ThreadCreate: caller='%s'/%d: ppThread=%p pvUser=%p pfnThread=%p pfnWakeup=%p cbStack=%#zx enmType=%d pszName=%p:{%s}\n",
|
---|
1235 | pDevIns->pReg->szName, pDevIns->iInstance, ppThread, pvUser, pfnThread, pfnWakeup, cbStack, enmType, pszName, pszName));
|
---|
1236 |
|
---|
1237 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1238 | AssertFailed();
|
---|
1239 |
|
---|
1240 | LogFlow(("pdmR3DevHlp_ThreadCreate: caller='%s'/%d: returns %Rrc *ppThread=%RTthrd\n", pDevIns->pReg->szName, pDevIns->iInstance,
|
---|
1241 | rc, *ppThread));
|
---|
1242 | return rc;
|
---|
1243 | }
|
---|
1244 |
|
---|
1245 |
|
---|
1246 | /** @interface_method_impl{PDMDEVHLPR3,pfnSetAsyncNotification} */
|
---|
1247 | static DECLCALLBACK(int) pdmR3DevHlp_SetAsyncNotification(PPDMDEVINS pDevIns, PFNPDMDEVASYNCNOTIFY pfnAsyncNotify)
|
---|
1248 | {
|
---|
1249 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1250 | LogFlow(("pdmR3DevHlp_SetAsyncNotification: caller='%s'/%d: pfnAsyncNotify=%p\n", pDevIns->pReg->szName, pDevIns->iInstance, pfnAsyncNotify));
|
---|
1251 |
|
---|
1252 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1253 | AssertFailed();
|
---|
1254 |
|
---|
1255 | LogFlow(("pdmR3DevHlp_SetAsyncNotification: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
1256 | return rc;
|
---|
1257 | }
|
---|
1258 |
|
---|
1259 |
|
---|
1260 | /** @interface_method_impl{PDMDEVHLPR3,pfnAsyncNotificationCompleted} */
|
---|
1261 | static DECLCALLBACK(void) pdmR3DevHlp_AsyncNotificationCompleted(PPDMDEVINS pDevIns)
|
---|
1262 | {
|
---|
1263 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1264 | AssertFailed();
|
---|
1265 | }
|
---|
1266 |
|
---|
1267 |
|
---|
1268 | /** @interface_method_impl{PDMDEVHLPR3,pfnRTCRegister} */
|
---|
1269 | static DECLCALLBACK(int) pdmR3DevHlp_RTCRegister(PPDMDEVINS pDevIns, PCPDMRTCREG pRtcReg, PCPDMRTCHLP *ppRtcHlp)
|
---|
1270 | {
|
---|
1271 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1272 | LogFlow(("pdmR3DevHlp_RTCRegister: caller='%s'/%d: pRtcReg=%p:{.u32Version=%#x, .pfnWrite=%p, .pfnRead=%p} ppRtcHlp=%p\n",
|
---|
1273 | pDevIns->pReg->szName, pDevIns->iInstance, pRtcReg, pRtcReg->u32Version, pRtcReg->pfnWrite,
|
---|
1274 | pRtcReg->pfnWrite, ppRtcHlp));
|
---|
1275 |
|
---|
1276 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1277 | AssertFailed();
|
---|
1278 |
|
---|
1279 | LogFlow(("pdmR3DevHlp_RTCRegister: caller='%s'/%d: returns %Rrc\n",
|
---|
1280 | pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
1281 | return rc;
|
---|
1282 | }
|
---|
1283 |
|
---|
1284 |
|
---|
1285 | /** @interface_method_impl{PDMDEVHLPR3,pfnDMARegister} */
|
---|
1286 | static DECLCALLBACK(int) pdmR3DevHlp_DMARegister(PPDMDEVINS pDevIns, unsigned uChannel, PFNDMATRANSFERHANDLER pfnTransferHandler, void *pvUser)
|
---|
1287 | {
|
---|
1288 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1289 |
|
---|
1290 | RT_NOREF(uChannel, pfnTransferHandler, pvUser);
|
---|
1291 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1292 | AssertFailed();
|
---|
1293 |
|
---|
1294 | LogFlow(("pdmR3DevHlp_DMARegister: caller='%s'/%d: returns %Rrc\n",
|
---|
1295 | pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
1296 | return rc;
|
---|
1297 | }
|
---|
1298 |
|
---|
1299 |
|
---|
1300 | /** @interface_method_impl{PDMDEVHLPR3,pfnDMAReadMemory} */
|
---|
1301 | static DECLCALLBACK(int) pdmR3DevHlp_DMAReadMemory(PPDMDEVINS pDevIns, unsigned uChannel, void *pvBuffer, uint32_t off, uint32_t cbBlock, uint32_t *pcbRead)
|
---|
1302 | {
|
---|
1303 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1304 | LogFlow(("pdmR3DevHlp_DMAReadMemory: caller='%s'/%d: uChannel=%d pvBuffer=%p off=%#x cbBlock=%#x pcbRead=%p\n",
|
---|
1305 | pDevIns->pReg->szName, pDevIns->iInstance, uChannel, pvBuffer, off, cbBlock, pcbRead));
|
---|
1306 |
|
---|
1307 | RT_NOREF(uChannel, pvBuffer, off, cbBlock, pcbRead);
|
---|
1308 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1309 | AssertFailed();
|
---|
1310 |
|
---|
1311 | LogFlow(("pdmR3DevHlp_DMAReadMemory: caller='%s'/%d: returns %Rrc\n",
|
---|
1312 | pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
1313 | return rc;
|
---|
1314 | }
|
---|
1315 |
|
---|
1316 |
|
---|
1317 | /** @interface_method_impl{PDMDEVHLPR3,pfnDMAWriteMemory} */
|
---|
1318 | static DECLCALLBACK(int) pdmR3DevHlp_DMAWriteMemory(PPDMDEVINS pDevIns, unsigned uChannel, const void *pvBuffer, uint32_t off, uint32_t cbBlock, uint32_t *pcbWritten)
|
---|
1319 | {
|
---|
1320 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1321 | LogFlow(("pdmR3DevHlp_DMAWriteMemory: caller='%s'/%d: uChannel=%d pvBuffer=%p off=%#x cbBlock=%#x pcbWritten=%p\n",
|
---|
1322 | pDevIns->pReg->szName, pDevIns->iInstance, uChannel, pvBuffer, off, cbBlock, pcbWritten));
|
---|
1323 |
|
---|
1324 | RT_NOREF(uChannel, pvBuffer, off, cbBlock, pcbWritten);
|
---|
1325 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1326 | AssertFailed();
|
---|
1327 |
|
---|
1328 | LogFlow(("pdmR3DevHlp_DMAWriteMemory: caller='%s'/%d: returns %Rrc\n",
|
---|
1329 | pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
1330 | return rc;
|
---|
1331 | }
|
---|
1332 |
|
---|
1333 |
|
---|
1334 | /** @interface_method_impl{PDMDEVHLPR3,pfnDMASetDREQ} */
|
---|
1335 | static DECLCALLBACK(int) pdmR3DevHlp_DMASetDREQ(PPDMDEVINS pDevIns, unsigned uChannel, unsigned uLevel)
|
---|
1336 | {
|
---|
1337 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1338 | LogFlow(("pdmR3DevHlp_DMASetDREQ: caller='%s'/%d: uChannel=%d uLevel=%d\n",
|
---|
1339 | pDevIns->pReg->szName, pDevIns->iInstance, uChannel, uLevel));
|
---|
1340 |
|
---|
1341 | RT_NOREF(uChannel, uLevel);
|
---|
1342 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1343 | AssertFailed();
|
---|
1344 |
|
---|
1345 | LogFlow(("pdmR3DevHlp_DMASetDREQ: caller='%s'/%d: returns %Rrc\n",
|
---|
1346 | pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
1347 | return rc;
|
---|
1348 | }
|
---|
1349 |
|
---|
1350 | /** @interface_method_impl{PDMDEVHLPR3,pfnDMAGetChannelMode} */
|
---|
1351 | static DECLCALLBACK(uint8_t) pdmR3DevHlp_DMAGetChannelMode(PPDMDEVINS pDevIns, unsigned uChannel)
|
---|
1352 | {
|
---|
1353 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1354 | LogFlow(("pdmR3DevHlp_DMAGetChannelMode: caller='%s'/%d: uChannel=%d\n",
|
---|
1355 | pDevIns->pReg->szName, pDevIns->iInstance, uChannel));
|
---|
1356 |
|
---|
1357 | uint8_t u8Mode = 0;
|
---|
1358 | AssertFailed();
|
---|
1359 |
|
---|
1360 | LogFlow(("pdmR3DevHlp_DMAGetChannelMode: caller='%s'/%d: returns %#04x\n",
|
---|
1361 | pDevIns->pReg->szName, pDevIns->iInstance, u8Mode));
|
---|
1362 | return u8Mode;
|
---|
1363 | }
|
---|
1364 |
|
---|
1365 | /** @interface_method_impl{PDMDEVHLPR3,pfnDMASchedule} */
|
---|
1366 | static DECLCALLBACK(void) pdmR3DevHlp_DMASchedule(PPDMDEVINS pDevIns)
|
---|
1367 | {
|
---|
1368 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1369 | LogFlow(("pdmR3DevHlp_DMASchedule: caller='%s'/%d\n",
|
---|
1370 | pDevIns->pReg->szName, pDevIns->iInstance));
|
---|
1371 |
|
---|
1372 | AssertFailed();
|
---|
1373 | }
|
---|
1374 |
|
---|
1375 |
|
---|
1376 | /** @interface_method_impl{PDMDEVHLPR3,pfnCMOSWrite} */
|
---|
1377 | static DECLCALLBACK(int) pdmR3DevHlp_CMOSWrite(PPDMDEVINS pDevIns, unsigned iReg, uint8_t u8Value)
|
---|
1378 | {
|
---|
1379 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1380 | LogFlow(("pdmR3DevHlp_CMOSWrite: caller='%s'/%d: iReg=%#04x u8Value=%#04x\n",
|
---|
1381 | pDevIns->pReg->szName, pDevIns->iInstance, iReg, u8Value));
|
---|
1382 |
|
---|
1383 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1384 | AssertFailed();
|
---|
1385 |
|
---|
1386 | LogFlow(("pdmR3DevHlp_CMOSWrite: caller='%s'/%d: return %Rrc\n",
|
---|
1387 | pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
1388 | return rc;
|
---|
1389 | }
|
---|
1390 |
|
---|
1391 |
|
---|
1392 | /** @interface_method_impl{PDMDEVHLPR3,pfnCMOSRead} */
|
---|
1393 | static DECLCALLBACK(int) pdmR3DevHlp_CMOSRead(PPDMDEVINS pDevIns, unsigned iReg, uint8_t *pu8Value)
|
---|
1394 | {
|
---|
1395 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1396 | LogFlow(("pdmR3DevHlp_CMOSWrite: caller='%s'/%d: iReg=%#04x pu8Value=%p\n",
|
---|
1397 | pDevIns->pReg->szName, pDevIns->iInstance, iReg, pu8Value));
|
---|
1398 |
|
---|
1399 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1400 | AssertFailed();
|
---|
1401 |
|
---|
1402 | LogFlow(("pdmR3DevHlp_CMOSWrite: caller='%s'/%d: return %Rrc\n",
|
---|
1403 | pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
1404 | return rc;
|
---|
1405 | }
|
---|
1406 |
|
---|
1407 |
|
---|
1408 | /** @interface_method_impl{PDMDEVHLPR3,pfnAssertEMT} */
|
---|
1409 | static DECLCALLBACK(bool) pdmR3DevHlp_AssertEMT(PPDMDEVINS pDevIns, const char *pszFile, unsigned iLine, const char *pszFunction)
|
---|
1410 | {
|
---|
1411 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1412 | RT_NOREF(pszFile, iLine, pszFunction);
|
---|
1413 | AssertFailed();
|
---|
1414 | return false;
|
---|
1415 | }
|
---|
1416 |
|
---|
1417 |
|
---|
1418 | /** @interface_method_impl{PDMDEVHLPR3,pfnAssertOther} */
|
---|
1419 | static DECLCALLBACK(bool) pdmR3DevHlp_AssertOther(PPDMDEVINS pDevIns, const char *pszFile, unsigned iLine, const char *pszFunction)
|
---|
1420 | {
|
---|
1421 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1422 | RT_NOREF(pszFile, iLine, pszFunction);
|
---|
1423 | AssertFailed();
|
---|
1424 | return false;
|
---|
1425 | }
|
---|
1426 |
|
---|
1427 |
|
---|
1428 | /** @interface_method_impl{PDMDEVHLPR3,pfnLdrGetRCInterfaceSymbols} */
|
---|
1429 | static DECLCALLBACK(int) pdmR3DevHlp_LdrGetRCInterfaceSymbols(PPDMDEVINS pDevIns, void *pvInterface, size_t cbInterface,
|
---|
1430 | const char *pszSymPrefix, const char *pszSymList)
|
---|
1431 | {
|
---|
1432 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1433 | LogFlow(("pdmR3DevHlp_PDMLdrGetRCInterfaceSymbols: caller='%s'/%d: pvInterface=%p cbInterface=%zu pszSymPrefix=%p:{%s} pszSymList=%p:{%s}\n",
|
---|
1434 | pDevIns->pReg->szName, pDevIns->iInstance, pvInterface, cbInterface, pszSymPrefix, pszSymPrefix, pszSymList, pszSymList));
|
---|
1435 |
|
---|
1436 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1437 | AssertFailed();
|
---|
1438 |
|
---|
1439 | LogFlow(("pdmR3DevHlp_PDMLdrGetRCInterfaceSymbols: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName,
|
---|
1440 | pDevIns->iInstance, rc));
|
---|
1441 | return rc;
|
---|
1442 | }
|
---|
1443 |
|
---|
1444 |
|
---|
1445 | /** @interface_method_impl{PDMDEVHLPR3,pfnLdrGetR0InterfaceSymbols} */
|
---|
1446 | static DECLCALLBACK(int) pdmR3DevHlp_LdrGetR0InterfaceSymbols(PPDMDEVINS pDevIns, void *pvInterface, size_t cbInterface,
|
---|
1447 | const char *pszSymPrefix, const char *pszSymList)
|
---|
1448 | {
|
---|
1449 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1450 | LogFlow(("pdmR3DevHlp_PDMLdrGetR0InterfaceSymbols: caller='%s'/%d: pvInterface=%p cbInterface=%zu pszSymPrefix=%p:{%s} pszSymList=%p:{%s}\n",
|
---|
1451 | pDevIns->pReg->szName, pDevIns->iInstance, pvInterface, cbInterface, pszSymPrefix, pszSymPrefix, pszSymList, pszSymList));
|
---|
1452 |
|
---|
1453 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1454 | AssertFailed();
|
---|
1455 |
|
---|
1456 | LogFlow(("pdmR3DevHlp_PDMLdrGetR0InterfaceSymbols: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName,
|
---|
1457 | pDevIns->iInstance, rc));
|
---|
1458 | return rc;
|
---|
1459 | }
|
---|
1460 |
|
---|
1461 |
|
---|
1462 | /** @interface_method_impl{PDMDEVHLPR3,pfnCallR0} */
|
---|
1463 | static DECLCALLBACK(int) pdmR3DevHlp_CallR0(PPDMDEVINS pDevIns, uint32_t uOperation, uint64_t u64Arg)
|
---|
1464 | {
|
---|
1465 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1466 | LogFlow(("pdmR3DevHlp_CallR0: caller='%s'/%d: uOperation=%#x u64Arg=%#RX64\n",
|
---|
1467 | pDevIns->pReg->szName, pDevIns->iInstance, uOperation, u64Arg));
|
---|
1468 |
|
---|
1469 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1470 | AssertFailed();
|
---|
1471 |
|
---|
1472 | LogFlow(("pdmR3DevHlp_CallR0: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName,
|
---|
1473 | pDevIns->iInstance, rc));
|
---|
1474 | return rc;
|
---|
1475 | }
|
---|
1476 |
|
---|
1477 |
|
---|
1478 | /** @interface_method_impl{PDMDEVHLPR3,pfnVMGetSuspendReason} */
|
---|
1479 | static DECLCALLBACK(VMSUSPENDREASON) pdmR3DevHlp_VMGetSuspendReason(PPDMDEVINS pDevIns)
|
---|
1480 | {
|
---|
1481 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1482 | VMSUSPENDREASON enmReason = VMSUSPENDREASON_INVALID;
|
---|
1483 | AssertFailed();
|
---|
1484 | LogFlow(("pdmR3DevHlp_VMGetSuspendReason: caller='%s'/%d: returns %d\n",
|
---|
1485 | pDevIns->pReg->szName, pDevIns->iInstance, enmReason));
|
---|
1486 | return enmReason;
|
---|
1487 | }
|
---|
1488 |
|
---|
1489 |
|
---|
1490 | /** @interface_method_impl{PDMDEVHLPR3,pfnVMGetResumeReason} */
|
---|
1491 | static DECLCALLBACK(VMRESUMEREASON) pdmR3DevHlp_VMGetResumeReason(PPDMDEVINS pDevIns)
|
---|
1492 | {
|
---|
1493 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1494 | VMRESUMEREASON enmReason = VMRESUMEREASON_INVALID;
|
---|
1495 | AssertFailed();
|
---|
1496 | LogFlow(("pdmR3DevHlp_VMGetResumeReason: caller='%s'/%d: returns %d\n",
|
---|
1497 | pDevIns->pReg->szName, pDevIns->iInstance, enmReason));
|
---|
1498 | return enmReason;
|
---|
1499 | }
|
---|
1500 |
|
---|
1501 |
|
---|
1502 | /** @interface_method_impl{PDMDEVHLPR3,pfnGetUVM} */
|
---|
1503 | static DECLCALLBACK(PUVM) pdmR3DevHlp_GetUVM(PPDMDEVINS pDevIns)
|
---|
1504 | {
|
---|
1505 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1506 | AssertFailed();
|
---|
1507 | LogFlow(("pdmR3DevHlp_GetUVM: caller='%s'/%d: returns %p\n", pDevIns->pReg->szName, pDevIns->iInstance, NULL));
|
---|
1508 | return NULL;
|
---|
1509 | }
|
---|
1510 |
|
---|
1511 |
|
---|
1512 | /** @interface_method_impl{PDMDEVHLPR3,pfnGetVM} */
|
---|
1513 | static DECLCALLBACK(PVM) pdmR3DevHlp_GetVM(PPDMDEVINS pDevIns)
|
---|
1514 | {
|
---|
1515 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1516 | PTSTDEVDUTINT pThis = TSTDEV_PDMDEVINS_2_DUT(pDevIns);
|
---|
1517 | PVM pVM = pThis->pVm;
|
---|
1518 | LogFlow(("pdmR3DevHlp_GetVM: caller='%s'/%d: returns %p\n", pDevIns->pReg->szName, pDevIns->iInstance, NULL));
|
---|
1519 | return pVM;
|
---|
1520 | }
|
---|
1521 |
|
---|
1522 |
|
---|
1523 | /** @interface_method_impl{PDMDEVHLPR3,pfnGetVMCPU} */
|
---|
1524 | static DECLCALLBACK(PVMCPU) pdmR3DevHlp_GetVMCPU(PPDMDEVINS pDevIns)
|
---|
1525 | {
|
---|
1526 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1527 | AssertFailed();
|
---|
1528 | LogFlow(("pdmR3DevHlp_GetVMCPU: caller='%s'/%d for CPU %u\n", pDevIns->pReg->szName, pDevIns->iInstance, NULL));
|
---|
1529 | return NULL;
|
---|
1530 | }
|
---|
1531 |
|
---|
1532 |
|
---|
1533 | /** @interface_method_impl{PDMDEVHLPR3,pfnGetCurrentCpuId} */
|
---|
1534 | static DECLCALLBACK(VMCPUID) pdmR3DevHlp_GetCurrentCpuId(PPDMDEVINS pDevIns)
|
---|
1535 | {
|
---|
1536 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1537 | VMCPUID idCpu = 0;
|
---|
1538 | AssertFailed();
|
---|
1539 | LogFlow(("pdmR3DevHlp_GetCurrentCpuId: caller='%s'/%d for CPU %u\n", pDevIns->pReg->szName, pDevIns->iInstance, idCpu));
|
---|
1540 | return idCpu;
|
---|
1541 | }
|
---|
1542 |
|
---|
1543 |
|
---|
1544 | /** @interface_method_impl{PDMDEVHLPR3,pfnPCIBusRegister} */
|
---|
1545 | static DECLCALLBACK(int) pdmR3DevHlp_PCIBusRegister(PPDMDEVINS pDevIns, PPDMPCIBUSREG pPciBusReg,
|
---|
1546 | PCPDMPCIHLPR3 *ppPciHlpR3, uint32_t *piBus)
|
---|
1547 | {
|
---|
1548 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1549 | LogFlow(("pdmR3DevHlp_PCIBusRegister: caller='%s'/%d: pPciBusReg=%p:{.u32Version=%#x, .pfnRegisterR3=%p, .pfnIORegionRegisterR3=%p, "
|
---|
1550 | ".pfnSetIrqR3=%p, .pszSetIrqRC=%p:{%s}, .pszSetIrqR0=%p:{%s}} ppPciHlpR3=%p piBus=%p\n",
|
---|
1551 | pDevIns->pReg->szName, pDevIns->iInstance, pPciBusReg, pPciBusReg->u32Version, pPciBusReg->pfnRegisterR3,
|
---|
1552 | pPciBusReg->pfnIORegionRegisterR3, pPciBusReg->pfnSetIrqR3, pPciBusReg->pszSetIrqRC, pPciBusReg->pszSetIrqRC,
|
---|
1553 | pPciBusReg->pszSetIrqR0, pPciBusReg->pszSetIrqR0, ppPciHlpR3, piBus));
|
---|
1554 |
|
---|
1555 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1556 | AssertFailed();
|
---|
1557 |
|
---|
1558 | LogFlow(("pdmR3DevHlp_PCIBusRegister: caller='%s'/%d: returns %Rrc *piBus=%u\n",
|
---|
1559 | pDevIns->pReg->szName, pDevIns->iInstance, rc, *piBus));
|
---|
1560 | return rc;
|
---|
1561 | }
|
---|
1562 |
|
---|
1563 |
|
---|
1564 | /** @interface_method_impl{PDMDEVHLPR3,pfnPICRegister} */
|
---|
1565 | static DECLCALLBACK(int) pdmR3DevHlp_PICRegister(PPDMDEVINS pDevIns, PPDMPICREG pPicReg, PCPDMPICHLPR3 *ppPicHlpR3)
|
---|
1566 | {
|
---|
1567 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1568 | LogFlow(("pdmR3DevHlp_PICRegister: caller='%s'/%d: pPicReg=%p:{.u32Version=%#x, .pfnSetIrqR3=%p, .pfnGetInterruptR3=%p, .pszGetIrqRC=%p:{%s}, .pszGetInterruptRC=%p:{%s}, .pszGetIrqR0=%p:{%s}, .pszGetInterruptR0=%p:{%s} } ppPicHlpR3=%p\n",
|
---|
1569 | pDevIns->pReg->szName, pDevIns->iInstance, pPicReg, pPicReg->u32Version, pPicReg->pfnSetIrqR3, pPicReg->pfnGetInterruptR3,
|
---|
1570 | pPicReg->pszSetIrqRC, pPicReg->pszSetIrqRC, pPicReg->pszGetInterruptRC, pPicReg->pszGetInterruptRC,
|
---|
1571 | pPicReg->pszSetIrqR0, pPicReg->pszSetIrqR0, pPicReg->pszGetInterruptR0, pPicReg->pszGetInterruptR0,
|
---|
1572 | ppPicHlpR3));
|
---|
1573 |
|
---|
1574 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1575 | AssertFailed();
|
---|
1576 |
|
---|
1577 | LogFlow(("pdmR3DevHlp_PICRegister: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
1578 | return rc;
|
---|
1579 | }
|
---|
1580 |
|
---|
1581 |
|
---|
1582 | /** @interface_method_impl{PDMDEVHLPR3,pfnAPICRegister} */
|
---|
1583 | static DECLCALLBACK(int) pdmR3DevHlp_APICRegister(PPDMDEVINS pDevIns)
|
---|
1584 | {
|
---|
1585 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1586 |
|
---|
1587 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1588 | AssertFailed();
|
---|
1589 |
|
---|
1590 | LogFlow(("pdmR3DevHlp_APICRegister: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
1591 | return rc;
|
---|
1592 | }
|
---|
1593 |
|
---|
1594 |
|
---|
1595 | /** @interface_method_impl{PDMDEVHLPR3,pfnIOAPICRegister} */
|
---|
1596 | static DECLCALLBACK(int) pdmR3DevHlp_IOAPICRegister(PPDMDEVINS pDevIns, PPDMIOAPICREG pIoApicReg, PCPDMIOAPICHLPR3 *ppIoApicHlpR3)
|
---|
1597 | {
|
---|
1598 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1599 | LogFlow(("pdmR3DevHlp_IOAPICRegister: caller='%s'/%d: pIoApicReg=%p:{.u32Version=%#x, .pfnSetIrqR3=%p, .pszSetIrqRC=%p:{%s}, .pszSetIrqR0=%p:{%s}} ppIoApicHlpR3=%p\n",
|
---|
1600 | pDevIns->pReg->szName, pDevIns->iInstance, pIoApicReg, pIoApicReg->u32Version, pIoApicReg->pfnSetIrqR3,
|
---|
1601 | pIoApicReg->pszSetIrqRC, pIoApicReg->pszSetIrqRC, pIoApicReg->pszSetIrqR0, pIoApicReg->pszSetIrqR0, ppIoApicHlpR3));
|
---|
1602 |
|
---|
1603 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1604 | AssertFailed();
|
---|
1605 |
|
---|
1606 | LogFlow(("pdmR3DevHlp_IOAPICRegister: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
1607 | return rc;
|
---|
1608 | }
|
---|
1609 |
|
---|
1610 |
|
---|
1611 | /** @interface_method_impl{PDMDEVHLPR3,pfnHPETRegister} */
|
---|
1612 | static DECLCALLBACK(int) pdmR3DevHlp_HPETRegister(PPDMDEVINS pDevIns, PPDMHPETREG pHpetReg, PCPDMHPETHLPR3 *ppHpetHlpR3)
|
---|
1613 | {
|
---|
1614 | PDMDEV_ASSERT_DEVINS(pDevIns); RT_NOREF_PV(pDevIns);
|
---|
1615 | LogFlow(("pdmR3DevHlp_HPETRegister: caller='%s'/%d:\n", pDevIns->pReg->szName, pDevIns->iInstance));
|
---|
1616 |
|
---|
1617 | RT_NOREF(pHpetReg, ppHpetHlpR3);
|
---|
1618 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1619 | AssertFailed();
|
---|
1620 |
|
---|
1621 | LogFlow(("pdmR3DevHlp_HPETRegister: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
1622 | return rc;
|
---|
1623 | }
|
---|
1624 |
|
---|
1625 |
|
---|
1626 | /** @interface_method_impl{PDMDEVHLPR3,pfnPciRawRegister} */
|
---|
1627 | static DECLCALLBACK(int) pdmR3DevHlp_PciRawRegister(PPDMDEVINS pDevIns, PPDMPCIRAWREG pPciRawReg, PCPDMPCIRAWHLPR3 *ppPciRawHlpR3)
|
---|
1628 | {
|
---|
1629 | PDMDEV_ASSERT_DEVINS(pDevIns); RT_NOREF_PV(pDevIns);
|
---|
1630 | LogFlow(("pdmR3DevHlp_PciRawRegister: caller='%s'/%d:\n", pDevIns->pReg->szName, pDevIns->iInstance));
|
---|
1631 |
|
---|
1632 | RT_NOREF(pPciRawReg, ppPciRawHlpR3);
|
---|
1633 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1634 | AssertFailed();
|
---|
1635 |
|
---|
1636 | LogFlow(("pdmR3DevHlp_PciRawRegister: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
1637 | return rc;
|
---|
1638 | }
|
---|
1639 |
|
---|
1640 |
|
---|
1641 | /** @interface_method_impl{PDMDEVHLPR3,pfnDMACRegister} */
|
---|
1642 | static DECLCALLBACK(int) pdmR3DevHlp_DMACRegister(PPDMDEVINS pDevIns, PPDMDMACREG pDmacReg, PCPDMDMACHLP *ppDmacHlp)
|
---|
1643 | {
|
---|
1644 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1645 | LogFlow(("pdmR3DevHlp_DMACRegister: caller='%s'/%d: pDmacReg=%p:{.u32Version=%#x, .pfnRun=%p, .pfnRegister=%p, .pfnReadMemory=%p, .pfnWriteMemory=%p, .pfnSetDREQ=%p, .pfnGetChannelMode=%p} ppDmacHlp=%p\n",
|
---|
1646 | pDevIns->pReg->szName, pDevIns->iInstance, pDmacReg, pDmacReg->u32Version, pDmacReg->pfnRun, pDmacReg->pfnRegister,
|
---|
1647 | pDmacReg->pfnReadMemory, pDmacReg->pfnWriteMemory, pDmacReg->pfnSetDREQ, pDmacReg->pfnGetChannelMode, ppDmacHlp));
|
---|
1648 |
|
---|
1649 | RT_NOREF(pDmacReg, ppDmacHlp);
|
---|
1650 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1651 | AssertFailed();
|
---|
1652 |
|
---|
1653 | LogFlow(("pdmR3DevHlp_DMACRegister: caller='%s'/%d: returns %Rrc\n",
|
---|
1654 | pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
1655 | return rc;
|
---|
1656 | }
|
---|
1657 |
|
---|
1658 |
|
---|
1659 | /**
|
---|
1660 | * @copydoc PDMDEVHLPR3::pfnRegisterVMMDevHeap
|
---|
1661 | */
|
---|
1662 | static DECLCALLBACK(int) pdmR3DevHlp_RegisterVMMDevHeap(PPDMDEVINS pDevIns, RTGCPHYS GCPhys, RTR3PTR pvHeap, unsigned cbHeap)
|
---|
1663 | {
|
---|
1664 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1665 | LogFlow(("pdmR3DevHlp_RegisterVMMDevHeap: caller='%s'/%d: GCPhys=%RGp pvHeap=%p cbHeap=%#x\n",
|
---|
1666 | pDevIns->pReg->szName, pDevIns->iInstance, GCPhys, pvHeap, cbHeap));
|
---|
1667 |
|
---|
1668 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1669 | AssertFailed();
|
---|
1670 |
|
---|
1671 | LogFlow(("pdmR3DevHlp_RegisterVMMDevHeap: caller='%s'/%d: returns %Rrc\n",
|
---|
1672 | pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
1673 | return rc;
|
---|
1674 | }
|
---|
1675 |
|
---|
1676 |
|
---|
1677 | /**
|
---|
1678 | * @interface_method_impl{PDMDEVHLPR3,pfnFirmwareRegister}
|
---|
1679 | */
|
---|
1680 | static DECLCALLBACK(int) pdmR3DevHlp_FirmwareRegister(PPDMDEVINS pDevIns, PCPDMFWREG pFwReg, PCPDMFWHLPR3 *ppFwHlp)
|
---|
1681 | {
|
---|
1682 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1683 | LogFlow(("pdmR3DevHlp_FirmwareRegister: caller='%s'/%d: pFWReg=%p:{.u32Version=%#x, .pfnIsHardReset=%p, .u32TheEnd=%#x} ppFwHlp=%p\n",
|
---|
1684 | pDevIns->pReg->szName, pDevIns->iInstance, pFwReg, pFwReg->u32Version, pFwReg->pfnIsHardReset, pFwReg->u32TheEnd, ppFwHlp));
|
---|
1685 |
|
---|
1686 | RT_NOREF(pFwReg, ppFwHlp);
|
---|
1687 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1688 | AssertFailed();
|
---|
1689 |
|
---|
1690 | LogFlow(("pdmR3DevHlp_FirmwareRegister: caller='%s'/%d: returns %Rrc\n",
|
---|
1691 | pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
1692 | return rc;
|
---|
1693 | }
|
---|
1694 |
|
---|
1695 |
|
---|
1696 | /** @interface_method_impl{PDMDEVHLPR3,pfnVMReset} */
|
---|
1697 | static DECLCALLBACK(int) pdmR3DevHlp_VMReset(PPDMDEVINS pDevIns, uint32_t fFlags)
|
---|
1698 | {
|
---|
1699 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1700 | LogFlow(("pdmR3DevHlp_VMReset: caller='%s'/%d: fFlags=%#x\n",
|
---|
1701 | pDevIns->pReg->szName, pDevIns->iInstance, fFlags));
|
---|
1702 |
|
---|
1703 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1704 | AssertFailed();
|
---|
1705 |
|
---|
1706 | LogFlow(("pdmR3DevHlp_VMReset: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
1707 | return rc;
|
---|
1708 | }
|
---|
1709 |
|
---|
1710 |
|
---|
1711 | /** @interface_method_impl{PDMDEVHLPR3,pfnVMSuspend} */
|
---|
1712 | static DECLCALLBACK(int) pdmR3DevHlp_VMSuspend(PPDMDEVINS pDevIns)
|
---|
1713 | {
|
---|
1714 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1715 | LogFlow(("pdmR3DevHlp_VMSuspend: caller='%s'/%d:\n",
|
---|
1716 | pDevIns->pReg->szName, pDevIns->iInstance));
|
---|
1717 |
|
---|
1718 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1719 | AssertFailed();
|
---|
1720 |
|
---|
1721 | LogFlow(("pdmR3DevHlp_VMSuspend: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
1722 | return rc;
|
---|
1723 | }
|
---|
1724 |
|
---|
1725 |
|
---|
1726 | /** @interface_method_impl{PDMDEVHLPR3,pfnVMSuspendSaveAndPowerOff} */
|
---|
1727 | static DECLCALLBACK(int) pdmR3DevHlp_VMSuspendSaveAndPowerOff(PPDMDEVINS pDevIns)
|
---|
1728 | {
|
---|
1729 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1730 | LogFlow(("pdmR3DevHlp_VMSuspendSaveAndPowerOff: caller='%s'/%d:\n",
|
---|
1731 | pDevIns->pReg->szName, pDevIns->iInstance));
|
---|
1732 |
|
---|
1733 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1734 | AssertFailed();
|
---|
1735 |
|
---|
1736 | LogFlow(("pdmR3DevHlp_VMSuspendSaveAndPowerOff: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
1737 | return rc;
|
---|
1738 | }
|
---|
1739 |
|
---|
1740 |
|
---|
1741 | /** @interface_method_impl{PDMDEVHLPR3,pfnVMPowerOff} */
|
---|
1742 | static DECLCALLBACK(int) pdmR3DevHlp_VMPowerOff(PPDMDEVINS pDevIns)
|
---|
1743 | {
|
---|
1744 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1745 | LogFlow(("pdmR3DevHlp_VMPowerOff: caller='%s'/%d:\n",
|
---|
1746 | pDevIns->pReg->szName, pDevIns->iInstance));
|
---|
1747 |
|
---|
1748 | int rc = VERR_NOT_IMPLEMENTED;
|
---|
1749 | AssertFailed();
|
---|
1750 |
|
---|
1751 | LogFlow(("pdmR3DevHlp_VMPowerOff: caller='%s'/%d: returns %Rrc\n", pDevIns->pReg->szName, pDevIns->iInstance, rc));
|
---|
1752 | return rc;
|
---|
1753 | }
|
---|
1754 |
|
---|
1755 |
|
---|
1756 | /** @interface_method_impl{PDMDEVHLPR3,pfnA20IsEnabled} */
|
---|
1757 | static DECLCALLBACK(bool) pdmR3DevHlp_A20IsEnabled(PPDMDEVINS pDevIns)
|
---|
1758 | {
|
---|
1759 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1760 |
|
---|
1761 | bool fRc = false;
|
---|
1762 | AssertFailed();
|
---|
1763 |
|
---|
1764 | LogFlow(("pdmR3DevHlp_A20IsEnabled: caller='%s'/%d: returns %d\n", pDevIns->pReg->szName, pDevIns->iInstance, fRc));
|
---|
1765 | return fRc;
|
---|
1766 | }
|
---|
1767 |
|
---|
1768 |
|
---|
1769 | /** @interface_method_impl{PDMDEVHLPR3,pfnA20Set} */
|
---|
1770 | static DECLCALLBACK(void) pdmR3DevHlp_A20Set(PPDMDEVINS pDevIns, bool fEnable)
|
---|
1771 | {
|
---|
1772 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1773 | LogFlow(("pdmR3DevHlp_A20Set: caller='%s'/%d: fEnable=%d\n", pDevIns->pReg->szName, pDevIns->iInstance, fEnable));
|
---|
1774 | AssertFailed();
|
---|
1775 | }
|
---|
1776 |
|
---|
1777 |
|
---|
1778 | /** @interface_method_impl{PDMDEVHLPR3,pfnGetCpuId} */
|
---|
1779 | static DECLCALLBACK(void) pdmR3DevHlp_GetCpuId(PPDMDEVINS pDevIns, uint32_t iLeaf,
|
---|
1780 | uint32_t *pEax, uint32_t *pEbx, uint32_t *pEcx, uint32_t *pEdx)
|
---|
1781 | {
|
---|
1782 | PDMDEV_ASSERT_DEVINS(pDevIns);
|
---|
1783 | LogFlow(("pdmR3DevHlp_GetCpuId: caller='%s'/%d: iLeaf=%d pEax=%p pEbx=%p pEcx=%p pEdx=%p\n",
|
---|
1784 | pDevIns->pReg->szName, pDevIns->iInstance, iLeaf, pEax, pEbx, pEcx, pEdx));
|
---|
1785 | AssertPtr(pEax); AssertPtr(pEbx); AssertPtr(pEcx); AssertPtr(pEdx);
|
---|
1786 |
|
---|
1787 | AssertFailed();
|
---|
1788 |
|
---|
1789 | LogFlow(("pdmR3DevHlp_GetCpuId: caller='%s'/%d: returns void - *pEax=%#x *pEbx=%#x *pEcx=%#x *pEdx=%#x\n",
|
---|
1790 | pDevIns->pReg->szName, pDevIns->iInstance, *pEax, *pEbx, *pEcx, *pEdx));
|
---|
1791 | }
|
---|
1792 |
|
---|
1793 | const PDMDEVHLPR3 g_tstDevPdmDevHlpR3 =
|
---|
1794 | {
|
---|
1795 | PDM_DEVHLPR3_VERSION,
|
---|
1796 | pdmR3DevHlp_IOPortRegister,
|
---|
1797 | pdmR3DevHlp_IOPortRegisterRC,
|
---|
1798 | pdmR3DevHlp_IOPortRegisterR0,
|
---|
1799 | pdmR3DevHlp_IOPortDeregister,
|
---|
1800 | pdmR3DevHlp_MMIORegister,
|
---|
1801 | pdmR3DevHlp_MMIORegisterRC,
|
---|
1802 | pdmR3DevHlp_MMIORegisterR0,
|
---|
1803 | pdmR3DevHlp_MMIODeregister,
|
---|
1804 | pdmR3DevHlp_MMIO2Register,
|
---|
1805 | pdmR3DevHlp_MMIOExPreRegister,
|
---|
1806 | pdmR3DevHlp_MMIOExDeregister,
|
---|
1807 | pdmR3DevHlp_MMIOExMap,
|
---|
1808 | pdmR3DevHlp_MMIOExUnmap,
|
---|
1809 | pdmR3DevHlp_MMIOExReduce,
|
---|
1810 | pdmR3DevHlp_MMHyperMapMMIO2,
|
---|
1811 | pdmR3DevHlp_MMIO2MapKernel,
|
---|
1812 | pdmR3DevHlp_ROMRegister,
|
---|
1813 | pdmR3DevHlp_ROMProtectShadow,
|
---|
1814 | pdmR3DevHlp_SSMRegister,
|
---|
1815 | pdmR3DevHlp_TMTimerCreate,
|
---|
1816 | pdmR3DevHlp_TMUtcNow,
|
---|
1817 | pdmR3DevHlp_PhysRead,
|
---|
1818 | pdmR3DevHlp_PhysWrite,
|
---|
1819 | pdmR3DevHlp_PhysGCPhys2CCPtr,
|
---|
1820 | pdmR3DevHlp_PhysGCPhys2CCPtrReadOnly,
|
---|
1821 | pdmR3DevHlp_PhysReleasePageMappingLock,
|
---|
1822 | pdmR3DevHlp_PhysReadGCVirt,
|
---|
1823 | pdmR3DevHlp_PhysWriteGCVirt,
|
---|
1824 | pdmR3DevHlp_PhysGCPtr2GCPhys,
|
---|
1825 | pdmR3DevHlp_MMHeapAlloc,
|
---|
1826 | pdmR3DevHlp_MMHeapAllocZ,
|
---|
1827 | pdmR3DevHlp_MMHeapFree,
|
---|
1828 | pdmR3DevHlp_VMState,
|
---|
1829 | pdmR3DevHlp_VMTeleportedAndNotFullyResumedYet,
|
---|
1830 | pdmR3DevHlp_VMSetError,
|
---|
1831 | pdmR3DevHlp_VMSetErrorV,
|
---|
1832 | pdmR3DevHlp_VMSetRuntimeError,
|
---|
1833 | pdmR3DevHlp_VMSetRuntimeErrorV,
|
---|
1834 | pdmR3DevHlp_DBGFStopV,
|
---|
1835 | pdmR3DevHlp_DBGFInfoRegister,
|
---|
1836 | pdmR3DevHlp_DBGFRegRegister,
|
---|
1837 | pdmR3DevHlp_DBGFTraceBuf,
|
---|
1838 | pdmR3DevHlp_STAMRegister,
|
---|
1839 | pdmR3DevHlp_STAMRegisterF,
|
---|
1840 | pdmR3DevHlp_STAMRegisterV,
|
---|
1841 | pdmR3DevHlp_PCIRegister,
|
---|
1842 | pdmR3DevHlp_PCIRegisterMsi,
|
---|
1843 | pdmR3DevHlp_PCIIORegionRegister,
|
---|
1844 | pdmR3DevHlp_PCISetConfigCallbacks,
|
---|
1845 | pdmR3DevHlp_PCIPhysRead,
|
---|
1846 | pdmR3DevHlp_PCIPhysWrite,
|
---|
1847 | pdmR3DevHlp_PCISetIrq,
|
---|
1848 | pdmR3DevHlp_PCISetIrqNoWait,
|
---|
1849 | pdmR3DevHlp_ISASetIrq,
|
---|
1850 | pdmR3DevHlp_ISASetIrqNoWait,
|
---|
1851 | pdmR3DevHlp_IoApicSendMsi,
|
---|
1852 | pdmR3DevHlp_DriverAttach,
|
---|
1853 | pdmR3DevHlp_DriverDetach,
|
---|
1854 | pdmR3DevHlp_QueueCreate,
|
---|
1855 | pdmR3DevHlp_CritSectInit,
|
---|
1856 | pdmR3DevHlp_CritSectGetNop,
|
---|
1857 | pdmR3DevHlp_CritSectGetNopR0,
|
---|
1858 | pdmR3DevHlp_CritSectGetNopRC,
|
---|
1859 | pdmR3DevHlp_SetDeviceCritSect,
|
---|
1860 | pdmR3DevHlp_ThreadCreate,
|
---|
1861 | pdmR3DevHlp_SetAsyncNotification,
|
---|
1862 | pdmR3DevHlp_AsyncNotificationCompleted,
|
---|
1863 | pdmR3DevHlp_RTCRegister,
|
---|
1864 | pdmR3DevHlp_PCIBusRegister,
|
---|
1865 | pdmR3DevHlp_PICRegister,
|
---|
1866 | pdmR3DevHlp_APICRegister,
|
---|
1867 | pdmR3DevHlp_IOAPICRegister,
|
---|
1868 | pdmR3DevHlp_HPETRegister,
|
---|
1869 | pdmR3DevHlp_PciRawRegister,
|
---|
1870 | pdmR3DevHlp_DMACRegister,
|
---|
1871 | pdmR3DevHlp_DMARegister,
|
---|
1872 | pdmR3DevHlp_DMAReadMemory,
|
---|
1873 | pdmR3DevHlp_DMAWriteMemory,
|
---|
1874 | pdmR3DevHlp_DMASetDREQ,
|
---|
1875 | pdmR3DevHlp_DMAGetChannelMode,
|
---|
1876 | pdmR3DevHlp_DMASchedule,
|
---|
1877 | pdmR3DevHlp_CMOSWrite,
|
---|
1878 | pdmR3DevHlp_CMOSRead,
|
---|
1879 | pdmR3DevHlp_AssertEMT,
|
---|
1880 | pdmR3DevHlp_AssertOther,
|
---|
1881 | pdmR3DevHlp_LdrGetRCInterfaceSymbols,
|
---|
1882 | pdmR3DevHlp_LdrGetR0InterfaceSymbols,
|
---|
1883 | pdmR3DevHlp_CallR0,
|
---|
1884 | pdmR3DevHlp_VMGetSuspendReason,
|
---|
1885 | pdmR3DevHlp_VMGetResumeReason,
|
---|
1886 | 0,
|
---|
1887 | 0,
|
---|
1888 | 0,
|
---|
1889 | 0,
|
---|
1890 | 0,
|
---|
1891 | 0,
|
---|
1892 | 0,
|
---|
1893 | 0,
|
---|
1894 | 0,
|
---|
1895 | 0,
|
---|
1896 | pdmR3DevHlp_GetUVM,
|
---|
1897 | pdmR3DevHlp_GetVM,
|
---|
1898 | pdmR3DevHlp_GetVMCPU,
|
---|
1899 | pdmR3DevHlp_GetCurrentCpuId,
|
---|
1900 | pdmR3DevHlp_RegisterVMMDevHeap,
|
---|
1901 | pdmR3DevHlp_FirmwareRegister,
|
---|
1902 | pdmR3DevHlp_VMReset,
|
---|
1903 | pdmR3DevHlp_VMSuspend,
|
---|
1904 | pdmR3DevHlp_VMSuspendSaveAndPowerOff,
|
---|
1905 | pdmR3DevHlp_VMPowerOff,
|
---|
1906 | pdmR3DevHlp_A20IsEnabled,
|
---|
1907 | pdmR3DevHlp_A20Set,
|
---|
1908 | pdmR3DevHlp_GetCpuId,
|
---|
1909 | pdmR3DevHlp_TMTimeVirtGet,
|
---|
1910 | pdmR3DevHlp_TMTimeVirtGetFreq,
|
---|
1911 | pdmR3DevHlp_TMTimeVirtGetNano,
|
---|
1912 | pdmR3DevHlp_GetSupDrvSession,
|
---|
1913 | pdmR3DevHlp_QueryGenericUserObject,
|
---|
1914 | PDM_DEVHLPR3_VERSION /* the end */
|
---|
1915 | };
|
---|
1916 |
|
---|