VirtualBox

source: vbox/trunk/src/VBox/VMM/include/TRPMInternal.h@ 104407

Last change on this file since 104407 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 Id Revision
File size: 2.6 KB
Line 
1/* $Id: TRPMInternal.h 98103 2023-01-17 14:15:46Z vboxsync $ */
2/** @file
3 * TRPM - Internal header file.
4 */
5
6/*
7 * Copyright (C) 2006-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#ifndef VMM_INCLUDED_SRC_include_TRPMInternal_h
29#define VMM_INCLUDED_SRC_include_TRPMInternal_h
30#ifndef RT_WITHOUT_PRAGMA_ONCE
31# pragma once
32#endif
33
34#include <VBox/cdefs.h>
35#include <VBox/types.h>
36#include <VBox/vmm/stam.h>
37#include <VBox/vmm/cpum.h>
38#include <VBox/vmm/pgm.h>
39
40RT_C_DECLS_BEGIN
41
42
43/** @defgroup grp_trpm_int Internals
44 * @ingroup grp_trpm
45 * @internal
46 * @{
47 */
48
49/**
50 * TRPM Data (part of VM)
51 *
52 * @note This used to be a big deal when we had raw-mode, now it's a dud. :-)
53 */
54typedef struct TRPM
55{
56 /** Statistics for interrupt handlers. */
57 STAMCOUNTER aStatForwardedIRQ[256];
58} TRPM;
59
60/** Pointer to TRPM Data. */
61typedef TRPM *PTRPM;
62
63
64/**
65 * Per CPU data for TRPM.
66 */
67typedef struct TRPMCPU
68{
69 /** Active Interrupt or trap vector number.
70 * If not UINT32_MAX this indicates that we're currently processing a
71 * interrupt, trap, fault, abort, whatever which have arrived at that
72 * vector number.
73 */
74 uint32_t uActiveVector;
75
76 /** Active trap type. */
77 TRPMEVENT enmActiveType;
78
79 /** Errorcode for the active interrupt/trap. */
80 uint32_t uActiveErrorCode;
81
82 /** Instruction length for software interrupts and software exceptions
83 * (\#BP, \#OF) */
84 uint8_t cbInstr;
85
86 /** Whether this \#DB trap is caused due to INT1/ICEBP. */
87 bool fIcebp;
88
89 /** CR2 at the time of the active exception. */
90 RTGCUINTPTR uActiveCR2;
91} TRPMCPU;
92
93/** Pointer to TRPMCPU Data. */
94typedef TRPMCPU *PTRPMCPU;
95/** Pointer to const TRPMCPU Data. */
96typedef const TRPMCPU *PCTRPMCPU;
97
98/** @} */
99
100RT_C_DECLS_END
101
102#endif /* !VMM_INCLUDED_SRC_include_TRPMInternal_h */
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