Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 635352 - x11-drivers/nvidia-drivers-340.104 - .../work/kernel/uvm/nvidia_uvm_lite.c:857:14: error: initialization from incompatible pointer type [-Werror=incompatible-pointer-types]
Summary: x11-drivers/nvidia-drivers-340.104 - .../work/kernel/uvm/nvidia_uvm_lite.c:85...
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: Jeroen Roovers (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-10-24 19:41 UTC by hangglider
Modified: 2018-01-21 10:38 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge --info (info,1.36 KB, text/plain)
2017-10-24 19:41 UTC, hangglider
Details

Note You need to log in before you can comment on or make changes to this bug.
Description hangglider 2017-10-24 19:41:42 UTC
Created attachment 499994 [details]
emerge --info

Linux 4.10.x => 4.11.y introduces a change in include/linux/mm.h, where the 1st arg of vm_operations_struct.fault is removed. Resulting error is like that:

/var/tmp/portage/x11-drivers/nvidia-drivers-340.104/work/kernel/uvm/nvidia_uvm_lite.c: At top level:
/var/tmp/portage/x11-drivers/nvidia-drivers-340.104/work/kernel/uvm/nvidia_uvm_lite.c:857:14: error: initialization from incompatible pointer type [-Werror=incompatible-pointer-types]
     .fault = _fault,
              ^
/var/tmp/portage/x11-drivers/nvidia-drivers-340.104/work/kernel/uvm/nvidia_uvm_lite.c:857:14: note: (near initialization for 'uvmlite_vma_ops.fault')
/var/tmp/portage/x11-drivers/nvidia-drivers-340.104/work/kernel/uvm/nvidia_uvm_lite.c:887:14: error: initialization from incompatible pointer type [-Werror=incompatible-pointer-types]
     .fault = _sigbus_fault,
              ^
/var/tmp/portage/x11-drivers/nvidia-drivers-340.104/work/kernel/uvm/nvidia_uvm_lite.c:887:14: note: (near initialization for 'counters_vma_ops.fault')
cc1: some warnings being treated as errors

This could most probably also affect different versions of the driver(s) - I'd expect newer drivers to be more supported, but my old notebook limits me to that version.

Furthermore, flavour of kernel should not matter much (pf-sources-4.13-p4 in my case), as the problem seems to be introduced from a change in mainline kernel.
Comment 1 hangglider 2017-10-28 17:17:17 UTC
only happens with USE="uvm"
Comment 2 Jeroen Roovers (RETIRED) gentoo-dev 2017-10-29 11:07:19 UTC
nvidia-drivers-340.104.ebuild:
    if use kernel_linux && kernel_is ge 4 10; then
        ewarn "Gentoo supports kernels which are supported by NVIDIA"
        ewarn "which are limited to the following kernels:"
        ewarn "<sys-kernel/gentoo-sources-4.10"
        ewarn "<sys-kernel/vanilla-sources-4.10"
        ewarn ""
        ewarn "You are free to utilize eapply_user to provide whatever"
        ewarn "support you feel is appropriate, but will not receive"
        ewarn "support as a result of those changes."
        ewarn ""
        ewarn "Do not file a bug report about this."
        ewarn ""
    fi