All of lore.kernel.org
 help / color / mirror / Atom feed
From: Pavel Machek <pavel@ucw.cz>
To: Nigel Cunningham <ncunningham@linuxmail.org>
Cc: Andrew Morton <akpm@digeo.com>,
	Patrick Mochel <mochel@digitalimplant.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] Suspend2 Merge: Driver model patches 0/2
Date: Thu, 16 Sep 2004 13:18:52 +0200	[thread overview]
Message-ID: <20040916111852.GC5467@elf.ucw.cz> (raw)
In-Reply-To: <1095332314.3855.157.camel@laptop.cunninghams>

Hi!

> Here are two patches for the driver model, which have been in use in
> suspend2 for around a month.
> 
> The first provides support for keeping part of the device tree alive
> while suspending the remainder. This is accomplished by abstracting the
> dpm_active, dpm_off and dpm_irq lists into a new struct partial device

I believe this is wrong approach.

For atomic snapshot to work, all devices need to be stopped. If your
video card does DMA, it needs to be stopped. So all drivers need to
know, you can not just exclude part of tree.

Now, you probably do not want disks to spin down and you want your
screen unblanked (as an optimalization/speedup). Patch for keeping
disk up is allready in -mm. Patch for keeping radeonfb up looks like
this, and is pending, too.

If more such patches are needed, post them, but not telling drivers
based on their class is not an option.

								Pavel

--- clean-mm/drivers/video/aty/radeon_pm.c	2004-08-24 09:03:18.000000000 +0200
+++ linux-mm/drivers/video/aty/radeon_pm.c	2004-09-15 13:00:51.000000000 +0200
@@ -871,7 +871,8 @@
 	agp_enable(0);
 #endif
 
-	fb_set_suspend(info, 1);
+	if (system_state != SYSTEM_SNAPSHOT)
+		fb_set_suspend(info, 1);
 
 	if (!(info->flags & FBINFO_HWACCEL_DISABLED)) {
 		/* Make sure engine is reset */
@@ -880,12 +881,14 @@
 		radeon_engine_idle();
 	}
 
-	/* Blank display and LCD */
-	radeonfb_blank(VESA_POWERDOWN, info);
-
-	/* Sleep */
-	rinfo->asleep = 1;
-	rinfo->lock_blank = 1;
+	if (system_state != SYSTEM_SNAPSHOT) {
+		/* Blank display and LCD */
+		radeonfb_blank(VESA_POWERDOWN, info);
+
+		/* Sleep */
+		rinfo->asleep = 1;
+		rinfo->lock_blank = 1;
+	}
 
 	/* Suspend the chip to D2 state when supported
 	 */

-- 
People were complaining that M$ turns users into beta-testers...
...jr ghea gurz vagb qrirybcref, naq gurl frrz gb yvxr vg gung jnl!

  reply	other threads:[~2004-09-16 11:19 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-09-16 10:58 [PATCH] Suspend2 Merge: Driver model patches 0/2 Nigel Cunningham
2004-09-16 11:18 ` Pavel Machek [this message]
2004-09-16 11:29   ` Nigel Cunningham
2004-09-16 11:32     ` Pavel Machek
2004-09-16 11:47       ` Nigel Cunningham
2004-09-16 12:13         ` Pavel Machek
2004-09-16 22:06           ` Nigel Cunningham

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20040916111852.GC5467@elf.ucw.cz \
    --to=pavel@ucw.cz \
    --cc=akpm@digeo.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mochel@digitalimplant.org \
    --cc=ncunningham@linuxmail.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.