It's a bit of a "fallback" mechanism in systemd, and so few upstream packages (if any) make use of that directory, and in any case, the first one to use it would be the one to create it.
That's pretty standard in installation scripts. The Makefile from that out-of-kernel module actually does that for the module directory, but forgoes to do it for the system-sleep directory. Well. So, go into your Makefile and change
install:
@mkdir -p $(MODDESTDIR)realtek/rtw89/
install -p -m 644 $(MODULE_NAME).ko $(MODDESTDIR)realtek/rtw89/
/sbin/depmod -a ${KVER}
@cp suspend_rtw8852au /usr/lib/systemd/system-sleep/.
uninstall:
rm -f $(MODDESTDIR)realtek/rtw89/$(MODULE_NAME).ko
/sbin/depmod -a ${KVER}
to
# Bad style:
# should require the module to be built first
# and should update if you change the suspend script
install: $(MODULE_NAME).ko suspend_rtw8852au
@mkdir -p $(MODDESTDIR)realtek/rtw89/
install -p -m 644 $(MODULE_NAME).ko $(MODDESTDIR)realtek/rtw89/
/sbin/depmod -a ${KVER}
@mkdir -p /usr/lib/systemd/system-sleep
install -m 644 suspend_rtw8852au /usr/lib/systemd/system-sleep/.
# Forgot to uninstall the suspend script
uninstall:
rm -f $(MODDESTDIR)realtek/rtw89/$(MODULE_NAME).ko
/sbin/depmod -a ${KVER}
rm -f /usr/lib/systemd/system-sleep/suspend_rtw8852au
(when changing, make sure to use Tabs, not spaces, for the indents here – make is very particular on these. It has to be tabulator indents!)
(There's more things that aren't good about that Makefile – it's incorrect about the targets that are phony etc., the actual build targets don't depend on the source files, and whatever the developer thought when he wrote the clean: target – but let's not fix these in a Stack Exchange post.)
ip link. Debian 13 currently uses kernel version 6.12. Do you mean I should just be able to use the adapter directly after connecting it to the computer with no additional installation or configuration?find /lib/firmware/ -iname '*8852au*'finds two files in/lib/firmware/rtl_btbut not in/lib/firmware/rtlwifi. I also tried uninstalling the github driver and restarting the computer but then no WiFi interface showed up when runningip link.