Package Base Details: nvidia-340xx

Git Clone URL: https://aur.archlinux.org/nvidia-340xx.git (read-only, click to copy)
Submitter: simonsmh
Maintainer: JerryXiao (graysky)
Last Packager: graysky
Votes: 40
Popularity: 1.88
First Submitted: 2019-06-07 10:29
Last Updated: 2020-10-22 11:05

Pinned Comments

graysky commented on 2020-10-18 11:09

https://forums.developer.nvidia.com/t/nvidia-driver-not-yet-supported-for-linux-kernel-5-9/157263

Latest Comments

« First ‹ Previous 1 2 3 4 5 6 7 8 ... Next › Last »

piotro commented on 2020-10-19 18:19

@speps: nice catch! Thx!

graysky commented on 2020-10-19 16:23

@speps - Here is the contents of that file:

#define NV_REMAP_PFN_RANGE_PRESENT
#define NV_VMAP_PRESENT
#define NV_VMAP_ARGUMENT_COUNT 4
#define NV_SET_PAGES_UC_PRESENT
#define NV_SET_MEMORY_UC_PRESENT
#define NV_SET_MEMORY_ARRAY_UC_PRESENT
#undef NV_CHANGE_PAGE_ATTR_PRESENT
#define NV_PCI_GET_CLASS_PRESENT
#define NV_PCI_CHOOSE_STATE_PRESENT
#define NV_VM_INSERT_PAGE_PRESENT
#undef NV_ACQUIRE_CONSOLE_SEM_PRESENT
#define NV_CONSOLE_LOCK_PRESENT
#define NV_KMEM_CACHE_CREATE_PRESENT
#define NV_KMEM_CACHE_CREATE_ARGUMENT_COUNT 5
#define NV_ON_EACH_CPU_PRESENT
#define NV_ON_EACH_CPU_ARGUMENT_COUNT 3
#define NV_SMP_CALL_FUNCTION_PRESENT
#define NV_SMP_CALL_FUNCTION_ARGUMENT_COUNT 3
#define NV_ACPI_EVALUATE_INTEGER_PRESENT
typedef unsigned long long nv_acpi_integer_t;
#define NV_IOREMAP_CACHE_PRESENT
#define NV_IOREMAP_WC_PRESENT
#define NV_ACPI_WALK_NAMESPACE_PRESENT
#define NV_ACPI_WALK_NAMESPACE_ARGUMENT_COUNT 7
#define NV_PCI_DOMAIN_NR_PRESENT
#define NV_PCI_DMA_MAPPING_ERROR_PRESENT
#define NV_PCI_DMA_MAPPING_ERROR_ARGUMENT_COUNT 2
#define NV_SG_ALLOC_TABLE_PRESENT
#define NV_SG_ALLOC_TABLE_FROM_PAGES_PRESENT
#define NV_SG_INIT_TABLE_PRESENT
#define NV_PCI_GET_DOMAIN_BUS_AND_SLOT_PRESENT
#define NV_GET_NUM_PHYSPAGES_PRESENT
#define NV_EFI_ENABLED_PRESENT
#define NV_EFI_ENABLED_ARGUMENT_COUNT 1
#define NV_PROC_CREATE_DATA_PRESENT
#define NV_PDE_DATA_PRESENT
#define NV_PROC_REMOVE_PRESENT
#define NV_PM_VT_SWITCH_REQUIRED_PRESENT
#define NV_PCI_SAVE_STATE_ARGUMENT_COUNT 1
#undef NV_DRM_PCI_SET_BUSID_PRESENT
#undef NV_WRITE_CR4_PRESENT
#define NV_FOR_EACH_ONLINE_NODE_PRESENT
#define NV_NODE_END_PFN_PRESENT
#undef NV_GET_USER_PAGES_HAS_WRITE_AND_FORCE_ARGS
#undef NV_GET_USER_PAGES_HAS_TASK_STRUCT
#define NV_GET_USER_PAGES_REMOTE_PRESENT
#undef NV_GET_USER_PAGES_REMOTE_HAS_LOCKED_ARG
#undef NV_GET_USER_PAGES_REMOTE_HAS_WRITE_AND_FORCE_ARGS
#undef NV_REGISTER_CPU_NOTIFIER_PRESENT
#define NV_CPUHP_SETUP_STATE_PRESENT
#undef NV_DRM_LEGACY_PCI_INIT_PRESENT
#define NV_TIMER_SETUP_PRESENT
#undef NV_DO_GETTIMEOFDAY_PRESENT
#undef NV_DRM_GEM_OBJECT_PUT_UNLOCKED_PRESENT

canolucas commented on 2020-10-19 16:10

nvidia-340xx-dkms is working fine here using linux 5.9.1-arch1-1 and newly added kernel-5.9.patch

lpga commented on 2020-10-19 13:02

I'm a owner of a GT 8800 512MB graphic card, and I applied the patch that speps posted and successfully build the module for the kernel 5.9. For now it seems that there's no problem (no OpenCL or CUDA).

speps commented on 2020-10-18 21:54

@graysky: working and building fine here, in a clean chroot.

Seems like, in your setup, the NV_SET_MEMORY_ARRAY_UC_PRESENT is defined, while it should be undef.

Can you please check what you get in kernel/conftest/function.h after build?

graysky commented on 2020-10-18 20:35

@speps - I added the patch and the build errors out (building in a buildroot).

...
/build/nvidia-340xx/src/NVIDIA-Linux-x86_64-340.108-no-compat32/kernel/nv-vm.c: In function ‘nv_set_memory_array_type’:
/build/nvidia-340xx/src/NVIDIA-Linux-x86_64-340.108-no-compat32/kernel/nv-vm.c:86:13: error: implicit declaration of function ‘set_memory_array_uc’; did you mean ‘set_pages_array_uc’? [-Werror=implicit-function-declaration]
   86 |             set_memory_array_uc(pages, num_pages);
      |             ^~~~~~~~~~~~~~~~~~~
      |             set_pages_array_uc
   ./tools/objtool/objtool orc generate  --module --no-fp --retpoline --uaccess /build/nvidia-340xx/src/NVIDIA-Linux-x86_64-340.108-no-compat32/kernel/nv-vtophys.o
/build/nvidia-340xx/src/NVIDIA-Linux-x86_64-340.108-no-compat32/kernel/nv-vm.c:89:13: error: implicit declaration of function ‘set_memory_array_wb’; did you mean ‘set_pages_array_wb’? [-Werror=implicit-function-declaration]
   89 |             set_memory_array_wb(pages, num_pages);
      |             ^~~~~~~~~~~~~~~~~~~
      |             set_pages_array_wb
cc1: some warnings being treated as errors
make[2]: *** [scripts/Makefile.build:283: /build/nvidia-340xx/src/NVIDIA-Linux-x86_64-340.108-no-compat32/kernel/nv-procfs.o] Error 1
cc1: some warnings being treated as errors
make[2]: *** [scripts/Makefile.build:283: /build/nvidia-340xx/src/NVIDIA-Linux-x86_64-340.108-no-compat32/kernel/nv-vm.o] Error 1
make[1]: *** [Makefile:1784: /build/nvidia-340xx/src/NVIDIA-Linux-x86_64-340.108-no-compat32/kernel] Error 2
make[1]: Leaving directory '/usr/lib/modules/5.9.1-arch1-1/build'
NVIDIA: left KBUILD.
nvidia.ko failed to build!
make: *** [Makefile:197: nvidia.ko] Error 1

speps commented on 2020-10-18 20:01

@graysky: piotro patch is fine but incomplete, the uvm part is missing.

Here is a working patch for kernel 5.9: http://ix.io/2Bbp

You can use it by adding (patch -p1 --no-backup-if-mismatch -i "$srcdir"/kernel-5.9.patch) to the PKGBUILD and the relative checksum.

graysky commented on 2020-10-18 16:38

@piorto - Tried applying just your patch and the two I am currently shipping (3 totally) but ran into build errors. How are you recommending usage?

piotro commented on 2020-10-18 13:02

Hi, You may be interested in 340.108 support on 5.9 kernel I developed for my distro.... https://github.com/warpme/minimyth2/blob/master/script/nvidia/nvidia-340.108/files/nvidia-340.108-fix-5.9-kernel-compile.patch

graysky commented on 2020-10-18 11:09

https://forums.developer.nvidia.com/t/nvidia-driver-not-yet-supported-for-linux-kernel-5-9/157263