public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] kernel/power/disk.c trivial cleanups
@ 2005-03-03 23:15 Todd Poynor
  2005-03-04  9:16 ` Pavel Machek
  0 siblings, 1 reply; 3+ messages in thread
From: Todd Poynor @ 2005-03-03 23:15 UTC (permalink / raw)
  To: linux-kernel

* Remove duplicate include.

* Avoid "mode set to ''" message when error updating /sys/power/disk.

Signed-off-by: Todd Poynor <tpoynor@mvista.com>

--- linux-2.6.11-rc4-orig/kernel/power/disk.c	2005-02-23 09:47:03.000000000 -0800
+++ linux-2.6.11-rc4-pm/kernel/power/disk.c	2005-03-03 05:00:18.609860968 -0800
@@ -16,7 +16,6 @@
 #include <linux/device.h>
 #include <linux/delay.h>
 #include <linux/fs.h>
-#include <linux/device.h>
 #include "power.h"
 
 
@@ -321,8 +320,9 @@
 	} else
 		error = -EINVAL;
 
-	pr_debug("PM: suspend-to-disk mode set to '%s'\n",
-		 pm_disk_modes[mode]);
+	if (mode == pm_disk_mode)
+		pr_debug("PM: suspend-to-disk mode set to '%s'\n",
+			 pm_disk_modes[mode]);
 	up(&pm_sem);
 	return error ? error : n;
 }

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] kernel/power/disk.c trivial cleanups
  2005-03-03 23:15 [PATCH] kernel/power/disk.c trivial cleanups Todd Poynor
@ 2005-03-04  9:16 ` Pavel Machek
  2005-03-04 16:39   ` Stefan Seyfried
  0 siblings, 1 reply; 3+ messages in thread
From: Pavel Machek @ 2005-03-04  9:16 UTC (permalink / raw)
  To: Todd Poynor; +Cc: linux-kernel

Hi!

> * Remove duplicate include.
> 
> * Avoid "mode set to ''" message when error updating /sys/power/disk.
> 
> Signed-off-by: Todd Poynor <tpoynor@mvista.com>

Duplicate remove killed, thanks. I do not think debugging print
requires that much care...
								Pavel
-- 
People were complaining that M$ turns users into beta-testers...
...jr ghea gurz vagb qrirybcref, naq gurl frrz gb yvxr vg gung jnl!

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] kernel/power/disk.c trivial cleanups
  2005-03-04  9:16 ` Pavel Machek
@ 2005-03-04 16:39   ` Stefan Seyfried
  0 siblings, 0 replies; 3+ messages in thread
From: Stefan Seyfried @ 2005-03-04 16:39 UTC (permalink / raw)
  To: Pavel Machek; +Cc: linux-kernel, tpoynor

Pavel Machek wrote:

> Duplicate remove killed, thanks. I do not think debugging print
> requires that much care...

I think it does. I tried s4bios ("firmware" mode) on hp 4150 today and
wondered why it said "mode set to firmware" but in fact did not do it.
You'll get a complete report for this later ;-)

Stefan


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2005-03-04 17:21 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-03-03 23:15 [PATCH] kernel/power/disk.c trivial cleanups Todd Poynor
2005-03-04  9:16 ` Pavel Machek
2005-03-04 16:39   ` Stefan Seyfried

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox