device_suspend(9)
π device_suspend(9) β like, the whole Kernel API Manual vibe
okay bestie, gather round, because this one is literally the page you want if you're tryna understand how a single device gets told "hey babe, go to sleep." yes this is the Kernel API Manual entry, and yes it's giving very much "small function, big job."
β¨ NAME β¨
device_suspend β Execute "suspend" callbacks for given device.
like, for one device. not the whole system. one. device. π
πΈ SYNOPSIS πΈ
void device_suspend (struct device *dev , pm_message_t state , bool
async );
not me obsessing over a three-argument function π it's so clean.
π¦ ARGUMENTS π¦
devβ Device to handle. that's your main character right there, the device getting the suspend treatment πstateβ PM transition of the system being carried out. basically the vibe check for which power-management transition we're in the middle of.asyncβ Iftrue, the device is being suspended asynchronously. so it's doing the whole thing off to the side, not sitting in the front row waiting π«Ά
π₯ SEE ALSO π₯
okay so there's a lot of family here. like a whole friend group. the original points at Kernel file ./drivers/base/power/main.c and then these icons:
pm_hibernate_is_recovering(9)device_pm_sleep_init(9)device_pm_lock(9)device_pm_unlock(9)device_pm_add(9)device_pm_remove(9)device_pm_move_before(9)device_pm_move_after(9)device_pm_move_last(9)dpm_wait(9)pm_op(9)pm_late_early_op(9)pm_noirq_op(9)dpm_watchdog_handler(9)dpm_watchdog_set(9)dpm_watchdog_clear(9)dev_pm_skip_resume(9)device_resume_noirq(9)dpm_resume_noirq(9)device_resume_early(9)dpm_resume_early(9)dpm_resume_start(9)device_resume(9)dpm_resume(9)device_complete(9)dpm_complete(9)dpm_resume_end(9)resume_event(9)device_suspend_noirq(9)dpm_suspend_noirq(9)device_suspend_late(9)dpm_suspend_late(9)dpm_suspend_end(9)legacy_suspend(9)dpm_suspend(9)device_prepare(9)dpm_prepare(9)dpm_suspend_start(9)device_pm_wait_for_dev(9)dpm_for_each_dev(9)
and that's the whole page, no cap β¨
this lil cutie lives in ./drivers/base/power, October 2026 edition, and the page itself is device_suspend(9) β go read the whole friend group, iykyk ππ¦πΈ
π¦ 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