Can't get a higher resolution?

Hi,
I have a display that works fine on Ubuntu, but on FreeBSD I can't get higher resolution, did I miss some thing?
I got X-Windows by following command
Code:
pkg install xorg
pkg install drm-kmod
pkg install xf86-video-intel
on FreeBSD 3121 13.1-RELEASE FreeBSD 13.1-RELEASE releng/13.1-n250148-fc952ac2212 GENERIC amd64
Code:
$ xrandr 
Screen 0: minimum 320 x 200, current 800 x 600, maximum 16384 x 16384
eDP-1 connected primary 800x600+0+0 (normal left inverted right x axis y axis) 530mm x 398mm
   800x600       60.32*+  72.19    75.00    56.25  
   640x480       75.00    72.81    75.00    66.67    59.94  
   720x405       59.51    58.99  
   720x400       70.08  
   640x360       59.84    59.32  
HDMI-1 disconnected (normal left inverted right x axis y axis)
HDMI-2 disconnected (normal left inverted right x axis y axis)
on 5.14.0-1011-oem #11-Ubuntu SMP Mon Dec 13 18:01:14 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
Code:
~$ xrandr Screen 0: minimum 320 x 200, current 4640 x 1080, maximum 16384 x 16384 
eDP-1 connected primary 1920x1080+0+0 (normal left inverted right x axis y axis) 344mm x 193mm   
1920x1080     60.01*+  60.01    59.97    59.96    59.93     
1680x1050     59.95    59.88     
1600x1024     60.17     
1400x1050     59.98     
1600x900      59.99    59.94    59.95    59.82     
1280x1024     60.02     1440x900      59.89     
1400x900      59.96    59.88     
1280x960      60.00     
1440x810      60.00    59.97     
1368x768      59.88    59.85     
1360x768      59.80    59.96     1280x800      59.99    59.97    59.81    59.91     1152x864      60.00     1280x720      60.00    59.99    59.86    59.74     1024x768      60.04    60.00     960x720       60.00     928x696       60.05     896x672       60.01     1024x576      59.95    59.96    59.90    59.82     960x600       59.93    60.00     960x540       59.96    59.99    59.63    59.82     800x600       60.00    60.32    56.25   
....still alot (Sorry for bad format :( )
I try to get EDID from command $ xrandr --verbose , and they are the same on FreeBSD and Ubuntu
Code:
00 FF FF FF FF FF FF 00 4C 26 12 79 01 00 00 00 19 17 01 03 68 12 0A 78 CA CF 74 A3 57 4C B0 23 09 48 4C BF EF 80 81 40 A9 40 D1 C0 01 01 01 01 01 01 01 01 01 01 A0 0F 20 00 31 58 1C 20 28 80 14 00 12 8E 21 00 00 1E 01 1D 00 72 51 D0 1E 20 6E 28 55 00 C4 8E 21 00 00 1E 00 00 00 FC 00 53 45 46 38 30 30 57 4C 0A 20 20 20 20 00 00 00 FD 00 37 4B 1F 4B 07 00 0A 20 20 20 20 20 20 00 AF
Also try add custom resolution but fail.
Code:
$ cvt 1280 720
 # 1280x720 59.86 Hz (CVT 0.92M9) hsync: 44.77 kHz; pclk: 74.50 MHz Modeline "1280x720_60.00"   74.50  1280 1344 1472 1664  720 723 728 748 -hsync +vsync
$ xrandr --newmode "1280x720_60.00"   74.50  1280 1344 1472 1664  720 723 728 748 -hsync +vsync 
$ xrandr --addmode eDP-1 1280x720_60.00 
X Error of failed request:  BadMatch (invalid parameter attributes)  
   Major opcode of failed request:  140 (RANDR)  
   Minor opcode of failed request:  18 (RRAddOutputMode)  
   Serial number of failed request:  30  
   Current serial number in output stream:  31
Here is some info may need.
Code:
$ dmesg -a | grep '\[drm\]' [drm] Unable to create a private tmpfs mount, hugepage support will be disabled(-19).
[drm] Got stolen memory base 0x8e000000, size 0x2000000
drmn0: [drm] Finished loading DMC firmware i915/skl_dmc_ver1_27.bin (v1.27)
[drm] Initialized i915 1.6.0 20200917 for drmn0 on minor 0

$ pkg info -Ig 'drm-*' drm-510-kmod-5.10.113_8        
DRM drivers modules drm-kmod-20220907_1            
Metaport of DRM modules for the linuxkpi-based KMS components

$ pciconf -vl | grep -B3 display 
vgapci0@pci0:0:2:0:    class=0x030000 rev=0x07 hdr=0x00 vendor=0x8086 device=0x1906 subvendor=0x8086 subdevice=0x2015
    vendor     = 'Intel Corporation'
    device     = 'HD Graphics 510'
    class      = display


This question also posts on Discord help desk.
 
Hi SirDice,
I just new to FreeBSD, I am pretty sure after ' pkg install drm-kmod' I didn't do anything else.
How can I enble it? Is this correct?
kldload drm-kmod
 
Start by reading the handbook.

Hi SirDice,
Sorry for the late reply.
I didn't see a way to enable drm-kmod in chapter5, here is what I do .
Code:
sudo sysrc kld_list+="/boot/modules/i915kms.ko"
sudo sysrc -f /etc/rc.conf kld_list+=i915kms # From [URL]https://wiki.freebsd.org/Graphics[/URL]
But also not thing change.
The /etc/rc.conf
Code:
$ cat /etc/rc.conf
hostname="3121"
ifconfig_igb0="DHCP"
ifconfig_igb0_ipv6="inet6 accept_rtadv"
sshd_enable="YES"
dbus_enable="YES"
slim_enable="YES"
# Set dumpdev to "AUTO" to enable crash dumps, "NO" to disable
dumpdev="AUTO"
zfs_enable="YES"
kld_list="acpi_video i915kms /boot/modules/i915kms.ko"

After that I try follow chapter 5.4.5
Code:
sudo vim /etc/make.conf

SYSDIR=/SYS
PORTS_MODULES=graphics/drm-kmod

freebsd-update install
And still the same.
Here is dmesg
Code:
$ dmesg | grep i915
drmn0: successfully loaded firmware image 'i915/skl_dmc_ver1_27.bin'
drmn0: [drm] Finished loading DMC firmware i915/skl_dmc_ver1_27.bin (v1.27)
[drm] Initialized i915 1.6.0 20200917 for drmn0 on minor 0
drmn0: successfully loaded firmware image 'i915/skl_dmc_ver1_27.bin'
drmn0: [drm] Finished loading DMC firmware i915/skl_dmc_ver1_27.bin (v1.27)
[drm] Initialized i915 1.6.0 20200917 for drmn0 on minor 0
 
Code:
kld_list="acpi_video i915kms /boot/modules/i915kms.ko"
Remove that /boot/modules/i915kms.ko, you only need i915kms in there.

Code:
slim_enable="YES"
Remove this one too, at least until you configured X properly. It's easier to test with startx.

Now run startx and see what happens, post /var/log/Xorg.0.log so we can check too; easy way: cat /var/log/Xorg.0.log | nc termbin.com 9999
 
Remove that /boot/modules/i915kms.ko, you only need i915kms in there.

Code:
slim_enable="YES"
Remove this one too, at least until you configured X properly. It's easier to test with startx.

Now run startx and see what happens, post /var/log/Xorg.0.log so we can check too; easy way: cat /var/log/Xorg.0.log | nc termbin.com 9999

wols@3121:~ $ cat /etc/rc.conf
hostname="3121"
ifconfig_igb0="DHCP"
ifconfig_igb0_ipv6="inet6 accept_rtadv"
sshd_enable="YES"
dbus_enable="YES"
# slim_enable="YES"
# Set dumpdev to "AUTO" to enable crash dumps, "NO" to disable
dumpdev="AUTO"
zfs_enable="YES"
kld_list="acpi_video i915kms"
wols@3121:~ $

And here is /var/log/Xorg.0.log , thank you : )
https://termbin.com/rwy8
 
Interesting, if I don't create a conf file explicitly saying to load intel (or nvidia) driver, Xorg loads the modesetting for me (or fails with no driver found).
 
wols@3121:~ $ sudo pkg remove xf86-video-intel
Password:
Checking integrity... done (0 conflicting)
Deinstallation has been requested for the following 1 packages (of 0 packages in the universe):

Installed packages to be REMOVED:
xf86-video-intel: 2.99.917.916_2,1

Number of packages to be removed: 1

The operation will free 2 MiB.

Proceed with deinstalling packages? [y/N]: y
[1/1] Deinstalling xf86-video-intel-2.99.917.916_2,1...
[1/1] Deleting files for xf86-video-intel-2.99.917.916_2,1: 100%
Thanks !! It's works now.

But I have to startx manually, I think I can put it into boot up script : )
<< This is due to # slim_enable="YES"
=================================
OK, So here is how I fix the black bar.
xrandr --output eDP-1 --set 'scaling mode' 'Full'

After that I got a black bar on my screen, is more like a monitor issue, is it?

17561248052329.jpg
 
Back
Top