wakeup_source_sysfs_add(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’« wakeup_source_sysfs_add(9) πŸ’«

okay so bestie, welcome to the Kernel API Manual β€” this one's a lil function called wakeup_source_sysfs_add, and honestly? it's giving "make my wakeup source visible in sysfs" energy. no cap. ✨


🌸 NAME 🌸

wakeup_source_sysfs_add β€” adds wakeup_source attributes to sysfs. that's the whole vibe. she shows up, she makes files, she leaves. iconic. πŸ’…


πŸ¦‹ SYNOPSIS πŸ¦‹

int wakeup_source_sysfs_add (struct device *parent , struct
wakeup_source *ws );

literally just call her with a parent device and a wakeup source and she does the thing. returns an int, so like, pay attention to that. 🫢


πŸŽ€ ARGUMENTS πŸŽ€

  • parent β€” the Device that the given wakeup source is associated with. and yes, she can be NULL if the source is virtual (a little ghost girl, no physical device, still valid πŸ’€).
  • ws β€” the Wakeup source that's getting added in sysfs. that's the main character right there. πŸ‘‘

πŸ”₯ SEE ALSO πŸ”₯


ngl the parent being NULL thing is the one detail people forget, so like, don't be that person. πŸ“

and that's the page!! πŸ’– this gem lives in ./drivers/base/power, and the version/date stamp on her is October 2026 β€” so like, yeah, she's from the future, slay. bye bestie, go add some sysfs attributes πŸ§šβ€β™€οΈβœ¨πŸŒΈ

πŸ“¦ where this page comes from