[Intel-gfx] Partial success - Fixing resume from s2ram on S6010

Thomas Richter thor at math.tu-berlin.de
Mon Jun 9 12:57:46 CEST 2014


Hi Ville, dear intel experts,

without the deadlock in i915, I had at least a partial success in 
restoring the video on the Fujitsu S6010.
Apparently, the bios does not re-initialize the 830MG registers, nor the 
registers of the ns2501 DVO.
Instead, the 830MG is configured in a 640x480 mode (no matter what the 
suspend mode was) and
the DVO is configured in a DPMS off state (no matter what the mode was 
before the suspend).

The attached script, to be placed in /etc/pm/sleep.d/99video will force 
correct values back into the registers
and thus restore the display. Partially. Trouble still is that the 
restored screen has some type of "hick-up" by
moving left or right by a couple of pixels (probably exactly by one 
tile, I did not measure). Interestingly,
a dump of the DVO and 830MG registers did not reveal any significant 
difference before and after the restore,
so it is still unclear why that hick-up appears.

Anyhow - it seems that $OTHER_OS has a completely different strategy for 
resume than Linux. $OTHER_OS seems
to simply re-load the video registers for the currently active mode, 
ignoring the current state of the hardware.
The i915 kernel module instead seems to try to interpret the current 
register set to a video mode, and then
restores its state from the state of the hardware. It seems to me that 
this is a less than ideal approach, and
it would be better keep a copy of the registers how they should be 
during suspend, and restore them in
the kernel module to the correct video mode on resume, ignoring whatever 
the bios left there.

Do kernel modules like the i915 or the dvo_ns2501 offer some kind of 
hook that is called by the kernel when
the machine is suspended and resumed? If so, this would be extremely 
helpful and would allow a much safer
suspend/resume operation than currently possible with the mode-detect 
guess i915 attempts to do.

Thanks,
     Thomas

-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 99video
URL: <http://lists.freedesktop.org/archives/intel-gfx/attachments/20140609/cc551918/attachment.ksh>


More information about the Intel-gfx mailing list