[Pm-utils] Improve 98smart-kernel-video

Victor Lowther victor.lowther at gmail.com
Fri Oct 30 20:54:27 PDT 2009


On Tue, 2009-10-27 at 08:37 +0100, Michael Biebl wrote:
> Hi,
> 
> the current 98smart-kernel-video shell script is imho overly
> complicated and actual error prone.
> E.g. have_kms checks for
> [ -d /sys/class/drm/card0/device/graphics/fb0 ] || return 1
> and then removes all quirks.

Back when KMS was first introduced we were assurred that the above
method was the way to ensure that the devault framebuffer was really
using KMS.  Apparently things did not work out that way, then.

> But any framebuffer driver (like radeonfb or vesafb) creates that
> directory, and removing the quirks will lead to failing suspends.
> 
> I had a lengthy irc discussion on #irc (see [1]) and as result I
> propose the following patch:
> remove have_smart_intel
> change have_kms and grep for noveaufb|drmfb in /proc/fb
> 
> Patch is attached.

Still ugly, but it should work for now.  It is a shame that the graphics
folks do not have a sysfs attribute they could add to KMS capable
drivers that we could use to see if KMS is being used, but I suppose
that is too simple.

> Comments welcome.
> If there are no complaints, I'm going to commit this patch and intend
> to apply it to the Debian pm-utils package.

Go ahead and push it -- let me know when it is in the git repo, and I
will spin a new release of pm-utils.

> Cheers,
> Michael
> 
> 
> [1] http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=517651
> 
> _______________________________________________
> Pm-utils mailing list
> Pm-utils at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/pm-utils



More information about the Pm-utils mailing list