vim 580.105.08-1-for-6.18.0-cachyos2.fc43.x86_64.failed.log
最终定位到相应错误:
1 2 3 4 5 6 7 8 9 10
Build fails:
nvidia-uvm/uvm_va_range_device_p2p.c:363:13: error: too many arguments to function 'get_dev_pagemap' 363 | get_dev_pagemap(page_to_pfn(page), NULL); | ^~~~~~~~~~~~~~~ In file included from/nix/store/.../linux-6.18-dev/lib/modules/6.18.0/source/include/linux/mm.h:33, /nix/store/.../linux-6.18-dev/lib/modules/6.18.0/source/include/linux/memremap.h:214:21: note: declared here 214 | struct dev_pagemap *get_dev_pagemap(unsigned long pfn); | ^~~~~~~~~~~~~~~
+#include <linux/version.h> + #include "uvm_common.h" #include "uvm_linux.h" #include "uvm_types.h" @@ -360,7 +362,11 @@ static NV_STATUS alloc_device_p2p_mem(uvm_gpu_t *gpu, // a reference to them, so take one now if using DEVICE_COHERENT pages. if (gpu->parent->cdmm_enabled) { get_page(page); +#if LINUX_VERSION_CODE < KERNEL_VERSION(6, 18, 0) get_dev_pagemap(page_to_pfn(page), NULL); +#else + get_dev_pagemap(page_to_pfn(page)); +#endif /* < 6.18 */ } #else // CDMM P2PDMA will never be enabled for this case -- 2.51.0