drmAvailable(3)
π drmAvailable(3) β a Direct Rendering Manager moment β¨
okay so bestie, this one's from the Direct Rendering Manager section of the manual (yes, that's the manual name, we're folding it in here so it doesn't get lost π) and it's genuinely one of the shortest little guys in the whole libdrm lineup. which honestly? iconic. lowkey a snack. let's get into it π
β¨ NAME β¨
drmAvailable β the function that tells you whether a DRM kernel driver has been loaded π
π¦ SYNOPSIS π¦
#include <xf86drm.h>
int drmAvailable(void);
that's it. that's the whole vibe. no arguments, no drama, just a function with <kbd>void</kbd> energy π«Ά (no really, it takes void β it wants nothing from you, main character behaviour fr fr)
πΈ DESCRIPTION πΈ
okay so here's the tea β: drmAvailable lets the caller determine whether a kernel DRM driver is loaded. that's literally the whole job. you call it, it does a vibe check on the kernel, and it tells you what's up β¨
no cap, that's the entire description. sometimes a girl just has one task and she does it flawlessly π
β RETURN VALUE β
1β a DRM driver is currently loaded π slay, we're so back0β otherwise. no driver loaded, we're giving "nobody's home" energy π
so like, it's a yes/no girlie. 1 means loaded, 0 means not. don't overthink it π
π REPORTING BUGS π
found a bug in this function? bestie, do not suffer in silence π β bugs in this function should be reported to:
https://gitlab.freedesktop.org/mesa/libdrm/-/issues
go tell the maintainers, they wanna know, i promise π«Ά
π SEE ALSO π
drm(7)drmOpen(3)
like, go read those too if you're doing a whole DRM deep dive π¦ iykyk
heads up bestie: everything above is straight from the manpage, i'm just the hype woman π don't come for me if your kernel has opinions β this function only reports, it doesn't fix β¨
and that's a wrap π¬ this page is brought to you by the libdrm girlies, dated September 2012 (yes she's been serving this look since 2012 and she's still iconic π), in Direct Rendering Manager section 3 of the manual. periodt π πΈ
π¦ where this page comes from
- arch rolling: libdrm 2.4.134-1 Β· MIT
- fedora 44: libdrm-devel 2.4.131-1.fc44 Β· MIT
- fedora 44: libdrm-devel 2.4.131-1.fc44 Β· MIT
- fedora 44: libdrm-devel 2.4.134-1.fc44 Β· MIT
- fedora 44: libdrm-devel 2.4.134-1.fc44 Β· MIT
- nixos 26.05: libdrm 2.4.133
- ubuntu resolute: libdrm-dev 2.4.131-1 Β· MIT
- ubuntu stonking: libdrm-dev 2.4.134-3 Β· MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms