Section "Screen"
Identifier "Screen1"
Device "Card1"
Monitor "Monitor1"
SubSection "Display"
Viewport 0 0
Depth 1
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 4
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 8
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 15
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 16
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 24
EndSubSection
EndSection
I spend and hour of two to test whatever I could run in 13.1 Release.
Two graphics cards: amdgpu and intel.
I couldn't get anything except two separate screens (so, u have to run 'two' window managers - tried with openbox and It was working fine),
or Xinerama - tried that with openbox and KDE, but couldn't really configure anything in KDE as randr is disabled because of xinerama.
Ziomario I will now write slow so u can read it whole.
What I have added to /etc/rc.conf:
without that I couldn't even get text console on intel gpu (even if it was set as boot card in bios).Code:kld_list="amdgpu i915kms"
now the /usr/local/etc/X11/xorg.conf.d/xorg.conf:
Code:Section "ServerLayout" Identifier "layout" Screen 0 "intel" Screen 1 "amdgpu" # Screen "amdgpu" LeftOf "intel" #Option "Xinerama" "1" EndSection Section "Device" Identifier "amdgpu" Driver "amdgpu" BusID "3@0:0:0" #replace with information from lspci -v EndSection Section "Screen" Identifier "amdgpu" Device "amdgpu" Option "AllowEmptyInitialConfiguration" EndSection Section "Device" Identifier "intel" BusID "0@0:2:0" #same as above lspci -v Driver "intel" EndSection Section "Screen" Identifier "intel" Device "intel" EndSection
Just by uncommenting Xinerama line you can get both screens acting like one desktop, but with limitations like no acceleration, no randr etc.
You can try to replace amdgpu with nvidia, and it could possibly work the same.
I was just using search site, and some linux howto's. I can bet this config could be even simpler and had working without forcing xinerama but require linux.
This topic isn't really FreeBSD specific, and there is lots of Linux howto's on how to setup multihead multimonitor Xorg on the internets.
PS. if you want to run for example double window managers on separate screens, just do in your .xinitrc:
Nothing really amazing but at least you can start from here and customise this to your liking.Code:DISPLAY=:0.0 exec openbox-session & DISPLAY=:0.1 exec openbox-session
Let's recap ? :
Code:/etc/rc.conf : kld_list="nvidia nvidia-modeset" /boot/loader.conf nothing related to the gpu /etc/X11/ no conf files. /usr/local/etc/X11/xorg.conf.d/gedit 40-card0-intel.conf # Intel gpu Section "Device" Identifier "Card0" Option "DPMS" Driver "intel" BusID "PCI:0:2:0" EndSection /usr/local/etc/X11/xorg.conf.d/gedit 40-card1-nvidia.conf # Nvidia gpu Section "Device" Identifier "Card1" Option "DPMS" Driver "nvidia" BusID "PCI:2:0:0" EndSection
/var/log/Xorg.0.log :
Ubuntu Pastebin
pastebin.ubuntu.com
result : the monitor attached to the nvidia gpu is turned off and the mouse can't across over it.
Using the first device section listed.
[ 68.520] (**) | |-->Device "Card0"
[ 68.520] (**) | |-->GPUDevice "Card1"
To use the NVIDIA driver as an RandR 1.4 output source provider, the X server needs to be configured to use the NVIDIA driver for its primary screen and to use the “modesetting” driver for the other graphics device.
Section "ServerLayout"
Identifier "layout"
Screen 0 "nvidia"
Inactive "intel"
EndSection
Section "Device"
Identifier "nvidia"
Driver "nvidia"
BusID "PCI:2:0:0" #1060
EndSection
Section "Screen"
Identifier "nvidia"
Device "nvidia"
Option "AllowEmptyInitialConfiguration"
EndSection
Section "Device"
Identifier "intel"
Driver "modesetting"
EndSection
Section "Screen"
Identifier "intel"
Device "intel"
EndSection
Section "ServerLayout"
Identifier "layout"
Screen 0 "iGPU"
Option "AllowNVIDIAGPUScreens"
EndSection
Section "Device"
Identifier "iGPU"
Driver "modesetting"
BusID "PCI:0:2:0" #intel gpu
EndSection
Section "Screen"
Identifier "iGPU"
Device "iGPU"
EndSection
Section "Device"
Identifier "dGPU"
Driver "nvidia"
BusID "PCI:2:0:0" #1060
EndSection
-----> What also might be worth to give it a shot is to make the NVIDIA primary and the Intel secondary. From what I got what you are looking for the order of the two cards doesn't matter to you as long as one screen is directed by the Intel device and the other one by the NVIDIA GPU.
I'm not sure that I can do this. I think I have only 1 option to try :
a) Intel gpu as primary,nvidia 1060 as offloading graphic display,2080 ti kept free to be passed in bhyve
because yesterday I've ascertained that my BIOS accept only :
-) intel gpu as primary
-) 2080 ti as primary
I don't know why but the 1060 is not accepted as primary gpu. It is not detected at all. So,keeping in consideration that I can't choose the 2080 ti as primary,because if I do this I can't pass it to a guest os virtualized with bhyve,I can only use the intel gpu as primary.
pciconf -vl
vgapci2@pci0:0:2:0: class=0x030000 rev=0x02 hdr=0x00 vendor=0x8086 device=0x3e98 subvendor=0x1458 subdevice=0xd000
vendor = 'Intel Corporation'
device = 'CoffeeLake-S GT2 [UHD Graphics 630]'
class = display
subclass = VGA
vgapci0@pci0:1:0:0: class=0x030000 rev=0xa1 hdr=0x00 vendor=0x10de device=0x1e04 subvendor=0x19da subdevice=0x2503
vendor = 'NVIDIA Corporation'
device = 'TU102 [GeForce RTX 2080 Ti]'
class = display
subclass = VGA
vgapci1@pci0:2:0:0: class=0x030000 rev=0xa1 hdr=0x00 vendor=0x10de device=0x1c02 subvendor=0x19da subdevice=0x2438
vendor = 'NVIDIA Corporation'
device = 'GP106 [GeForce GTX 1060 3GB]'
class = display
subclass = VGA
Can you please post the output of the following commands:
Code:
# prints, if your intel gpu has been proper detected by the kernel module
dmesg | grep drm
# prints gpu device handler have been created
ls -l /dev/dri
# prints the packages the fils belong to
pkg which /usr/local/lib/xorg/modules/drivers/modesetting_drv.so
pkg which /usr/local/lib/xorg/modules/drivers/intel_drv.so
# prints all installed packages which contain the word video
pkg info | grep video
# prints all installed nvidia driver
pkg info | grep nvidia
# prints who is part of the video group
getent group video
# print loaded kernel modules
kldstat
Just read again the whole thread and came across post of yours (#23), which to me looks like we are on the right track. The configuration mentioned in #23 is the same which you got right now. The difference is, that the 1060 is plugged in as well and is being detected by X as "GPUDevice", where the 2080 had been detected as usual "Device" according to the Xorg.0.log posted in #23.I think that I'm on the right track. I've modified the xorg.conf file like this :
Code:Section "Device" Identifier "Card0" Driver "intel" BusID "PCI:0:2:0" EndSection Section "Device" Identifier "Card1" Driver "nvidia" BusID "PCI:2:0:0" EndSection
and now the monitor 2 is turned on and I can see the mouse pointer that can go on that monitor,BUT there is nothing inside of it,it is totally black. Any idea why is empty and black ? This is the new log file :
Ubuntu Pastebin
pastebin.ubuntu.com
Just read again the whole thread and came across post of yours (#23), which to me looks like we are on the right track. The configuration mentioned in #23 is the same which you got right now. The difference is, that the 1060 is plugged in as well and is being detected by X as "GPUDevice", where the 2080 had been detected as usual "Device" according to the Xorg.0.log posted in #23.
set DISPLAY=:0.1 exec ck-launch-session dbus-launch --exit-with-session startplasma-x11
Section "Device"
Identifier "Card0"
Driver "intel"
BusID "PCI:0:2:0"
EndSection
Section "Device"
Identifier "Card1"
Driver "nvidia"
BusID "PCI:2:0:0" #nvidia gtx 1060
EndSection
# dmesg | grep drm
drmn2: <drmn> on vgapci2
vgapci2: child drmn2 requested pci_enable_io
vgapci2: child drmn2 requested pci_enable_io
[drm] Unable to create a private tmpfs mount, hugepage support will be disabled(-19).
[drm] Got stolen memory base 0x3b800000, size 0x4000000
[drm] Supports vblank timestamp caching Rev 2 (21.10.2013).
[drm] Driver supports precise vblank timestamp query.
[drm] Connector eDP-1: get mode from tunables:
[drm] - kern.vt.fb.modes.eDP-1
[drm] - kern.vt.fb.default_mode
drmn2: successfully loaded firmware image 'i915/kbl_dmc_ver1_04.bin'
[drm] Finished loading DMC firmware i915/kbl_dmc_ver1_04.bin (v1.4)
[drm] failed to retrieve link info, disabling eDP
[drm] Connector HDMI-A-1: get mode from tunables:
[drm] - kern.vt.fb.modes.HDMI-A-1
[drm] - kern.vt.fb.default_mode
drmn2: Failed to program MOCS registers; expect performance issues.
[drm] Initialized i915 1.6.0 20190822 for drmn2 on minor 0
name=drmn2 flags=0x0 stride=7680 bpp=32
drmn2: fb0: i915drmfb frame buffer device
# ls -l /dev/dri
total 0
lrwxr-xr-x 1 root wheel 8 Jul 23 22:24 card0 -> ../drm/0
lrwxr-xr-x 1 root wheel 10 Jul 23 22:24 renderD128 -> ../drm/128
# pkg which /usr/local/lib/xorg/modules/drivers/modesetting_drv.so
/usr/local/lib/xorg/modules/drivers/modesetting_drv.so was installed by package xorg-server-1.20.14,1
# pkg which /usr/local/lib/xorg/modules/drivers/intel_drv.so
/usr/local/lib/xorg/modules/drivers/intel_drv.so was installed by package xf86-video-intel-2.99.917.916_1,1
# pkg info | grep video
emby-server-4.7.5.0 Media server to organize, play & stream audio/video to various devices
ffmpeg-4.4.2_5,1 Realtime audio/video encoder/converter and streaming server
ffmpegthumbnailer-2.2.2 Lightweight video thumbnailer that can be used by file managers
frei0r-1.8.0 Minimalistic plugin API for video effects
gavl-1.4.0_4 Library for handling uncompressed video and audio data
gstreamer1-libav-1.16.2 GStreamer plug-in with many audio/video decoders/encoders
gstreamer1-plugins-core-1.16 Core set of typical audio and video GStreamer plugins
intel-media-sdk-22.4.3 Hardware video decoding/encoding/filtering on Intel GPUs
kdemultimedia-ffmpegthumbs-22.04.3 FFmpeg-based thumbnail generator for video files
libde265-1.0.8 Open source h.265 video codec
libtheora-1.1.1_7 Theora video codec for the Ogg multimedia streaming system
movit-1.6.3 High-performance video filters for the GPU
qt5-multimedia-5.15.5p1 Qt audio, video, radio and camera support module (KDE patched)
simplescreenrecorder-0.4.4 Screen video recorder
vmaf-2.3.1 Perceptual video quality assessment based on multi-method fusion
xf86-video-intel-2.99.917.916_1,1 X.Org legacy driver for Intel integrated graphics chipsets
xf86-video-vmware-13.3.0_6 X.Org vmware display driver
# pkg info | grep nvidia
linux-nvidia-libs-510.60.02 NVidia graphics libraries and programs (Linux version)
nvidia-driver-510.60.02 NVidia graphics card binary drivers for hardware OpenGL rendering
nvidia-settings-470.86 Display Control Panel for X NVidia driver
# getent group video
video:*:44:marietto
# kldstat
Id Refs Address Size Name
1 137 0xffffffff80200000 1f30590 kernel
2 2 0xffffffff82131000 82b0 bridgestp.ko
3 1 0xffffffff8213a000 40f8 nmdm.ko
4 1 0xffffffff8213f000 29d28 fusefs.ko
5 3 0xffffffff82169000 929d8 vboxdrv.ko
6 1 0xffffffff821fc000 feb0 if_bridge.ko
7 1 0xffffffff8220c000 5ec1d8 zfs.ko
9 1 0xffffffff8280f000 5848b8 vmm.ko
10 1 0xffffffff82d94000 af68 cryptodev.ko
11 1 0xffffffff83210000 639c linprocfs.ko
12 6 0xffffffff83217000 10ab0 linux_common.ko
13 1 0xffffffff83228000 3284 linsysfs.ko
14 1 0xffffffff8322c000 9ea0 tmpfs.ko
15 1 0xffffffff83236000 3530 fdescfs.ko
16 2 0xffffffff8323a000 4240 vboxnetflt.ko
17 2 0xffffffff8323f000 aac8 netgraph.ko
18 1 0xffffffff8324a000 31c8 ng_ether.ko
19 1 0xffffffff8324e000 55e0 vboxnetadp.ko
20 1 0xffffffff83254000 2220 cpuctl.ko
21 1 0xffffffff83257000 fd310 nvidia-modeset.ko
22 1 0xffffffff83400000 2354ab8 nvidia.ko
23 2 0xffffffff83355000 38070 linux.ko
24 1 0xffffffff8338e000 3378 acpi_wmi.ko
25 1 0xffffffff83392000 3250 ichsmb.ko
26 1 0xffffffff83396000 2180 smbus.ko
27 1 0xffffffff83399000 2110 pchtherm.ko
28 1 0xffffffff8339c000 e538 snd_uaudio.ko
29 1 0xffffffff833ab000 2340 uhid.ko
30 1 0xffffffff833ae000 3380 usbhid.ko
31 1 0xffffffff833b2000 31f8 hidbus.ko
32 1 0xffffffff833b6000 3320 wmt.ko
33 1 0xffffffff833ba000 4350 ums.ko
34 1 0xffffffff833bf000 32208 linux64.ko
35 1 0xffffffff833f2000 2260 pty.ko
36 1 0xffffffff833f5000 4700 nullfs.ko
37 1 0xffffffff833fa000 2a08 mac_ntpd.ko
38 1 0xffffffff85755000 158438 i915kms.ko
39 1 0xffffffff858ae000 7f020 drm.ko
40 2 0xffffffff8592e000 cbc8 linuxkpi_gplv2.ko
# xrandr -q
Screen 0: minimum 320 x 200, current 1920 x 1080, maximum 16384 x 16384
HDMI-1 connected 1920x1080+0+0 (normal left inverted right x axis y axis) 598mm x 336mm
1920x1080 60.00*+ 50.00 59.94
1920x1080i 60.00 50.00 59.94
1680x1050 59.88
1280x1024 75.02 60.02
1440x900 59.90
1280x960 60.00
1280x720 60.00 50.00 59.94
1024x768 75.03 70.07 60.00
832x624 74.55
800x600 72.19 75.00 60.32 56.25
720x576 50.00
720x480 60.00 59.94
640x480 75.00 72.81 66.67 60.00 59.94