mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-24 21:18:24 +08:00
refactor: decouple ClosCacheReservation from Drm
The dependency towards `Drm` is unnecessary and only makes testing more difficult. Instead, dependency towards `IoctlHelper` alone only is sufficient. Related-To: NEO-10158 Signed-off-by: Maciej Bielski <maciej.bielski@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
1f79f867e6
commit
790bb84841
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2021-2022 Intel Corporation
|
||||
* Copyright (C) 2021-2024 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -16,14 +16,14 @@
|
||||
|
||||
namespace NEO {
|
||||
|
||||
class Drm;
|
||||
class IoctlHelper;
|
||||
|
||||
struct CacheInfo {
|
||||
CacheInfo(Drm &drm, size_t maxReservationCacheSize, uint32_t maxReservationNumCacheRegions, uint16_t maxReservationNumWays)
|
||||
CacheInfo(IoctlHelper &ioctlHelper, size_t maxReservationCacheSize, uint32_t maxReservationNumCacheRegions, uint16_t maxReservationNumWays)
|
||||
: maxReservationCacheSize(maxReservationCacheSize),
|
||||
maxReservationNumCacheRegions(maxReservationNumCacheRegions),
|
||||
maxReservationNumWays(maxReservationNumWays),
|
||||
cacheReserve(drm) {
|
||||
cacheReserve{ioctlHelper} {
|
||||
}
|
||||
|
||||
MOCKABLE_VIRTUAL ~CacheInfo();
|
||||
|
||||
Reference in New Issue
Block a user