summaryrefslogtreecommitdiff
path: root/Kernel/API/FB.h
diff options
context:
space:
mode:
authorLiav A <liavalb@gmail.com>2022-04-29 20:11:42 +0300
committerAndreas Kling <kling@serenityos.org>2022-05-05 20:55:57 +0200
commit6d7e2596e00c0edc570ddc438b14e2ccce153762 (patch)
tree31b63c94f9a422f0988319577640f140343f862a /Kernel/API/FB.h
parentd9a2706079d314416353148cc9822e997c37b680 (diff)
downloadserenity-6d7e2596e00c0edc570ddc438b14e2ccce153762.zip
WindowServer: Implement mechanism to restore safe mode setting
Such mechanism will be used by the Intel Graphics driver, because we lack support of changing the resolution on this driver currently, so, when WindowServer will try to mode-set the display then it will fail, and will use the safe mode-setting call instead to be able to show something on screen.
Diffstat (limited to 'Kernel/API/FB.h')
-rw-r--r--Kernel/API/FB.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/Kernel/API/FB.h b/Kernel/API/FB.h
index 339f32eb41..2917806122 100644
--- a/Kernel/API/FB.h
+++ b/Kernel/API/FB.h
@@ -64,6 +64,11 @@ ALWAYS_INLINE int fb_set_head_mode_setting(int fd, FBHeadModeSetting* mode_setti
return ioctl(fd, FB_IOCTL_SET_HEAD_MODE_SETTING, mode_setting);
}
+ALWAYS_INLINE int fb_set_safe_head_mode_setting(int fd)
+{
+ return ioctl(fd, FB_IOCTL_SET_SAFE_HEAD_MODE_SETTING, nullptr);
+}
+
ALWAYS_INLINE int fb_get_head_mode_setting(int fd, FBHeadModeSetting* mode_setting)
{
FBHeadModeSetting head_mode_setting;