diff options
author | Patrick Venture <venture@google.com> | 2018-11-28 14:24:41 -0800 |
---|---|---|
committer | Patrick Venture <venture@google.com> | 2018-11-30 14:22:09 -0800 |
commit | 7b91cbc101f36f1038d595f99a7423ee4de6575b (patch) | |
tree | c9538a3ec3d77973862c77fcf34dae615fdc44af /internal | |
parent | 30993b3d0389f31e6321e11091057944d71bed94 (diff) | |
download | phosphor-ipmi-flash-7b91cbc101f36f1038d595f99a7423ee4de6575b.tar.gz phosphor-ipmi-flash-7b91cbc101f36f1038d595f99a7423ee4de6575b.zip |
lpc_aspeed: add mapping implementation
Add mapper implementation for Aspeed.
Change-Id: I4bc1cbaaa6c0bf57424b0c881cb087153d63597c
Signed-off-by: Patrick Venture <venture@google.com>
Diffstat (limited to 'internal')
-rw-r--r-- | internal/sys.cpp | 6 | ||||
-rw-r--r-- | internal/sys.hpp | 2 |
2 files changed, 8 insertions, 0 deletions
diff --git a/internal/sys.cpp b/internal/sys.cpp index b61dfea..c87d5e6 100644 --- a/internal/sys.cpp +++ b/internal/sys.cpp @@ -17,6 +17,7 @@ #include "sys.hpp" #include <fcntl.h> +#include <sys/ioctl.h> #include <sys/mman.h> #include <unistd.h> @@ -53,6 +54,11 @@ int SysImpl::getpagesize() const return ::getpagesize(); } +int SysImpl::ioctl(int fd, unsigned long request, void* param) const +{ + return ::ioctl(fd, request, param); +} + SysImpl sys_impl; } // namespace internal diff --git a/internal/sys.hpp b/internal/sys.hpp index fb824ef..9327799 100644 --- a/internal/sys.hpp +++ b/internal/sys.hpp @@ -34,6 +34,7 @@ class Sys off_t offset) const = 0; virtual int munmap(void* addr, size_t length) const = 0; virtual int getpagesize() const = 0; + virtual int ioctl(int fd, unsigned long request, void* param) const = 0; }; /** @@ -50,6 +51,7 @@ class SysImpl : public Sys off_t offset) const override; int munmap(void* addr, size_t length) const override; int getpagesize() const override; + int ioctl(int fd, unsigned long request, void* param) const override; }; /** @brief Default instantiation of sys */ |