Lines Matching refs:topo_info
202 struct drm_i915_query_topology_info *topo_info; in test_query_topology_kernel_writes() local
214 topo_info = (struct drm_i915_query_topology_info *) (_topo_info + sizeof(*_topo_info)); in test_query_topology_kernel_writes()
215 memset(topo_info, 0, item.length); in test_query_topology_kernel_writes()
217 item.data_ptr = to_user_pointer(topo_info); in test_query_topology_kernel_writes()
246 slice_available(const struct drm_i915_query_topology_info *topo_info, in slice_available() argument
249 return (topo_info->data[s / 8] >> (s % 8)) & 1; in slice_available()
253 subslice_available(const struct drm_i915_query_topology_info *topo_info, in subslice_available() argument
256 return (topo_info->data[topo_info->subslice_offset + in subslice_available()
257 s * topo_info->subslice_stride + in subslice_available()
262 eu_available(const struct drm_i915_query_topology_info *topo_info, in eu_available() argument
265 return (topo_info->data[topo_info->eu_offset + in eu_available()
266 (s * topo_info->max_subslices + ss) * topo_info->eu_stride + in eu_available()
278 struct drm_i915_query_topology_info *topo_info; in test_query_topology_coherent_slice_mask() local
300 topo_info = calloc(1, item.length); in test_query_topology_coherent_slice_mask()
302 item.data_ptr = to_user_pointer(topo_info); in test_query_topology_coherent_slice_mask()
310 for (s = 0; s < topo_info->max_slices; s++) { in test_query_topology_coherent_slice_mask()
311 if (slice_available(topo_info, s)) in test_query_topology_coherent_slice_mask()
322 for (s = 0; s < topo_info->max_subslices; s++) { in test_query_topology_coherent_slice_mask()
323 if (subslice_available(topo_info, 0, s)) in test_query_topology_coherent_slice_mask()
336 free(topo_info); in test_query_topology_coherent_slice_mask()
346 struct drm_i915_query_topology_info *topo_info; in test_query_topology_matches_eu_total() local
359 topo_info = calloc(1, item.length); in test_query_topology_matches_eu_total()
361 item.data_ptr = to_user_pointer(topo_info); in test_query_topology_matches_eu_total()
365 topo_info->max_slices, topo_info->max_subslices, in test_query_topology_matches_eu_total()
366 topo_info->max_eus_per_subslice); in test_query_topology_matches_eu_total()
368 topo_info->subslice_offset, topo_info->subslice_stride); in test_query_topology_matches_eu_total()
370 topo_info->eu_offset, topo_info->eu_stride); in test_query_topology_matches_eu_total()
373 for (s = 0; s < topo_info->max_slices; s++) { in test_query_topology_matches_eu_total()
377 slice_available(topo_info, s) ? "available" : "fused"); in test_query_topology_matches_eu_total()
379 if (!slice_available(topo_info, s)) in test_query_topology_matches_eu_total()
382 for (ss = 0; ss < topo_info->max_subslices; ss++) { in test_query_topology_matches_eu_total()
386 subslice_available(topo_info, s, ss) ? "available" : "fused"); in test_query_topology_matches_eu_total()
388 if (!subslice_available(topo_info, s, ss)) in test_query_topology_matches_eu_total()
392 for (eu = 0; eu < topo_info->max_eus_per_subslice; eu++) { in test_query_topology_matches_eu_total()
393 uint8_t val = eu_available(topo_info, s, ss, in test_query_topology_matches_eu_total()
394 topo_info->max_eus_per_subslice - 1 - eu); in test_query_topology_matches_eu_total()
404 igt_assert(slice_available(topo_info, s)); in test_query_topology_matches_eu_total()
405 igt_assert(subslice_available(topo_info, s, ss)); in test_query_topology_matches_eu_total()
407 if (subslice_available(topo_info, s, ss)) { in test_query_topology_matches_eu_total()
408 igt_assert(slice_available(topo_info, s)); in test_query_topology_matches_eu_total()
413 free(topo_info); in test_query_topology_matches_eu_total()
427 struct drm_i915_query_topology_info *topo_info; in test_query_topology_known_pci_ids() local
438 topo_info = (struct drm_i915_query_topology_info *) calloc(1, item.length); in test_query_topology_known_pci_ids()
440 item.data_ptr = to_user_pointer(topo_info); in test_query_topology_known_pci_ids()
443 for (s = 0; s < topo_info->max_slices; s++) { in test_query_topology_known_pci_ids()
444 if (slice_available(topo_info, s)) in test_query_topology_known_pci_ids()
447 for (ss = 0; ss < topo_info->max_subslices; ss++) { in test_query_topology_known_pci_ids()
448 if (subslice_available(topo_info, s, ss)) in test_query_topology_known_pci_ids()
483 free(topo_info); in test_query_topology_known_pci_ids()