[Solved] How to disable vblank to sync for i915 graphics?

Archived topics about LMDE 1 and LMDE 2
Locked
trenthawkins

[Solved] How to disable vblank to sync for i915 graphics?

Post by trenthawkins »

This might be a newbie question, but i would really love it if someone could explain how i disable vblank to sync for my i915 graphics card.

I know that i need to set the option "SwapbuffersWait" to false in X, but given that X11 doesn't require a xorg.conf file to be created anymore, where do i change this option so that when the xorg setup is automatically created it parses this command?

The only helpful information i have found on this topic comes from the Arch Wiki here - https://wiki.archlinux.org/index.php/In ... ce_results

This says:
To disable VSync just add in your /etc/X11/xorg.conf.d/20-intel.conf in Section "Device" string Option "SwapbuffersWait" "false"
At the moment I can't use LMDE on my machine because when it runs off battery power it flickers uncontrollably and i have spent some time searching for a solution and the only thing i can think of trying is to stop it from synchronising the rendering to the vertical refresh (which is enabled by default).
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 2 times in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
User avatar
Roken
Level 5
Level 5
Posts: 737
Joined: Fri Nov 19, 2010 4:55 pm
Location: Newport, S Wales

Re: How to disable vblank to sync for i915 graphics?

Post by Roken »

I can't answer your specific question, but I can say that the latest RC of the 3.2 kernel (rc3) includes a lot of changes for i915 (I noticed when I looked through the changelog before building) so maybe it will get easier before too long.
Kernel Linux Tex 5.12.14-zen1-1-zen, XFCE
Arch
Dual GTX1070 8Gb
AMD Ryzen 1800X
32Gb RAM
ej64
Level 4
Level 4
Posts: 323
Joined: Tue Nov 24, 2009 7:43 am
Location: somewhere in Germany

Re: How to disable vblank to sync for i915 graphics?

Post by ej64 »

trenthawkins wrote:
This says:
To disable VSync just add in your /etc/X11/xorg.conf.d/20-intel.conf in Section "Device" string Option "SwapbuffersWait" "false"
At the moment I can't use LMDE on my machine because when it runs off battery power it flickers uncontrollably and i have spent some time searching for a solution and the only thing i can think of trying is to stop it from synchronising the rendering to the vertical refresh (which is enabled by default).
1. Boot your system in maintainance mode (usually 2nd grub line), X must not run to do the following
2. login as root for maintainance (usual password for su)
3. run: "Xorg -configure"
4. You'll find an xorg.conf.new in /root
5. copy this file to /etc/X11/xorg.conf or copy and rename
6. insert "SwapbuffersWait" false into the first device section, it will look like this

Code: Select all

Section "Device"
        ### Available Driver options are:-
        ### Values: <i>: integer, <f>: float, <bool>: "True"/"False",
        ### <string>: "String", <freq>: "<f> Hz/kHz/MHz",
        ### <percent>: "<f>%"
        ### [arg]: arg optional
        #Option     "DRI"                	# [<bool>]
        #Option     "ColorKey"           	# <i>
        #Option     "VideoKey"           	# <i>
        #Option     "FallbackDebug"      	# [<bool>]
        #Option     "Tiling"             	# [<bool>]
        #Option     "LinearFramebuffer"  	# [<bool>]
        #Option     "Shadow"             	# [<bool>]
        Option     "SwapbuffersWait"    	false
        #Option     "TripleBuffer"       	# [<bool>]
        #Option     "XvMC"               	# [<bool>]
        #Option     "XvPreferOverlay"    	# [<bool>]
        #Option     "DebugFlushBatches"  	# [<bool>]
        #Option     "DebugFlushCaches"   	# [<bool>]
        #Option     "DebugWait"          	# [<bool>]
        #Option     "HotPlug"            	# [<bool>]
        #Option     "RelaxedFencing"     	# [<bool>]
	Identifier  "Card0"
	Driver      "intel"
	BusID       "PCI:0:2:0"
EndSection
7. reboot and have fun :D
Thinkpad X220 with Samsung SSD running Xubuntu 13.04
I'm getting old gladly -- I don't like to die young ...
trenthawkins

Re: How to disable vblank to sync for i915 graphics?

Post by trenthawkins »

Thanks for the help ej64 and Roken, but i decided to take a different route and have an interesting result as a consequence.

For anyone that is interested i will quickly elaborate, and i will post this on the Linux Hybrid Graphics list too.

I have a Dell Vostro 3350 Laptop with a hybrid AMD/i915 graphics set up. I won't go into the details, but suffice to say most Linux OSs boot with the intel driver running the graphics and the AMD stays on causing a fan to spin constantly and my battery life to be pathetic (3 hrs max - should be 8+).

The solution to the problem i initially used was vga_switcheroo which is already in the kernel. This is fairly straight forward to set up and looked like a good solution. Except that every time i turned off the discrete card my graphics would flicker constantly, especially on batter power.

I have been playing around with Chakra for a bit and after i found i couldn't use vga_switcheroo i have been using acpi_call. Here is the forum thread on this topic: http://chakra-project.org/bbs/viewtopic.php?id=5995 and here is the method for installing: http://hybrid-graphics-linux.tuxfamily. ... =Acpi_call

Now i just went through this method and successfully turned off the graphics card using the script /usr/src/acpi_call-0.0.1/test_off.sh

What happened?

Well the flickering went away and my machine works perfectly!!!!!!!

This may indicate that there is a problem with the specific calls that vga_switcheroo uses for my machine.

Anyway hopefully someone out there sees this thread and solves their problem.
Locked

Return to “LMDE Archive”