• Daniel Vetter's avatar
    drm/fb_helper: check whether fbcon is bound · 20c60c35
    Daniel Vetter authored
    We need to make sure that the fbcon is still bound when touching the
    hw, since otherwise we might corrupt the modeset state of kms clients.
    X mostly works around that with VT switching and setting the VT into
    raw mode, which disables most fbcon events.
    
    Raw kms test programs though don't do that dance, and in the future
    we might want to aim to abolish CONFIG_VT anyway. So improve preventive
    measures a bit. To do so, extract the existing logic for handling hotplug
    events (which X can't block with the current set of tricks) and reuse
    it for the fbdev blanking helper.
    
    Long-term we really need to either scrap this all and only have a OOPS
    console, or come up with a saner model for device ownership sharing
    between fbdev/fbcon and kms userspace.
    Reviewed-by: default avatarRob Clark <rob@ti.com>
    Signed-off-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
    20c60c35
drm_fb_helper.c 37.7 KB