Re: What to do with xf86-video-intel backlight control when running Xorg as non root

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Feb 13, 2014 at 04:52:59PM +0100, Hans de Goede wrote:
> Hi All,
> 
> Currently xf86-video-intel is unique in that it is the only video driver
> which does backlight control inside the driver rather then letting
> something else (ie the desktop environment) deal with it.
> 
> This is a problem when running the xserver without root rights because
> writing /sys/class/backlight/foo/brightness requires root rights.
> 
> There are 2 possible (short term) solutions for this:
> 
> 1) Detect that the xserver is not running as root, and don't register the
> backlight property on the connectors, let something else deal with it,
> as is done or other xf86-video-* drivers already.
> 
> 2) Add a little xf86-video-intel-brightness helper on Linux which the driver
> execs (through pkexec) each time it needs to set the brightness.
> 
> 
> 1) of course is very KISS, so I like. 2) is not that hard either, and
> 1) might cause some regressions in cases where ie gsd-brightness-helper
> does not do the right thing, where as the intel driver does. OTOH it seems
> that the intel video code is mostly there to deal with older kernels, and
> rootless xorg will be used with newer kernels only anyways.

Not registering a property that is broken seems like the fundamental first
step. Would it be possible to use udev to set the access mode on the
backlight properties such that the display controller does have
permission to write to those files? Otherwise, it seems like we need the
proxy in order to keep the xrandr property available to users and
prevent those who rely upon it in scripts from seeing regressions.
-Chris

-- 
Chris Wilson, Intel Open Source Technology Centre
_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/intel-gfx




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux