Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ld: cannot find ./nvidia/nv-kernel.o due to Kbuild changes in 6.13 #747

Open
1 task
philmmanjaro opened this issue Dec 2, 2024 · 11 comments
Open
1 task

Comments

@philmmanjaro
Copy link

NVIDIA Open GPU Kernel Modules Version

565.57.01

Operating System and Version

Manjaro 24.2

Kernel Release

6.13.0-rc1-1-MANJARO

Please confirm you are running a stable release kernel (e.g. not a -rc). We do not accept bug reports for unreleased kernels.

  • I am running on a stable kernel release.

Build Command

The Kbuild changes merged in 6.13-rc1 prevent the nvidia drivers to compile.

Terminal output/Build Log

==> Starting build()...
make: Entering directory '/build/linux613-nvidia/src/NVIDIA-Linux-x86_64-565.57.01-no-compat32/kernel-open'
make[1]: Entering directory '/usr/lib/modules/6.13.0-rc0-4-MANJARO/build'
make[2]: Entering directory '/build/linux613-nvidia/src/NVIDIA-Linux-x86_64-565.57.01-no-compat32/kernel-open'
warning: the compiler differs from the one used to build the kernel
  The kernel was built by: gcc (GCC) 14.2.1 20240910
  You are using:           cc (GCC) 14.2.1 20240910
  SYMLINK nvidia/nv-kernel.o
  SYMLINK nvidia-modeset/nv-modeset-kernel.o
 CONFTEST: hash__remap_4k_pfn
 CONFTEST: set_pages_uc
 CONFTEST: list_is_first
 CONFTEST: set_memory_uc
 CONFTEST: set_memory_array_uc
 CONFTEST: set_pages_array_uc
 CONFTEST: ioremap_cache
 CONFTEST: ioremap_wc
 CONFTEST: ioremap_driver_hardened
 CONFTEST: ioremap_driver_hardened_wc
 CONFTEST: ioremap_cache_shared
 CONFTEST: pci_get_domain_bus_and_slot
 CONFTEST: get_num_physpages
 CONFTEST: pde_data
 CONFTEST: xen_ioemu_inject_msi
 CONFTEST: phys_to_dma
 CONFTEST: get_dma_ops
 CONFTEST: dma_attr_macros
 CONFTEST: dma_map_page_attrs
 CONFTEST: write_cr4
 CONFTEST: of_find_node_by_phandle
 CONFTEST: of_node_to_nid
 CONFTEST: pnv_pci_get_npu_dev
 CONFTEST: of_get_ibm_chip_id
 CONFTEST: pci_stop_and_remove_bus_device
 CONFTEST: pci_rebar_get_possible_sizes
 CONFTEST: wait_for_random_bytes
 CONFTEST: register_cpu_notifier
 CONFTEST: cpuhp_setup_state
 CONFTEST: dma_map_resource
 CONFTEST: get_backlight_device_by_name
 CONFTEST: timer_setup
 CONFTEST: pci_enable_msix_range
 CONFTEST: kernel_read_has_pointer_pos_arg
 CONFTEST: kernel_write_has_pointer_pos_arg
 CONFTEST: dma_direct_map_resource
 CONFTEST: tegra_get_platform
 CONFTEST: tegra_bpmp_send_receive
 CONFTEST: flush_cache_all
 CONFTEST: vmf_insert_pfn
 CONFTEST: jiffies_to_timespec
 CONFTEST: ktime_get_raw_ts64
 CONFTEST: ktime_get_real_ts64
 CONFTEST: full_name_hash
 CONFTEST: pci_enable_atomic_ops_to_root
 CONFTEST: vga_tryget
 CONFTEST: cc_platform_has
 CONFTEST: cc_attr_guest_sev_snp
 CONFTEST: hv_get_isolation_type
 CONFTEST: seq_read_iter
 CONFTEST: follow_pfn
 CONFTEST: drm_gem_object_get
 CONFTEST: drm_gem_object_put_unlocked
 CONFTEST: add_memory_driver_managed
 CONFTEST: device_property_read_u64
 CONFTEST: devm_of_platform_populate
 CONFTEST: of_dma_configure
 CONFTEST: of_property_count_elems_of_size
 CONFTEST: of_property_read_variable_u8_array
 CONFTEST: of_property_read_variable_u32_array
 CONFTEST: i2c_new_client_device
 CONFTEST: i2c_unregister_device
 CONFTEST: of_get_named_gpio
 CONFTEST: devm_gpio_request_one
 CONFTEST: gpio_direction_input
 CONFTEST: gpio_direction_output
 CONFTEST: gpio_get_value
 CONFTEST: gpio_set_value
 CONFTEST: gpio_to_irq
 CONFTEST: icc_get
 CONFTEST: icc_put
 CONFTEST: icc_set_bw
 CONFTEST: dma_buf_export_args
 CONFTEST: dma_buf_ops_has_kmap
 CONFTEST: dma_buf_ops_has_kmap_atomic
 CONFTEST: dma_buf_ops_has_map
 CONFTEST: dma_buf_ops_has_map_atomic
 CONFTEST: dma_buf_has_dynamic_attachment
 CONFTEST: dma_buf_attachment_has_peer2peer
 CONFTEST: dma_set_mask_and_coherent
 CONFTEST: devm_clk_bulk_get_all
 CONFTEST: get_task_ioprio
 CONFTEST: mdev_set_iommu_device
 CONFTEST: offline_and_remove_memory
 CONFTEST: stack_trace
 CONFTEST: crypto_tfm_ctx_aligned
 CONFTEST: radix_tree_empty
 CONFTEST: radix_tree_replace_slot
 CONFTEST: pnv_npu2_init_context
 CONFTEST: cpumask_of_node
 CONFTEST: ioasid_get
 CONFTEST: mm_pasid_drop
 CONFTEST: mmget_not_zero
 CONFTEST: mmgrab
 CONFTEST: iommu_sva_bind_device_has_drvdata_arg
 CONFTEST: vm_fault_to_errno
 CONFTEST: find_next_bit_wrap
 CONFTEST: iommu_is_dma_domain
 CONFTEST: folio_test_swapcache
 CONFTEST: acpi_video_backlight_use_native
 CONFTEST: drm_dev_unref
 CONFTEST: drm_reinit_primary_mode_group
 CONFTEST: get_user_pages_remote
 CONFTEST: get_user_pages
 CONFTEST: pin_user_pages_remote
 CONFTEST: pin_user_pages
 CONFTEST: drm_gem_object_lookup
 CONFTEST: drm_atomic_state_ref_counting
 CONFTEST: drm_driver_has_gem_prime_res_obj
 CONFTEST: drm_atomic_helper_connector_dpms
 CONFTEST: drm_connector_funcs_have_mode_in_name
 CONFTEST: drm_connector_has_vrr_capable_property
 CONFTEST: drm_framebuffer_get
 CONFTEST: drm_dev_put
 CONFTEST: drm_format_num_planes
 CONFTEST: drm_connector_for_each_possible_encoder
 CONFTEST: drm_rotation_available
 CONFTEST: drm_vma_offset_exact_lookup_locked
 CONFTEST: nvhost_dma_fence_unpack
 CONFTEST: dma_fence_set_error
 CONFTEST: fence_set_error
 CONFTEST: sync_file_get_fence
 CONFTEST: drm_aperture_remove_conflicting_pci_framebuffers
 CONFTEST: drm_fbdev_generic_setup
 CONFTEST: drm_fbdev_ttm_setup
 CONFTEST: drm_connector_attach_hdr_output_metadata_property
 CONFTEST: drm_helper_crtc_enable_color_mgmt
 CONFTEST: drm_crtc_enable_color_mgmt
 CONFTEST: drm_atomic_helper_legacy_gamma_set
 CONFTEST: vmf_insert_mixed
 CONFTEST: pfn_to_pfn_t
 CONFTEST: drm_gem_prime_mmap
 CONFTEST: is_export_symbol_gpl_of_node_to_nid
 CONFTEST: is_export_symbol_gpl_sme_active
 CONFTEST: is_export_symbol_present_swiotlb_map_sg_attrs
 CONFTEST: is_export_symbol_present_swiotlb_dma_ops
 CONFTEST: is_export_symbol_present___close_fd
 CONFTEST: is_export_symbol_present_close_fd
 CONFTEST: is_export_symbol_present_get_unused_fd
 CONFTEST: is_export_symbol_present_get_unused_fd_flags
 CONFTEST: is_export_symbol_present_nvhost_get_default_device
 CONFTEST: is_export_symbol_present_nvhost_syncpt_unit_interface_get_byte_offset
 CONFTEST: is_export_symbol_present_nvhost_syncpt_unit_interface_get_aperture
 CONFTEST: is_export_symbol_present_tegra_dce_register_ipc_client
 CONFTEST: is_export_symbol_present_tegra_dce_unregister_ipc_client
 CONFTEST: is_export_symbol_present_tegra_dce_client_ipc_send_recv
 CONFTEST: is_export_symbol_present_dram_clk_to_mc_clk
 CONFTEST: is_export_symbol_present_get_dram_num_channels
 CONFTEST: is_export_symbol_present_tegra_dram_types
 CONFTEST: is_export_symbol_present_pxm_to_node
 CONFTEST: is_export_symbol_present_screen_info
 CONFTEST: is_export_symbol_gpl_screen_info
 CONFTEST: is_export_symbol_present_i2c_bus_status
 CONFTEST: is_export_symbol_present_tegra_fuse_control_read
 CONFTEST: is_export_symbol_present_tegra_get_platform
 CONFTEST: is_export_symbol_present_pci_find_host_bridge
 CONFTEST: is_export_symbol_present_tsec_comms_send_cmd
 CONFTEST: is_export_symbol_present_tsec_comms_set_init_cb
 CONFTEST: is_export_symbol_present_tsec_comms_clear_init_cb
 CONFTEST: is_export_symbol_present_tsec_comms_alloc_mem_from_gscco
 CONFTEST: is_export_symbol_present_tsec_comms_free_gscco_mem
 CONFTEST: is_export_symbol_present_memory_block_size_bytes
 CONFTEST: crypto
 CONFTEST: is_export_symbol_present_follow_pte
 CONFTEST: is_export_symbol_gpl_pci_ats_supported
 CONFTEST: is_export_symbol_present_int_active_memcg
 CONFTEST: is_export_symbol_present_migrate_vma_setup
 CONFTEST: dma_ops
 CONFTEST: swiotlb_dma_ops
 CONFTEST: noncoherent_swiotlb_dma_ops
 CONFTEST: vm_fault_has_address
 CONFTEST: vm_insert_pfn_prot
 CONFTEST: vmf_insert_pfn_prot
 CONFTEST: vm_ops_fault_removed_vma_arg
 CONFTEST: kmem_cache_has_kobj_remove_work
 CONFTEST: sysfs_slab_unlink
 CONFTEST: proc_ops
 CONFTEST: timespec64
 CONFTEST: vmalloc_has_pgprot_t_arg
 CONFTEST: mm_has_mmap_lock
 CONFTEST: pci_channel_state
 CONFTEST: pci_dev_has_ats_enabled
 CONFTEST: remove_memory_has_nid_arg
 CONFTEST: add_memory_driver_managed_has_mhp_flags_arg
 CONFTEST: num_registered_fb
 CONFTEST: pci_driver_has_driver_managed_dma
 CONFTEST: vm_area_struct_has_const_vm_flags
 CONFTEST: memory_failure_has_trapno_arg
 CONFTEST: foll_longterm_present
 CONFTEST: bus_type_has_iommu_ops
 CONFTEST: mmu_notifier_ops_invalidate_range
 CONFTEST: mmu_notifier_ops_arch_invalidate_secondary_tlbs
 CONFTEST: migrate_vma_added_flags
 CONFTEST: migrate_device_range
 CONFTEST: handle_mm_fault_has_mm_arg
 CONFTEST: handle_mm_fault_has_pt_regs_arg
 CONFTEST: mempolicy_has_unified_nodes
 CONFTEST: mempolicy_has_home_node
 CONFTEST: mpol_preferred_many_present
 CONFTEST: mmu_interval_notifier
 CONFTEST: fault_flag_remote_present
 CONFTEST: struct_page_has_zone_device_data
 CONFTEST: drm_bus_present
 CONFTEST: drm_bus_has_bus_type
 CONFTEST: drm_bus_has_get_irq
 CONFTEST: drm_bus_has_get_name
 CONFTEST: drm_driver_has_device_list
 CONFTEST: drm_driver_has_legacy_dev_list
 CONFTEST: drm_driver_has_set_busid
 CONFTEST: drm_crtc_state_has_connectors_changed
 CONFTEST: drm_init_function_args
 CONFTEST: drm_helper_mode_fill_fb_struct
 CONFTEST: drm_master_drop_has_from_release_arg
 CONFTEST: drm_driver_unload_has_int_return_type
 CONFTEST: drm_atomic_helper_crtc_destroy_state_has_crtc_arg
 CONFTEST: drm_atomic_helper_plane_destroy_state_has_plane_arg
 CONFTEST: drm_mode_object_find_has_file_priv_arg
 CONFTEST: dma_buf_owner
 CONFTEST: drm_connector_list_iter
 CONFTEST: drm_atomic_helper_swap_state_has_stall_arg
 CONFTEST: drm_driver_prime_flag_present
 CONFTEST: vm_fault_t
 CONFTEST: drm_gem_object_has_resv
 CONFTEST: drm_crtc_state_has_async_flip
 CONFTEST: drm_crtc_state_has_pageflip_flags
 CONFTEST: drm_crtc_state_has_vrr_enabled
 CONFTEST: drm_format_modifiers_present
 CONFTEST: drm_vma_node_is_allowed_has_tag_arg
 CONFTEST: drm_vma_offset_node_has_readonly
 CONFTEST: drm_display_mode_has_vrefresh
 CONFTEST: drm_driver_master_set_has_int_return_type
 CONFTEST: drm_driver_has_gem_free_object
 CONFTEST: drm_prime_pages_to_sg_has_drm_device_arg
 CONFTEST: drm_driver_has_gem_prime_callbacks
 CONFTEST: drm_crtc_atomic_check_has_atomic_state_arg
 CONFTEST: drm_gem_object_vmap_has_map_arg
 CONFTEST: drm_plane_atomic_check_has_atomic_state_arg
 CONFTEST: drm_device_has_pdev
 CONFTEST: drm_crtc_state_has_no_vblank
 CONFTEST: drm_mode_config_has_allow_fb_modifiers
 CONFTEST: drm_has_hdr_output_metadata
 CONFTEST: dma_resv_add_fence
 CONFTEST: dma_resv_reserve_fences
 CONFTEST: reservation_object_reserve_shared_has_num_fences_arg
 CONFTEST: drm_connector_has_override_edid
 CONFTEST: drm_master_has_leases
 CONFTEST: drm_file_get_master
 CONFTEST: drm_modeset_lock_all_end
 CONFTEST: drm_connector_lookup
 CONFTEST: drm_connector_put
 CONFTEST: drm_driver_has_dumb_destroy
 CONFTEST: fence_ops_use_64bit_seqno
 CONFTEST: drm_aperture_remove_conflicting_pci_framebuffers_has_driver_arg
 CONFTEST: drm_mode_create_dp_colorspace_property_has_supported_colorspaces_arg
 CONFTEST: drm_syncobj_features_present
 CONFTEST: drm_unlocked_ioctl_flag_present
 CONFTEST: drm_framebuffer_obj_present
 CONFTEST: drm_color_ctm_3x4_present
 CONFTEST: drm_color_lut
 CONFTEST: drm_property_blob_put
 CONFTEST: drm_driver_has_gem_prime_mmap
 CONFTEST: drm_output_poll_changed
 CONFTEST: dom0_kernel_present
 CONFTEST: nvidia_vgpu_kvm_build
 CONFTEST: nvidia_grid_build
 CONFTEST: nvidia_grid_csp_build
 CONFTEST: pm_runtime_available
 CONFTEST: pci_class_multimedia_hd_audio
 CONFTEST: drm_available
 CONFTEST: vfio_pci_core_available
 CONFTEST: mdev_available
 CONFTEST: cmd_uphy_display_port_init
 CONFTEST: cmd_uphy_display_port_off
 CONFTEST: memory_failure_mf_sw_simulated_defined
 CONFTEST: drm_atomic_available
 CONFTEST: is_export_symbol_gpl_refcount_inc
 CONFTEST: is_export_symbol_gpl_refcount_dec_and_test
 CONFTEST: drm_alpha_blending_available
 CONFTEST: is_export_symbol_present_drm_gem_prime_fd_to_handle
 CONFTEST: is_export_symbol_present_drm_gem_prime_handle_to_fd
 CONFTEST: ib_peer_memory_symbols
  CC [M]  nvidia/nv.o
  CC [M]  nvidia/nv-pci.o
  CC [M]  nvidia/nv-dmabuf.o
  CC [M]  nvidia/nv-nano-timer.o
  CC [M]  nvidia/nv-acpi.o
  CC [M]  nvidia/nv-cray.o
  CC [M]  nvidia/nv-dma.o
  CC [M]  nvidia/nv-i2c.o
  CC [M]  nvidia/nv-mmap.o
  CC [M]  nvidia/nv-p2p.o
  CC [M]  nvidia/nv-pat.o
  CC [M]  nvidia/nv-procfs.o
  CC [M]  nvidia/nv-usermap.o
  CC [M]  nvidia/nv-vm.o
  CC [M]  nvidia/nv-vtophys.o
  CC [M]  nvidia/os-interface.o
  CC [M]  nvidia/os-mlock.o
In file included from ././common/inc/nv-dmabuf.h:27,
                 from nvidia/nv-dmabuf.c:24:
nvidia/nv-dmabuf.c: In function ‘nv_dma_buf_alloc_file_private’:
././common/inc/nv-linux.h:579:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  579 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/nv-dmabuf.c:125:5: note: in expansion of macro ‘NV_KZALLOC’
  125 |     NV_KZALLOC(priv, sizeof(nv_dma_buf_file_private_t));
      |     ^~~~~~~~~~
nvidia/nv-dmabuf.c: In function ‘nv_dma_buf_map_pages’:
././common/inc/nv-linux.h:579:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  579 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/nv-dmabuf.c:605:5: note: in expansion of macro ‘NV_KZALLOC’
  605 |     NV_KZALLOC(sgt, sizeof(struct sg_table));
      |     ^~~~~~~~~~
nvidia/nv-dmabuf.c: In function ‘nv_dma_buf_map_pfns’:
././common/inc/nv-linux.h:579:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  579 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/nv-dmabuf.c:699:5: note: in expansion of macro ‘NV_KZALLOC’
  699 |     NV_KZALLOC(sgt, sizeof(struct sg_table));
      |     ^~~~~~~~~~
In file included from nvidia/nv-nano-timer.c:31:
nvidia/nv-nano-timer.c: In function ‘nv_alloc_nano_timer’:
././common/inc/nv-linux.h:572:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  572 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/nv-nano-timer.c:90:5: note: in expansion of macro ‘NV_KMALLOC’
   90 |     NV_KMALLOC(nv_nstimer, sizeof(nv_nano_timer_t));
      |     ^~~~~~~~~~
In file included from ././common/inc/nv-pci.h:28,
                 from nvidia/nv-pci.c:26:
nvidia/nv-pci.c: In function ‘nv_pci_probe’:
././common/inc/nv-linux.h:579:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  579 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/nv-pci.c:728:5: note: in expansion of macro ‘NV_KZALLOC’
  728 |     NV_KZALLOC(nvl, sizeof(nv_linux_state_t));
      |     ^~~~~~~~~~
nvidia/nv-mmap.c:321:5: warning: conflicting types for ‘nv_encode_caching’ due to enum/integer mismatch; have ‘int(pgprot_t *, NvU32,  nv_memory_type_t)’ {aka ‘int(struct pgprot *, unsigned int,  nv_memory_type_t)’} [-Wenum-int-mismatch]
  321 | int nv_encode_caching(
      |     ^~~~~~~~~~~~~~~~~
In file included from ././common/inc/nv-linux.h:1805,
                 from nvidia/nv-mmap.c:27:
././common/inc/nv-proto.h:44:13: note: previous declaration of ‘nv_encode_caching’ with type ‘int(pgprot_t *, NvU32,  NvU32)’ {aka ‘int(struct pgprot *, unsigned int,  unsigned int)’}
   44 | int         nv_encode_caching           (pgprot_t *, NvU32, NvU32);
      |             ^~~~~~~~~~~~~~~~~
In file included from nvidia/nv-procfs.c:27:
nvidia/nv-procfs.c: In function ‘nv_procfs_open_file’:
././common/inc/nv-linux.h:579:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  579 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/nv-procfs.c:273:5: note: in expansion of macro ‘NV_KZALLOC’
  273 |     NV_KZALLOC(nvpp, sizeof(nv_procfs_private_t));
      |     ^~~~~~~~~~
  CC [M]  nvidia/os-pci.o
  CC [M]  nvidia/os-registry.o
  CC [M]  nvidia/os-usermap.o
  CC [M]  nvidia/nv-modeset-interface.o
  CC [M]  nvidia/nv-pci-table.o
In file included from nvidia/nv.c:34:
nvidia/nv.c: In function ‘nvos_create_alloc’:
././common/inc/nv-linux.h:579:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  579 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/nv.c:323:5: note: in expansion of macro ‘NV_KZALLOC’
  323 |     NV_KZALLOC(at, sizeof(nv_alloc_t));
      |     ^~~~~~~~~~
nvidia/nv.c: In function ‘nv_alloc_file_private’:
././common/inc/nv-linux.h:579:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  579 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/nv.c:1011:5: note: in expansion of macro ‘NV_KZALLOC’
 1011 |     NV_KZALLOC(nvlfp, sizeof(nv_linux_file_private_t));
      |     ^~~~~~~~~~
  CC [M]  nvidia/nv-kthread-q.o
nvidia/nv.c: In function ‘nvidia_ioctl’:
././common/inc/nv-linux.h:572:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  572 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/nv.c:2399:5: note: in expansion of macro ‘NV_KMALLOC’
 2399 |     NV_KMALLOC(arg_copy, arg_size);
      |     ^~~~~~~~~~
././common/inc/nv-linux.h:572:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  572 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/nv.c:2502:13: note: in expansion of macro ‘NV_KMALLOC’
 2502 |             NV_KMALLOC(nvlfp->attached_gpus, arg_size);
      |             ^~~~~~~~~~
nvidia/nv.c: In function ‘nv_map_guest_pages’:
././common/inc/nv-linux.h:572:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  572 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/nv.c:3139:5: note: in expansion of macro ‘NV_KMALLOC’
 3139 |     NV_KMALLOC(pages, sizeof(struct page *) * page_count);
      |     ^~~~~~~~~~
nvidia/nv.c: In function ‘nv_alloc_kernel_mapping’:
././common/inc/nv-linux.h:572:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  572 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/nv.c:3634:13: note: in expansion of macro ‘NV_KMALLOC’
 3634 |             NV_KMALLOC(pages, sizeof(struct page *) * page_count);
      |             ^~~~~~~~~~
nvidia/nv.c: In function ‘nv_post_event’:
././common/inc/nv-linux.h:586:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  586 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/nv.c:3918:9: note: in expansion of macro ‘NV_KMALLOC_ATOMIC’
 3918 |         NV_KMALLOC_ATOMIC(nvet, sizeof(nvidia_event_t));
      |         ^~~~~~~~~~~~~~~~~
  CC [M]  nvidia/nv-memdbg.o
In file included from nvidia/os-interface.c:27:
nvidia/os-interface.c: In function ‘os_alloc_mem’:
././common/inc/nv-linux.h:586:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  586 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/os-interface.c:637:13: note: in expansion of macro ‘NV_KMALLOC_ATOMIC’
  637 |             NV_KMALLOC_ATOMIC(*address, alloc_size);
      |             ^~~~~~~~~~~~~~~~~
././common/inc/nv-linux.h:601:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  601 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/os-interface.c:643:13: note: in expansion of macro ‘NV_KMALLOC_NO_OOM’
  643 |             NV_KMALLOC_NO_OOM(*address, alloc_size);
      |             ^~~~~~~~~~~~~~~~~
  CC [M]  nvidia/nv-ibmnpu.o
nvidia/os-interface.c: In function ‘os_queue_work_item’:
././common/inc/nv-linux.h:586:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  586 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/os-interface.c:1184:5: note: in expansion of macro ‘NV_KMALLOC_ATOMIC’
 1184 |     NV_KMALLOC_ATOMIC(oqd, sizeof(os_queue_data_t));
      |     ^~~~~~~~~~~~~~~~~
nvidia/os-interface.c: In function ‘os_alloc_wait_queue’:
././common/inc/nv-linux.h:572:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  572 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/os-interface.c:2059:5: note: in expansion of macro ‘NV_KMALLOC’
 2059 |     NV_KMALLOC(*wq, sizeof(os_wait_queue));
      |     ^~~~~~~~~~
  CC [M]  nvidia/nv-report-err.o
  CC [M]  nvidia/nv-msi.o
  CC [M]  nvidia/nv-rsync.o
  CC [M]  nvidia/nv-caps.o
  CC [M]  nvidia/nv-caps-imex.o
  CC [M]  nvidia/nv-host1x.o
  CC [M]  nvidia/nv_uvm_interface.o
  CC [M]  nvidia/libspdm_aead.o
  CC [M]  nvidia/libspdm_ecc.o
  CC [M]  nvidia/libspdm_hkdf.o
  CC [M]  nvidia/libspdm_rand.o
  CC [M]  nvidia/libspdm_shash.o
  CC [M]  nvidia/libspdm_rsa.o
  CC [M]  nvidia/libspdm_aead_aes_gcm.o
In file included from ././common/inc/nv-msi.h:27,
                 from nvidia/nv-msi.c:24:
nvidia/nv-msi.c: In function ‘nv_init_msi’:
././common/inc/nv-linux.h:579:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  579 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/nv-msi.c:39:9: note: in expansion of macro ‘NV_KZALLOC’
   39 |         NV_KZALLOC(nvl->irq_count, sizeof(nv_irq_count_info_t) * nvl->num_intr);
      |         ^~~~~~~~~~
nvidia/nv-msi.c: In function ‘nv_init_msix’:
././common/inc/nv-linux.h:572:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  572 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/nv-msi.c:90:5: note: in expansion of macro ‘NV_KMALLOC’
   90 |     NV_KMALLOC(nvl->msix_entries, sizeof(struct msix_entry) * num_intr);
      |     ^~~~~~~~~~
././common/inc/nv-linux.h:579:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  579 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/nv-msi.c:102:5: note: in expansion of macro ‘NV_KZALLOC’
  102 |     NV_KZALLOC(nvl->irq_count, sizeof(nv_irq_count_info_t) * num_intr);
      |     ^~~~~~~~~~
  CC [M]  nvidia/libspdm_sha.o
  CC [M]  nvidia/libspdm_hmac_sha.o
  CC [M]  nvidia/libspdm_internal_crypt_lib.o
nvidia/libspdm_aead.c:41:5: warning: no previous prototype for ‘libspdm_aead_prealloc’ [-Wmissing-prototypes]
   41 | int libspdm_aead_prealloc(void **context, char const *alg)
      |     ^~~~~~~~~~~~~~~~~~~~~
nvidia/libspdm_aead.c:178:5: warning: no previous prototype for ‘libspdm_aead_prealloced’ [-Wmissing-prototypes]
  178 | int libspdm_aead_prealloced(void *context,
      |     ^~~~~~~~~~~~~~~~~~~~~~~
  CC [M]  nvidia/libspdm_hkdf_sha.o
  CC [M]  nvidia/libspdm_x509.o
  CC [M]  nvidia/libspdm_ec.o
nvidia/libspdm_rand.c:34:6: warning: no previous prototype for ‘libspdm_random_seed’ [-Wmissing-prototypes]
   34 | bool libspdm_random_seed(const uint8_t *seed, size_t seed_size)
      |      ^~~~~~~~~~~~~~~~~~~
  CC [M]  nvidia/libspdm_rsa_ext.o
  CC [M]  nvidia/nvlink_linux.o
  CC [M]  nvidia/nvlink_caps.o
In file included from nvidia/nv-caps.c:24:
nvidia/nv-caps.c: In function ‘nv_cap_procfs_open’:
././common/inc/nv-linux.h:572:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  572 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/nv-caps.c:435:5: note: in expansion of macro ‘NV_KMALLOC’
  435 |     NV_KMALLOC(private, sizeof(nv_cap_file_private_t));
      |     ^~~~~~~~~~
nvidia/nv-caps.c: In function ‘nv_cap_alloc’:
././common/inc/nv-linux.h:572:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  572 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/nv-caps.c:635:5: note: in expansion of macro ‘NV_KMALLOC’
  635 |     NV_KMALLOC(cap, sizeof(nv_cap_t));
      |     ^~~~~~~~~~
././common/inc/nv-linux.h:572:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  572 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/nv-caps.c:642:5: note: in expansion of macro ‘NV_KMALLOC’
  642 |     NV_KMALLOC(cap->path, len);
      |     ^~~~~~~~~~
././common/inc/nv-linux.h:572:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  572 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/nv-caps.c:654:5: note: in expansion of macro ‘NV_KMALLOC’
  654 |     NV_KMALLOC(cap->name, len);
      |     ^~~~~~~~~~
nvidia/nv-caps.c: In function ‘nv_cap_init’:
././common/inc/nv-linux.h:572:37: warning: suggest braces around empty body in an ‘if’ statement [-Wempty-body]
  572 |             NV_MEMDBG_ADD(ptr, size); \
      |                                     ^
nvidia/nv-caps.c:759:5: note: in expansion of macro ‘NV_KMALLOC’
  759 |     NV_KMALLOC(name, (strlen(path) + strlen(dir)) + 1);
      |     ^~~~~~~~~~
  CC [M]  nvidia/procfs_nvswitch.o
  CC [M]  nvidia/linux_nvswitch.o
  CC [M]  nvidia/i2c_nvswitch.o
  CC [M]  nvidia-uvm/uvm_conf_computing.o
nvidia/libspdm_hkdf_sha.c:29:6: warning: no previous prototype for ‘libspdm_hkdf_sha256_extract_and_expand’ [-Wmissing-prototypes]
   29 | bool libspdm_hkdf_sha256_extract_and_expand(const uint8_t *key, size_t key_size,
      |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
nvidia/libspdm_hkdf_sha.c:57:6: warning: no previous prototype for ‘libspdm_hkdf_sha384_extract_and_expand’ [-Wmissing-prototypes]
   57 | bool libspdm_hkdf_sha384_extract_and_expand(const uint8_t *key, size_t key_size,
      |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
nvidia/libspdm_hkdf_sha.c:85:6: warning: no previous prototype for ‘libspdm_hkdf_sha512_extract_and_expand’ [-Wmissing-prototypes]
   85 | bool libspdm_hkdf_sha512_extract_and_expand(const uint8_t *key, size_t key_size,
      |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  CC [M]  nvidia-uvm/uvm_sec2_test.o
nvidia/libspdm_internal_crypt_lib.c:31:6: warning: no previous prototype for ‘libspdm_check_crypto_backend’ [-Wmissing-prototypes]
   31 | bool libspdm_check_crypto_backend(void)
      |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
  CC [M]  nvidia-uvm/uvm_maxwell_sec2.o
  CC [M]  nvidia-uvm/uvm_hopper_sec2.o
  CC [M]  nvidia-uvm/uvm_blackwell.o
nvidia/libspdm_x509.c:35:6: warning: no previous prototype for ‘libspdm_x509_construct_certificate’ [-Wmissing-prototypes]
   35 | bool libspdm_x509_construct_certificate(const uint8_t *cert, size_t cert_size,
      |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
nvidia/libspdm_x509.c:42:6: warning: no previous prototype for ‘libspdm_x509_construct_certificate_stack’ [-Wmissing-prototypes]
   42 | bool libspdm_x509_construct_certificate_stack(uint8_t **x509_stack, ...)
      |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
nvidia/libspdm_x509.c:48:6: warning: no previous prototype for ‘libspdm_x509_free’ [-Wmissing-prototypes]
   48 | void libspdm_x509_free(void *x509_cert)
      |      ^~~~~~~~~~~~~~~~~
nvidia/libspdm_x509.c:53:6: warning: no previous prototype for ‘libspdm_x509_stack_free’ [-Wmissing-prototypes]
   53 | void libspdm_x509_stack_free(void *x509_stack)
      |      ^~~~~~~~~~~~~~~~~~~~~~~
nvidia/libspdm_x509.c:111:6: warning: no previous prototype for ‘libspdm_x509_get_common_name’ [-Wmissing-prototypes]
  111 | bool libspdm_x509_get_common_name(const uint8_t *cert, size_t cert_size,
      |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
nvidia/libspdm_x509.c:120:1: warning: no previous prototype for ‘libspdm_x509_get_organization_name’ [-Wmissing-prototypes]
  120 | libspdm_x509_get_organization_name(const uint8_t *cert, size_t cert_size,
      | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
nvidia/libspdm_x509.c:340:6: warning: no previous prototype for ‘libspdm_x509_get_tbs_cert’ [-Wmissing-prototypes]
  340 | bool libspdm_x509_get_tbs_cert(const uint8_t *cert, size_t cert_size,
      |      ^~~~~~~~~~~~~~~~~~~~~~~~~
nvidia/libspdm_x509.c:371:1: warning: no previous prototype for ‘libspdm_x509_get_issuer_common_name’ [-Wmissing-prototypes]
  371 | libspdm_x509_get_issuer_common_name(const uint8_t *cert, size_t cert_size,
      | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
nvidia/libspdm_x509.c:380:1: warning: no previous prototype for ‘libspdm_x509_get_issuer_orgnization_name’ [-Wmissing-prototypes]
  380 | libspdm_x509_get_issuer_orgnization_name(const uint8_t *cert, size_t cert_size,
      | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
nvidia/libspdm_x509.c:388:6: warning: no previous prototype for ‘libspdm_x509_get_signature_algorithm’ [-Wmissing-prototypes]
  388 | bool libspdm_x509_get_signature_algorithm(const uint8_t *cert,
      |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
nvidia/libspdm_x509.c:449:6: warning: no previous prototype for ‘libspdm_gen_x509_csr’ [-Wmissing-prototypes]
  449 | bool libspdm_gen_x509_csr(size_t hash_nid, size_t asym_nid,
      |      ^~~~~~~~~~~~~~~~~~~~
nvidia/libspdm_ec.c:36:6: warning: no previous prototype for ‘libspdm_ec_set_pub_key’ [-Wmissing-prototypes]
   36 | bool libspdm_ec_set_pub_key(void *ec_context, const uint8_t *public_key,
      |      ^~~~~~~~~~~~~~~~~~~~~~
nvidia/libspdm_ec.c:46:6: warning: no previous prototype for ‘libspdm_ec_get_pub_key’ [-Wmissing-prototypes]
   46 | bool libspdm_ec_get_pub_key(void *ec_context, uint8_t *public_key,
      |      ^~~~~~~~~~~~~~~~~~~~~~
nvidia/libspdm_ec.c:60:6: warning: no previous prototype for ‘libspdm_ec_check_key’ [-Wmissing-prototypes]
   60 | bool libspdm_ec_check_key(const void *ec_context)
      |      ^~~~~~~~~~~~~~~~~~~~
  CC [M]  nvidia-uvm/uvm_blackwell_fault_buffer.o
  CC [M]  nvidia-uvm/uvm_blackwell_mmu.o
  CC [M]  nvidia-uvm/uvm_blackwell_host.o
  CC [M]  nvidia-uvm/uvm_common.o
  CC [M]  nvidia-uvm/uvm_linux.o
  CC [M]  nvidia-uvm/nvstatus.o
  CC [M]  nvidia-uvm/nvCpuUuid.o
  CC [M]  nvidia-uvm/nv-kthread-q.o
  CC [M]  nvidia-uvm/nv-kthread-q-selftest.o
  CC [M]  nvidia-uvm/uvm.o
  CC [M]  nvidia-uvm/uvm_tools.o
  CC [M]  nvidia-uvm/uvm_global.o
  CC [M]  nvidia-uvm/uvm_gpu.o
  CC [M]  nvidia-uvm/uvm_gpu_isr.o
  CC [M]  nvidia-uvm/uvm_procfs.o
  CC [M]  nvidia-uvm/uvm_va_space.o
  CC [M]  nvidia-uvm/uvm_va_space_mm.o
  CC [M]  nvidia-uvm/uvm_gpu_semaphore.o
  CC [M]  nvidia-uvm/uvm_mem.o
  CC [M]  nvidia-uvm/uvm_rm_mem.o
  CC [M]  nvidia-uvm/uvm_channel.o
  CC [M]  nvidia-uvm/uvm_lock.o
  CC [M]  nvidia-uvm/uvm_hal.o
  CC [M]  nvidia-uvm/uvm_processors.o
  CC [M]  nvidia-uvm/uvm_range_tree.o
  CC [M]  nvidia-uvm/uvm_rb_tree.o
nvidia-uvm/uvm_gpu.c: In function ‘init_procfs_dirs’:
nvidia-uvm/uvm_gpu.c:972:5: warning: ISO C90 forbids variable length array ‘uuid_buffer’ [-Wvla]
  972 |     char uuid_buffer[max(UVM_PARENT_GPU_UUID_STRING_LENGTH, UVM_GPU_UUID_STRING_LENGTH)];
      |     ^~~~
nvidia-uvm/uvm_gpu.c:973:5: warning: ISO C90 forbids variable length array ‘gpu_dir_name’ [-Wvla]
  973 |     char gpu_dir_name[sizeof(symlink_name) + sizeof(uuid_buffer) + 1];
      |     ^~~~
  CC [M]  nvidia-uvm/uvm_range_allocator.o
  CC [M]  nvidia-uvm/uvm_va_range.o
  CC [M]  nvidia-uvm/uvm_va_range_device_p2p.o
  CC [M]  nvidia-uvm/uvm_va_policy.o
  CC [M]  nvidia-uvm/uvm_va_block.o
  CC [M]  nvidia-uvm/uvm_range_group.o
  CC [M]  nvidia-uvm/uvm_gpu_replayable_faults.o
  CC [M]  nvidia-uvm/uvm_gpu_non_replayable_faults.o
  CC [M]  nvidia-uvm/uvm_gpu_access_counters.o
  CC [M]  nvidia-uvm/uvm_perf_events.o
  CC [M]  nvidia-uvm/uvm_perf_module.o
  CC [M]  nvidia-uvm/uvm_mmu.o
  CC [M]  nvidia-uvm/uvm_pte_batch.o
  CC [M]  nvidia-uvm/uvm_tlb_batch.o
  CC [M]  nvidia-uvm/uvm_push.o
  CC [M]  nvidia-uvm/uvm_thread_context.o
  CC [M]  nvidia-uvm/uvm_pushbuffer.o
  CC [M]  nvidia-uvm/uvm_tracker.o
  CC [M]  nvidia-uvm/uvm_maxwell.o
  CC [M]  nvidia-uvm/uvm_maxwell_host.o
  CC [M]  nvidia-uvm/uvm_maxwell_ce.o
  CC [M]  nvidia-uvm/uvm_maxwell_mmu.o
  CC [M]  nvidia-uvm/uvm_maxwell_fault_buffer.o
  CC [M]  nvidia-uvm/uvm_maxwell_access_counter_buffer.o
  CC [M]  nvidia-uvm/uvm_pascal.o
  CC [M]  nvidia-uvm/uvm_pascal_ce.o
  CC [M]  nvidia-uvm/uvm_pascal_host.o
  CC [M]  nvidia-uvm/uvm_pascal_mmu.o
  CC [M]  nvidia-uvm/uvm_pascal_fault_buffer.o
  CC [M]  nvidia-uvm/uvm_volta_ce.o
  CC [M]  nvidia-uvm/uvm_volta_host.o
  CC [M]  nvidia-uvm/uvm_volta_mmu.o
  CC [M]  nvidia-uvm/uvm_volta.o
  CC [M]  nvidia-uvm/uvm_volta_fault_buffer.o
  CC [M]  nvidia-uvm/uvm_turing_access_counter_buffer.o
  CC [M]  nvidia-uvm/uvm_turing.o
  CC [M]  nvidia-uvm/uvm_volta_access_counter_buffer.o
  CC [M]  nvidia-uvm/uvm_turing_fault_buffer.o
  CC [M]  nvidia-uvm/uvm_turing_mmu.o
  CC [M]  nvidia-uvm/uvm_turing_host.o
  CC [M]  nvidia-uvm/uvm_ampere.o
  CC [M]  nvidia-uvm/uvm_ampere_ce.o
  CC [M]  nvidia-uvm/uvm_ampere_host.o
  CC [M]  nvidia-uvm/uvm_ampere_fault_buffer.o
  CC [M]  nvidia-uvm/uvm_ampere_mmu.o
  CC [M]  nvidia-uvm/uvm_hopper_fault_buffer.o
  CC [M]  nvidia-uvm/uvm_hopper.o
  CC [M]  nvidia-uvm/uvm_hopper_ce.o
  CC [M]  nvidia-uvm/uvm_hopper_host.o
  CC [M]  nvidia-uvm/uvm_hopper_mmu.o
  CC [M]  nvidia-uvm/uvm_ada.o
  CC [M]  nvidia-uvm/uvm_policy.o
  CC [M]  nvidia-uvm/uvm_perf_utils.o
  CC [M]  nvidia-uvm/uvm_kvmalloc.o
  CC [M]  nvidia-uvm/uvm_pmm_sysmem.o
  CC [M]  nvidia-uvm/uvm_pmm_gpu.o
  CC [M]  nvidia-uvm/uvm_migrate.o
  CC [M]  nvidia-uvm/uvm_populate_pageable.o
  CC [M]  nvidia-uvm/uvm_migrate_pageable.o
  CC [M]  nvidia-uvm/uvm_map_external.o
  CC [M]  nvidia-uvm/uvm_user_channel.o
  CC [M]  nvidia-uvm/uvm_hmm.o
  CC [M]  nvidia-uvm/uvm_perf_heuristics.o
  CC [M]  nvidia-uvm/uvm_perf_thrashing.o
  CC [M]  nvidia-uvm/uvm_perf_prefetch.o
  CC [M]  nvidia-uvm/uvm_ats.o
  CC [M]  nvidia-uvm/uvm_ats_ibm.o
  CC [M]  nvidia-uvm/uvm_ats_faults.o
  CC [M]  nvidia-uvm/uvm_ats_sva.o
  CC [M]  nvidia-uvm/uvm_test.o
  CC [M]  nvidia-uvm/uvm_test_rng.o
  CC [M]  nvidia-uvm/uvm_range_tree_test.o
  CC [M]  nvidia-uvm/uvm_range_allocator_test.o
  CC [M]  nvidia-uvm/uvm_gpu_semaphore_test.o
  CC [M]  nvidia-uvm/uvm_mem_test.o
  CC [M]  nvidia-uvm/uvm_rm_mem_test.o
  CC [M]  nvidia-uvm/uvm_page_tree_test.o
  CC [M]  nvidia-uvm/uvm_tracker_test.o
  CC [M]  nvidia-uvm/uvm_push_test.o
  CC [M]  nvidia-uvm/uvm_channel_test.o
  CC [M]  nvidia-uvm/uvm_ce_test.o
  CC [M]  nvidia-uvm/uvm_host_test.o
  CC [M]  nvidia-uvm/uvm_lock_test.o
  CC [M]  nvidia-uvm/uvm_perf_utils_test.o
  CC [M]  nvidia-uvm/uvm_kvmalloc_test.o
  CC [M]  nvidia-uvm/uvm_pmm_test.o
  CC [M]  nvidia-uvm/uvm_pmm_sysmem_test.o
  CC [M]  nvidia-uvm/uvm_perf_events_test.o
  CC [M]  nvidia-uvm/uvm_perf_module_test.o
  CC [M]  nvidia-uvm/uvm_get_rm_ptes_test.o
  CC [M]  nvidia-uvm/uvm_fault_buffer_flush_test.o
  CC [M]  nvidia-uvm/uvm_peer_identity_mappings_test.o
  CC [M]  nvidia-uvm/uvm_va_block_test.o
  CC [M]  nvidia-uvm/uvm_range_group_tree_test.o
  CC [M]  nvidia-uvm/uvm_thread_context_test.o
  CC [M]  nvidia-uvm/uvm_rb_tree_test.o
  CC [M]  nvidia-modeset/nvidia-modeset-linux.o
  CC [M]  nvidia-modeset/nv-kthread-q.o
  CC [M]  nvidia-drm/nvidia-drm.o
  CC [M]  nvidia-drm/nvidia-drm-drv.o
  CC [M]  nvidia-drm/nvidia-drm-utils.o
  CC [M]  nvidia-drm/nvidia-drm-crtc.o
  CC [M]  nvidia-drm/nvidia-drm-encoder.o
  CC [M]  nvidia-drm/nvidia-drm-connector.o
  CC [M]  nvidia-drm/nvidia-drm-gem.o
  CC [M]  nvidia-drm/nvidia-drm-fb.o
  CC [M]  nvidia-drm/nvidia-drm-modeset.o
  CC [M]  nvidia-drm/nvidia-drm-fence.o
  CC [M]  nvidia-drm/nvidia-drm-helper.o
  CC [M]  nvidia-drm/nv-kthread-q.o
  CC [M]  nvidia-drm/nv-pci-table.o
  CC [M]  nvidia-drm/nvidia-drm-gem-nvkms-memory.o
  CC [M]  nvidia-drm/nvidia-drm-gem-user-memory.o
  CC [M]  nvidia-drm/nvidia-drm-gem-dma-buf.o
  CC [M]  nvidia-drm/nvidia-drm-format.o
  CC [M]  nvidia-drm/nvidia-drm-os-interface.o
  CC [M]  nvidia-drm/nvidia-drm-linux.o
  CC [M]  nvidia-peermem/nvidia-peermem.o
ld -r -o nvidia/nv-interface.o nvidia/nv.o nvidia/nv-pci.o nvidia/nv-dmabuf.o nvidia/nv-nano-timer.o nvidia/nv-acpi.o nvidia/nv-cray.o nvidia/nv-dma.o nvidia/nv-i2c.o nvidia/nv-mmap.o nvidia/nv-p2p.o nvidia/nv-pat.o nvidia/nv-procfs.o nvidia/nv-usermap.o nvidia/nv-vm.o nvidia/nv-vtophys.o nvidia/os-interface.o nvidia/os-mlock.o nvidia/os-pci.o nvidia/os-registry.o nvidia/os-usermap.o nvidia/nv-modeset-interface.o nvidia/nv-pci-table.o nvidia/nv-kthread-q.o nvidia/nv-memdbg.o nvidia/nv-ibmnpu.o nvidia/nv-report-err.o nvidia/nv-rsync.o nvidia/nv-msi.o nvidia/nv-caps.o nvidia/nv-caps-imex.o nvidia/nv-host1x.o nvidia/nv_uvm_interface.o nvidia/libspdm_aead.o nvidia/libspdm_ecc.o nvidia/libspdm_hkdf.o nvidia/libspdm_rand.o nvidia/libspdm_shash.o nvidia/libspdm_rsa.o nvidia/libspdm_aead_aes_gcm.o nvidia/libspdm_sha.o nvidia/libspdm_hmac_sha.o nvidia/libspdm_internal_crypt_lib.o nvidia/libspdm_hkdf_sha.o nvidia/libspdm_ec.o nvidia/libspdm_x509.o nvidia/libspdm_rsa_ext.o nvidia/nvlink_linux.o nvidia/nvlink_caps.o nvidia/linux_nvswitch.o nvidia/procfs_nvswitch.o nvidia/i2c_nvswitch.o
ld -r -o nvidia-modeset/nv-modeset-interface.o nvidia-modeset/nvidia-modeset-linux.o nvidia-modeset/nv-kthread-q.o
  LD [M]  nvidia.o
ld: cannot find ./nvidia/nv-kernel.o: No such file or directory
make[4]: *** [/usr/lib/modules/6.13.0-rc0-4-MANJARO/build/scripts/Makefile.build:387: nvidia.o] Error 1
make[4]: *** Waiting for unfinished jobs....
  LD [M]  nvidia-modeset.o
ld: cannot find ./nvidia-modeset/nv-modeset-kernel.o: No such file or directory
make[4]: *** [/usr/lib/modules/6.13.0-rc0-4-MANJARO/build/scripts/Makefile.build:387: nvidia-modeset.o] Error 1
make[3]: *** [/usr/lib/modules/6.13.0-rc0-4-MANJARO/build/Makefile:1989: .] Error 2
make[2]: *** [/usr/lib/modules/6.13.0-rc0-4-MANJARO/build/Makefile:251: __sub-make] Error 2
make[2]: Leaving directory '/build/linux613-nvidia/src/NVIDIA-Linux-x86_64-565.57.01-no-compat32/kernel-open'
make[1]: *** [Makefile:251: __sub-make] Error 2
make[1]: Leaving directory '/usr/lib/modules/6.13.0-rc0-4-MANJARO/build'
make: *** [Makefile:89: modules] Error 2
make: Leaving directory '/build/linux613-nvidia/src/NVIDIA-Linux-x86_64-565.57.01-no-compat32/kernel-open'

More Info

When I find time, I might do a git-bisect to find the commit causing this.

@aritger
Copy link
Collaborator

aritger commented Dec 2, 2024

Thank you for reporting this. We're also tracking this internally as NVIDIA bug 4989092. If you can do a git-bisect, that would be very useful. Thanks.

@philmmanjaro
Copy link
Author

Guy's you should step up your game and check. Seems the symlinks get done wrongly as mentioned here: #746 (comment). For 470xx series the community already has a patch: https://gist.github.com/joanbm/d1f89391a4b20f4b56ba931ef6ca62da. Should apply to newer and older Nvidia drivers just fine.

@philmmanjaro
Copy link
Author

@aritger the issue is commit 80f289101690 "kbuild: change working directory to external module directory with M=" (Masahiro Yamada, 10 Nov 2024)

@barneysspeedshop
Copy link

So the patch definitely works, just apply https://gist.githubusercontent.com/joanbm/d1f89391a4b20f4b56ba931ef6ca62da/raw/8458c7c58249a0dceb5ab1b5aada7e705a88b4ff/nvidia-470xx-fix-linux-6.13.patch but I'm stuck on this part:

Kernel Release

6.13.0-rc0-1-MANJARO
Please confirm you are running a stable release kernel (e.g. not a -rc). We do not accept bug reports for unreleased kernels.

It looks like it's against the nvidia rules to post a bug for an RC kernel version. Though, it seems like this one was welcomed in #747 (comment)

While it seems like it's considered acceptable by nvidia in this case, I'm curious if someone can explain to me why the bug reports for release candidates are not allowed, or why they would be accepted in this particular case?

@mtijanic
Copy link
Collaborator

mtijanic commented Dec 5, 2024

While it seems like it's considered acceptable by nvidia in this case, I'm curious if someone can explain to me why the bug reports for release candidates are not allowed, or why they would be accepted in this particular case?

Hi there. We'll need to revisit our policy on this, but I imagine it could look something roughly like:

  • Bug reports for RC kernels are welcome as a way to provide a good, searchable location for anyone hitting the same issue and a place to post patches as above.
  • RC kernels are not actually supported, and we may not respond to these bugs.

I believe there are two reasons for the original policy. One is that because the early RCs are sometimes very unstable, we don't want to spend time chasing down issues that are not part of our stack.

The other is that by far the overwhelming majority of these RC bug reports are due to some API changes that make the NV driver fail to build/load. This is something we are actively tracking internally, so these bug reports don't actually help us, it is just extra work to triage and respond. However, they do help everyone else, so I think the policy might get changed. Maybe we'll provide a separate bug template and tag for these issues.

@philmmanjaro
Copy link
Author

@mtijanic the RC1 is the most important kernel version there is. It normally includes all changes made in that kernel series. The following RCs are to polish the regressions or features introduced in that development cycle. Nvidia can simply join that development cycle similar as other companies like Intel and AMD do. Also post their fixes as soon as they have some to the public on given issues we may open. As distro maintainers we have to prepare our systems as soon as possible. Some distributions, especially rolling ones, might adopt software as soon as they got tagged stable.

Therefore I always ignored the rules of not posting bugs for not released kernels. It simply makes no sense to have such a rule, as you have to change the code anyway.

Sure, QA and official support might take longer for Nvidia to do. However, if Nvidia decides to do open kernel modules like AMD, Nvidia has to join and develop in the development cycle at given merge windows as everybody else has to do too.

So why not start early as the trend is in that direction anyway.

@mtijanic
Copy link
Collaborator

mtijanic commented Dec 5, 2024

As an out of tree driver we adapt our release (and thus QA) schedule not just to linux mainline, but also HW releases, security rollouts across multiple LTS driver branches, enterprise customer schedules, LTS kernel releases, and even Windows and the big game title releases. Unfortunately, this means we cannot always provide latest mainline compatible releases.

There's certainly an argument to be made that we can still handle this much better even within all the above constraints, such as maybe pushing the kernel-compatibility patches out of band as they are developed. We are actively discussing this internally and looking to improve the situation for bleeding edge rolling release distros.

@philmmanjaro
Copy link
Author

That would be really good. As most of the patches the user community provides get tested even on older Nvidia drivers which are EOL, as the 390xx series as an example. You can follow those efforts for example at the AUR from Arch:

https://aur.archlinux.org/cgit/aur.git/log/?h=nvidia-470xx-utils
https://aur.archlinux.org/cgit/aur.git/log/?h=nvidia-390xx-utils

Also Joan provides some patches for the 470xx driver series, as he still has to use that driver. Most of them also apply to newer or older drivers:

https://gist.github.com/joanbm

Most bleeding edge Distros are able to patch drivers as needed. The only issue here might be, that it might violate the licenses of the proprietary drivers. However, we only modify those source available parts anyway. So the binary blobs are never touched. Might be a gray area. So if that can be also added to the internal discussions it would help us a lot.

@ttabi
Copy link

ttabi commented Dec 5, 2024

So why not start early as the trend is in that direction anyway.

That's the point that Milos is making -- we already have started. We track not only the -rc kernels internally, but also linux-next, so we are typically aware of -rc1 build failures before -rc1 is released. So as he said: "these bug reports don't actually help us, it is just extra work to triage and respond."

@barneysspeedshop
Copy link

@mtijanic Thank you for your response. That's super helpful to understand the position. I agree that this bug report was helpful to me as it led me to the resolution of the issue I was having. I also understand that from a development/product owner standpoint it probably is not beneficial to understand these bugs.

@philmmanjaro
Copy link
Author

philmmanjaro commented Dec 6, 2024

@ttabi the issue here is that Nvidia may know about the issues due to their internal bug tracker. However the Distro maintainers and users who want to use the latest kernels or have to ship the drivers in combination with the latest kernels would want to know about the issue and possible patches already existing. So having those issues publicly posted helps the community and users of the Nvidia drivers.

Posts like https://forums.developer.nvidia.com/t/patch-for-565-57-01-linux-kernel-6-12/313260 are great - a great example to publish patches as needed as soon as they are known and created.

And even when the community is posting again issues you already know, the proper response would be: hey here is the patch, will be officially released in 565.xxx, which is scheduled for release at <some date>. We also track it in our internal tracker with <some number>. Apply the patch on your own risk, as we may change it as needed.

xtexChooser added a commit to AOSC-Tracking/nvidia-open that referenced this issue Dec 14, 2024
Cherry-pick of abc88d52ee5e86decd5e98b3223d3feec0dd66bc from nvidia-driver tracking repo.

Link: https://gist.github.com/joanbm/d1f89391a4b20f4b56ba931ef6ca62da
Link: NVIDIA#747
Author: Joan Bruguera <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants