Commit Graph

167 Commits

Author SHA1 Message Date
Mateusz Jablonski ffe77d06e3 Ensure that ioctl helper is initialized only once
Related-To: NEO-6999
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-06-08 17:54:21 +02:00
Mateusz Jablonski 4d6169ee8b Extract querying device id and revision to a dedicated method
Related-To: NEO-6999
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-06-08 14:04:46 +02:00
Mateusz Jablonski 70cf43fd6e Remove redundant query for device id and revision
Related-To: NEO-6999
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-06-08 12:21:33 +02:00
Mateusz Jablonski 695958bd10 Move I915_PARAM values to DrmParam enum class
Related-To: NEO-6852
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-06-06 18:46:04 +02:00
Mateusz Jablonski 09c68a6bb1 Move query compute slices and query memory regions to DrmParam enum
Related-To: NEO-6852, NEO-6999, NEO-7028
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-06-01 19:38:34 +02:00
Mateusz Jablonski c4bb209f91 Move query hwconfig table and engine info to DrmParam enum
Related-To: NEO-6852, NEO-6999
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-06-01 18:49:49 +02:00
Mateusz Jablonski 0420df780d Create enum wrapper for drm engine class values
Related-To: NEO-6852, NEO-6999
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-06-01 14:39:29 +02:00
Compute-Runtime-Validation ce7de9d66e Revert "Unify query ioctls"
This reverts commit 571199d048.

Signed-off-by: Compute-Runtime-Validation <compute-runtime-validation@intel.com>
2022-05-31 20:40:00 +02:00
Bartosz Dunajski 571199d048 Unify query ioctls
Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
2022-05-31 15:28:23 +02:00
Mateusz Jablonski 9938b4001d Use ioctl helper when creating VM
Related-To: NEO-6999, NEO-6852
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-05-27 21:52:07 +02:00
Mateusz Jablonski b3814e41b4 Create enum for Ioctl request values
Related-To: NEO-6852
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-05-27 13:22:59 +02:00
Mateusz Jablonski c4095411c7 Remove HwHelper::isLinuxCompletionFenceSupported method
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-05-27 12:07:15 +02:00
Mateusz Jablonski 05cb48976f Create wrappers for drm getparam, query, gem close, prime handle, version
Related-To: NEO-6852
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-05-24 19:51:27 +02:00
Mateusz Jablonski 7d3fc9ab74 Create wrappers for gem context destroy, gem vm control, gem wait, reset stats
Related-To: NEO-6852
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-05-24 16:01:05 +02:00
Mateusz Jablonski 51d1752a68 Create a wrapper for drm_i915_gem_context_create_ext
Related-To: NEO-6852
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-05-24 15:21:58 +02:00
Mateusz Jablonski b0e75b18fd Create a wrapper for drm_i915_gem_context_create_ext_setparam
Related-To: NEO-6852, NEO-6999
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-05-23 16:42:54 +02:00
Mateusz Jablonski a552252fee Extend IoctlHelper::get interface - pass drm version
Related-To: NEO-6999
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-05-23 13:45:33 +02:00
Mateusz Jablonski 2202d05ea1 Create a wrapper for drm_i915_gem_context_param
Related-To: NEO-6852, NEO-6999
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-05-20 16:11:51 +02:00
Mateusz Jablonski 3ac5853e8d Add a method to check drm support
Related-To: NEO-6999
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-05-20 12:44:19 +02:00
Mateusz Jablonski 3be31b821b Create a wrapper for drm_i915_query_topology_info
Related-To: NEO-6852
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-05-19 15:27:46 +02:00
Mateusz Jablonski e7e1e64cca Create a wrapper for drm_i915_gem_context_param_sseu
Related-To: NEO-6852
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-05-19 14:10:09 +02:00
Mateusz Jablonski ac3005a463 Create a wrapper for drm_i915_query_item
Related-To: NEO-6852
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-05-18 11:32:44 +02:00
Artur Harasimiuk 819e0f5515 style: configure readability-identifier-naming.LocalVariableCase
Signed-off-by: Artur Harasimiuk <artur.harasimiuk@intel.com>
2022-05-16 12:39:44 +02:00
Artur Harasimiuk e9be9b64c6 clang-tidy configuration cleanup
Define single .clang-tidy configuration with all used checks and use
NOLINT to selectively silence tool. That way cleanup should be easier.
third_part/ has its own configuration that disables clang-tidy for this
folder.

Signed-off-by: Artur Harasimiuk <artur.harasimiuk@intel.com>
2022-05-11 14:02:04 +02:00
Bartosz Dunajski 206e485dfc Remove not needed DEBUG_BREAK_IF
Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
2022-05-09 11:26:16 +02:00
Bartosz Dunajski f8ce86b116 XE_HPC: Fallback path to fix PAT_INDEX programming
Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
2022-05-05 15:06:21 +02:00
Bartosz Dunajski 4f7a225baf Set PAT programming support during VmBind support query
Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
2022-05-04 16:26:15 +02:00
Mateusz Jablonski 4a5f1b9358 refactor: extract common logic for waiting on user fences in Drm
Related-To: NEO-6643
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-04-25 17:34:23 +02:00
Naklicki, Mateusz f1574bebb4 Use flag to opt-in for VM_BIND mode
Related-To: NEO-6640
Signed-off-by: Naklicki, Mateusz <mateusz.naklicki@intel.com>
2022-04-22 17:11:37 +02:00
Bartosz Dunajski 06fa316a75 Assign pat_index to BO during creation
Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
2022-04-21 13:25:13 +02:00
Milczarek, Slawomir 6256f89a79 Page fault support to be controlled with the registry key
Signed-off-by: Milczarek, Slawomir <slawomir.milczarek@intel.com>
2022-04-13 14:29:02 +02:00
Slawomir Milczarek 858766c080 Remove unused members and getters in system info
Related-To: NEO-6835

Signed-off-by: Slawomir Milczarek <slawomir.milczarek@intel.com>
2022-04-12 10:46:53 +02:00
Bartosz Dunajski 884d729e4e Improve pat index programming on linux
Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
2022-04-12 08:18:20 +02:00
Daniel Chabrowski 4d4ccfd128 Remove cache info base class
There is only one implementation of said class and we don't
even adhere to the interface it provides.

Signed-off-by: Daniel Chabrowski <daniel.chabrowski@intel.com>
2022-04-07 18:15:57 +02:00
Michal Mrozek fe9fe80fc6 Avoid dynamic memory allocation [3/n]
- use reference on auto type to prevent copy.

Signed-off-by: Michal Mrozek <michal.mrozek@intel.com>
2022-04-06 18:07:19 +02:00
Mateusz Jablonski d3b7ea10c8 Dont allocate dynamic memory when preparing params for vm bind call
Related-To: NEO-6837
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-04-05 19:41:56 +02:00
Daniel Chabrowski 5350553f72 Use PrelimHelper for isDebugAttachAvailable
Signed-off-by: Daniel Chabrowski daniel.chabrowski@intel.com
Related-To: NEO-6591
2022-03-30 16:17:05 +02:00
Naklicki, Mateusz bce96e666f Use updated macro names
Related-To: NEO-6730

Signed-off-by: Naklicki, Mateusz <mateusz.naklicki@intel.com>
2022-03-30 10:44:59 +02:00
Filip Hazubski 0fa923dff6 Add check for open syscall in case it fails
Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
2022-03-29 10:17:26 +02:00
Joshua Santosh Ranjan 71abef22bd Code cleanup
This patch fixes missed type-casting.

Related-To: LOCI-3022

Signed-off-by: Joshua Santosh Ranjan <joshua.santosh.ranjan@intel.com>
2022-03-23 19:05:48 +01:00
Joshua Santosh Ranjan 05a150f49f L0 Core Add Support For pci_speed_ext
This patch adds support for reading PCI bandwidth, generation
and linkwidth information from sysfs nodes for the linux
platform.

Related-To: LOCI-2969

Signed-off-by: Joshua Santosh Ranjan <joshua.santosh.ranjan@intel.com>
2022-03-16 22:47:59 +01:00
Milczarek, Slawomir 13bc2300e1 Add mock function to check for page fault support
Signed-off-by: Milczarek, Slawomir <slawomir.milczarek@intel.com>
2022-02-28 18:36:31 +01:00
Daniel Chabrowski 187f772ae5 Remove drm_query_flags
Signed-off-by: Daniel Chabrowski daniel.chabrowski@intel.com
Related-To: NEO-6591
2022-02-23 13:49:37 +01:00
Mateusz Jablonski 235f9be779 Move ioctl strings out of ioctl helper
In order to setup ioctl helper we need to call ioctl to get hw info

Related-To: NEO-6591

Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-02-17 12:30:47 +01:00
Mateusz Jablonski dabbabd3c9 Refactor createDrmContext function
merge createDrmContext, createDrmContextExt and appendDrmContextFlag

Related-To: NEO-6591

Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-02-16 15:15:35 +01:00
Mateusz Jablonski b9d613995d Move createDrmVirtualMemory function to drm_neo.cpp
Related-To: NEO-6591
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-02-16 11:34:52 +01:00
Daniel Chabrowski 85de06649d Support for execbuffer user fence ext
Signed-off-by: Daniel Chabrowski daniel.chabrowski@intel.com
Related-To: NEO-6591
2022-02-16 10:55:07 +01:00
Mateusz Jablonski 4a24195e99 Move bind/unbind buffer objects methods to drm_neo.cpp
use ioctl helper to handle binding properly

Related-To: NEO-6591
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-02-16 08:37:16 +01:00
Mateusz Jablonski 143f67f2fe Enable vm bind availability based on ioctl helper support
Related-To: NEO-6591
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-02-15 15:27:52 +01:00
Mateusz Jablonski cf27583264 Move createDrmContextExt to drm_neo.cpp
add ioctl helper functions to create dedicated drm contexts

createContextWithAccessCounters
createCooperativeContext

Related-To: NEO-6591

Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-02-15 09:16:36 +01:00