

I’ve created a small helper script to help me with this:
#!/bin/bash
USED_VER=$(uname -r)
echo "Kernel version in use: $USED_VER"
echo "Other installed versions:"
dpkg --list 'linux-image*' | grep ^ii | grep -v $USED_VER
echo "Remove unneeded packages above using the following command:"
echo "sudo apt remove linux-image-VERSION"
It prints a list of the installed kernels (excl. the running one) and prints the command to uninstall the packages (it doesn’t remove anything by itself).
Unfortunately, the former is not possible due to asinine requirements by the HDMI Forum: https://www.phoronix.com/news/HDMI-2.1-OSS-Rejected The only option is to use DisplayPort instead (or perhaps an adapter).