mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-05 00:20:11 +01:00
i915: Use drm_intel_get_aperture_sizes instead of drmAgpSize
Send the zombie back to the grave before it infects the townsfolk. Signed-off-by: Ian Romanick <ian.d.romanick@intel.com> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Cc: "10.0" <mesa-stable@lists.freedesktop.org>
This commit is contained in:
parent
279e8d2641
commit
9fe108db09
1 changed files with 6 additions and 2 deletions
|
|
@ -723,9 +723,13 @@ i915_query_renderer_integer(__DRIscreen *psp, int param, int *value)
|
|||
* assume that there's some fragmentation, and we start doing extra
|
||||
* flushing, etc. That's the big cliff apps will care about.
|
||||
*/
|
||||
const unsigned long agp_bytes = drmAgpSize(psp->fd);
|
||||
size_t aper_size;
|
||||
size_t mappable_size;
|
||||
|
||||
drm_intel_get_aperture_sizes(psp->fd, &mappable_size, &aper_size);
|
||||
|
||||
const unsigned gpu_mappable_megabytes =
|
||||
(agp_bytes / (1024 * 1024)) * 3 / 4;
|
||||
(aper_size / (1024 * 1024)) * 3 / 4;
|
||||
|
||||
const long system_memory_pages = sysconf(_SC_PHYS_PAGES);
|
||||
const long system_page_size = sysconf(_SC_PAGE_SIZE);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue