diff --git a/devices/memctrl/memctrlbase.h b/devices/memctrl/memctrlbase.h
index 15798f8..2769f16 100644
--- a/devices/memctrl/memctrlbase.h
+++ b/devices/memctrl/memctrlbase.h
@@ -1,6 +1,6 @@
/*
DingusPPC - The Experimental PowerPC Macintosh emulator
-Copyright (C) 2018-21 divingkatae and maximum
+Copyright (C) 2018-22 divingkatae and maximum
(theweirdo) spatium
(Contact divingkatae#1017 or powermax#2286 on Discord for more info)
@@ -28,6 +28,17 @@ along with this program. If not, see .
#include
#include
+// Common DRAM capacities.
+enum {
+ DRAM_CAP_2MB = (1 << 21),
+ DRAM_CAP_4MB = (1 << 22),
+ DRAM_CAP_8MB = (1 << 23),
+ DRAM_CAP_16MB = (1 << 24),
+ DRAM_CAP_32MB = (1 << 25),
+ DRAM_CAP_64MB = (1 << 26),
+ DRAM_CAP_128MB = (1 << 27),
+};
+
enum RangeType {
RT_ROM = 1, /* read-only memory */
RT_RAM = 2, /* random access memory */
diff --git a/devices/memctrl/platinum.h b/devices/memctrl/platinum.h
index c493ad9..651edc8 100644
--- a/devices/memctrl/platinum.h
+++ b/devices/memctrl/platinum.h
@@ -23,8 +23,8 @@ along with this program. If not, see .
Author: Max Poliakovski
- Platium is a single chip memory subsystem controller designed especially
- for the Power Macintosh 7200 computer, code name Catalyst.
+ Platinum is a single chip memory and video subsystem controller designed
+ especially for the Power Macintosh 7200 computer, code name Catalyst.
*/
#ifndef PLATINUM_MEMCTRL_H
@@ -136,16 +136,6 @@ enum PlatinumReg : uint32_t {
IRIDIUM_CONFIG = 0x4A0,
};
-enum {
- DRAM_CAP_2MB = (1 << 21),
- DRAM_CAP_4MB = (1 << 22),
- DRAM_CAP_8MB = (1 << 23),
- DRAM_CAP_16MB = (1 << 24),
- DRAM_CAP_32MB = (1 << 25),
- DRAM_CAP_64MB = (1 << 26),
- DRAM_CAP_128MB = (1 << 27),
-};
-
// FB_RESET register bits.
enum {
VRAM_SM_RESET = (1 << 0), // VRAM state machine reset
diff --git a/machines/machinecatalyst.cpp b/machines/machinecatalyst.cpp
index 7b87410..e0a0292 100644
--- a/machines/machinecatalyst.cpp
+++ b/machines/machinecatalyst.cpp
@@ -54,7 +54,7 @@ int initialize_catalyst(std::string& id)
}
// plug 8MB RAM DIMM into slot #0
- platinum_obj->insert_ram_dimm(0, Platinum::DRAM_CAP_8MB);
+ platinum_obj->insert_ram_dimm(0, DRAM_CAP_8MB);
// allocate and map physical RAM
platinum_obj->map_phys_ram();