lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAKMK7uGTmb8SiTW+6mjovJwmrZYqhJY84ZyD5ozM_ynTBoOjGg@mail.gmail.com>
Date:   Tue, 11 Jun 2019 21:41:40 +0200
From:   Daniel Vetter <daniel.vetter@...ll.ch>
To:     Sven Joachim <svenjoac@....de>
Cc:     Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        stable <stable@...r.kernel.org>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        Dave Airlie <airlied@...hat.com>
Subject: Re: Linux 5.1.9 build failure with CONFIG_NOUVEAU_LEGACY_CTX_SUPPORT=n

On Tue, Jun 11, 2019 at 8:53 PM Sven Joachim <svenjoac@....de> wrote:
>
> On 2019-06-11 19:33 +0200, Daniel Vetter wrote:
>
> > On Tue, Jun 11, 2019 at 5:37 PM Greg Kroah-Hartman
> > <gregkh@...uxfoundation.org> wrote:
> >> On Tue, Jun 11, 2019 at 03:56:35PM +0200, Sven Joachim wrote:
> >> > Commit 1e07d63749 ("drm/nouveau: add kconfig option to turn off nouveau
> >> > legacy contexts. (v3)") has caused a build failure for me when I
> >> > actually tried that option (CONFIG_NOUVEAU_LEGACY_CTX_SUPPORT=n):
> >> >
> >> > ,----
> >> > | Kernel: arch/x86/boot/bzImage is ready  (#1)
> >> > |   Building modules, stage 2.
> >> > |   MODPOST 290 modules
> >> > | ERROR: "drm_legacy_mmap" [drivers/gpu/drm/nouveau/nouveau.ko] undefined!
> >> > | scripts/Makefile.modpost:91: recipe for target '__modpost' failed
> >> > `----
> >
> > Calling drm_legacy_mmap is definitely not a great idea.
>
> Certainly not, but it was done by Dave in commit 2036eaa7403 ("nouveau:
> bring back legacy mmap handler") for compatibility with old
> xf86-video-nouveau versions (older than 1.0.4) that call DRIOpenDRMMaster.
>
> If that is really necessary, it probably has been broken in Linus' tree
> by commit bed2dd8421 where the test has been moved to ttm_bo_mmap() and
> returns -EINVAL on failure.

Looking at the commit it's actually 1.0.1, which was release in 2012.
I'd say lets keep current upstream as-is, and hope no one cares
anymore ...
-Daniel

> > I think either
> > we need a custom patch to remove that out on older kernels, or maybe
> > even #ifdef if you want to be super paranoid about breaking stuff ...
> >
> >> > Upstream does not have that problem, as commit bed2dd8421 ("drm/ttm:
> >> > Quick-test mmap offset in ttm_bo_mmap()") has removed the use of
> >> > drm_legacy_mmap from nouveau_ttm.c.  Unfortunately that commit does not
> >> > apply in 5.1.9.
> >> >
> >> > Most likely 4.19.50 and 4.14.125 are also affected, I haven't tested
> >> > them yet.
> >>
> >> They probably are.
> >>
> >> Should I just revert this patch in the stable tree, or add some other
> >> patch (like the one pointed out here, which seems an odd patch for
> >> stable...)
> >
> > ... or backport the above patch, that should be save to do too. Not
> > sure what stable folks prefer?
> > -Daniel
>
> Cheers,
>        Sven



-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ