diff --git a/devices/memctrl/mpc106.cpp b/devices/memctrl/mpc106.cpp
index 75f4c0a..014284b 100644
--- a/devices/memctrl/mpc106.cpp
+++ b/devices/memctrl/mpc106.cpp
@@ -23,6 +23,7 @@ along with this program. If not, see .
#include
#include
+#include
#include
#include
#include
@@ -233,3 +234,9 @@ void MPC106::setup_ram() {
LOG_F(ERROR, "MPC106 RAM allocation failed! \n");
}
}
+
+static const DeviceDescription Grackle_Descriptor = {
+ MPC106::create, {}, {}
+};
+
+REGISTER_DEVICE(Grackle, Grackle_Descriptor);
diff --git a/devices/memctrl/mpc106.h b/devices/memctrl/mpc106.h
index e89f81f..b55e3c5 100644
--- a/devices/memctrl/mpc106.h
+++ b/devices/memctrl/mpc106.h
@@ -40,14 +40,18 @@ along with this program. If not, see .
#include
#include
+#include
#include
-
class MPC106 : public MemCtrlBase, public PCIDevice, public PCIHost {
public:
MPC106();
~MPC106() = default;
+ static std::unique_ptr create() {
+ return std::unique_ptr(new MPC106());
+ }
+
uint32_t read(uint32_t reg_start, uint32_t offset, int size);
void write(uint32_t reg_start, uint32_t offset, uint32_t value, int size);