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: <Yf2A1GN0Mg9aotUY@ravnborg.org>
Date:   Fri, 4 Feb 2022 20:39:00 +0100
From:   Sam Ravnborg <sam@...nborg.org>
To:     Daniel Vetter <daniel.vetter@...ll.ch>
Cc:     DRI Development <dri-devel@...ts.freedesktop.org>,
        linux-fbdev@...r.kernel.org,
        Thomas Zimmermann <tzimmermann@...e.de>,
        Xiyu Yang <xiyuyang19@...an.edu.cn>,
        Du Cheng <ducheng2@...il.com>,
        Tetsuo Handa <penguin-kernel@...ove.sakura.ne.jp>,
        Intel Graphics Development <intel-gfx@...ts.freedesktop.org>,
        Zheyu Ma <zheyuma97@...il.com>,
        LKML <linux-kernel@...r.kernel.org>,
        Matthew Wilcox <willy@...radead.org>,
        William Kucharski <william.kucharski@...cle.com>,
        Claudio Suarez <cssk@...-c.es>,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        Alex Deucher <alexander.deucher@....com>,
        Daniel Vetter <daniel.vetter@...el.com>,
        Zhen Lei <thunder.leizhen@...wei.com>
Subject: Re: [PATCH 14/21] fbcon: use lock_fb_info in fbcon_open/release

On Mon, Jan 31, 2022 at 10:05:45PM +0100, Daniel Vetter wrote:
> Now we get to the real motiviation, because fbmem.c insists that
> that's the right lock for these.
> 
> Ofc fbcon.c has a lot more places where it probably should call
> lock_fb_info(). But looking at fbmem.c at least most of these seem to
> be protected by console_lock() too, which is probably what papers over
> any issues.
> 
> Note that this means we're shuffling around a bit the locking sections
> for some of the console takeover and unbind paths, but not all:
> - console binding/unbinding from the console layer never with
> lock_fb_info
> - unbind (as opposed to unlink) never bother with lock_fb_info
> 
> Also the real serialization against set_par and set_pan are still
> doing by wrapping the entire ioctl code in console_lock(). So this
> shuffling shouldn't be worse than what we had from a "can you trigger
> races?" pov, but it's at least clearer.
> 
> Signed-off-by: Daniel Vetter <daniel.vetter@...el.com>
> Cc: Daniel Vetter <daniel@...ll.ch>
> Cc: Claudio Suarez <cssk@...-c.es>
> Cc: Tetsuo Handa <penguin-kernel@...ove.SAKURA.ne.jp>
> Cc: Thomas Zimmermann <tzimmermann@...e.de>
> Cc: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
> Cc: Du Cheng <ducheng2@...il.com>
> Cc: Sam Ravnborg <sam@...nborg.org>
> Cc: Matthew Wilcox <willy@...radead.org>
> Cc: William Kucharski <william.kucharski@...cle.com>
> Cc: Alex Deucher <alexander.deucher@....com>
> Cc: Zheyu Ma <zheyuma97@...il.com>
> Cc: Zhen Lei <thunder.leizhen@...wei.com>
> Cc: Xiyu Yang <xiyuyang19@...an.edu.cn>

Well, the patch does what the commit log says.
Acked-by: Sam Ravnborg <sam@...nborg.org>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ