mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-08 14:02:58 +08:00
Add flags parameter to user fence wait function
Related-To: NEO-5845 Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
843b65bb07
commit
991fd3b358
@@ -24,7 +24,7 @@ int DrmCommandStreamReceiver<GfxFamily>::waitUserFence(uint32_t waitValue) {
|
||||
if (useContextForUserFenceWait) {
|
||||
ctxId = static_cast<const OsContextLinux *>(osContext)->getDrmContextIds()[0];
|
||||
}
|
||||
return this->drm->waitUserFence(ctxId, tagAddress, waitValue, Drm::ValueWidth::U32, kmdWaitTimeout);
|
||||
return this->drm->waitUserFence(ctxId, tagAddress, waitValue, Drm::ValueWidth::U32, kmdWaitTimeout, 0u);
|
||||
}
|
||||
|
||||
} // namespace NEO
|
||||
|
||||
@@ -19,6 +19,7 @@ class TestedDrmCommandStreamReceiver : public DrmCommandStreamReceiver<GfxFamily
|
||||
using CommandStreamReceiver::commandStream;
|
||||
using CommandStreamReceiver::createPreemptionAllocation;
|
||||
using CommandStreamReceiver::flushStamp;
|
||||
using CommandStreamReceiver::getTagAddress;
|
||||
using CommandStreamReceiver::globalFenceAllocation;
|
||||
using CommandStreamReceiver::makeResident;
|
||||
using CommandStreamReceiver::taskCount;
|
||||
|
||||
@@ -361,20 +361,22 @@ class DrmMockCustom : public Drm {
|
||||
uint32_t ctxId = 0u;
|
||||
ValueWidth dataWidth = ValueWidth::U8;
|
||||
int64_t timeout = 0;
|
||||
uint16_t flags = 0;
|
||||
|
||||
uint32_t called = 0u;
|
||||
};
|
||||
|
||||
WaitUserFenceCall waitUserFenceCall{};
|
||||
|
||||
int waitUserFence(uint32_t ctxId, uint64_t address, uint64_t value, ValueWidth dataWidth, int64_t timeout) override {
|
||||
int waitUserFence(uint32_t ctxId, uint64_t address, uint64_t value, ValueWidth dataWidth, int64_t timeout, uint16_t flags) override {
|
||||
waitUserFenceCall.called++;
|
||||
waitUserFenceCall.ctxId = ctxId;
|
||||
waitUserFenceCall.address = address;
|
||||
waitUserFenceCall.dataWidth = dataWidth;
|
||||
waitUserFenceCall.value = value;
|
||||
waitUserFenceCall.timeout = timeout;
|
||||
return Drm::waitUserFence(ctxId, address, value, dataWidth, timeout);
|
||||
waitUserFenceCall.flags = flags;
|
||||
return Drm::waitUserFence(ctxId, address, value, dataWidth, timeout, flags);
|
||||
}
|
||||
|
||||
struct IsVmBindAvailableCall {
|
||||
|
||||
@@ -211,7 +211,7 @@ class Drm : public DriverModel {
|
||||
U32,
|
||||
U64
|
||||
};
|
||||
MOCKABLE_VIRTUAL int waitUserFence(uint32_t ctxId, uint64_t address, uint64_t value, ValueWidth dataWidth, int64_t timeout);
|
||||
MOCKABLE_VIRTUAL int waitUserFence(uint32_t ctxId, uint64_t address, uint64_t value, ValueWidth dataWidth, int64_t timeout, uint16_t flags);
|
||||
|
||||
void setNewResourceBound(bool value) { this->newResourceBound = value; };
|
||||
bool getNewResourceBound() { return this->newResourceBound; };
|
||||
|
||||
@@ -75,7 +75,7 @@ int Drm::unbindBufferObject(OsContext *osContext, uint32_t vmHandleId, BufferObj
|
||||
void Drm::waitForBind(uint32_t vmHandleId) {
|
||||
}
|
||||
|
||||
int Drm::waitUserFence(uint32_t ctx, uint64_t address, uint64_t value, ValueWidth dataWidth, int64_t timeout) {
|
||||
int Drm::waitUserFence(uint32_t ctx, uint64_t address, uint64_t value, ValueWidth dataWidth, int64_t timeout, uint16_t flags) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
@@ -84,7 +84,7 @@ int Drm::unbindBufferObject(OsContext *osContext, uint32_t vmHandleId, BufferObj
|
||||
void Drm::waitForBind(uint32_t vmHandleId) {
|
||||
}
|
||||
|
||||
int Drm::waitUserFence(uint32_t ctx, uint64_t address, uint64_t value, ValueWidth dataWidth, int64_t timeout) {
|
||||
int Drm::waitUserFence(uint32_t ctx, uint64_t address, uint64_t value, ValueWidth dataWidth, int64_t timeout, uint16_t flags) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user