Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

fbcon: Consistently protect deferred_takeover with console_lock()

This shouldn't be a problem in practice since until we've actually
taken over the console there's nothing we've registered with the
console/vt subsystem, so the exit/unbind path that check this can't
do the wrong thing. But it's confusing, so fix it by moving it a tad
later.

Acked-by: Sam Ravnborg <sam@ravnborg.org>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
Cc: Daniel Vetter <daniel@ffwll.ch>
Cc: Du Cheng <ducheng2@gmail.com>
Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
Cc: Claudio Suarez <cssk@net-c.es>
Cc: Thomas Zimmermann <tzimmermann@suse.de>
Link: https://patchwork.freedesktop.org/patch/msgid/20220405210335.3434130-14-daniel.vetter@ffwll.ch

+3 -2
+3 -2
drivers/video/fbdev/core/fbcon.c
··· 3227 3227 3228 3228 console_lock(); 3229 3229 3230 + deferred_takeover = false; 3231 + logo_shown = FBCON_LOGO_DONTSHOW; 3232 + 3230 3233 for_each_registered_fb(i) 3231 3234 fbcon_fb_registered(registered_fb[i]); 3232 3235 ··· 3247 3244 pr_info("fbcon: Taking over console\n"); 3248 3245 3249 3246 dummycon_unregister_output_notifier(&fbcon_output_nb); 3250 - deferred_takeover = false; 3251 - logo_shown = FBCON_LOGO_DONTSHOW; 3252 3247 3253 3248 /* We may get called in atomic context */ 3254 3249 schedule_work(&fbcon_deferred_takeover_work);