fix: check reset status after completion

Added a logic to check the reset status after the completion to make
sure we go through the logic at least once

Related-To: GSD-8902
Signed-off-by: Young Jin Yoon <young.jin.yoon@intel.com>
This commit is contained in:
Young Jin Yoon
2024-05-07 16:58:28 +00:00
committed by Compute-Runtime-Automation
parent aa0441bc63
commit 2c488d9e84
10 changed files with 150 additions and 10 deletions

View File

@@ -170,6 +170,9 @@ class Drm : public DriverModel {
bool checkToDisableScratchPage();
unsigned int getGpuFaultCheckThreshold() const;
bool checkGpuPageFaultRequired() {
return (checkToDisableScratchPage() && getGpuFaultCheckThreshold() != 0);
}
MOCKABLE_VIRTUAL bool resourceRegistrationEnabled();
MOCKABLE_VIRTUAL uint32_t registerResource(DrmResourceClass classType, const void *data, size_t size);
MOCKABLE_VIRTUAL void unregisterResource(uint32_t handle);
@@ -226,7 +229,7 @@ class Drm : public DriverModel {
MOCKABLE_VIRTUAL int waitUserFence(uint32_t ctxId, uint64_t address, uint64_t value, ValueWidth dataWidth, int64_t timeout, uint16_t flags, bool userInterrupt,
uint32_t externalInterruptId, GraphicsAllocation *allocForInterruptWait);
int waitOnUserFences(const OsContextLinux &osContext, uint64_t address, uint64_t value, uint32_t numActiveTiles, int64_t timeout, uint32_t postSyncOffset, bool userInterrupt,
int waitOnUserFences(OsContextLinux &osContext, uint64_t address, uint64_t value, uint32_t numActiveTiles, int64_t timeout, uint32_t postSyncOffset, bool userInterrupt,
uint32_t externalInterruptId, GraphicsAllocation *allocForInterruptWait);
void setNewResourceBoundToVM(BufferObject *bo, uint32_t vmHandleId);
@@ -266,6 +269,9 @@ class Drm : public DriverModel {
protected:
Drm(std::unique_ptr<HwDeviceIdDrm> &&hwDeviceIdIn, RootDeviceEnvironment &rootDeviceEnvironment);
int waitOnUserFencesImpl(const OsContextLinux &osContext, uint64_t address, uint64_t value, uint32_t numActiveTiles, int64_t timeout, uint32_t postSyncOffset, bool userInterrupt,
uint32_t externalInterruptId, GraphicsAllocation *allocForInterruptWait);
int getQueueSliceCount(GemContextParamSseu *sseu);
std::string generateUUID();
std::string generateElfUUID(const void *data);