Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
1024x768 aspect ratio gets stretched across 2560x1080 screen
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
kabirbg
n00b
n00b


Joined: 30 Jun 2022
Posts: 5

PostPosted: Thu Jun 30, 2022 9:18 pm    Post subject: 1024x768 aspect ratio gets stretched across 2560x1080 screen Reply with quote

Hi all,

New gentoo user here. I have a 2560x1080 ultrawide (21:9) display, something that is cool to look at but has given me a lot of headache getting set up with Xorg! I am using bspwm and the gentoo dist kernel (not my own configuration). Running xrandr gives me:

Code:
xrandr: Failed to get size of gamma for output default
Screen 0: minimum 1024 x 768, current 1024 x 768, maximum 1024 x 768
default connected 1024x768+0+0 0mm x 0mm
   1024x768      76.00*


I cannot add a new resolution or change the resolution using xrandr. I have looked all around and found various solutions on the internet, but none of them worked for me. It says Screen 0 only supports 1024 x 768, but in reality the physical monitor supports much higher resolutions.

I'm using Intel integrated graphics (Intel UHD 770, Alder Lake, if that helps); I set VIDEO_CARDS="intel" in my /etc/portage/make.conf. Do I need to add i915, fbdev and/or vesa? I tried adding them and removing but it made no difference (unless rebuilding xorg-server is not the right course of action and it's some other ebuild that uses the VIDEO_CARDS option).

Any help would be much appreciated!
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54214
Location: 56N 3W

PostPosted: Thu Jun 30, 2022 10:09 pm    Post subject: Reply with quote

kabirbg,

Welcome to Gentoo.

Use wgetpaste to share the output of the dmesg command and your Xorg.0.log.
That will show what the kernel and Xorg did as they started.
It sounds like you are using the wrong video driver for your hardware but the logs will help.

Code:
emerge -N @world
will rebuild everything affected by a USE flag change.
You would want xorg-drivers, mesa and libdrm.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
kabirbg
n00b
n00b


Joined: 30 Jun 2022
Posts: 5

PostPosted: Thu Jun 30, 2022 11:51 pm    Post subject: Reply with quote

Thank you so much!

dmesg output: http://0x0.st/oSFx.txt

Xorg.0.log: http://0x0.st/oSF3.log
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54214
Location: 56N 3W

PostPosted: Fri Jul 01, 2022 7:26 am    Post subject: Reply with quote

kabirbg,

Code:
[   860.526] (==) Matched intel as autoconfigured driver 0
[   860.526] (==) Matched modesetting as autoconfigured driver 1
[   860.526] (==) Matched fbdev as autoconfigured driver 2
[   860.526] (==) Matched vesa as autoconfigured driver 3

Good. The auto detect did its thing and says that the intel driver is best for you.

Code:
[   860.526] (==) Assigned the driver to the xf86ConfigLayout
[   860.526] (II) LoadModule: "intel"
[   860.526] (WW) Warning, couldn't open module intel
but its not built.
Code:
emerge -1av xorg-drivers mesa
and checx the VIDEO_CARDS intel is not shown is green with an *.
If it is, run the emerge to build intel support. If its Red, you have it.

Code:
[   860.527] (II) modesetting: Driver for Modesetting Kernel Drivers: kms
[   860.527] (EE) open /dev/dri/card0: No such file or directory

Your kernel is missing kernel modesetting support. That's a kernel rebuild.
You need DRI support and i915 support.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
kabirbg
n00b
n00b


Joined: 30 Jun 2022
Posts: 5

PostPosted: Fri Jul 01, 2022 4:41 pm    Post subject: Reply with quote

Hi,

It's showing VIDEO_CARDS="intel" in red for both xorg-drivers and mesa.

I see, I'll have to rebuild the kernel... I'm using a distkernel though, so I assumed that would have KMS built in. Does this mean I have to configure my own kernel and not use the distkernel, or is there another route? (The reason I am iffy about this is because when I tried configuring my own, I got an unbootable system, whereas the distkernel worked perfectly for me and so I felt like I would do something wrong if I tried to manually configure...)
--------
EDIT: I read the wiki article and I can just add a one-line config change still using the dist-kernel. Which is perfect. So I'll try that and let you know!

Thank you so much!!
Back to top
View user's profile Send private message
kabirbg
n00b
n00b


Joined: 30 Jun 2022
Posts: 5

PostPosted: Sun Jul 03, 2022 2:05 am    Post subject: Reply with quote

Hi NeddySeagoon,

I applied your changes (specifically, adding a file in /etc/kernel/config.d to set CONFIG_DRM=y and CONFIG_DRM_I915=y), but the result is the same. In the Xorg log, it is the same as before (intel, vesa or fbdev could not be loaded) except that modesetting is loaded, but open /dev/dri/card0 still fails.

Are there other config options I need enable as well?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum