bmc: lpc: add support for lpc mapping and copying
The lpc handler object now handles copying the data after the window is
mapped, but the hardware specific pieces still play in dealing with the
driver directly.
Signed-off-by: Patrick Venture <venture@google.com>
Change-Id: I2f448411fd4ef9b61b5d1158915c70902b16666b
diff --git a/mapper_errors.hpp b/mapper_errors.hpp
new file mode 100644
index 0000000..8f30f30
--- /dev/null
+++ b/mapper_errors.hpp
@@ -0,0 +1,25 @@
+#pragma once
+
+#include <exception>
+#include <string>
+
+namespace ipmi_flash
+{
+
+class MapperException : public std::exception
+{
+ public:
+ explicit MapperException(const std::string& message) : message(message)
+ {
+ }
+
+ virtual const char* what() const noexcept override
+ {
+ return message.c_str();
+ }
+
+ private:
+ std::string message;
+};
+
+} // namespace ipmi_flash