VirtualBox

source: vbox/trunk/src/VBox/VMM/VMMAll/AllPdbTypeHack.cpp@ 100594

Last change on this file since 100594 was 98103, checked in by vboxsync, 23 months ago

Copyright year updates by scm.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 4.0 KB
Line 
1/* $Id: AllPdbTypeHack.cpp 98103 2023-01-17 14:15:46Z vboxsync $ */
2/** @file
3 * Debug info hack for the VM and VMCPU structures.
4 */
5
6/*
7 * Copyright (C) 2016-2023 Oracle and/or its affiliates.
8 *
9 * This file is part of VirtualBox base platform packages, as
10 * available from https://www.virtualbox.org.
11 *
12 * This program is free software; you can redistribute it and/or
13 * modify it under the terms of the GNU General Public License
14 * as published by the Free Software Foundation, in version 3 of the
15 * License.
16 *
17 * This program is distributed in the hope that it will be useful, but
18 * WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
20 * General Public License for more details.
21 *
22 * You should have received a copy of the GNU General Public License
23 * along with this program; if not, see <https://www.gnu.org/licenses>.
24 *
25 * SPDX-License-Identifier: GPL-3.0-only
26 */
27
28
29/*********************************************************************************************************************************
30* Header Files *
31*********************************************************************************************************************************/
32#include <VBox/vmm/cfgm.h>
33#include <VBox/vmm/cpum.h>
34#include <VBox/vmm/mm.h>
35#include <VBox/vmm/pgm.h>
36#include <VBox/vmm/selm.h>
37#include <VBox/vmm/trpm.h>
38#include <VBox/vmm/vmm.h>
39#include <VBox/vmm/stam.h>
40#include "../include/PDMInternal.h"
41#include <VBox/vmm/pdm.h>
42#include "../include/CFGMInternal.h"
43#include "../include/CPUMInternal.h"
44#include "../include/MMInternal.h"
45#include "../include/PGMInternal.h"
46#include "../include/SELMInternal.h"
47#include "../include/TRPMInternal.h"
48#include "../include/TMInternal.h"
49#include "../include/IOMInternal.h"
50#ifdef IN_RING3
51# include "../include/SSMInternal.h"
52#endif
53#include "../include/HMInternal.h"
54#include "../include/VMMInternal.h"
55#include "../include/DBGFInternal.h"
56#include "../include/GIMInternal.h"
57#include "../include/APICInternal.h"
58#include "../include/STAMInternal.h"
59#include "../include/VMInternal.h"
60#include "../include/EMInternal.h"
61#include "../include/IEMInternal.h"
62#include "../include/NEMInternal.h"
63#include "../VMMR0/GMMR0Internal.h"
64#include "../VMMR0/GVMMR0Internal.h"
65#include <VBox/vmm/vmcc.h>
66#ifdef IN_RING3
67# include <VBox/vmm/uvm.h>
68#endif
69#include <VBox/vmm/gvm.h>
70
71
72extern "C" {
73
74/* Global pointer variables as an alternative to the parameter list. Just to ensure the precense of the types. */
75PVM g_PdbTypeHack1 = NULL;
76PVMCPU g_PdbTypeHack2 = NULL;
77PPDMCRITSECT g_PdbTypeHack3 = NULL;
78PPDMCRITSECTRW g_PdbTypeHack4 = NULL;
79PPDMDEVINS g_PdbTypeHack5 = NULL;
80PPDMDRVINS g_PdbTypeHack6 = NULL;
81PPDMUSBINS g_PdbTypeHack7 = NULL;
82PCVMCPU g_PdbTypeHack8 = NULL;
83CTX_SUFF(PVM) g_PdbTypeHack9 = NULL;
84CTX_SUFF(PVMCPU) g_PdbTypeHack10 = NULL;
85
86DECLEXPORT(uint32_t) PdbTypeHack(PVM pVM, PVMCPU pVCpu, PPDMCRITSECT pCs1, PPDMCRITSECTRW pCs2);
87}
88
89DECLEXPORT(uint32_t) PdbTypeHack(PVM pVM, PVMCPU pVCpu, PPDMCRITSECT pCs1, PPDMCRITSECTRW pCs2)
90{
91 /* Just some dummy operations accessing each type. Probably not necessary, but
92 helps making sure we've included all we need to get at the internal stuff.. */
93 return pVM->fGlobalForcedActions
94 | (pVM == g_PdbTypeHack1)
95 | (pVM == g_PdbTypeHack9)
96 | pVCpu->fLocalForcedActions
97 | (pVCpu == g_PdbTypeHack2)
98 | (pVCpu == g_PdbTypeHack8)
99 | (pVCpu == g_PdbTypeHack10)
100 | pCs1->s.Core.fFlags
101 | (pCs1 == g_PdbTypeHack3)
102 | pCs2->s.Core.fFlags
103 | (pCs2 == g_PdbTypeHack4)
104 | g_PdbTypeHack5->Internal.s.idxR0Device
105 | (g_PdbTypeHack5 != NULL)
106 | (uint32_t)g_PdbTypeHack6->Internal.s.fDetaching
107 | (g_PdbTypeHack6 != NULL)
108 | (uint32_t)g_PdbTypeHack7->Internal.s.fVMSuspended
109 | (g_PdbTypeHack7 != NULL);
110}
111
Note: See TracBrowser for help on using the repository browser.

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