mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-07 21:27:04 +08:00
Use PrelimHelper for isDebugAttachAvailable
Signed-off-by: Daniel Chabrowski daniel.chabrowski@intel.com Related-To: NEO-6591
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
08e3853982
commit
5350553f72
@@ -891,6 +891,10 @@ bool Drm::sysmanQueryEngineInfo() {
|
||||
return Drm::queryEngineInfo(true);
|
||||
}
|
||||
|
||||
bool Drm::isDebugAttachAvailable() {
|
||||
return ioctlHelper->isDebugAttachAvailable();
|
||||
}
|
||||
|
||||
int getMaxGpuFrequencyOfDevice(Drm &drm, std::string &sysFsPciPath, int &maxGpuFrequency) {
|
||||
maxGpuFrequency = 0;
|
||||
std::string clockSysFsPath = sysFsPciPath + "/gt_max_freq_mhz";
|
||||
|
||||
@@ -9,10 +9,6 @@
|
||||
|
||||
namespace NEO {
|
||||
|
||||
bool Drm::isDebugAttachAvailable() {
|
||||
return false;
|
||||
}
|
||||
|
||||
bool Drm::hasPageFaultSupport() const {
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -126,6 +126,7 @@ class IoctlHelper {
|
||||
virtual int unregisterUuid(Drm *drm, uint32_t handle) = 0;
|
||||
virtual bool isContextDebugSupported(Drm *drm) = 0;
|
||||
virtual int setContextDebugFlag(Drm *drm, uint32_t drmContextId) = 0;
|
||||
virtual bool isDebugAttachAvailable() = 0;
|
||||
};
|
||||
|
||||
class IoctlHelperUpstream : public IoctlHelper {
|
||||
@@ -178,6 +179,7 @@ class IoctlHelperUpstream : public IoctlHelper {
|
||||
int unregisterUuid(Drm *drm, uint32_t handle) override;
|
||||
bool isContextDebugSupported(Drm *drm) override;
|
||||
int setContextDebugFlag(Drm *drm, uint32_t drmContextId) override;
|
||||
bool isDebugAttachAvailable() override;
|
||||
};
|
||||
|
||||
template <PRODUCT_FAMILY gfxProduct>
|
||||
@@ -243,6 +245,7 @@ class IoctlHelperPrelim20 : public IoctlHelper {
|
||||
int unregisterUuid(Drm *drm, uint32_t handle) override;
|
||||
bool isContextDebugSupported(Drm *drm) override;
|
||||
int setContextDebugFlag(Drm *drm, uint32_t drmContextId) override;
|
||||
bool isDebugAttachAvailable() override;
|
||||
};
|
||||
|
||||
} // namespace NEO
|
||||
|
||||
@@ -550,4 +550,8 @@ int IoctlHelperPrelim20::setContextDebugFlag(Drm *drm, uint32_t drmContextId) {
|
||||
return IoctlHelper::ioctl(drm, DRM_IOCTL_I915_GEM_CONTEXT_SETPARAM, &ctxParam);
|
||||
}
|
||||
|
||||
bool IoctlHelperPrelim20::isDebugAttachAvailable() {
|
||||
return true;
|
||||
}
|
||||
|
||||
} // namespace NEO
|
||||
|
||||
@@ -246,4 +246,8 @@ int IoctlHelperUpstream::setContextDebugFlag(Drm *drm, uint32_t drmContextId) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
bool IoctlHelperUpstream::isDebugAttachAvailable() {
|
||||
return false;
|
||||
}
|
||||
|
||||
} // namespace NEO
|
||||
|
||||
Reference in New Issue
Block a user