mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-09 06:23:01 +08:00
Add cl_khr_pci_bus_info extension
Signed-off-by: Egor Suldin <egor.suldin@intel.com> https://github.com/intel/compute-runtime/pull/374
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
c94ad034d9
commit
2b3b47b495
36
shared/test/common/mocks/mock_driver_info.h
Normal file
36
shared/test/common/mocks/mock_driver_info.h
Normal file
@@ -0,0 +1,36 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2021 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "shared/source/os_interface/driver_info.h"
|
||||
|
||||
namespace NEO {
|
||||
|
||||
class DriverInfoMock : public DriverInfo {
|
||||
public:
|
||||
DriverInfoMock(){};
|
||||
|
||||
std::string getDeviceName(std::string defaultName) override { return deviceName; };
|
||||
std::string getVersion(std::string defaultVersion) override { return version; };
|
||||
|
||||
void setDeviceName(const std::string &name) { deviceName = name; }
|
||||
void setVersion(const std::string &versionString) { version = versionString; }
|
||||
|
||||
void setPciBusInfo(const PhysicalDevicePciBusInfo &info) {
|
||||
pciBusInfo.pciDomain = info.pciDomain;
|
||||
pciBusInfo.pciBus = info.pciBus;
|
||||
pciBusInfo.pciDevice = info.pciDevice;
|
||||
pciBusInfo.pciFunction = info.pciFunction;
|
||||
}
|
||||
|
||||
private:
|
||||
std::string deviceName;
|
||||
std::string version;
|
||||
};
|
||||
|
||||
} // namespace NEO
|
||||
Reference in New Issue
Block a user