Index: /trunk/include/VBox/graphics.h
===================================================================
--- /trunk/include/VBox/graphics.h	(revision 104786)
+++ /trunk/include/VBox/graphics.h	(revision 104786)
@@ -0,0 +1,57 @@
+/** @file
+ * Common defines which are being used by various graphics implementations
+ * (VBoxVGA, VBoxSVGA, VMSVGA) and Main.
+ */
+
+/*
+ * Copyright (C) 2017-2023 Oracle and/or its affiliates.
+ *
+ * This file is part of VirtualBox base platform packages, as
+ * available from https://www.virtualbox.org.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation, in version 3 of the
+ * License.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, see <https://www.gnu.org/licenses>.
+ *
+ * The contents of this file may alternatively be used under the terms
+ * of the Common Development and Distribution License Version 1.0
+ * (CDDL), a copy of it is provided in the "COPYING.CDDL" file included
+ * in the VirtualBox distribution, in which case the provisions of the
+ * CDDL are applicable instead of those of the GPL.
+ *
+ * You may elect to license modified versions of this file under the
+ * terms and conditions of either the GPL or the CDDL or both.
+ *
+ * SPDX-License-Identifier: GPL-3.0-only OR CDDL-1.0
+ */
+
+#ifndef VBOX_INCLUDED_graphics_h
+#define VBOX_INCLUDED_graphics_h
+#ifndef RT_WITHOUT_PRAGMA_ONCE
+# pragma once
+#endif
+
+/** The default amount of VGA VRAM (in bytes). */
+# define VGA_VRAM_DEFAULT           (_4M)
+/** The minimum amount of VGA VRAM (in bytes). */
+# define VGA_VRAM_MIN               (_1M)
+/** The maximum amount of VGA VRAM (in bytes). Limited by VBOX_MAX_ALLOC_PAGE_COUNT. */
+# define VGA_VRAM_MAX               (256 * _1M)
+
+/** The minimum amount of SVGA VRAM (in bytes). */
+#define SVGA_VRAM_MIN_SIZE          (4 * 640 * 480)
+/** The maximum amount of SVGA VRAM (in bytes) when 3D acceleration is enabled. */
+#define SVGA_VRAM_MIN_SIZE_3D       (16 * 1024 * 1024)
+/** The maximum amount of SVGA VRAM (in bytes). */
+#define SVGA_VRAM_MAX_SIZE          (128 * 1024 * 1024)
+
+#endif /* !VBOX_INCLUDED_graphics_h */
Index: /trunk/src/VBox/Devices/Graphics/DevVGA.h
===================================================================
--- /trunk/src/VBox/Devices/Graphics/DevVGA.h	(revision 104785)
+++ /trunk/src/VBox/Devices/Graphics/DevVGA.h	(revision 104786)
@@ -72,4 +72,6 @@
 #endif
 
+#include <VBox/graphics.h> /* For VRAM ranges. */
+
 #include <iprt/list.h>
 
@@ -77,14 +79,4 @@
 /** Use VBE bytewise I/O. Only needed for Windows Longhorn/Vista betas and backwards compatibility. */
 #define VBE_BYTEWISE_IO
-
-#ifdef VBOX
-/** The default amount of VRAM. */
-# define VGA_VRAM_DEFAULT    (_4M)
-/** The maximum amount of VRAM. Limited by VBOX_MAX_ALLOC_PAGE_COUNT. */
-# define VGA_VRAM_MAX        (256 * _1M)
-/** The minimum amount of VRAM. */
-# define VGA_VRAM_MIN        (_1M)
-#endif
-
 
 /** @name Macros dealing with partial ring-0/raw-mode VRAM mappings.
Index: /trunk/src/VBox/Devices/Graphics/vmsvga_include/svga_reg.h
===================================================================
--- /trunk/src/VBox/Devices/Graphics/vmsvga_include/svga_reg.h	(revision 104785)
+++ /trunk/src/VBox/Devices/Graphics/vmsvga_include/svga_reg.h	(revision 104786)
@@ -41,4 +41,6 @@
 
 #include "svga_types.h"
+
+#include <VBox/graphics.h> /* For VRAM ranges. */
 
 /*
@@ -2268,7 +2270,4 @@
  * Size of SVGA device memory such as frame buffer and FIFO.
  */
-#define SVGA_VRAM_MIN_SIZE             (4 * 640 * 480) /* bytes */
-#define SVGA_VRAM_MIN_SIZE_3D       (16 * 1024 * 1024)
-#define SVGA_VRAM_MAX_SIZE         (128 * 1024 * 1024)
 #define SVGA_MEMORY_SIZE_MAX      (1024 * 1024 * 1024)
 #define SVGA_FIFO_SIZE_MAX           (2 * 1024 * 1024)
Index: /trunk/src/VBox/Main/Makefile.kmk
===================================================================
--- /trunk/src/VBox/Main/Makefile.kmk	(revision 104785)
+++ /trunk/src/VBox/Main/Makefile.kmk	(revision 104786)
@@ -211,10 +211,4 @@
 # Unconditionally enable the new semaphore key generation code
 VBOX_MAIN_DEFS += VBOX_WITH_NEW_SYS_V_KEYGEN
-
-# Main graphics include paths. Used by VBoxC and VBoxSVC.
-VBOX_MAIN_GRAPHICS_INCS = \
-	$(PATH_ROOT)/src/VBox/Devices/Graphics/ \
-	$(if $(VBOX_WITH_VMSVGA),$(PATH_ROOT)/src/VBox/Devices/Graphics/vmsvga_include,) \
-	$(VBOX_GRAPHICS_INCS)
 
 VBOX_IDL_FILE.MSCOM    = $(VBOX_PATH_SDK)/bindings/mscom/idl/VirtualBox.idl
@@ -573,6 +567,6 @@
  	$(dir $(VBOX_XML_SCHEMADEFS_H)) \
  	$(VBOX_MAIN_APIWRAPPER_INCS) \
- 	$(VBOX_MAIN_GRAPHICS_INCS) \
  	. \
+ 	$(VBOX_GRAPHICS_INCS)
  	VBoxSVC_INCS.win = \
  	$(VBoxCOM_0_OUTDIR)
@@ -1082,5 +1076,5 @@
  	$(dir $(VBOX_XML_SCHEMADEFS_H)) \
  	$(VBOX_MAIN_APIWRAPPER_DIR)/dtrace \
- 	$(VBOX_MAIN_GRAPHICS_INCS)
+ 	$(VBOX_GRAPHICS_INCS)
  VBoxC_INCS.win     = \
  	$(VBoxCOM_0_OUTDIR) \
Index: /trunk/src/VBox/Main/src-all/PlatformPropertiesImpl.cpp
===================================================================
--- /trunk/src/VBox/Main/src-all/PlatformPropertiesImpl.cpp	(revision 104785)
+++ /trunk/src/VBox/Main/src-all/PlatformPropertiesImpl.cpp	(revision 104786)
@@ -32,10 +32,7 @@
 #include "Global.h"
 
-#include "VBox/vmm/pdmcritsect.h"            /* required by DevVGA.h */
-#include "VBox/param.h"                      /* Ditto. */
-#include "DevVGA.h"
-
 #include <iprt/cpp/utils.h>
 
+#include <VBox/graphics.h> /* For VRAM ranges. */
 #include <VBox/settings.h>
 
