Zend certified PHP/Magento developer

Xorg turns laptop screen off on startup on Gentoo

I am having a problem with my Gentoo installation (binary kernel) where Xorg only turns off my laptop’s screen when using Startx, and I can only change TTY to use Gentoo but only on CLI.

This happened after following steps shown on Nvidia Optimus wiki page and rebooting.
Thankfully I have a Windows partition (From where I am asking for help)

  • I have tried many solutions including:
  • Forcing drivers to load Intel first.
  • Loading Nvidia Module with DRM and Modeset.
  • Using
    Xrandr but it didn’t wanna work even with export DISPLAY=:0 because
    of Authentication stuff.
  • Adding the Xrandr commands to SDDM script at boot
  • Changing from SDDM to LightDM

I am really desperate for a solution so if anyone can give me advice or guidance it would be appreciated.

My hardware is as follows:

  • Intel(R) Core(TM) i5-10300H CPU
  • Nvidia GeForce GTX 1650 GPU
  • 8 GB of RAM
  • Binary Kernel