Redesign ULT by mocking sysfs and implementing for pci

Change-Id: I5ee2219208d05c125d1fce1a4a5b992bc8c4646e
This commit is contained in:
Mraghuwa
2020-05-21 12:15:07 +05:30
committed by sys_ocldev
parent e25eb4057c
commit b6ccfed471
11 changed files with 267 additions and 221 deletions

View File

@@ -83,15 +83,16 @@ class SysfsAccess : private FsAccess {
MOCKABLE_VIRTUAL ze_result_t read(const std::string file, int &val);
MOCKABLE_VIRTUAL ze_result_t read(const std::string file, uint64_t &val);
MOCKABLE_VIRTUAL ze_result_t read(const std::string file, double &val);
ze_result_t read(const std::string file, std::vector<std::string> &val);
MOCKABLE_VIRTUAL ze_result_t read(const std::string file, std::vector<std::string> &val);
ze_result_t write(const std::string file, const std::string val);
MOCKABLE_VIRTUAL ze_result_t write(const std::string file, const int val);
MOCKABLE_VIRTUAL ze_result_t write(const std::string file, const uint64_t val);
MOCKABLE_VIRTUAL ze_result_t write(const std::string file, const double val);
ze_result_t write(const std::string file, std::vector<std::string> val);
MOCKABLE_VIRTUAL ze_result_t scanDirEntries(const std::string path, std::vector<std::string> &list);
ze_result_t readSymLink(const std::string path, std::string &buf);
MOCKABLE_VIRTUAL ze_result_t readSymLink(const std::string path, std::string &buf);
ze_result_t getRealPath(const std::string path, std::string &buf);
ze_result_t bindDevice(const std::string device);
ze_result_t unbindDevice(const std::string device);