rt_mutex_lock_interruptible(9)
π NAME π
rt_mutex_lock_interruptible β bestie, this is the one that locks a rt_mutex, and it's interruptible about it β¨
So like, it's in the Kernel API Manual <pink>rt_mutex_lock_interruptible(9)</pink> β okay that's the whole title, putting it right up here so we don't lose it π
πΈ SYNOPSIS πΈ
int rt_mutex_lock_interruptible (struct rt_mutex *lock );
That's the whole vibe: it returns an int and it takes exactly one thing β a pointer to a struct rt_mutex β and honestly? icon behaviour π
π¦ ARGUMENTS π¦
lockβ thert_mutexthat's about to get locked. like, that's it, that's the whole parameter. it's the mutex bestie. the mutex in question. the one getting locked. no cap π«Ά
β RETURN β
okay so here's the vibe check on what comes back:
0β we won, it worked, success, slay π-EINTRβ this is what you get when the whole thing got interrupted by a signal π like the wait got cut short, nothing you did wrong, just signals being signals fr fr
heads up: it genuinely returns either0or-EINTR, and-EINTRspecifically means "interrupted by a signal" β that's the literal documented meaning, no extra lore, iykyk π
π§ SEE ALSO π§
the whole friend group π these are all in the kernel file ./kernel/locking/rtmutex_api.c and you should lowkey go meet all of them:
rt_mutex_lock_nested(9)rt_mutex_lock(9)rt_mutex_lock_killable(9)rt_mutex_trylock(9)rt_mutex_unlock(9)__rt_mutex_futex_unlock(9)__rt_mutex_init(9)rt_mutex_init_proxy_locked(9)rt_mutex_proxy_unlock(9)__rt_mutex_start_proxy_lock(9)rt_mutex_start_proxy_lock(9)rt_mutex_wait_proxy_lock(9)rt_mutex_cleanup_proxy_lock(9)
like a full roster, we love a complete cast π the double-underscore ones are giving "internal but still invited to the party" energy ngl π₯
and that's the page!! mwah π this came to you from ./kernel/locking, dated October 2026 β that's the source/version and the date, both of which I was absolutely not going to forget because forgetting details is not the move πβ¨
π¦ 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