lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20070701202336.GV10869@stusta.de>
Date:	Sun, 1 Jul 2007 22:23:36 +0200
From:	Adrian Bunk <bunk@...sta.de>
To:	Andrew Morton <akpm@...ux-foundation.org>,
	"Rafael J. Wysocki" <rjw@...k.pl>, Pavel Machek <pavel@....cz>
Cc:	linux-kernel@...r.kernel.org, linux-pm@...ts.linux-foundation.org
Subject: [-mm patch] kernel/power/main.c: make code static

On Thu, Jun 28, 2007 at 03:43:21AM -0700, Andrew Morton wrote:
>...
> Changes since 2.6.22-rc4-mm2:
>...
> +pm-reduce-code-duplication-between-mainc-and-userc.patch
>...
>  PM updates
>...


Some code can now become static.

Signed-off-by: Adrian Bunk <bunk@...sta.de>

---

 include/linux/pm.h   |    1 -
 kernel/power/main.c  |    4 ++--
 kernel/power/power.h |    1 -
 3 files changed, 2 insertions(+), 4 deletions(-)

--- linux-2.6.22-rc6-mm1/kernel/power/power.h.old	2007-07-01 00:21:34.000000000 +0200
+++ linux-2.6.22-rc6-mm1/kernel/power/power.h	2007-07-01 00:21:41.000000000 +0200
@@ -177,7 +177,6 @@
 				unsigned int, char *);
 
 /* kernel/power/main.c */
-extern int suspend_enter(suspend_state_t state);
 extern int suspend_devices_and_enter(suspend_state_t state);
 extern struct blocking_notifier_head pm_chain_head;
 
--- linux-2.6.22-rc6-mm1/include/linux/pm.h.old	2007-07-01 00:22:53.000000000 +0200
+++ linux-2.6.22-rc6-mm1/include/linux/pm.h	2007-07-01 00:23:04.000000000 +0200
@@ -138,7 +138,6 @@
  * @pm_ops: The new power management operations to set.
  */
 extern void pm_set_ops(struct pm_ops *pm_ops);
-extern struct pm_ops *pm_ops;
 extern int pm_suspend(suspend_state_t state);
 
 extern int pm_valid_only_mem(suspend_state_t state);
--- linux-2.6.22-rc6-mm1/kernel/power/main.c.old	2007-07-01 00:21:49.000000000 +0200
+++ linux-2.6.22-rc6-mm1/kernel/power/main.c	2007-07-01 00:23:11.000000000 +0200
@@ -31,7 +31,7 @@
 
 DEFINE_MUTEX(pm_mutex);
 
-struct pm_ops *pm_ops;
+static struct pm_ops *pm_ops;
 
 /**
  *	pm_set_ops - Set the global power method table. 
@@ -127,7 +127,7 @@
  *
  *	This function should be called after devices have been suspended.
  */
-int suspend_enter(suspend_state_t state)
+static int suspend_enter(suspend_state_t state)
 {
 	int error = 0;
 

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ