Cannot change resolution in Ubuntu 22.04

I have an ASUS ROG STRIX with AMD Ryzen9, Nvidia Geforce RTX 4060, kernel 6.5.0-14.14~22.04.1; I am using the NVIDIA driver metapackage from nvidia-driver-535 (proprietary,tested). The default resolution is 2560x1440 (16:9) but with this resolution everything is too small, and I would like to change to 1920x1080. I changed the resolution months ago and it worked, but some days ago I turned on the pc and the screen looked like this:


After a while I managed to figure out that the only way to see the screen again was to set it to the default resolution.
Anyone knows how to fix it?
Thanks

kernel/amdgpu issue:
https://forums.developer.nvidia.com/t/black-screen-issue-after-ubuntu-update-on-laptop-running-ubuntu-22-04-1-lts-with-geforce-rtx-3050-ti-graphics-card/279677/2?u=generix

Thanks. I followed what you said in the linked post, but with kernel 6.2 the wifi did not work (that’s why I switched to kernel 6.5) and the resolution was not selectionable. So i tried with a newer kernel (6.7) and the problem to the pc screen looks solved…but now the second monitor does not work, it is not even recognized when connected. After upgrading to kernel 6.7, I noticed that I don’t have the nvidia-driver-535 (proprietary, tested) anymore…it says only proprietary (the “tested” disappeared). I tried to upgrade to 545 and also to go back to 525, but none of them worked. They are both not-tested.

I suspect you installed the kernel from the mainline repo? That has an incompatible header package so the nvidia driver doesn’t compile. Please uninstall the 6.7 kernel packages and use the liquorix ppa instead.

Yeah, using liquorix solved the problem. Thank you!