Re: [RFC][PATCH -mm 1/3] Separate freezer from PM code

2007-04-23 Thread Pavel Machek
Hi!

> Now that the freezer is used by kprobes, it is no longer a PM-specific piece 
> of
> code.  Move the freezer code out of kernel/power and introduce the
> CONFIG_FREEZER option that will be chosen automatically if PM or KPROBES is 
> set.
> 
> Signed-off-by: Rafael J. Wysocki <[EMAIL PROTECTED]>

ACK.
Pavel

-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) 
http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [RFC][PATCH -mm 1/3] Separate freezer from PM code

2007-04-23 Thread Pavel Machek
Hi!

 Now that the freezer is used by kprobes, it is no longer a PM-specific piece 
 of
 code.  Move the freezer code out of kernel/power and introduce the
 CONFIG_FREEZER option that will be chosen automatically if PM or KPROBES is 
 set.
 
 Signed-off-by: Rafael J. Wysocki [EMAIL PROTECTED]

ACK.
Pavel

-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) 
http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[RFC][PATCH -mm 1/3] Separate freezer from PM code

2007-04-22 Thread Rafael J. Wysocki
From: Rafael J. Wysocki <[EMAIL PROTECTED]>

Now that the freezer is used by kprobes, it is no longer a PM-specific piece of
code.  Move the freezer code out of kernel/power and introduce the
CONFIG_FREEZER option that will be chosen automatically if PM or KPROBES is set.

Signed-off-by: Rafael J. Wysocki <[EMAIL PROTECTED]>
---
 arch/arm/Kconfig |5 +
 arch/avr32/Kconfig.debug |5 +
 arch/blackfin/Kconfig|5 +
 arch/frv/Kconfig |5 +
 arch/i386/Kconfig|5 +
 arch/ia64/Kconfig|5 +
 arch/mips/Kconfig|5 +
 arch/powerpc/Kconfig |5 +
 arch/ppc/Kconfig |5 +
 arch/s390/Kconfig|5 +
 arch/sh/Kconfig  |5 +
 arch/sparc64/Kconfig |5 +
 arch/x86_64/Kconfig  |8 +
 include/linux/freezer.h  |2 
 kernel/Makefile  |1 
 kernel/freezer.c |  224 +++
 kernel/kprobes.c |2 
 kernel/power/Makefile|2 
 kernel/power/process.c   |  224 ---
 19 files changed, 296 insertions(+), 227 deletions(-)

Index: linux-2.6.21-rc6-mm1/arch/x86_64/Kconfig
===
--- linux-2.6.21-rc6-mm1.orig/arch/x86_64/Kconfig   2007-04-22 
14:14:44.0 +0200
+++ linux-2.6.21-rc6-mm1/arch/x86_64/Kconfig2007-04-22 14:16:03.0 
+0200
@@ -695,6 +695,14 @@ config GENERIC_PENDING_IRQ
depends on GENERIC_HARDIRQS && SMP
default y
 
+#
+# Use the tasks freezer
+#
+config FREEZER
+   bool
+   default y
+   depends on PM || KPROBES
+
 menu "Power management options"
 
 source kernel/power/Kconfig
Index: linux-2.6.21-rc6-mm1/arch/avr32/Kconfig.debug
===
--- linux-2.6.21-rc6-mm1.orig/arch/avr32/Kconfig.debug  2007-04-22 
14:14:44.0 +0200
+++ linux-2.6.21-rc6-mm1/arch/avr32/Kconfig.debug   2007-04-22 
14:16:03.0 +0200
@@ -17,3 +17,8 @@ config KPROBES
   If in doubt, say "N".
 
 endmenu
+
+config FREEZER
+   bool
+   default y
+   depends on KPROBES
Index: linux-2.6.21-rc6-mm1/arch/frv/Kconfig
===
--- linux-2.6.21-rc6-mm1.orig/arch/frv/Kconfig  2007-04-22 14:14:44.0 
+0200
+++ linux-2.6.21-rc6-mm1/arch/frv/Kconfig   2007-04-22 14:16:03.0 
+0200
@@ -364,6 +364,11 @@ source "drivers/pcmcia/Kconfig"
 #sleep-deprived psychotic hacker types can say Y now, everyone else
 #should probably wait a while.
 
+config FREEZER
+   bool
+   default y
+   depends on PM
+
 menu "Power management options"
 source kernel/power/Kconfig
 endmenu
Index: linux-2.6.21-rc6-mm1/arch/i386/Kconfig
===
--- linux-2.6.21-rc6-mm1.orig/arch/i386/Kconfig 2007-04-22 14:14:44.0 
+0200
+++ linux-2.6.21-rc6-mm1/arch/i386/Kconfig  2007-04-22 14:16:03.0 
+0200
@@ -912,6 +912,11 @@ config ARCH_ENABLE_MEMORY_HOTPLUG
def_bool y
depends on HIGHMEM
 
+config FREEZER
+   bool
+   default y
+   depends on PM || KPROBES
+
 menu "Power management options (ACPI, APM)"
depends on !X86_VOYAGER
 
Index: linux-2.6.21-rc6-mm1/arch/ia64/Kconfig
===
--- linux-2.6.21-rc6-mm1.orig/arch/ia64/Kconfig 2007-04-22 14:14:44.0 
+0200
+++ linux-2.6.21-rc6-mm1/arch/ia64/Kconfig  2007-04-22 14:16:03.0 
+0200
@@ -490,6 +490,11 @@ source "fs/Kconfig.binfmt"
 
 endmenu
 
+config FREEZER
+   bool
+   default y
+   depends on PM || KPROBES
+
 menu "Power management and ACPI"
 
 source "kernel/power/Kconfig"
Index: linux-2.6.21-rc6-mm1/arch/powerpc/Kconfig
===
--- linux-2.6.21-rc6-mm1.orig/arch/powerpc/Kconfig  2007-04-22 
14:14:44.0 +0200
+++ linux-2.6.21-rc6-mm1/arch/powerpc/Kconfig   2007-04-22 14:16:03.0 
+0200
@@ -569,6 +569,11 @@ config CMDLINE
  some command-line options at build time by entering them here.  In
  most cases you will need to specify the root device here.
 
+config FREEZER
+   bool
+   default y
+   depends on PM || KPROBES
+
 if !44x || BROKEN
 source kernel/power/Kconfig
 endif
Index: linux-2.6.21-rc6-mm1/arch/ppc/Kconfig
===
--- linux-2.6.21-rc6-mm1.orig/arch/ppc/Kconfig  2007-04-22 14:14:44.0 
+0200
+++ linux-2.6.21-rc6-mm1/arch/ppc/Kconfig   2007-04-22 14:16:03.0 
+0200
@@ -1154,6 +1154,11 @@ config PROC_HARDWARE
 source "drivers/zorro/Kconfig"
 
 if !44x || BROKEN
+config FREEZER
+   bool
+   default y
+   depends on PM
+
 source kernel/power/Kconfig
 endif
 
Index: linux-2.6.21-rc6-mm1/arch/s390/Kconfig

[RFC][PATCH -mm 1/3] Separate freezer from PM code

2007-04-22 Thread Rafael J. Wysocki
From: Rafael J. Wysocki [EMAIL PROTECTED]

Now that the freezer is used by kprobes, it is no longer a PM-specific piece of
code.  Move the freezer code out of kernel/power and introduce the
CONFIG_FREEZER option that will be chosen automatically if PM or KPROBES is set.

Signed-off-by: Rafael J. Wysocki [EMAIL PROTECTED]
---
 arch/arm/Kconfig |5 +
 arch/avr32/Kconfig.debug |5 +
 arch/blackfin/Kconfig|5 +
 arch/frv/Kconfig |5 +
 arch/i386/Kconfig|5 +
 arch/ia64/Kconfig|5 +
 arch/mips/Kconfig|5 +
 arch/powerpc/Kconfig |5 +
 arch/ppc/Kconfig |5 +
 arch/s390/Kconfig|5 +
 arch/sh/Kconfig  |5 +
 arch/sparc64/Kconfig |5 +
 arch/x86_64/Kconfig  |8 +
 include/linux/freezer.h  |2 
 kernel/Makefile  |1 
 kernel/freezer.c |  224 +++
 kernel/kprobes.c |2 
 kernel/power/Makefile|2 
 kernel/power/process.c   |  224 ---
 19 files changed, 296 insertions(+), 227 deletions(-)

Index: linux-2.6.21-rc6-mm1/arch/x86_64/Kconfig
===
--- linux-2.6.21-rc6-mm1.orig/arch/x86_64/Kconfig   2007-04-22 
14:14:44.0 +0200
+++ linux-2.6.21-rc6-mm1/arch/x86_64/Kconfig2007-04-22 14:16:03.0 
+0200
@@ -695,6 +695,14 @@ config GENERIC_PENDING_IRQ
depends on GENERIC_HARDIRQS  SMP
default y
 
+#
+# Use the tasks freezer
+#
+config FREEZER
+   bool
+   default y
+   depends on PM || KPROBES
+
 menu Power management options
 
 source kernel/power/Kconfig
Index: linux-2.6.21-rc6-mm1/arch/avr32/Kconfig.debug
===
--- linux-2.6.21-rc6-mm1.orig/arch/avr32/Kconfig.debug  2007-04-22 
14:14:44.0 +0200
+++ linux-2.6.21-rc6-mm1/arch/avr32/Kconfig.debug   2007-04-22 
14:16:03.0 +0200
@@ -17,3 +17,8 @@ config KPROBES
   If in doubt, say N.
 
 endmenu
+
+config FREEZER
+   bool
+   default y
+   depends on KPROBES
Index: linux-2.6.21-rc6-mm1/arch/frv/Kconfig
===
--- linux-2.6.21-rc6-mm1.orig/arch/frv/Kconfig  2007-04-22 14:14:44.0 
+0200
+++ linux-2.6.21-rc6-mm1/arch/frv/Kconfig   2007-04-22 14:16:03.0 
+0200
@@ -364,6 +364,11 @@ source drivers/pcmcia/Kconfig
 #sleep-deprived psychotic hacker types can say Y now, everyone else
 #should probably wait a while.
 
+config FREEZER
+   bool
+   default y
+   depends on PM
+
 menu Power management options
 source kernel/power/Kconfig
 endmenu
Index: linux-2.6.21-rc6-mm1/arch/i386/Kconfig
===
--- linux-2.6.21-rc6-mm1.orig/arch/i386/Kconfig 2007-04-22 14:14:44.0 
+0200
+++ linux-2.6.21-rc6-mm1/arch/i386/Kconfig  2007-04-22 14:16:03.0 
+0200
@@ -912,6 +912,11 @@ config ARCH_ENABLE_MEMORY_HOTPLUG
def_bool y
depends on HIGHMEM
 
+config FREEZER
+   bool
+   default y
+   depends on PM || KPROBES
+
 menu Power management options (ACPI, APM)
depends on !X86_VOYAGER
 
Index: linux-2.6.21-rc6-mm1/arch/ia64/Kconfig
===
--- linux-2.6.21-rc6-mm1.orig/arch/ia64/Kconfig 2007-04-22 14:14:44.0 
+0200
+++ linux-2.6.21-rc6-mm1/arch/ia64/Kconfig  2007-04-22 14:16:03.0 
+0200
@@ -490,6 +490,11 @@ source fs/Kconfig.binfmt
 
 endmenu
 
+config FREEZER
+   bool
+   default y
+   depends on PM || KPROBES
+
 menu Power management and ACPI
 
 source kernel/power/Kconfig
Index: linux-2.6.21-rc6-mm1/arch/powerpc/Kconfig
===
--- linux-2.6.21-rc6-mm1.orig/arch/powerpc/Kconfig  2007-04-22 
14:14:44.0 +0200
+++ linux-2.6.21-rc6-mm1/arch/powerpc/Kconfig   2007-04-22 14:16:03.0 
+0200
@@ -569,6 +569,11 @@ config CMDLINE
  some command-line options at build time by entering them here.  In
  most cases you will need to specify the root device here.
 
+config FREEZER
+   bool
+   default y
+   depends on PM || KPROBES
+
 if !44x || BROKEN
 source kernel/power/Kconfig
 endif
Index: linux-2.6.21-rc6-mm1/arch/ppc/Kconfig
===
--- linux-2.6.21-rc6-mm1.orig/arch/ppc/Kconfig  2007-04-22 14:14:44.0 
+0200
+++ linux-2.6.21-rc6-mm1/arch/ppc/Kconfig   2007-04-22 14:16:03.0 
+0200
@@ -1154,6 +1154,11 @@ config PROC_HARDWARE
 source drivers/zorro/Kconfig
 
 if !44x || BROKEN
+config FREEZER
+   bool
+   default y
+   depends on PM
+
 source kernel/power/Kconfig
 endif
 
Index: linux-2.6.21-rc6-mm1/arch/s390/Kconfig