drm_privacy...set_sw_state(9)
π drm_privacy...set_sw_state(9) β like, the Kernel API Manual, bestie β¨
okay so this one's from the Kernel API Manual and it's literally called drm_privacy_screen_set_sw_state β say that five times fast, I dare you π«Ά
πΈ NAME πΈ
drm_privacy_screen_set_sw_state β set a privacy-screen's sw-state. that's it. that's the whole vibe π«
β¨ SYNOPSIS β¨
int drm_privacy_screen_set_sw_state (struct drm_privacy_screen *priv ,
enum drm_privacy_screen_status sw_state );
bestie look at that signature. two arguments. so clean. we love to see it π
π ARGUMENTS π
privβ the privacy screen you're setting the sw-state for. it's the main character here, give it what it needs πsw_stateβ the new sw-state value you want to set. brand new value, who dis π
π¦ DESCRIPTION π¦
okay so here's the tea β β this function sets the sw-state of a privacy screen. simple enough, right? but wait, there's a plot twist:
if the privacy-screen is not in a locked hw-state, then the actual and hw-state of the privacy-screen get immediately updated to the new value. like, right away. instant. no waiting around π¨
but if the privacy-screen is in a locked hw-state, then the new sw-state gets remembered as the requested state β like, the state it should be put in when it becomes unlocked π. so it's not ignored, it's just... on hold. patient queen behavior tbh π
ngl this is giving "hold my call, I'll get back to you" energy and honestly? respect π
β RETURN β
0β success! slay! we ate! π- negative error code β failure π something went wrong, go check it
π₯ SEE ALSO π₯
- Kernel file
./drivers/gpu/drm/drm_privacy_screen.coverview(9) drm_privacy_screen_lookup_add(9)drm_privacy_screen_lookup_remove(9)drm_privacy_screen_get(9)drm_privacy_screen_put(9)drm_privacy_screen_get_state(9)drm_privacy_screen_register_notifier(9)drm_privacy_screen_unregister_notifier(9)drm_privacy_screen_register(9)drm_privacy_screen_unregister(9)drm_privacy_screen_call_notifier_chain(9)
a whole friend group of functions fr fr β go say hi to all of them π«Άβ¨
mwah π that's the whole page, brought to you by the fine folks at ./drivers/gpu/drm, dated October 2026. go forth and set those sw-states, bestie β you've got this ππΈ
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms