You are not logged in.

#1 2023-01-15 00:09:55

hematinik
Member
Registered: 2022-03-23
Posts: 34

[SOLVED] Forcing X server to only support monitor's native resolution

What Im trying to achieve is to change the output of `xrandr --q1` from this:

 SZ:    Pixels          Physical       Refresh
*0   1920 x 1080   ( 372mm x 207mm )  *50   52  
 1   1920 x 1200   ( 372mm x 230mm )   51  
 2   1680 x 1050   ( 325mm x 202mm )   53  
 3   1600 x 1200   ( 310mm x 230mm )   54  
 4   1440 x 900    ( 279mm x 173mm )   55  
 5   1366 x 768    ( 264mm x 147mm )   56  
 6   1280 x 1024   ( 248mm x 197mm )   57  
 7   1280 x 800    ( 248mm x 153mm )   58  
 8   1280 x 720    ( 248mm x 138mm )   59  
 9   1024 x 768    ( 198mm x 147mm )   60  
 10   800 x 600    ( 155mm x 115mm )   61  
 11   640 x 480    ( 124mm x  92mm )   62  
Current rotation - normal
Current reflection - none
Rotations possible - normal left inverted right 
Reflections possible - X Axis Y Axis

to this:

 SZ:    Pixels          Physical       Refresh
*0   1920 x 1080   ( 372mm x 207mm )  *50   52  
Current rotation - normal
Current reflection - none
Rotations possible - normal left inverted right 
Reflections possible - X Axis Y Axis

I tried the workaround suggested here https://wiki.winehq.org/FAQ#Broken_NVID … _RandR_1.0 but no luck.

Last edited by hematinik (2023-01-23 08:32:16)

Offline

#2 2023-01-15 00:13:55

Head_on_a_Stick
Member
From: London
Registered: 2014-02-20
Posts: 7,680
Website

Re: [SOLVED] Forcing X server to only support monitor's native resolution

Why do you want to do this? What is the problem you are attempting to solve?

See also https://xyproblem.info/.

Offline

#3 2023-01-15 00:14:59

hematinik
Member
Registered: 2022-03-23
Posts: 34

Re: [SOLVED] Forcing X server to only support monitor's native resolution

it is related to a bug in wine mentioned here https://wiki.winehq.org/FAQ#Broken_NVID … _RandR_1.0

Offline

#4 2023-01-15 00:20:19

hematinik
Member
Registered: 2022-03-23
Posts: 34

Re: [SOLVED] Forcing X server to only support monitor's native resolution

Head_on_a_Stick wrote:

Why do you want to do this? What is the problem you are attempting to solve?

See also https://xyproblem.info/.

Thank you but I don't think that's the case because it is supposed to fix/workaround a known bug.

Last edited by hematinik (2023-01-15 00:23:28)

Offline

#5 2023-01-15 09:00:14

seth
Member
Registered: 2012-09-03
Posts: 49,981

Re: [SOLVED] Forcing X server to only support monitor's native resolution

That's the definition of an xy-problem.

1. do you inded get this error message (the wine bug is from 2013…)

err:winediag:xrandr12_init_modes Broken NVIDIA RandR detected, falling back to RandR 1.0. Please consider using the Nouveau driver instead.

2. Do you use the nvidia driver?
3. What's the ouput of "xrandr -q" and your xorg log, https://wiki.archlinux.org/title/Xorg#General
4. https://us.download.nvidia.com/XFree86/ … tions.html - look for 'Option "ModeValidation" "string"'

Offline

#6 2023-01-15 22:28:47

hematinik
Member
Registered: 2022-03-23
Posts: 34

Re: [SOLVED] Forcing X server to only support monitor's native resolution

seth wrote:

That's the definition of an xy-problem

You are right my mistake.

1- Yes I do, I have the exact symptoms as described in the linked WINE FAQ page
2- I am using nvidia driver (nvidia-340xx-dkms)
3- output of "xrandr -q"

Screen 0: minimum 8 x 8, current 1920 x 1080, maximum 8192 x 8192
LVDS-0 connected primary (normal left inverted right x axis y axis)
   1920x1200     59.95 +
DP-0 connected 1920x1080+0+0 (normal left inverted right x axis y axis) 1872mm x 1053mm
   1920x1080     60.00*+  59.94    50.00    29.97    25.00    23.97    60.00    50.04  
   1680x1050     59.95  
   1600x900      60.00  
   1440x900      59.89  
   1366x768      59.79  
   1280x1024     75.02    60.02  
   1280x800      59.81  
   1280x720      60.00    59.94    50.00  
   1152x864      75.00  
   1024x768      75.03    70.07    60.00  
   800x600       75.00    72.19    60.32  
   720x576       50.00    50.08  
   720x480       59.94    60.05  
   640x480       75.00    72.81    59.94  
DP-1 disconnected (normal left inverted right x axis y axis)

the Xorg log:

Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (II) Module wfb: vendor="X.Org Foundation"
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]:         compiled for 1.21.1.4, module version = 1.0.0
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]:         ABI class: X.Org ANSI C Emulation, version 0.4
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (II) Loading sub module "ramdac"
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (II) LoadModule: "ramdac"
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (II) Module "ramdac" already built-in
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (**) NVIDIA(0): Depth 24, (--) framebuffer bpp 32
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (==) NVIDIA(0): RGB weight 888
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (==) NVIDIA(0): Default visual is TrueColor
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (==) NVIDIA(0): Using gamma correction (1.0, 1.0, 1.0)
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (II) Applying OutputClass "nvidia" options to /dev/dri/card0
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (**) NVIDIA(0): Option "Stereo" "0"
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (**) NVIDIA(0): Option "UseEdidDpi" "False"
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (**) NVIDIA(0): Option "DPI" "96x96"
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (**) NVIDIA(0): Option "SLI" "Off"
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (**) NVIDIA(0): Option "MultiGPU" "Off"
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (**) NVIDIA(0): Option "BaseMosaic" "off"
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (**) NVIDIA(0): Option "AllowEmptyInitialConfiguration"
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (**) NVIDIA(0): Stereo disabled by request
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (**) NVIDIA(0): NVIDIA SLI disabled.
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (**) NVIDIA(0): NVIDIA Multi-GPU disabled.
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (**) NVIDIA(0): Option "MetaModes" "DP-0: 1920x1080_60 +0+0"
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (**) NVIDIA(0): Enabling 2D acceleration
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (II) NVIDIA(0): Display (Apple Color LCD (DFP-0)) does not support NVIDIA 3D
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (II) NVIDIA(0):     Vision stereo.
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (II) NVIDIA(0): Display (SAMSUNG (DFP-1)) does not support NVIDIA 3D Vision
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (II) NVIDIA(0):     stereo.
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (II) NVIDIA(0): NVIDIA GPU GeForce GT 330M (GT216) at PCI:1:0:0 (GPU-0)
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (--) NVIDIA(0): Memory: 524288 kBytes
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (--) NVIDIA(0): VideoBIOS: 70.16.58.0a.00
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (II) NVIDIA(0): Detected PCI Express Link width: 16X
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (--) NVIDIA(0): Valid display device(s) on GeForce GT 330M at PCI:1:0:0
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (--) NVIDIA(0):     Apple Color LCD (DFP-0) (boot, connected)
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (--) NVIDIA(0):     SAMSUNG (DFP-1) (connected)
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (--) NVIDIA(0):     DFP-2
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (--) NVIDIA(0): Apple Color LCD (DFP-0): Internal LVDS
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (--) NVIDIA(GPU-0): Apple Color LCD (DFP-0): 330.0 MHz maximum pixel clock
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (--) NVIDIA(0): SAMSUNG (DFP-1): Internal TMDS
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (--) NVIDIA(GPU-0): SAMSUNG (DFP-1): 165.0 MHz maximum pixel clock
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (--) NVIDIA(0): DFP-2: Internal DisplayPort
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (--) NVIDIA(GPU-0): DFP-2: 480.0 MHz maximum pixel clock
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (**) NVIDIA(0): Using HorizSync/VertRefresh ranges from the EDID for display
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (**) NVIDIA(0):     device Apple Color LCD (DFP-0) (Using EDID frequencies has
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (**) NVIDIA(0):     been enabled on all display devices.)
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (**) NVIDIA(0): Using HorizSync/VertRefresh ranges from the EDID for display
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (**) NVIDIA(0):     device SAMSUNG (DFP-1) (Using EDID frequencies has been
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (**) NVIDIA(0):     enabled on all display devices.)
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (II) NVIDIA(0): Validated MetaModes:
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (II) NVIDIA(0):     "DP-0:1920x1080_60+0+0"
Jan 16 01:35:48 mbp /usr/lib/gdm-x-session[618]: (II) NVIDIA(0): Virtual screen size determined to be 1920 x 1080
Jan 16 01:35:49 mbp /usr/lib/gdm-x-session[618]: (**) NVIDIA(0): DPI set to (96, 96); computed from "DPI" X config option
Jan 16 01:35:49 mbp /usr/lib/gdm-x-session[618]: (II) NVIDIA: Using 768.00 MB of virtual memory for indirect memory access.
Jan 16 01:35:49 mbp /usr/lib/gdm-x-session[618]: (II) NVIDIA(0): ACPI: failed to connect to the ACPI event daemon; the daemon
Jan 16 01:35:49 mbp /usr/lib/gdm-x-session[618]: (II) NVIDIA(0):     may not be running or the "AcpidSocketPath" X
Jan 16 01:35:49 mbp /usr/lib/gdm-x-session[618]: (II) NVIDIA(0):     configuration option may not be set correctly.  When the
Jan 16 01:35:49 mbp /usr/lib/gdm-x-session[618]: (II) NVIDIA(0):     ACPI event daemon is available, the NVIDIA X driver will
Jan 16 01:35:49 mbp /usr/lib/gdm-x-session[618]: (II) NVIDIA(0):     try to use it to receive ACPI event notifications.  For
Jan 16 01:35:49 mbp /usr/lib/gdm-x-session[618]: (II) NVIDIA(0):     details, please see the "ConnectToAcpid" and
Jan 16 01:35:49 mbp /usr/lib/gdm-x-session[618]: (II) NVIDIA(0):     "AcpidSocketPath" X configuration options in Appendix B: X
Jan 16 01:35:49 mbp /usr/lib/gdm-x-session[618]: (II) NVIDIA(0):     Config Options in the README.
Jan 16 01:35:49 mbp /usr/lib/gdm-x-session[618]: (II) NVIDIA(0): Setting mode "DP-0:1920x1080_60+0+0"
Jan 16 01:35:49 mbp /usr/lib/gdm-x-session[618]: (==) NVIDIA(0): Disabling shared memory pixmaps
Jan 16 01:35:49 mbp /usr/lib/gdm-x-session[618]: (==) NVIDIA(0): Backing store enabled
Jan 16 01:35:49 mbp /usr/lib/gdm-x-session[618]: (==) NVIDIA(0): Silken mouse enabled
Jan 16 01:35:49 mbp /usr/lib/gdm-x-session[618]: (**) NVIDIA(0): DPMS enabled
Jan 16 01:35:49 mbp /usr/lib/gdm-x-session[618]: (WW) NVIDIA(0): Option "PrimaryGPU" is not used
Jan 16 01:35:49 mbp /usr/lib/gdm-x-session[618]: (II) Loading sub module "dri2"
Jan 16 01:35:49 mbp /usr/lib/gdm-x-session[618]: (II) LoadModule: "dri2"
Jan 16 01:35:49 mbp /usr/lib/gdm-x-session[618]: (II) Module "dri2" already built-in
Jan 16 01:35:49 mbp /usr/lib/gdm-x-session[618]: (II) NVIDIA(0): [DRI2] Setup complete
Jan 16 01:35:49 mbp /usr/lib/gdm-x-session[618]: (II) NVIDIA(0): [DRI2]   VDPAU driver: nvidia

4- I tried "ModeValidation" and a few other things like disabling EDID (Option "UseEDID" "FALSE") , adding modeline and other options to xorg.conf such as:

# 1920x1080 59.96 Hz (CVT 2.07M9) hsync: 67.16 kHz; pclk: 173.00 MHz
Modeline      "1920x1080_60.00"  173.00  1920 2048 2248 2576  1080 1083 1088 1120 -hsync +vsync
Option          "PreferredMode" "1920x1080_60.00"
....
        SubSection "Display"
                Depth          24
                Modes         "1920x1080"
        EndSubSection

but still can't have only one resolution as the "xrandr --q1" 's output. as you can see I already have only one resolution available for the primary display (my laptop's display), when I unplug the external display I get WINE working fine even with an empty xorg.conf file. this is a known bug in the WINE community and I am not looking for a solution to that specific problem here in lovely Arch Forum. I just need someone help me to achieve the single resolution output so MAYBE it could help me overcome the problem.

Last edited by hematinik (2023-01-21 15:39:44)

Offline

#7 2023-01-16 03:58:25

headkase
Member
Registered: 2011-12-06
Posts: 1,975

Re: [SOLVED] Forcing X server to only support monitor's native resolution

An alternate solution that I often use with WINE is gamescope.  You give the game a resolution and optionally display it at another with FSR if you want.  It should work with nVidia, it works fine with AMD.  With gamescope the WINE application gets one resolution and that's it - the one you gave it.  That would accomplish the same effect as getting xrandr to have only one mode.

Edit: gamescope also works with Linux games as well, it'll wrap anything.

Last edited by headkase (2023-01-16 05:31:00)

Offline

#8 2023-01-16 08:48:50

seth
Member
Registered: 2012-09-03
Posts: 49,981

Re: [SOLVED] Forcing X server to only support monitor's native resolution

I suggest to narrow the workaround by following headkase's suggestion.

Otherwise (if that fails):

I tried "ModeValidation"

"How"? It's not in your xorg log.
You've to make sure that no modeline is automatically edid by server or edid and only your user supplied is accepted.
In doubt, post your xorg.conf (s) w/ what you've tried.

adding modeline and other options

(merely) *adding* a modeline will not remove others…

Offline

#9 2023-01-17 01:20:26

hematinik
Member
Registered: 2022-03-23
Posts: 34

Re: [SOLVED] Forcing X server to only support monitor's native resolution

There are a couple of workarounds such as switching to "wine-valve" or running wine in "Emulate a Virtual Desktop" mode - which I'm trying to avoid because wine-valve takes ages to compile and "emulated mode" is not a very productive feature. so here I am and this is what dear seth asked of me:

the "xorg.conf"

# nvidia-settings: X configuration file generated by nvidia-settings
# nvidia-settings:  version 340.108  (buildmeister@swio-display-x64-rhel04-01)  Wed Dec 11 15:13:22 PST 2019

Section "ServerLayout"
    Identifier     "Layout0"
    Screen      0  "Screen0" 0 0
    InputDevice    "Keyboard0" "CoreKeyboard"
    InputDevice    "Mouse0" "CorePointer"
    Option         "Xinerama" "0"
EndSection

Section "Files"
EndSection

Section "InputDevice"
    # generated from default
    Identifier     "Mouse0"
    Driver         "mouse"
    Option         "Protocol" "auto"
    Option         "Device" "/dev/psaux"
    Option         "Emulate3Buttons" "no"
    Option         "ZAxisMapping" "4 5"
EndSection

Section "InputDevice"
    # generated from default
    Identifier     "Keyboard0"
    Driver         "kbd"
EndSection

Section "Monitor"
    # HorizSync source: edid, VertRefresh source: edid
    Identifier     "Monitor0"
    VendorName     "Unknown"
    ModelName      "SAMSUNG"
    Modeline       "1920x1080_60"  173.00  1920 2048 2248 2576  1080 1083 1088 1120 -hsync +vsync
    Option         "PreferredMode"  "1920x1080_60"
    HorizSync       15.0 - 135.0
    VertRefresh     24.0 - 75.0
    Option         "DPMS"
EndSection

Section "Device"
    Identifier     "Device0"
    Driver         "nvidia"
    VendorName     "NVIDIA Corporation"
    BoardName      "GeForce GT 330M"
EndSection

Section "Screen"
    Identifier     "Screen0"
    Device         "Device0"
    Monitor        "Monitor0"
    DefaultDepth    24
    Option         "ModeValidation" "DP-0: NoEdidModes, NoPredefinedModes, NoXServerModes, NoVesaModes"
    Option         "Stereo" "0"
    Option         "metamodes" "DP-0: 1920x1080_60 +0+0"
    Option         "SLI" "Off"
    Option         "MultiGPU" "Off"
    Option         "BaseMosaic" "off"
    SubSection     "Display"
        Depth       24
        Modes       "1920x1080"
        Option      "UseEdidDpi" "False"
        Option      "DPI" "96x96"
    EndSubSection
EndSection

after applying this configuration I end up with

$ xrandr --q1
 SZ:    Pixels          Physical       Refresh
*0    800 x 600    ( 211mm x 158mm )  *50  
 1    640 x 480    ( 169mm x 127mm )   51  
 2    800 x 450    ( 211mm x 119mm )   52  
Current rotation - normal
Current reflection - none
Rotations possible - normal left inverted right 
Reflections possible - X Axis Y Axis

$ xrandr -q
Screen 0: minimum 8 x 8, current 800 x 600, maximum 8192 x 8192
LVDS-0 connected primary (normal left inverted right x axis y axis)
   1920x1200     59.95 +
DP-0 connected 800x600+0+0 (normal left inverted right x axis y axis) 1110mm x 620mm
   800x600       60.32*+
DP-1 disconnected (normal left inverted right x axis y axis)

the Xorg log

Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (WW) NVIDIA: The driver will continue to load, but may behave strangely.
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (WW) NVIDIA: This driver was compiled against the X.Org server SDK from commit e6ef2b12404dfec7f23592a3524d2a63d9d25802 and may not be compatible with the final version of this SDK.
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA dlloader X Driver  340.108  Wed Dec 11 14:06:00 PST 2019
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA Unified Driver for all Supported NVIDIA GPUs
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (II) Loading sub module "fb"
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (II) LoadModule: "fb"
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (II) Module "fb" already built-in
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (WW) Unresolved symbol: fbGetGCPrivateKey
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (II) Loading sub module "wfb"
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (II) LoadModule: "wfb"
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (II) Loading /usr/lib/xorg/modules/libwfb.so
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (II) Module wfb: vendor="X.Org Foundation"
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]:         compiled for 1.21.1.4, module version = 1.0.0
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]:         ABI class: X.Org ANSI C Emulation, version 0.4
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (II) Loading sub module "ramdac"
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (II) LoadModule: "ramdac"
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (II) Module "ramdac" already built-in
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (**) NVIDIA(0): Depth 24, (--) framebuffer bpp 32
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (==) NVIDIA(0): RGB weight 888
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (==) NVIDIA(0): Default visual is TrueColor
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (==) NVIDIA(0): Using gamma correction (1.0, 1.0, 1.0)
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (II) Applying OutputClass "nvidia" options to /dev/dri/card0
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (**) NVIDIA(0): Option "Stereo" "0"
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (**) NVIDIA(0): Option "UseEdidDpi" "False"
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (**) NVIDIA(0): Option "DPI" "96x96"
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (**) NVIDIA(0): Option "SLI" "Off"
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (**) NVIDIA(0): Option "MultiGPU" "Off"
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (**) NVIDIA(0): Option "ModeValidation" "DP-0: NoEdidModes, NoPredefinedModes, NoXServerModes, NoVesaModes"
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (**) NVIDIA(0): Option "BaseMosaic" "off"
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (**) NVIDIA(0): Option "AllowEmptyInitialConfiguration"
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (**) NVIDIA(0): Stereo disabled by request
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (**) NVIDIA(0): NVIDIA SLI disabled.
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (**) NVIDIA(0): NVIDIA Multi-GPU disabled.
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (**) NVIDIA(0): Option "MetaModes" "DP-0: 1920x1080_60 +0+0"
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (**) NVIDIA(0): Enabling 2D acceleration
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(0): Display (Apple Color LCD (DFP-0)) does not support NVIDIA 3D
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(0):     Vision stereo.
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(0): Display (SAMSUNG (DFP-1)) does not support NVIDIA 3D Vision
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(0):     stereo.
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(0): NVIDIA GPU GeForce GT 330M (GT216) at PCI:1:0:0 (GPU-0)
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (--) NVIDIA(0): Memory: 524288 kBytes
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (--) NVIDIA(0): VideoBIOS: 70.16.58.0a.00
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(0): Detected PCI Express Link width: 16X
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (--) NVIDIA(0): Valid display device(s) on GeForce GT 330M at PCI:1:0:0
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (--) NVIDIA(0):     Apple Color LCD (DFP-0) (boot, connected)
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (--) NVIDIA(0):     SAMSUNG (DFP-1) (connected)
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (--) NVIDIA(0):     DFP-2
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (--) NVIDIA(0): Apple Color LCD (DFP-0): Internal LVDS
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (--) NVIDIA(GPU-0): Apple Color LCD (DFP-0): 330.0 MHz maximum pixel clock
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (--) NVIDIA(0): SAMSUNG (DFP-1): Internal TMDS
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (--) NVIDIA(GPU-0): SAMSUNG (DFP-1): 165.0 MHz maximum pixel clock
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (--) NVIDIA(0): DFP-2: Internal DisplayPort
Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (--) NVIDIA(GPU-0): DFP-2: 480.0 MHz maximum pixel clock
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (**) NVIDIA(0): Using HorizSync/VertRefresh ranges from the EDID for display
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (**) NVIDIA(0):     device Apple Color LCD (DFP-0) (Using EDID frequencies has
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (**) NVIDIA(0):     been enabled on all display devices.)
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (**) NVIDIA(0): Using HorizSync/VertRefresh ranges from the EDID for display
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (**) NVIDIA(0):     device SAMSUNG (DFP-1) (Using EDID frequencies has been
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (**) NVIDIA(0):     enabled on all display devices.)
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(GPU-0): Mode Validation Overrides for SAMSUNG (DFP-1):
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(GPU-0):     NoVesaModes
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(GPU-0):     NoEdidModes
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(GPU-0):     NoXServerModes
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(GPU-0):     NoPredefinedModes
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (WW) NVIDIA(0): No valid modes for "DP-0:1920x1080_60+0+0"; removing.
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (WW) NVIDIA(0):
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (WW) NVIDIA(0): Unable to validate any modes; falling back to the default mode
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (WW) NVIDIA(0):     "nvidia-auto-select".
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (WW) NVIDIA(0):
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(0): Validated MetaModes:
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(0):     "DFP-1:nvidia-auto-select"
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(0): Virtual screen size determined to be 800 x 600
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (**) NVIDIA(0): DPI set to (96, 96); computed from "DPI" X config option
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA: Using 768.00 MB of virtual memory for indirect memory access.
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(0): ACPI: failed to connect to the ACPI event daemon; the daemon
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(0):     may not be running or the "AcpidSocketPath" X
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(0):     configuration option may not be set correctly.  When the
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(0):     ACPI event daemon is available, the NVIDIA X driver will
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(0):     try to use it to receive ACPI event notifications.  For
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(0):     details, please see the "ConnectToAcpid" and
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(0):     "AcpidSocketPath" X configuration options in Appendix B: X
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(0):     Config Options in the README.
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(0): Setting mode "DFP-1:nvidia-auto-select"
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (==) NVIDIA(0): Disabling shared memory pixmaps
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (==) NVIDIA(0): Backing store enabled
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (==) NVIDIA(0): Silken mouse enabled
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (**) NVIDIA(0): DPMS enabled
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (WW) NVIDIA(0): Option "PrimaryGPU" is not used
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (WW) NVIDIA(0): Option "PreferredMode" is not used
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (II) Loading sub module "dri2"
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (II) LoadModule: "dri2"
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (II) Module "dri2" already built-in
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(0): [DRI2] Setup complete
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA(0): [DRI2]   VDPAU driver: nvidia

Last edited by hematinik (2023-01-21 15:41:09)

Offline

#10 2023-01-17 08:11:28

seth
Member
Registered: 2012-09-03
Posts: 49,981

Re: [SOLVED] Forcing X server to only support monitor's native resolution

# nvidia-settings: X configuration file generated by nvidia-settings
# nvidia-settings:  version 340.108  (buildmeister@swio-display-x64-rhel04-01)  Wed Dec 11 15:13:22 PST 2019

Jan 17 04:13:14 mbp /usr/lib/gdm-x-session[620]: (II) NVIDIA GLX Module  340.108  Wed Dec 11 14:26:50 PST 2019


    Identifier     "Monitor0"
Jan 17 04:13:15 mbp /usr/lib/gdm-x-session[620]: (WW) NVIDIA(0): No valid modes for "DP-0:1920x1080_60+0+0"; removing.

Don't use nvidia-settings to generate the config, it produces cruft.

We define a modeline for the output, using the outputs name as Identifier to have it auto-applied and instead of defining a useless screen, tell the nvidia driver how to handle stuff.
YOu might want to extend the metamodes w/ your internal display.

Section "Monitor"
    Identifier     "DP-0"
    Modeline       "1920x1080_60"  173.00  1920 2048 2248 2576  1080 1083 1088 1120 -hsync +vsync
EndSection

Section "Device"
    Identifier     "Device0"
    Driver         "nvidia"
    VendorName     "NVIDIA Corporation"
    BoardName      "GeForce GT 330M"
    Option         "ModeValidation" "DP-0: NoEdidModes, NoPredefinedModes, NoXServerModes, NoVesaModes"
    Option         "metamodes" "DP-0: 1920x1080_60 +0+0"
    Option         "UseEdidDpi" "False"
    Option         "DPI" "96x96"
EndSection

Offline

#11 2023-01-17 10:03:38

hematinik
Member
Registered: 2022-03-23
Posts: 34

Re: [SOLVED] Forcing X server to only support monitor's native resolution

I copied your config and X totally ignored the new settings *sigh*. everytime I have a problem it is either nvidia or the Xserver or both involved! I think have to wait for the WINE 8 to hit the official repo as it seems they finally fixed the bug.

Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (WW) NVIDIA: The driver will continue to load, but may behave strangely.
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (WW) NVIDIA: This driver was compiled against the X.Org server SDK from commit e6ef2b12404dfec7f23592a3524d2a63d9d25802 and may not be compatible with the final v>
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) NVIDIA dlloader X Driver  340.108  Wed Dec 11 14:06:00 PST 2019
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) NVIDIA Unified Driver for all Supported NVIDIA GPUs
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) Loading sub module "fb"
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) LoadModule: "fb"
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) Module "fb" already built-in
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (WW) Unresolved symbol: fbGetGCPrivateKey
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) Loading sub module "wfb"
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) LoadModule: "wfb"
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) Loading /usr/lib/xorg/modules/libwfb.so
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) Module wfb: vendor="X.Org Foundation"
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]:         compiled for 1.21.1.4, module version = 1.0.0
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]:         ABI class: X.Org ANSI C Emulation, version 0.4
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) Loading sub module "ramdac"
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) LoadModule: "ramdac"
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) Module "ramdac" already built-in
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) NVIDIA(0): Creating default Display subsection in Screen section
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]:         "Default Screen Section" for depth/fbbpp 24/32
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (==) NVIDIA(0): Depth 24, (==) framebuffer bpp 32
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (==) NVIDIA(0): RGB weight 888
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (==) NVIDIA(0): Default visual is TrueColor
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (==) NVIDIA(0): Using gamma correction (1.0, 1.0, 1.0)
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) Applying OutputClass "nvidia" options to /dev/dri/card1
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (**) NVIDIA(0): Option "AllowEmptyInitialConfiguration"
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (**) NVIDIA(0): Enabling 2D acceleration
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) NVIDIA(0): Display (Apple Color LCD (DFP-0)) does not support NVIDIA 3D
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) NVIDIA(0):     Vision stereo.
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) NVIDIA(0): Display (SAMSUNG (DFP-1)) does not support NVIDIA 3D Vision
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) NVIDIA(0):     stereo.
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) NVIDIA(0): NVIDIA GPU GeForce GT 330M (GT216) at PCI:1:0:0 (GPU-0)
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (--) NVIDIA(0): Memory: 524288 kBytes
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (--) NVIDIA(0): VideoBIOS: 70.16.58.0a.00
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) NVIDIA(0): Detected PCI Express Link width: 16X
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (--) NVIDIA(0): Valid display device(s) on GeForce GT 330M at PCI:1:0:0
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (--) NVIDIA(0):     Apple Color LCD (DFP-0) (boot, connected)
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (--) NVIDIA(0):     SAMSUNG (DFP-1) (connected)
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (--) NVIDIA(0):     DFP-2
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (--) NVIDIA(0): Apple Color LCD (DFP-0): Internal LVDS
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (--) NVIDIA(GPU-0): Apple Color LCD (DFP-0): 330.0 MHz maximum pixel clock
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (--) NVIDIA(0): SAMSUNG (DFP-1): Internal TMDS
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (--) NVIDIA(GPU-0): SAMSUNG (DFP-1): 165.0 MHz maximum pixel clock
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (--) NVIDIA(0): DFP-2: Internal DisplayPort
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (--) NVIDIA(GPU-0): DFP-2: 480.0 MHz maximum pixel clock
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (**) NVIDIA(0): Using HorizSync/VertRefresh ranges from the EDID for display
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (**) NVIDIA(0):     device Apple Color LCD (DFP-0) (Using EDID frequencies has
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (**) NVIDIA(0):     been enabled on all display devices.)
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (**) NVIDIA(0): Using HorizSync/VertRefresh ranges from the EDID for display
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (**) NVIDIA(0):     device SAMSUNG (DFP-1) (Using EDID frequencies has been
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (**) NVIDIA(0):     enabled on all display devices.)
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (==) NVIDIA(0):
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (==) NVIDIA(0): No modes were requested; the default mode "nvidia-auto-select"
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (==) NVIDIA(0):     will be used as the requested mode.
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (==) NVIDIA(0):
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) NVIDIA(0): Validated MetaModes:
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) NVIDIA(0):     "DFP-0:nvidia-auto-select,DFP-1:nvidia-auto-select"
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) NVIDIA(0): Virtual screen size determined to be 3840 x 1200
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (--) NVIDIA(0): DPI set to (131, 132); computed from "UseEdidDpi" X config
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (--) NVIDIA(0):     option
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) NVIDIA: Using 768.00 MB of virtual memory for indirect memory access.
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) NVIDIA(0): ACPI: failed to connect to the ACPI event daemon; the daemon
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) NVIDIA(0):     may not be running or the "AcpidSocketPath" X
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) NVIDIA(0):     configuration option may not be set correctly.  When the
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) NVIDIA(0):     ACPI event daemon is available, the NVIDIA X driver will
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) NVIDIA(0):     try to use it to receive ACPI event notifications.  For
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) NVIDIA(0):     details, please see the "ConnectToAcpid" and
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) NVIDIA(0):     "AcpidSocketPath" X configuration options in Appendix B: X
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) NVIDIA(0):     Config Options in the README.
Jan 17 13:22:12 mbp /usr/lib/gdm-x-session[3006]: (II) NVIDIA(0): Setting mode "DFP-0:nvidia-auto-select,DFP-1:nvidia-auto-select"
Jan 17 13:22:13 mbp /usr/lib/gdm-x-session[3006]: (==) NVIDIA(0): Disabling shared memory pixmaps
Jan 17 13:22:13 mbp /usr/lib/gdm-x-session[3006]: (==) NVIDIA(0): Backing store enabled
Jan 17 13:22:13 mbp /usr/lib/gdm-x-session[3006]: (==) NVIDIA(0): Silken mouse enabled
Jan 17 13:22:13 mbp /usr/lib/gdm-x-session[3006]: (==) NVIDIA(0): DPMS enabled
Jan 17 13:22:13 mbp /usr/lib/gdm-x-session[3006]: (WW) NVIDIA(0): Option "PrimaryGPU" is not used
Jan 17 13:22:13 mbp /usr/lib/gdm-x-session[3006]: (II) Loading sub module "dri2"
Jan 17 13:22:13 mbp /usr/lib/gdm-x-session[3006]: (II) LoadModule: "dri2"
Jan 17 13:22:13 mbp /usr/lib/gdm-x-session[3006]: (II) Module "dri2" already built-in
Jan 17 13:22:13 mbp /usr/lib/gdm-x-session[3006]: (II) NVIDIA(0): [DRI2] Setup complete
Jan 17 13:22:13 mbp /usr/lib/gdm-x-session[3006]: (II) NVIDIA(0): [DRI2]   VDPAU driver: nvidia

Last edited by hematinik (2023-01-21 15:42:44)

Offline

#12 2023-01-17 10:09:18

d.ALT
Member
Registered: 2019-05-10
Posts: 914

Re: [SOLVED] Forcing X server to only support monitor's native resolution

Sorry... I didn't fully understand your needs here, maybe I'm wrong, but... Did you have a look at Lutris's lutris-fshack ?

lutris-fshack

Same as lutris, but includes fshack, a software implementation of monitor modesetting (resolution changing), ported over from Proton. With it, your whole monitor will no longer modeset to a lower resolution if the game requests it, instead Wine itself will do it and only do it for the game itself. It may also improve fullscreen behavior for games that run in your native resolution, but results may vary from game to game. Additionally, due to fshack being quite big and modifying a lot of components, some fixes and patches that are used in normal lutris aren't compatible with it and thus missing.

(https://github.com/lutris/docs/blob/mas … eBuilds.md)


<49,17,III,I>    Fama di loro il mondo esser non lassa;
<50,17,III,I>    misericordia e giustizia li sdegna:
<51,17,III,I>    non ragioniam di lor, ma guarda e passa.

Offline

#13 2023-01-17 11:59:44

seth
Member
Registered: 2012-09-03
Posts: 49,981

Re: [SOLVED] Forcing X server to only support monitor's native resolution

grep -Er '(Device0|nvidia)' /{etc,usr/share}/X11/xorg.conf*

Offline

#14 2023-01-17 12:18:55

hematinik
Member
Registered: 2022-03-23
Posts: 34

Re: [SOLVED] Forcing X server to only support monitor's native resolution

d.ALT wrote:

.. Did you have a look at Lutris's lutris-fshack ?

Thank you I just checked and it seems Lutris has patched their wine fork with https://bugs.winehq.org/attachment.cgi? … ction=diff so I guess that's the same story with "wine-valve". still Im trying to stick with vanilla WINE for some reason smile

Dear seth

$grep -Er '(Device0|nvidia)' /{etc,usr/share}/X11/xorg.conf*

/etc/X11/xorg.conf:# nvidia-settings: X configuration file generated by nvidia-settings
/etc/X11/xorg.conf:# nvidia-settings:  version 340.108  (buildmeister@swio-display-x64-rhel04-01)  Wed Dec 11 15:13:22 PST 2019
/etc/X11/xorg.conf:    Identifier     "Device0"
/etc/X11/xorg.conf:    Driver         "nvidia"
/etc/X11/xorg.conf:    Device         "Device0"
/etc/X11/xorg.conf.d/20-nvidia.conf:  ModulePath   "/usr/lib64/nvidia/xorg"
/etc/X11/xorg.conf.d/20-nvidia.conf:  Driver "nvidia"
/usr/share/X11/xorg.conf.d/10-nvidia-drm-outputclass.conf:    Identifier "nvidia"
/usr/share/X11/xorg.conf.d/10-nvidia-drm-outputclass.conf:    MatchDriver "nvidia-drm"
/usr/share/X11/xorg.conf.d/10-nvidia-drm-outputclass.conf:    Driver "nvidia"
/usr/share/X11/xorg.conf.d/10-nvidia-drm-outputclass.conf:    ModulePath "/usr/lib/nvidia/xorg"

Offline

#15 2023-01-17 12:21:25

d.ALT
Member
Registered: 2019-05-10
Posts: 914

Re: [SOLVED] Forcing X server to only support monitor's native resolution

hematinik wrote:
d.ALT wrote:

.. Did you have a look at Lutris's lutris-fshack ?

Thank you I just checked and it seems Lutris has patched their wine fork with https://bugs.winehq.org/attachment.cgi? … ction=diff so I guess that's the same story with "wine-valve". still Im trying to stick with vanilla WINE for some reason smile

Good approach, pal! cool


<49,17,III,I>    Fama di loro il mondo esser non lassa;
<50,17,III,I>    misericordia e giustizia li sdegna:
<51,17,III,I>    non ragioniam di lor, ma guarda e passa.

Offline

#16 2023-01-17 12:27:35

hematinik
Member
Registered: 2022-03-23
Posts: 34

Re: [SOLVED] Forcing X server to only support monitor's native resolution

seth wrote:
grep -Er '(Device0|nvidia)' /{etc,usr/share}/X11/xorg.conf*

I checked those files, nothing fancy there. the other thing I did was using "xvidtune -show" to find out the modeline Xserver detects and it was very different compared to the output of "cvt" and "gtf". so I used that but it did not help either, I got exactly the same results as before.

Last edited by hematinik (2023-01-17 12:36:32)

Offline

#17 2023-01-17 12:50:29

seth
Member
Registered: 2012-09-03
Posts: 49,981

Re: [SOLVED] Forcing X server to only support monitor's native resolution

/etc/X11/xorg.conf:    Device         "Device0"

Post that file and just to be sure also /etc/X11/xorg.conf.d/20-nvidia.conf
The config in #10 wasn't meant to be some replacement for those sections only, but to be the entire config.

Offline

#18 2023-01-17 17:04:46

headkase
Member
Registered: 2011-12-06
Posts: 1,975

Re: [SOLVED] Forcing X server to only support monitor's native resolution

Too bad gamescope went by without even an acknowledgement.  That would do it instead of tunnel-vision on Xorg settings.  Too bad.

Offline

#19 2023-01-17 19:24:05

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 21,425

Re: [SOLVED] Forcing X server to only support monitor's native resolution

Gamescope needs certain DRM/Vulkan extensions that aren't going to work on this old HW/driver

Offline

#20 2023-01-17 21:55:04

headkase
Member
Registered: 2011-12-06
Posts: 1,975

Re: [SOLVED] Forcing X server to only support monitor's native resolution

V1del wrote:

Gamescope needs certain DRM/Vulkan extensions that aren't going to work on this old HW/driver

You're correct, driver R515 minimum is needed.  That is where nVidia support began.

Offline

#21 2023-01-18 00:07:25

hematinik
Member
Registered: 2022-03-23
Posts: 34

Re: [SOLVED] Forcing X server to only support monitor's native resolution

headkase wrote:

Too bad gamescope went by without even an acknowledgement

I really appreciate your response. the reason for tunnel vision is to find the answer as the topic suggests not just to workaround WINE since there are some ways in order to do that. maybe it could help someone else with a different problem or maybe it is just a nerdy way of looking at things wink it doesn't hurt to learn more.. ( or it does.. it actually hurts..)

Dear seth, I updated the "grep" output because at the time I had reverted my "xorg.conf" back to the original, but the Xorg log I provided was actually based on your settings. here is what you asked:

$ grep -Er '(Device0|nvidia)' /{etc,usr/share}/X11/xorg.conf*

/etc/X11/xorg.conf:    Identifier     "Device0"
/etc/X11/xorg.conf:    Driver         "nvidia"
/etc/X11/xorg.conf.d/20-nvidia.conf:  ModulePath   "/usr/lib64/nvidia/xorg"
/etc/X11/xorg.conf.d/20-nvidia.conf:  Driver "nvidia"
/usr/share/X11/xorg.conf.d/10-nvidia-drm-outputclass.conf:    Identifier "nvidia"
/usr/share/X11/xorg.conf.d/10-nvidia-drm-outputclass.conf:    MatchDriver "nvidia-drm"
/usr/share/X11/xorg.conf.d/10-nvidia-drm-outputclass.conf:    Driver "nvidia"
/usr/share/X11/xorg.conf.d/10-nvidia-drm-outputclass.conf:    ModulePath "/usr/lib/nvidia/xorg"
#/etc/X11/xorg.conf

Section "Monitor"
    Identifier     "DP-0"
    Modeline       "1920x1080_60"  173.00  1920 2048 2248 2576  1080 1083 1088 1120 -hsync +vsync
EndSection

Section "Device"
    Identifier     "Device0"
    Driver         "nvidia"
    VendorName     "NVIDIA Corporation"
    BoardName      "GeForce GT 330M"
    Option         "ModeValidation" "DP-0: NoEdidModes, NoPredefinedModes, NoXServerModes, NoVesaModes"
    Option         "metamodes" "DP-0: 1920x1080_60 +0+0"
    Option         "UseEdidDpi" "False"
    Option         "DPI" "96x96"
EndSection
# /etc/X11/xorg.conf.d/20-nvidia.conf

Section "Files"
  ModulePath   "/usr/lib64/nvidia/xorg"
  ModulePath   "/usr/lib64/xorg/modules"
EndSection

Section "Device"
  Identifier "Nvidia Card"
  Driver "nvidia"
  VendorName "NVIDIA Corporation"
EndSection

Section "ServerFlags"
  Option "IgnoreABI" "1"
EndSection
# /usr/share/X11/xorg.conf.d/10-nvidia-drm-outputclass.conf

Section "OutputClass"
    Identifier "intel"
    MatchDriver "i915"
    Driver "modesetting"
EndSection

Section "OutputClass"
    Identifier "nvidia"
    MatchDriver "nvidia-drm"
    Driver "nvidia"
    Option "AllowEmptyInitialConfiguration"
    Option "PrimaryGPU" "yes"
    ModulePath "/usr/lib/nvidia/xorg"
    ModulePath "/usr/lib/xorg/modules"
EndSection

Last edited by hematinik (2023-01-18 00:09:34)

Offline

#22 2023-01-18 01:37:52

headkase
Member
Registered: 2011-12-06
Posts: 1,975

Re: [SOLVED] Forcing X server to only support monitor's native resolution

hematinik wrote:
headkase wrote:

Too bad gamescope went by without even an acknowledgement

I really appreciate your response. the reason for tunnel vision is to find the answer as the topic suggests not just to workaround WINE since there are some ways in order to do that. maybe it could help someone else with a different problem or maybe it is just a nerdy way of looking at things wink it doesn't hurt to learn more.. ( or it does.. it actually hurts..)

Right on, it's good - you're welcome.  Gamescope is a wrapping program.  You prepend it to a command you want.  Like:

gamescope -h 900  -H 1080 -f -U -- wine <wineprogram>

replace "wine <wineprogram>" with any executable.  The above gamescope parameters give the program a 900p screen and upscales it to 1080p with AMD FSR1.0 with the "-U" parameter.

Since it is a wrapper you can do it to any program, even native Linux ones.  It is a micro-compositor that provides a screen for whatever needs one.

A sensible attempt with your program could be:

gamescope -h 1080 -H 1080 -f -- <program>

Which means give a 1080p screen to the program, output a 1080p screen from that composition, and "-f" means fullscreen.  The two-dashes are part of the gamescope parameters and everything after is what you're launching.

Also, if it's a game you're launching then I highly recommend Lutris as a game manager, and ProtonUp-Qt to manage WINE runtimes.  The latter gets you access to the Glorious Eggroll WINEs that work so much better than vanilla WINE for gaming.  You don't want to use Proton directly because it has hard-coded options for working with Steam - it doesn't work properly anywhere but Steam.  ProtonUp-Qt offers WINE versions that have all the Proton changes but works outside of Steam (Lutris Glorious Eggroll ones).  In Lutris there is basic-built-in support for gamescope and you can use the command prefix option in a Lutris game's settings if you want specific options.

If this works you can use it for everything.  The minimum nVidia driver is R515 and the official repos are carrying R525.  So if you're in sync with the official repos then you should have what you need.

Edit: the only show-stopper is that it runs in Wayland.  If you can run Wayland you really should nowadays.

Last edited by headkase (2023-01-18 01:43:49)

Offline

#23 2023-01-18 03:13:32

hematinik
Member
Registered: 2022-03-23
Posts: 34

Re: [SOLVED] Forcing X server to only support monitor's native resolution

headkase wrote:

Right on, it's good - you're welcome.  Gamescope is a wrapping program[...]

THAT IS AWESOME INFO! *_*  dude you wrote a complete tutorial for gaming on linux and It deserves its own topic!.. like you said I can't have that luxury on my ancient setup which is not a big deal because Im a lover of old machines and broken things lol.

Offline

#24 2023-01-18 03:30:18

headkase
Member
Registered: 2011-12-06
Posts: 1,975

Re: [SOLVED] Forcing X server to only support monitor's native resolution

hematinik wrote:
headkase wrote:

Right on, it's good - you're welcome.  Gamescope is a wrapping program[...]

THAT IS AWESOME INFO! *_*  dude you wrote a complete tutorial for gaming on linux and It deserves its own topic!.. like you said I can't have that luxury on my ancient setup which is not a big deal because Im a lover of old machines and broken things lol.

You're welcome again. wink  I'm familiar with the setups because it's what I use myself.  So I pieced it together over time, hopefully you'll recollect later when you can run the components. smile

Offline

#25 2023-01-18 03:43:59

hematinik
Member
Registered: 2022-03-23
Posts: 34

Re: [SOLVED] Forcing X server to only support monitor's native resolution

Trust me it sticks in my memory for good.. labled as "The Great Headkase's Advice in the Hall of Linux Gods"

Last edited by hematinik (2023-01-18 03:59:12)

Offline

Board footer

Powered by FluxBB