José Roberto de Souza
eaeda2107e
anv: Use DRM_IOCTL_I915_GEM_CREATE_EXT in all supported kernels
...
As we continue to refactor the code base to support Xe KMD here I'm
dropping anv_gem_create() and unifying all graphics memory allocation
calls to anv_gem_create_regions().
anv_gem_create_regions() will call DRM_IOCTL_I915_GEM_CREATE_EXT
for integrated platforms too only leaving DRM_IOCTL_I915_GEM_CREATE
calls to kernel versions that do not support
DRM_IOCTL_I915_GEM_CREATE_EXT.
This can be detected by devinfo->mem.use_class_instance as
DRM_I915_QUERY_MEMORY_REGIONS uAPI landed in the same kernel version
as DRM_IOCTL_I915_GEM_CREATE_EXT.
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20948 >
2023-02-09 02:57:32 +00:00
José Roberto de Souza
099b9e5058
anv: Convert drm_i915_gem_memory_class_instance to intel_memory_class_instance
...
Also using pointers to intel_device_info struct instead of replicate
the same information.
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20948 >
2023-02-09 02:57:32 +00:00
José Roberto de Souza
e879b28994
anv: Move anv_device_check_status() code to i915/anv_device.c
...
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Acked-by: Rohan Garg <rohan.garg@intel.com >
Acked-by: Marcin Ślusarz <marcin.slusarz@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20428 >
2023-01-17 17:10:18 +00:00
José Roberto de Souza
94af444490
anv: Split i915 code from anv_batch_chain.c
...
There is no change in behavior here.
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Acked-by: Rohan Garg <rohan.garg@intel.com >
Acked-by: Marcin Ślusarz <marcin.slusarz@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20428 >
2023-01-17 17:10:18 +00:00
José Roberto de Souza
80c89c4606
anv: Start to move i915 specific code from anv_device to i915/anv_device
...
More code re-organization to separate i915_drm.h specific code from
the rest.
No behavior changes here.
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Acked-by: Rohan Garg <rohan.garg@intel.com >
Acked-by: Marcin Ślusarz <marcin.slusarz@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20428 >
2023-01-17 17:10:18 +00:00
José Roberto de Souza
3e28c5b9f9
anv: Pass anv_bo as parameter to anv_gem_mmap()
...
anv_bo has information that will be needed by a future patch in
anv_gem_mmap(), so here already preparing for that.
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20423 >
2022-12-23 18:22:29 +00:00
José Roberto de Souza
d5d1331381
intel: Add has_userptr_probe to intel_device_info
...
Iris, hasvk and anv were fetching the same information, better do it
on one place.
Reviewed-by: Tapani Pälli <tapani.palli@intel.com >
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19425 >
2022-11-07 17:22:14 +00:00
José Roberto de Souza
e9eceb1106
intel: Add has_mmap_offset to intel_device_info
...
All 4 drivers were fetching the same information, better do it on one
place.
Reviewed-by: Tapani Pälli <tapani.palli@intel.com >
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19425 >
2022-11-07 17:22:14 +00:00
José Roberto de Souza
dfd20f002f
intel: Add and use intel_gem_get_param()
...
Again sharing the same function across all Intel drivers.
Reviewed-by: Tapani Pälli <tapani.palli@intel.com >
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19425 >
2022-11-07 17:22:14 +00:00
José Roberto de Souza
39486661e9
intel: Add and use intel_gem_set_context_param()
...
Again sharing the same function across all Intel drivers.
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18974 >
2022-11-03 21:01:30 +00:00
José Roberto de Souza
6ae6921216
intel: Add and use intel_gem_destroy_context()
...
Again sharing the same function across all Intel drivers.
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18974 >
2022-11-03 21:01:30 +00:00
José Roberto de Souza
f928ead625
intel: Add and use intel_gem_create_context()
...
Add intel_gem_create_context() to common/intel_gem.c/h and use it
on Iris, Crocus, ANV and HASVK.
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18974 >
2022-11-03 21:01:30 +00:00
José Roberto de Souza
bc384e24f0
anv: Use Vulkan types for priority as much as possible
...
Continuing the work to split i915_drm.h specific code.
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18942 >
2022-10-04 18:35:50 +00:00
José Roberto de Souza
03b959286e
intel: Make engine related functions and types not i915 dependent
...
There is too much i915_drm.h code spread, this patch start to fix that
by re-organizing engine related code.
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18942 >
2022-10-04 18:35:50 +00:00
José Roberto de Souza
1e87834980
intel: Share code to read render timestamp
...
Timestamp read is not in any hot path so there is no down-sides in
share the same function between iris, crocus, anv and hasvk.
Also while at it also dropping the functions to read MMIO from kernel,
the only use is read render timestamp so we don't need it.
v2:
- fix compilaton of ds
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18920 >
2022-10-03 06:26:50 -07:00
José Roberto de Souza
1de5d2ac01
anv: Return earlier in anv_gem_get_tiling() when not supported
...
Tiling set and get UAPIs has the same support level.
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18251 >
2022-08-25 19:21:49 +00:00
José Roberto de Souza
e9cba466ea
anv: Nuke dead code
...
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18251 >
2022-08-25 19:21:49 +00:00
José Roberto de Souza
356a60bd6c
anv: Do not duplicate intel_device_info memory in each logical device
...
Each logical device can point to its physical device intel_device_info
saving at least one intel_device_info.
This also allow us to set 'const' to avoid values in intel_device_info
being changed by mistake.
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Acked-by: Jordan Justen <jordan.l.justen@intel.com >
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17897 >
2022-08-19 16:29:58 +00:00
Lionel Landwerlin
fae88d8791
anv: make use of the new smallbar uAPI
...
Instead of having 2 VkMemoryType pointing to the same VkMemoryHeap, we
have each VkMemoryType with VK_MEMORY_PROPERTY_DEVICE_LOCAL_BIT (one
host visible, the other not) point to its own VkMemoryHeap. For the
local heap that is host visible, we'll use the
I915_GEM_CREATE_EXT_FLAG_NEEDS_CPU_ACCESS flag at GEM BO creation.
When the smallbar uAPI is not available we fallback to a single heap
and do not use I915_GEM_CREATE_EXT_FLAG_NEEDS_CPU_ACCESS.
v2: Handle probed_cpu_visible_size == probed_size (Matthew)
v3:
* Jordan: Use region info from devinfo
v4: Also make the vram host visible heap as local (Ken)
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com >
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16739 >
2022-07-26 20:34:02 +00:00
Jordan Justen
695ba644ab
intel/gem: Return length from intel_i915_query_alloc
...
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com >
Reviewed-by: Caio Oliveira <caio.oliveira@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13866 >
2022-01-19 00:29:35 +00:00
Jason Ekstrand
88e97d75d0
intel/dev: Add gtt_size to devinfo
...
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13647 >
2021-12-11 05:05:19 +00:00
Jordan Justen
0634cb741b
intel: Add intel_gem_create_context_engines
...
Engines based contexts operate somewhat different for executing
batches. Previously, we would specify a bitmask value such as
I915_EXEC_RENDER to specify to run the batch on the render ring.
With engines contexts, instead this becomes an array of "engines", and
when the context is created we specify the class and instance of the
engine.
Each index in the array has a separate hardware-context. Previously we
had to create separate kernel level contexts to create multiple
hardware contexts, but now a single kernel context can own multiple
hardware contexts.
Another forward looking advantage to using the engines based contexts
is that the kernel does not plan to add new supported I915_EXEC_FOO
masks, whereas they instead plan to add new I915_ENGINE_CLASS_FOO
engine classes. Therefore some rings may only be usable with an engine
based class.
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com >
Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com >
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12692 >
2021-12-02 16:30:38 -08:00
Jordan Justen
9a9042a904
intel: Add intel_gem_count_engines
...
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com >
Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com >
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12692 >
2021-12-02 16:30:31 -08:00
Jason Ekstrand
2a910071bc
vulkan,anv: Auto-detect syncobj features
...
Instead of having a bunch of const vk_sync_type for each permutation of
vk_drm_syncobj capabilities, have a vk_drm_syncobj_get_type helper which
auto-detects features. If a driver can't support a feature for some
reason (i915 got timeline support very late, for instance), they can
always mask off feature bits they don't want.
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Acked-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13427 >
2021-11-16 10:54:27 -06:00
Jason Ekstrand
623e9ecd6d
anv: Remove unnecessary syncobj wrappers
...
These are entirely unused except for the syncobj in submit_simple_batch.
We can use the libdrm wrappers for that as they're basically equivalent
and the core Vulkan sync code already depends on them.
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13427 >
2021-11-16 10:54:27 -06:00
Jason Ekstrand
953a4ca6fe
intel: Add has_bit6_swizzle to devinfo
...
There's no good reason to have this rather complex check in three
drivers.
Reviewed-by: Dave Airlie <airlied@redhat.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13636 >
2021-11-04 18:51:04 +00:00
Jason Ekstrand
39f2594531
anv: Implement VK_EXT_global_priority_query
...
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11250 >
2021-10-20 15:51:59 +00:00
Jason Ekstrand
b8e2214ee5
anv: Use I915_USERPTR_PROBE when available
...
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12044 >
2021-08-12 15:07:23 -05:00
Jason Ekstrand
512fa2f4da
anv: Use I915_MMAP_OFFSET_FIXED for LMEM platforms
...
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11888 >
2021-08-12 19:29:59 +00:00
Jason Ekstrand
ffdf4d7683
intel: Pull anv_i915_query into common code
...
We also add a helper which contains the standard query+alloc+query
pattern used by anv_gem_get_engine_info(). The caller is required to
free the pointer.
These are declared static inline not because we care about the
performance of these helpers but because we're going to use them in the
intel_device_info code and we don't want a link dependency.
Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11770 >
2021-07-16 14:19:20 +00:00
Jason Ekstrand
b664481ba9
anv: Handle errors properly in anv_i915_query
...
DRM_IOCTL_I915_QUERY is a multi-query. The most egregious errors are
returned via the usual ioctl error mechanism but there are also
per-query errors that are indicated by item.length < 0. We need to
handle those as well. While we're at it, scrape errno so we can return
a proper integer error.
Fixes: c0d07c838a
"anv: Support i915 query (DRM_IOCTL_I915_QUERY)..."
Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11770 >
2021-07-16 14:19:20 +00:00
Sagar Ghuge
3f8eca7f82
anv: Wrapper around I915_GEM_CREATE_EXT_MEMORY_REGIONS
...
v2 (Jordan Justin):
- add anv_gem_stubs.c impl
v3 (Jason Ekstrand):
- Use the upstream uAPI
- Rework the interface a bit
Signed-off-by: Sagar Ghuge <sagar.ghuge@intel.com >
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com >
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5599 >
2021-06-24 16:14:38 +00:00
Jordan Justen
df5607d2ef
anv: Use fallback paths if DRM_I915_QUERY_ENGINE_INFO fails
...
Anvil can handle if this call fails, but not if we assert. :)
Reported-by: Brian Paul <brianp@vmware.com >
Fixes: 5d84c764fd
("anv: Gather engine info from i915 if available")
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9664 >
2021-03-18 00:54:29 +00:00
Anuj Phogat
96e251bde7
intel: Rename "GEN_" prefix used in common code to "INTEL_"
...
This patch renames all macros with "GEN_" prefix defined in
common code.
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com >
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9413 >
2021-03-10 22:23:51 +00:00
Anuj Phogat
692472a376
intel: Rename "gen_" prefix used in common code to "intel_"
...
This patch renames functions, structures, enums etc. with "gen_"
prefix defined in common code.
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com >
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9413 >
2021-03-10 22:23:51 +00:00
Anuj Phogat
733b0ee8cb
intel: Rename files with gen_ prefix in common code to intel_
...
Changes in this patch include:
- Rename all files in src/intel/common path
- Update the filenames used in source and build files
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com >
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9413 >
2021-03-10 22:23:51 +00:00
Jordan Justen
4656be70dd
anv: Support multiple engines with DRM_IOCTL_I915_GEM_CONTEXT_CREATE_EXT
...
v2 (Jason Ekstrand):
- Separate the anv_gem interface from anv_queue internals
- Rework on top of the new anv_queue_family stuff
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com >
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8667 >
2021-01-28 18:26:33 +00:00
Jordan Justen
c5e7c91487
anv: Add anv_gem_count_engines
...
v2 (Jason Ekstrand):
- Take a drm_i915_query_engine_info
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com >
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8667 >
2021-01-28 18:26:33 +00:00
Jordan Justen
5d84c764fd
anv: Gather engine info from i915 if available
...
v2 (Jason Ekstrand):
- Don't take an anv_physical_device in anv_gem_get_engine_info()
- Return the engine info from anv_gem_get_engine_info()
- Free the engine info in anv_physical_device_destroy()
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com >
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8667 >
2021-01-28 18:26:33 +00:00
Jordan Justen
c0d07c838a
anv: Support i915 query (DRM_IOCTL_I915_QUERY) from Linux v4.17
...
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com >
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8667 >
2021-01-28 18:26:33 +00:00
Lionel Landwerlin
34721e2af4
anv: pass context to reset stats helper
...
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net >
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8667 >
2021-01-28 18:26:32 +00:00
Robin Ole Heinemann
df76963a5c
anv: Add DRM_RDWR flag in anv_gem_handle_to_fd
...
The DRM_RDWR flag is needed for mmap with PROT_WRITE to work.
Cc: mesa-stable
Signed-off-by: Robin Ole Heinemann <robin.ole.heinemann@gmail.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8075 >
2020-12-15 08:20:34 +00:00
Marcin Ślusarz
b5e2c58ad8
anv: always annotate memory returned from anv_gem_mmap
...
anv_bo_pool_alloc expects that the memory returned by and_gem_mmap
was annotated using VALGRIND_MALLOCLIKE_BLOCK, but anv_gem_mmap_offset
didn't do that. Move annotation from anv_gem_mmap_legacy to common
code.
Fixes: 4abf0837cd
("anv: Add support for new MMAP_OFFSET ioctl.")
Signed-off-by: Marcin Ślusarz <marcin.slusarz@intel.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7381 >
2020-11-02 19:52:11 +00:00
Lionel Landwerlin
a965ffad21
anv: add new gem/drm helpers
...
Needed for dealing with the new DRM timeline syncobj ioctls.
v2: Make use of the anv_gem_get_drm_cap() parameter... (Jason)
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/2901 >
2020-09-01 16:40:11 +00:00
Rafael Antognolli
37a724e4ae
anv/dg1: Don't use SET_TILING kernel uapi.
...
It is not available on discrete platforms anymore.
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4956 >
2020-06-22 11:42:00 -07:00
Jan Beich
fcdefa7e47
anv,iris: unbreak on BSDs after 812cf5f522ab,abf8aed68047
...
../src/intel/vulkan/anv_gem.c:31:10: fatal error: 'linux/sync_file.h' file not found
#include <linux/sync_file.h>
^~~~~~~~~~~~~~~~~~~
../src/gallium/drivers/iris/iris_fence.c:29:10: fatal error: 'linux/sync_file.h' file not found
#include <linux/sync_file.h>
^~~~~~~~~~~~~~~~~~~
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5463 >
2020-06-16 16:02:33 +00:00
Eric Engestrom
e27f311c85
anv: pass the fd directly to anv_gem_reg_read()
...
This allows its use without the need for an anv_device.
Signed-off-by: Eric Engestrom <eric.engestrom@intel.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/2797 >
2020-05-20 21:49:10 +00:00
Rafael Antognolli
bb3545a6ee
intel: Store the aperture size in devinfo.
...
We will later use the devinfo from iris_bufmgr, where we don't have
access to the screen pointer. And since we are moving it, we can reuse
it in Anv and i965.
v2: return error code and check for it on Anv (Lionel).
v3: Remove anv_gem_get_aperture() from anv_private.h and stubs (Lionel).
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5043 >
2020-05-15 16:57:04 +00:00
Kenneth Graunke
615270502c
intel: Move anv_gem_supports_syncobj_wait to common code.
...
This will let me use this in iris.
We leave the existing anv function for anv_gem_stubs.c faking, but
move the contents to a helper in a new src/intel/common/gen_gem.c file.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3802 >
2020-05-01 19:00:02 +00:00
Kenneth Graunke
812cf5f522
anv: Include linux/sync_file.h instead of cut and pasting contents
...
Linux 4.7 has been out for a long time, this is probably safe to
depend on at this point, rather than cut and pasting the contents.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3802 >
2020-05-01 19:00:02 +00:00