Files
compute-runtime/runtime/gmm_helper/gmm_memory_base.h
Mateusz Jablonski c858a2b79f Refactor configuring device address space logic:
1. call GmmSetDeviceInfo
2. call ConfigureDeviceAddressSpace
3. obtain min address - only for gen12lp platforms

remove getConfigureAddressSpaceMode method

Resolves: NEO-4076

Change-Id: Ib72789c834df1307a3d105131943dcf9a54afc03
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2020-01-07 11:57:58 +01:00

41 lines
1.2 KiB
C++

/*
* Copyright (C) 2018-2020 Intel Corporation
*
* SPDX-License-Identifier: MIT
*
*/
#pragma once
#include "core/gmm_helper/gmm_lib.h"
#include <memory>
namespace NEO {
class GmmMemoryBase {
public:
virtual ~GmmMemoryBase() = default;
MOCKABLE_VIRTUAL bool configureDeviceAddressSpace(GMM_ESCAPE_HANDLE hAdapter,
GMM_ESCAPE_HANDLE hDevice,
GMM_ESCAPE_FUNC_TYPE pfnEscape,
GMM_GFX_SIZE_T SvmSize,
BOOLEAN BDWL3Coherency);
bool configureDevice(GMM_ESCAPE_HANDLE hAdapter,
GMM_ESCAPE_HANDLE hDevice,
GMM_ESCAPE_FUNC_TYPE pfnEscape,
GMM_GFX_SIZE_T SvmSize,
BOOLEAN BDWL3Coherency,
uintptr_t &minAddress,
bool obtainMinAddress);
MOCKABLE_VIRTUAL uintptr_t getInternalGpuVaRangeLimit();
MOCKABLE_VIRTUAL bool setDeviceInfo(GMM_DEVICE_INFO *deviceInfo);
protected:
GmmMemoryBase();
GMM_CLIENT_CONTEXT *clientContext = nullptr;
};
} // namespace NEO