[prev in list] [next in list] [prev in thread] [next in thread] 

List:       freedesktop-xorg
Subject:    xrandr can not set crtc problem
From:       XSign <evilsign () gmail ! com>
Date:       2019-09-25 13:41:49
Message-ID: CAAWPMdBXnPBqSWsjX0jM7c2fX35KTa5TCnUoe6HeqW8cBW-G0A () mail ! gmail ! com
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


Hi guys,

I'v configured my Xorg to use both intel & nvidia card on my laptop.

And I also have a dock with my Thinkpad T470.

When I disconnected the laptop from dock then connect the laptop to the
dock again, the secondary monitor can not light-up.

There is an error with /var/log/Xorg.0.log :

```
[   152.296] (II) modeset(0): Allocate new frame buffer 3840x1080 stride
[   152.339] (EE) modeset(0): failed to set mode: Invalid argument
[   152.692] (II) modeset(0): Allocate new frame buffer 1920x1080 stride
```

3480 is just equal to my 2 monitors width (each 1920, 1920 x 2 = 3480)

And if I try to use xrandr to active the secondary monitor, there is an
error too:

```
>> xrandr --output DP-2-1 --mode '1920x1080' --right-of eDP-1 --verbose
screen 0: 3840x1080 814x229 mm 119.79dpi
crtc 1:    1920x1080  60.00 +1920+0 "DP-2-1"
xrandr: Configure crtc 1 failed
crtc 0: disable
crtc 1: disable
crtc 2: disable
screen 0: revert
crtc 0: revert
crtc 1: revert
crtc 2: revert
```

It seems I didn't configure my screen correctly, is there anyone knows how
to fix this problem ?

Below is my Xorg's monitor configuration:

```
Section "ServerLayout"
Identifier "layout"
Screen 0 "iGPU"
Option "AllowNVIDIAGPUScreens"
EndSection

Section "Device"
Identifier "iGPU"
Driver "modesetting"
BusID "PCI:0:2:0"
Option "PrimaryGPU" "yes"
Option      "monitor-eDP-1" "LaptopMonitor"
Option      "monitor-DP-2-1" "CompanyMonitor"
EndSection
Section "Screen"
Identifier "iGPU"
Device "iGPU"
EndSection
Section "Device"
Identifier "dGPU"
Driver "nvidia"
Option "AllowEmptyInitialConfiguration" "true"
EndSection
Section "Monitor"
Identifier "LaptopMonitor"
#DisplaySize 541 304
DisplaySize 406 229
Option "Primary" "true"
Option "DPMS"
EndSection
Section "Monitor"
Identifier "CompanyMonitor"
#DisplaySize 508 285
DisplaySize 406 229
Option "DPMS"
Option "LeftOf" "LaptopMonitor"
EndSection
```

[Attachment #5 (text/html)]

<div dir="ltr"><div>Hi guys,</div><div><br></div><div>I&#39;v configured my Xorg to \
use both intel &amp; nvidia card on my laptop.</div><div><br></div><div>And I also \
have a dock with my Thinkpad T470.</div><div><br></div><div>When I disconnected the \
laptop from dock then connect the laptop to the dock again, the secondary monitor can \
not light-up.</div><div><br></div><div>There is an error with /var/log/Xorg.0.log \
:</div><div><br></div><div>```<br></div><div>[    152.296] (II) modeset(0): Allocate \
new frame buffer 3840x1080 stride<br>[    152.339] (EE) modeset(0): failed to set \
mode: Invalid argument<br>[    152.692] (II) modeset(0): Allocate new frame buffer \
1920x1080 stride</div><div>```</div><div><br></div><div>3480 is just equal to my 2 \
monitors width (each 1920, 1920 x 2 = 3480) <br></div><div><br></div><div>And if I \
try to use xrandr to active the secondary monitor, there is an error \
too:</div><div><br></div><div>```</div><div>&gt;&gt; xrandr --output DP-2-1 --mode \
&#39;1920x1080&#39; --right-of eDP-1 --verbose<br>screen 0: 3840x1080 814x229 mm \
119.79dpi<br>crtc 1:      1920x1080   60.00 +1920+0 &quot;DP-2-1&quot;<br>xrandr: \
Configure crtc 1 failed<br>crtc 0: disable<br>crtc 1: disable<br>crtc 2: \
disable<br>screen 0: revert<br>crtc 0: revert<br>crtc 1: revert<br>crtc 2: \
revert<br></div><div>```</div><div><br></div><div>It seems I didn&#39;t configure my \
screen correctly, is there anyone knows how to fix this problem \
?</div><div><br></div><div>Below is my Xorg&#39;s monitor \
configuration:</div><div><br></div><div>```</div><div>Section \
&quot;ServerLayout&quot;<br>	Identifier &quot;layout&quot;<br>	Screen 0 \
&quot;iGPU&quot;<br>	Option \
&quot;AllowNVIDIAGPUScreens&quot;<br>EndSection<br><br>Section \
&quot;Device&quot;<br>	Identifier &quot;iGPU&quot;<br>	Driver \
&quot;modesetting&quot;<br>	BusID &quot;PCI:0:2:0&quot;<br>	Option \
&quot;PrimaryGPU&quot; &quot;yes&quot;<br>	Option         &quot;monitor-eDP-1&quot; \
&quot;LaptopMonitor&quot;<br>	Option         &quot;monitor-DP-2-1&quot; \
&quot;CompanyMonitor&quot;<br>EndSection<br>Section &quot;Screen&quot;<br>	Identifier \
&quot;iGPU&quot;<br>	Device &quot;iGPU&quot;<br>EndSection<br>Section \
&quot;Device&quot;<br>	Identifier &quot;dGPU&quot;<br>	Driver \
&quot;nvidia&quot;<br>	Option &quot;AllowEmptyInitialConfiguration&quot; \
&quot;true&quot;<br>EndSection<br>Section &quot;Monitor&quot;<br>	Identifier \
&quot;LaptopMonitor&quot;<br>	#DisplaySize 541 304<br>	DisplaySize 406 229<br>	Option \
&quot;Primary&quot; &quot;true&quot;<br>	Option		 \
&quot;DPMS&quot;<br>EndSection<br>Section &quot;Monitor&quot;<br>	Identifier \
&quot;CompanyMonitor&quot;<br>	#DisplaySize 508 285<br>	DisplaySize 406 \
229<br>	Option		 &quot;DPMS&quot;<br>	Option		 &quot;LeftOf&quot; \
&quot;LaptopMonitor&quot;<br>EndSection<br></div><div>```<br></div></div>


[Attachment #6 (text/plain)]

_______________________________________________
xorg@lists.x.org: X.Org support
Archives: http://lists.freedesktop.org/archives/xorg
Info: https://lists.x.org/mailman/listinfo/xorg
Your subscription address: %(user_address)s

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic