@@ -879,13 +879,6 @@ get_properties_1_2(const struct anv_physical_device *pdevice,
879879 pdevice -> info .ver ==
880880 7 ? VK_SAMPLE_COUNT_1_BIT :
881881 isl_device_get_sample_counts (& pdevice -> isl_dev );
882-
883- /* Set maxBufferSize for VkPhysicalDeviceMaintenance4Properties.
884- * This is also set in get_properties_1_3() for Vulkan 1.3, but we set it
885- * here as well to ensure it's available when queried through the
886- * Maintenance4 extension in Vulkan 1.2.
887- */
888- p -> maxBufferSize = pdevice -> isl_dev .max_buffer_size ;
889882}
890883
891884static void
@@ -1320,34 +1313,6 @@ get_properties(const struct anv_physical_device *pdevice,
13201313 }
13211314}
13221315
1323- VKAPI_ATTR void VKAPI_CALL
1324- anv_GetPhysicalDeviceProperties2 (VkPhysicalDevice physicalDevice ,
1325- VkPhysicalDeviceProperties2 * pProperties )
1326- {
1327- ANV_FROM_HANDLE (anv_physical_device , pdevice , physicalDevice );
1328-
1329- /* Explicitly handle VkPhysicalDeviceMaintenance4Properties and VkPhysicalDeviceVulkan13Properties
1330- * There appears to be an issue with the property generation/copying for maxBufferSize,
1331- * so we manually fill it here to ensure it's properly exposed.
1332- * Note: Maintenance4 was promoted to Vulkan 1.3, so maxBufferSize appears in both structures.
1333- */
1334- vk_common_GetPhysicalDeviceProperties2 (physicalDevice , pProperties );
1335- vk_foreach_struct (ext , pProperties -> pNext ) {
1336- if (ext -> sType ==
1337- VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_MAINTENANCE_4_PROPERTIES ) {
1338- VkPhysicalDeviceMaintenance4Properties * props =
1339- (VkPhysicalDeviceMaintenance4Properties * ) ext ;
1340- props -> maxBufferSize = pdevice -> vk .properties .maxBufferSize ;
1341- }
1342- else if (ext -> sType ==
1343- VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_VULKAN_1_3_PROPERTIES ) {
1344- VkPhysicalDeviceVulkan13Properties * props =
1345- (VkPhysicalDeviceVulkan13Properties * ) ext ;
1346- props -> maxBufferSize = pdevice -> vk .properties .maxBufferSize ;
1347- }
1348- }
1349- }
1350-
13511316static uint64_t
13521317anv_compute_sys_heap_size (struct anv_physical_device * device ,
13531318 uint64_t available_ram )
@@ -1729,15 +1694,6 @@ anv_physical_device_try_create(struct vk_instance *vk_instance,
17291694 goto fail_fd ;
17301695 }
17311696
1732- /* Initialize a minimal properties struct with maxBufferSize set.
1733- * Hardcoded to 1GB for hasvk (Ivy Bridge/Haswell/Broadwell all support 1GB).
1734- * This ensures maxBufferSize is never 0 when validation layers query it.
1735- * This will be overwritten later by get_properties() with the actual ISL value.
1736- */
1737- struct vk_properties initial_props = {
1738- .maxBufferSize = 1073741824ull /* 1GB */
1739- };
1740-
17411697 struct vk_physical_device_dispatch_table dispatch_table ;
17421698 vk_physical_device_dispatch_table_from_entrypoints (& dispatch_table ,
17431699 & anv_physical_device_entrypoints ,
@@ -1746,18 +1702,13 @@ anv_physical_device_try_create(struct vk_instance *vk_instance,
17461702 & wsi_physical_device_entrypoints ,
17471703 false);
17481704
1749- result = vk_physical_device_init (& device -> vk , & instance -> vk , NULL , NULL , & initial_props ,
1705+ result = vk_physical_device_init (& device -> vk , & instance -> vk , NULL , NULL , NULL ,
17501706 & dispatch_table );
17511707 if (result != VK_SUCCESS ) {
17521708 vk_error (instance , result );
17531709 goto fail_alloc ;
17541710 }
17551711
1756- /* Explicitly set our custom GetPhysicalDeviceProperties2 implementation
1757- * to ensure Maintenance4Properties.maxBufferSize is properly exposed */
1758- device -> vk .dispatch_table .GetPhysicalDeviceProperties2 =
1759- anv_GetPhysicalDeviceProperties2 ;
1760-
17611712 device -> instance = instance ;
17621713
17631714 assert (strlen (path ) < ARRAY_SIZE (device -> path ));
0 commit comments