summaryrefslogtreecommitdiff
path: root/packages
diff options
context:
space:
mode:
authorMichael Lauer <mickey@vanille-media.de>2006-05-20 18:31:50 +0000
committerOpenEmbedded Project <openembedded-devel@lists.openembedded.org>2006-05-20 18:31:50 +0000
commit61a3368e962e14767ccbd4f24456b362bedbfdd2 (patch)
tree365738e7b61ac4c5ed95e64876acc334490c54f7 /packages
parentf89ded6650e53252ce92bb12072a47f63badc918 (diff)
parent5dc648ea9c4ff5e7976f17459dc2fb685fcebc26 (diff)
merge of 17b5ed09da5a4cdb493874b746d2586d5ba53c86
and 8d5e1a3025b2da6e7d30136891450c13c77eacfe
Diffstat (limited to 'packages')
-rw-r--r--packages/linux/linux-ezx/a780-transflash_power.patch132
-rw-r--r--packages/linux/linux-ezx/defconfig-a78017
-rw-r--r--packages/linux/linux-ezx/defconfig-e68021
-rw-r--r--packages/linux/linux-ezx/dpm-core-2.6.16.patch5197
-rw-r--r--packages/linux/linux-ezx/dpm-pxa27x-2.6.16.patch2469
-rw-r--r--packages/linux/linux-ezx/exz-platformdevices.patch63
-rw-r--r--packages/linux/linux-ezx/ezx-kbd.patch768
-rw-r--r--packages/linux/linux-ezx/ezx-mmc-ro.patch24
-rw-r--r--packages/linux/linux-ezx/ezx_camera.patch26846
-rw-r--r--packages/linux/linux-ezx/ezx_core.patch15352
-rw-r--r--packages/linux/linux-ezx/ezx_defconfig.patch4449
-rw-r--r--packages/linux/linux-ezx/ezx_mtd.patch219
-rw-r--r--packages/linux/linux-ezx/ezx_pxa_ssp.patch780
-rw-r--r--packages/linux/linux-ezx/ezx_roflash.patch895
-rw-r--r--packages/linux/linux-ezx/ezx_serial_emu.patch16
-rw-r--r--packages/linux/linux-ezx/ezx_sound.patch6874
-rw-r--r--packages/linux/linux-ezx/ezx_ts.patch1026
-rw-r--r--packages/linux/linux-ezx/ezx_usb_gadged_serial_pxa27x.patch48
-rw-r--r--packages/linux/linux-ezx/ezxfb-fix-screensave.patch34
-rw-r--r--packages/linux/linux-ezx/keypad-module.patch249
-rw-r--r--packages/linux/linux-ezx/laforge_config.patch1302
-rw-r--r--packages/linux/linux-ezx/nobody_cared.patch13
-rw-r--r--packages/linux/linux-ezx/old/.mtn2git_empty0
-rw-r--r--packages/linux/linux-ezx/old/ezx_pxamci_debug.patch70
-rw-r--r--packages/linux/linux-ezx/patch-2.6.16.134985
-rw-r--r--packages/linux/linux-ezx/pxa-spi.patch1041
-rw-r--r--packages/linux/linux-ezx/pxa27x_udc-more.patch106
-rw-r--r--packages/linux/linux-ezx/pxa7xx_udc.patch2738
-rw-r--r--packages/linux/linux-ezx/pxa_mtd_fix.patch45
-rw-r--r--packages/linux/linux-ezx/pxa_serial_bug_workaround.patch36
-rw-r--r--packages/linux/linux-ezx/pxa_serial_dpm.patch25
-rw-r--r--packages/linux/linux-ezx/pxamci-4bit.patch64
-rw-r--r--packages/linux/linux-ezx/pxamci_debug.patch15
-rw-r--r--packages/linux/linux-ezx/sa1100_rtc.patch604
-rw-r--r--packages/linux/linux-ezx/ssp_pcap_nobitbang.patch321
-rw-r--r--packages/linux/linux-ezx_2.6.16.13.bb46
36 files changed, 36 insertions, 76854 deletions
diff --git a/packages/linux/linux-ezx/a780-transflash_power.patch b/packages/linux/linux-ezx/a780-transflash_power.patch
deleted file mode 100644
index 4b4d4634b5..0000000000
--- a/packages/linux/linux-ezx/a780-transflash_power.patch
+++ /dev/null
@@ -1,132 +0,0 @@
-Index: linux-2.6.16.5-ezx/arch/arm/mach-pxa/ezx.c
-===================================================================
---- linux-2.6.16.5-ezx.orig/arch/arm/mach-pxa/ezx.c 2006-05-02 19:17:34.000000000 +0200
-+++ linux-2.6.16.5-ezx/arch/arm/mach-pxa/ezx.c 2006-05-02 22:30:24.000000000 +0200
-@@ -137,10 +137,63 @@
- /* this is only e680, i guess */
- }
-
-+#if defined(CONFIG_PXA_EZX_A780)
-+static u_int8_t mmc_voltage[] = {
-+ [MMC_VDD_160] = 5,
-+ [MMC_VDD_170] = 5,
-+ [MMC_VDD_180] = 6,
-+ [MMC_VDD_190] = 6,
-+ [MMC_VDD_200] = 7,
-+ [MMC_VDD_210] = 7,
-+ [MMC_VDD_220] = 8,
-+ [MMC_VDD_230] = 8,
-+ [MMC_VDD_240] = 9,
-+ [MMC_VDD_250] = 9,
-+ [MMC_VDD_260] = 10,
-+ [MMC_VDD_270] = 10,
-+ [MMC_VDD_280] = 11,
-+ [MMC_VDD_290] = 11,
-+ [MMC_VDD_300] = 12,
-+ [MMC_VDD_310] = 12,
-+ [MMC_VDD_320] = 13,
-+ [MMC_VDD_330] = 13,
-+ [MMC_VDD_340] = 14,
-+ [MMC_VDD_350] = 14,
-+ [MMC_VDD_360] = 15,
-+};
-+#elif defined(CONFIG_PXA_EZX_E680)
-+static u_int8_t mmc_voltage[] = {
-+ [MMC_VDD_160] = 3,
-+ [MMC_VDD_170] = 3,
-+ [MMC_VDD_180] = 3,
-+ [MMC_VDD_190] = 3,
-+ [MMC_VDD_200] = 3,
-+ [MMC_VDD_210] = 3,
-+ [MMC_VDD_220] = 3,
-+ [MMC_VDD_230] = 3,
-+ [MMC_VDD_240] = 3,
-+ [MMC_VDD_250] = 3,
-+ [MMC_VDD_260] = 3,
-+ [MMC_VDD_270] = 3,
-+ [MMC_VDD_280] = 3,
-+ [MMC_VDD_290] = 3,
-+ [MMC_VDD_300] = 3,
-+ [MMC_VDD_310] = 3,
-+ [MMC_VDD_320] = 3,
-+ [MMC_VDD_330] = 3,
-+ [MMC_VDD_340] = 3,
-+ [MMC_VDD_350] = 3,
-+ [MMC_VDD_360] = 3,
-+
-+};
-+#endif
-+
- static void ezx_mci_setpower(struct device *dev, unsigned int vdd)
- {
-- printk("%s entered\n", __FUNCTION__);
-- /* FIXME: implement this */
-+ printk("%s(vdd=%u) entered\n", __FUNCTION__, vdd);
-+ if (vdd <= MMC_VDD_360)
-+ SSP_PCAP_MMCSD_voltage(mmc_voltage[vdd]);
-+
- SSP_PCAP_MMCSD_poweron();
- }
-
-@@ -152,7 +205,14 @@
- }
-
- static struct pxamci_platform_data ezx_mci_platform_data = {
-- .ocr_mask = MMC_VDD_27_28, //|MMC_VDD_32_33|MMC_VDD_33_34,
-+#if defined(CONFIG_PXA_EZX_E680)
-+ .ocr_mask = MMC_VDD_27_28,
-+#elif defined(CONFIG_PXA_EZX_A780)
-+ .ocr_mask = MMC_VDD_160_165|MMC_VDD_18_19|MMC_VDD_20_21
-+ |MMC_VDD_22_23|MMC_VDD_24_25|MMC_VDD_26_27
-+ |MMC_VDD_28_29|MMC_VDD_30_31|MMC_VDD_32_33
-+ |MMC_VDD_34_35|MMC_VDD_35_36,
-+#endif
- .init = ezx_mci_init,
- .get_ro = ezx_mci_get_ro,
- .setpower = ezx_mci_setpower,
-Index: linux-2.6.16.5-ezx/drivers/misc/ezx/ssp_pcap_main.c
-===================================================================
---- linux-2.6.16.5-ezx.orig/drivers/misc/ezx/ssp_pcap_main.c 2006-05-02 19:17:34.000000000 +0200
-+++ linux-2.6.16.5-ezx/drivers/misc/ezx/ssp_pcap_main.c 2006-05-02 22:29:58.000000000 +0200
-@@ -125,18 +125,41 @@
-
- void SSP_PCAP_MMCSD_poweroff(void)
- {
-+#if defined(CONFIG_PXA_EZX_E680)
- SSP_PCAP_bit_clean(SSP_PCAP_ADJ_BIT_AUX_VREG_VAUX2_EN);
- SSP_PCAP_bit_clean(SSP_PCAP_ADJ_BIT_AUX_VREG_VAUX2_EN);
-+#else
-+ SSP_PCAP_bit_clean(SSP_PCAP_ADJ_BIT_AUX_VREG_VAUX3_EN);
-+#endif
- }
- EXPORT_SYMBOL(SSP_PCAP_MMCSD_poweroff);
-
- void SSP_PCAP_MMCSD_poweron(void)
- {
-+#if defined(CONFIG_PXA_EZX_E680)
- SSP_PCAP_bit_set(SSP_PCAP_ADJ_BIT_AUX_VREG_VAUX2_EN);
- SSP_PCAP_bit_set(SSP_PCAP_ADJ_BIT_AUX_VREG_VAUX2_EN);
-+#elif defined(CONFIG_PXA_EZX_A780)
-+ SSP_PCAP_bit_set(SSP_PCAP_ADJ_BIT_AUX_VREG_VAUX3_EN);
-+#endif
- }
- EXPORT_SYMBOL(SSP_PCAP_MMCSD_poweron);
-
-+void SSP_PCAP_MMCSD_voltage(unsigned char bits)
-+{
-+ unsigned int tmp;
-+ SSP_PCAP_read_data_from_PCAP(SSP_PCAP_ADJ_AUX_VREG_REGISTER, &tmp);
-+#if defined(CONFIG_PXA_EZX_E680)
-+ tmp &= 0xffffff9f; /* zero all vaux2 bits */
-+ tmp |= (bits & 0x3) << 5;
-+#elif defined(CONFIG_PXA_EZX_A780)
-+ tmp &= 0xfffff0ff; /* zero all vaux3 bits */
-+ tmp |= (bits & 0xf) << 8;
-+#endif
-+ SSP_PCAP_write_data_to_PCAP(SSP_PCAP_ADJ_AUX_VREG_REGISTER, tmp);
-+}
-+EXPORT_SYMBOL(SSP_PCAP_MMCSD_voltage);
-+
- static void accessory_bus_detect_handler(ACCESSORY_TYPE type,ACCESSORY_DEVICE_STATUS status,void* privdata )
- {
- sspUsbAccessoryInfo.type = (u32)type;
diff --git a/packages/linux/linux-ezx/defconfig-a780 b/packages/linux/linux-ezx/defconfig-a780
index e9dda2b13f..560530a1ce 100644
--- a/packages/linux/linux-ezx/defconfig-a780
+++ b/packages/linux/linux-ezx/defconfig-a780
@@ -1,7 +1,7 @@
#
# Automatically generated make config: don't edit
-# Linux kernel version: 2.6.16.5
-# Thu May 4 17:12:53 2006
+# Linux kernel version: 2.6.16.13
+# Thu May 18 19:40:25 2006
#
CONFIG_ARM=y
CONFIG_MMU=y
@@ -19,7 +19,7 @@ CONFIG_INIT_ENV_ARG_LIMIT=32
#
# General setup
#
-CONFIG_LOCALVERSION="-ezx3"
+CONFIG_LOCALVERSION="-ezx6"
# CONFIG_LOCALVERSION_AUTO is not set
# CONFIG_SWAP is not set
CONFIG_SYSVIPC=y
@@ -120,7 +120,9 @@ CONFIG_PXA_EZX=y
CONFIG_PXA_EZX_A780=y
CONFIG_PXA27x=y
CONFIG_IWMMXT=y
-CONFIG_PXA_SSP=y
+CONFIG_PXA_SPI=y
+CONFIG_PXA_EZX_PCAP=y
+CONFIG_PXA_EZX_PCAP_EMU=m
#
# Processor Type
@@ -169,7 +171,7 @@ CONFIG_ALIGNMENT_TRAP=y
#
CONFIG_ZBOOT_ROM_TEXT=0x0
CONFIG_ZBOOT_ROM_BSS=0x0
-CONFIG_CMDLINE="root=/dev/mmcblk0p2 rootfstype=ext3 rootdelay=5 ip=192.168.1.2:192.168.1.10:192.168.1.10:255.255.255.0:ezx:usb0:off console=tty0 console=ttyS2,115200n8"
+CONFIG_CMDLINE="mem=32M root=/dev/mmcblk0p1 rootfstype=ext3 rootdelay=1 ip=192.168.1.2:192.168.1.10:192.168.1.10:255.255.255.0:ezx:usb0:off console=ttyS2,115200n8 console=tty0"
# CONFIG_XIP_KERNEL is not set
#
@@ -236,7 +238,7 @@ CONFIG_TCP_CONG_BIC=y
# IP: Virtual Server Configuration
#
# CONFIG_IP_VS is not set
-CONFIG_IPV6=y
+CONFIG_IPV6=m
# CONFIG_IPV6_PRIVACY is not set
CONFIG_INET6_AH=m
CONFIG_INET6_ESP=m
@@ -692,11 +694,12 @@ CONFIG_INPUT_MOUSE=y
# CONFIG_MOUSE_VSXXXAA is not set
# CONFIG_INPUT_JOYSTICK is not set
CONFIG_INPUT_TOUCHSCREEN=y
-CONFIG_TOUCHSCREEN_ADS7846=m
+# CONFIG_TOUCHSCREEN_ADS7846 is not set
# CONFIG_TOUCHSCREEN_GUNZE is not set
# CONFIG_TOUCHSCREEN_ELO is not set
# CONFIG_TOUCHSCREEN_MTOUCH is not set
# CONFIG_TOUCHSCREEN_MK712 is not set
+CONFIG_TOUCHSCREEN_PCAP=m
# CONFIG_INPUT_MISC is not set
#
diff --git a/packages/linux/linux-ezx/defconfig-e680 b/packages/linux/linux-ezx/defconfig-e680
index d59985244e..560530a1ce 100644
--- a/packages/linux/linux-ezx/defconfig-e680
+++ b/packages/linux/linux-ezx/defconfig-e680
@@ -1,7 +1,7 @@
#
# Automatically generated make config: don't edit
-# Linux kernel version: 2.6.16.5
-# Thu May 4 17:12:53 2006
+# Linux kernel version: 2.6.16.13
+# Thu May 18 19:40:25 2006
#
CONFIG_ARM=y
CONFIG_MMU=y
@@ -19,7 +19,7 @@ CONFIG_INIT_ENV_ARG_LIMIT=32
#
# General setup
#
-CONFIG_LOCALVERSION="-ezx3"
+CONFIG_LOCALVERSION="-ezx6"
# CONFIG_LOCALVERSION_AUTO is not set
# CONFIG_SWAP is not set
CONFIG_SYSVIPC=y
@@ -116,11 +116,13 @@ CONFIG_PXA_EZX=y
# CONFIG_MACH_MAINSTONE is not set
# CONFIG_ARCH_PXA_IDP is not set
# CONFIG_PXA_SHARPSL is not set
-CONFIG_PXA_EZX_E680=y
-# CONFIG_PXA_EZX_A780 is not set
+# CONFIG_PXA_EZX_E680 is not set
+CONFIG_PXA_EZX_A780=y
CONFIG_PXA27x=y
CONFIG_IWMMXT=y
-CONFIG_PXA_SSP=y
+CONFIG_PXA_SPI=y
+CONFIG_PXA_EZX_PCAP=y
+CONFIG_PXA_EZX_PCAP_EMU=m
#
# Processor Type
@@ -169,7 +171,7 @@ CONFIG_ALIGNMENT_TRAP=y
#
CONFIG_ZBOOT_ROM_TEXT=0x0
CONFIG_ZBOOT_ROM_BSS=0x0
-CONFIG_CMDLINE="root=/dev/mmcblk0p2 rootfstype=ext3 rootdelay=5 ip=192.168.1.2:192.168.1.10:192.168.1.10:255.255.255.0:ezx:usb0:off console=tty0 console=ttyS2,115200n8"
+CONFIG_CMDLINE="mem=32M root=/dev/mmcblk0p1 rootfstype=ext3 rootdelay=1 ip=192.168.1.2:192.168.1.10:192.168.1.10:255.255.255.0:ezx:usb0:off console=ttyS2,115200n8 console=tty0"
# CONFIG_XIP_KERNEL is not set
#
@@ -236,7 +238,7 @@ CONFIG_TCP_CONG_BIC=y
# IP: Virtual Server Configuration
#
# CONFIG_IP_VS is not set
-CONFIG_IPV6=y
+CONFIG_IPV6=m
# CONFIG_IPV6_PRIVACY is not set
CONFIG_INET6_AH=m
CONFIG_INET6_ESP=m
@@ -692,11 +694,12 @@ CONFIG_INPUT_MOUSE=y
# CONFIG_MOUSE_VSXXXAA is not set
# CONFIG_INPUT_JOYSTICK is not set
CONFIG_INPUT_TOUCHSCREEN=y
-CONFIG_TOUCHSCREEN_ADS7846=m
+# CONFIG_TOUCHSCREEN_ADS7846 is not set
# CONFIG_TOUCHSCREEN_GUNZE is not set
# CONFIG_TOUCHSCREEN_ELO is not set
# CONFIG_TOUCHSCREEN_MTOUCH is not set
# CONFIG_TOUCHSCREEN_MK712 is not set
+CONFIG_TOUCHSCREEN_PCAP=m
# CONFIG_INPUT_MISC is not set
#
diff --git a/packages/linux/linux-ezx/dpm-core-2.6.16.patch b/packages/linux/linux-ezx/dpm-core-2.6.16.patch
deleted file mode 100644
index d0d34d1225..0000000000
--- a/packages/linux/linux-ezx/dpm-core-2.6.16.patch
+++ /dev/null
@@ -1,5197 +0,0 @@
-This is the Dynamic Power Management Core, as released by the upstream
-project for 2.6.16.
-
-Index: linux-2.6.16/arch/arm/Kconfig
-===================================================================
---- linux-2.6.16.orig/arch/arm/Kconfig 2006-03-20 05:53:29.000000000 +0000
-+++ linux-2.6.16/arch/arm/Kconfig 2006-04-11 06:34:10.000000000 +0000
-@@ -832,3 +832,5 @@
- source "crypto/Kconfig"
-
- source "lib/Kconfig"
-+
-+source "drivers/dpm/Kconfig"
-Index: linux-2.6.16/arch/i386/Kconfig
-===================================================================
---- linux-2.6.16.orig/arch/i386/Kconfig 2006-03-20 05:53:29.000000000 +0000
-+++ linux-2.6.16/arch/i386/Kconfig 2006-04-11 06:34:10.000000000 +0000
-@@ -908,6 +908,7 @@
- endmenu
-
- source "arch/i386/kernel/cpu/cpufreq/Kconfig"
-+source "arch/i386/kernel/cpu/dpm/Kconfig"
-
- endmenu
-
-Index: linux-2.6.16/arch/i386/kernel/cpu/Makefile
-===================================================================
---- linux-2.6.16.orig/arch/i386/kernel/cpu/Makefile 2006-03-20 05:53:29.000000000 +0000
-+++ linux-2.6.16/arch/i386/kernel/cpu/Makefile 2006-04-11 06:34:10.000000000 +0000
-@@ -17,3 +17,4 @@
-
- obj-$(CONFIG_MTRR) += mtrr/
- obj-$(CONFIG_CPU_FREQ) += cpufreq/
-+obj-$(CONFIG_DPM) += dpm/
-Index: linux-2.6.16/arch/i386/kernel/cpu/dpm/Kconfig
-===================================================================
---- linux-2.6.16.orig/arch/i386/kernel/cpu/dpm/Kconfig 1970-01-01 00:00:00.000000000 +0000
-+++ linux-2.6.16/arch/i386/kernel/cpu/dpm/Kconfig 2006-04-11 06:34:10.000000000 +0000
-@@ -0,0 +1,10 @@
-+#
-+# Dynamic Power Management
-+#
-+
-+source "drivers/dpm/Kconfig"
-+
-+config DPM_CENTRINO
-+ tristate "DPM for Intel Centrino Enhanced Speedstep"
-+ depends on DPM
-+ default n
-Index: linux-2.6.16/arch/i386/kernel/cpu/dpm/Makefile
-===================================================================
---- linux-2.6.16.orig/arch/i386/kernel/cpu/dpm/Makefile 1970-01-01 00:00:00.000000000 +0000
-+++ linux-2.6.16/arch/i386/kernel/cpu/dpm/Makefile 2006-04-11 06:34:10.000000000 +0000
-@@ -0,0 +1,3 @@
-+obj-$(CONFIG_DPM) += x86_dpm.o
-+obj-$(CONFIG_DPM_CENTRINO) += centrino_dpm.o
-+
-Index: linux-2.6.16/arch/i386/kernel/cpu/dpm/centrino_dpm.c
-===================================================================
---- linux-2.6.16.orig/arch/i386/kernel/cpu/dpm/centrino_dpm.c 1970-01-01 00:00:00.000000000 +0000
-+++ linux-2.6.16/arch/i386/kernel/cpu/dpm/centrino_dpm.c 2006-04-11 06:34:10.000000000 +0000
-@@ -0,0 +1,133 @@
-+/*
-+ * 2003 (c) MontaVista Software, Inc. This file is licensed under the
-+ * terms of the GNU General Public License version 2. This program is
-+ * licensed "as is" without any warranty of any kind, whether express
-+ * or implied.
-+ *
-+ * Based on speedstep-centrino.c by Jeremy Fitzhardinge <jeremy@goop.org>
-+ */
-+
-+#include <linux/config.h>
-+#include <linux/dpm.h>
-+#include <linux/errno.h>
-+#include <linux/init.h>
-+#include <linux/kernel.h>
-+#include <linux/delay.h>
-+
-+#include <asm/msr.h>
-+#include <asm/processor.h>
-+#include <asm/cpufeature.h>
-+
-+/* Extract clock in kHz from PERF_CTL value */
-+static unsigned extract_clock(unsigned msr)
-+{
-+ msr = (msr >> 8) & 0xff;
-+ return msr * 100000;
-+}
-+
-+/* Return the current CPU frequency in kHz */
-+static unsigned get_cur_freq(void)
-+{
-+ unsigned l, h;
-+
-+ rdmsr(MSR_IA32_PERF_STATUS, l, h);
-+ return extract_clock(l);
-+}
-+
-+static int
-+dpm_centrino_init_opt(struct dpm_opt *opt)
-+{
-+ int v = opt->pp[DPM_MD_V];
-+ int cpu = opt->pp[DPM_MD_CPU_FREQ];
-+
-+ struct dpm_md_opt *md_opt = &opt->md_opt;
-+
-+ md_opt->v = v;
-+ md_opt->cpu = cpu;
-+ return 0;
-+}
-+
-+/* Fully determine the current machine-dependent operating point, and fill in a
-+ structure presented by the caller. This should only be called when the
-+ dpm_sem is held. This call can return an error if the system is currently at
-+ an operating point that could not be constructed by dpm_md_init_opt(). */
-+
-+static int
-+dpm_centrino_get_opt(struct dpm_opt *opt)
-+{
-+ struct dpm_md_opt *md_opt = &opt->md_opt;
-+
-+ md_opt->v = 100; /* TODO. */
-+ md_opt->cpu = get_cur_freq();
-+ return 0;
-+}
-+
-+static int
-+dpm_centrino_set_opt(struct dpm_md_opt *md_opt)
-+{
-+ unsigned int msr = 0, oldmsr, h, mask = 0;
-+
-+ if (md_opt->cpu != -1) {
-+ msr |= ((md_opt->cpu)/100) << 8;
-+ mask |= 0xff00;
-+ }
-+
-+ if (md_opt->v != -1) {
-+ msr |= ((md_opt->v - 700) / 16);
-+ mask |= 0xff;
-+ }
-+
-+ rdmsr(MSR_IA32_PERF_CTL, oldmsr, h);
-+
-+ if (msr == (oldmsr & mask))
-+ return 0;
-+
-+ /* all but 16 LSB are "reserved", so treat them with
-+ care */
-+ oldmsr &= ~mask;
-+ msr &= mask;
-+ oldmsr |= msr;
-+
-+ wrmsr(MSR_IA32_PERF_CTL, oldmsr, h);
-+ return 0;
-+}
-+
-+static int dpm_centrino_startup(void)
-+{
-+ struct cpuinfo_x86 *cpu = cpu_data;
-+ unsigned l, h;
-+
-+ if (!cpu_has(cpu, X86_FEATURE_EST))
-+ return -ENODEV;
-+
-+ /* Check to see if Enhanced SpeedStep is enabled, and try to
-+ enable it if not. */
-+ rdmsr(MSR_IA32_MISC_ENABLE, l, h);
-+
-+ if (!(l & (1<<16))) {
-+ l |= (1<<16);
-+ wrmsr(MSR_IA32_MISC_ENABLE, l, h);
-+
-+ /* check to see if it stuck */
-+ rdmsr(MSR_IA32_MISC_ENABLE, l, h);
-+ if (!(l & (1<<16))) {
-+ printk(KERN_INFO "DPM: Couldn't enable Enhanced SpeedStep\n");
-+ return -ENODEV;
-+ }
-+ }
-+
-+ return 0;
-+}
-+
-+int __init dpm_centrino_init(void)
-+{
-+ printk("Dynamic Power Management for Intel Centrino Enhanced SpeedStep.\n");
-+
-+ dpm_bd.startup = dpm_centrino_startup;
-+ dpm_bd.init_opt = dpm_centrino_init_opt;
-+ dpm_bd.get_opt = dpm_centrino_get_opt;
-+ dpm_bd.set_opt = dpm_centrino_set_opt;
-+ return 0;
-+}
-+
-+__initcall(dpm_centrino_init);
-Index: linux-2.6.16/arch/i386/kernel/cpu/dpm/x86_dpm.c
-===================================================================
---- linux-2.6.16.orig/arch/i386/kernel/cpu/dpm/x86_dpm.c 1970-01-01 00:00:00.000000000 +0000
-+++ linux-2.6.16/arch/i386/kernel/cpu/dpm/x86_dpm.c 2006-04-11 06:34:10.000000000 +0000
-@@ -0,0 +1,133 @@
-+/*
-+ * 2003 (c) MontaVista Software, Inc. This file is licensed under the
-+ * terms of the GNU General Public License version 2. This program is
-+ * licensed "as is" without any warranty of any kind, whether express
-+ * or implied.
-+ */
-+
-+#include <linux/config.h>
-+#include <linux/dpm.h>
-+#include <linux/errno.h>
-+#include <linux/init.h>
-+#include <linux/kernel.h>
-+#include <linux/delay.h>
-+#include <linux/interrupt.h>
-+
-+#include <asm/page.h>
-+#include <asm/uaccess.h>
-+
-+struct dpm_bd dpm_bd;
-+
-+static int
-+dpm_x86_init_opt(struct dpm_opt *opt)
-+{
-+ return dpm_bd.init_opt ? dpm_bd.init_opt(opt) : -1;
-+}
-+
-+/* Fully determine the current machine-dependent operating point, and fill in a
-+ structure presented by the caller. This should only be called when the
-+ dpm_sem is held. This call can return an error if the system is currently at
-+ an operating point that could not be constructed by dpm_md_init_opt(). */
-+
-+static unsigned long loops_per_jiffy_ref = 0;
-+
-+static int
-+dpm_x86_get_opt(struct dpm_opt *opt)
-+{
-+ return dpm_bd.get_opt ? dpm_bd.get_opt(opt) : -1;
-+}
-+
-+int
-+dpm_x86_set_opt(struct dpm_opt *cur, struct dpm_opt *new)
-+{
-+ struct cpuinfo_x86 *cpu = cpu_data;
-+
-+ if (! new->md_opt.cpu) {
-+#ifdef CONFIG_PM
-+ pm_suspend(PM_SUSPEND_STANDBY);
-+
-+ /* Here when we wake up. Recursive call to switch back to
-+ * to task state.
-+ */
-+
-+ dpm_set_os(DPM_TASK_STATE);
-+#endif
-+ return 0;
-+ }
-+
-+ if (dpm_bd.set_opt){
-+ dpm_bd.set_opt(&new->md_opt);
-+
-+ }else{
-+ return -1;
-+ }
-+
-+ if (cur->md_opt.cpu && new->md_opt.cpu){
-+ loops_per_jiffy_ref = cpu->loops_per_jiffy;
-+ cpu->loops_per_jiffy =
-+ dpm_compute_lpj(loops_per_jiffy_ref ,
-+ cur->md_opt.cpu,
-+ new->md_opt.cpu);
-+
-+ loops_per_jiffy = cpu->loops_per_jiffy;
-+ if (cpu_khz)
-+ cpu_khz = dpm_compute_lpj(cpu_khz,
-+ cur->md_opt.cpu,
-+ new->md_opt.cpu);
-+ }
-+ return 0;
-+}
-+
-+/*
-+ * idle loop
-+ */
-+
-+static void (*orig_idle)(void);
-+
-+void dpm_x86_idle(void)
-+{
-+ extern void default_idle(void);
-+
-+ if (orig_idle)
-+ orig_idle();
-+ else
-+ default_idle();
-+}
-+
-+/****************************************************************************
-+ * Initialization/Exit
-+ ****************************************************************************/
-+
-+void
-+dpm_x86_startup(void)
-+{
-+ orig_idle = pm_idle;
-+ pm_idle = dpm_idle;
-+
-+ if (dpm_bd.startup)
-+ dpm_bd.startup();
-+}
-+
-+void
-+dpm_x86_cleanup(void)
-+{
-+ pm_idle = orig_idle;
-+
-+ if (dpm_bd.cleanup)
-+ dpm_bd.cleanup();
-+}
-+
-+int __init
-+dpm_x86_init(void)
-+{
-+ printk("Dynamic Power Management for x86.\n");
-+
-+ dpm_md.init_opt = dpm_x86_init_opt;
-+ dpm_md.set_opt = dpm_x86_set_opt;
-+ dpm_md.get_opt = dpm_x86_get_opt;
-+ dpm_md.idle = dpm_x86_idle;
-+ dpm_md.startup = dpm_x86_startup;
-+ dpm_md.cleanup = dpm_x86_cleanup;
-+ return 0;
-+}
-+__initcall(dpm_x86_init);
-Index: linux-2.6.16/arch/i386/kernel/process.c
-===================================================================
---- linux-2.6.16.orig/arch/i386/kernel/process.c 2006-03-20 05:53:29.000000000 +0000
-+++ linux-2.6.16/arch/i386/kernel/process.c 2006-04-11 06:34:10.000000000 +0000
-@@ -58,6 +58,8 @@
- #include <asm/tlbflush.h>
- #include <asm/cpu.h>
-
-+#include <linux/dpm.h>
-+
- asmlinkage void ret_from_fork(void) __asm__("ret_from_fork");
-
- static int hlt_counter;
-@@ -697,6 +699,7 @@
-
- disable_tsc(prev_p, next_p);
-
-+ dpm_set_os(next_p->dpm_state);
- return prev_p;
- }
-
-Index: linux-2.6.16/drivers/Makefile
-===================================================================
---- linux-2.6.16.orig/drivers/Makefile 2006-03-20 05:53:29.000000000 +0000
-+++ linux-2.6.16/drivers/Makefile 2006-04-11 06:34:10.000000000 +0000
-@@ -67,6 +67,7 @@
- obj-$(CONFIG_MCA) += mca/
- obj-$(CONFIG_EISA) += eisa/
- obj-$(CONFIG_CPU_FREQ) += cpufreq/
-+obj-$(CONFIG_DPM) += dpm/
- obj-$(CONFIG_MMC) += mmc/
- obj-$(CONFIG_INFINIBAND) += infiniband/
- obj-$(CONFIG_SGI_SN) += sn/
-Index: linux-2.6.16/drivers/base/core.c
-===================================================================
---- linux-2.6.16.orig/drivers/base/core.c 2006-03-20 05:53:29.000000000 +0000
-+++ linux-2.6.16/drivers/base/core.c 2006-04-11 06:34:10.000000000 +0000
-@@ -282,6 +282,8 @@
- if (parent)
- klist_add_tail(&dev->knode_parent, &parent->klist_children);
-
-+ assert_constraints(dev->constraints);
-+
- /* notify platform of device entry */
- if (platform_notify)
- platform_notify(dev);
-@@ -367,6 +369,8 @@
- klist_del(&dev->knode_parent);
- device_remove_file(dev, &dev->uevent_attr);
-
-+ deassert_constraints(dev->constraints);
-+
- /* Notify the platform of the removal, in case they
- * need to do anything...
- */
-Index: linux-2.6.16/drivers/base/power/Makefile
-===================================================================
---- linux-2.6.16.orig/drivers/base/power/Makefile 2006-03-20 05:53:29.000000000 +0000
-+++ linux-2.6.16/drivers/base/power/Makefile 2006-04-11 06:34:10.000000000 +0000
-@@ -1,4 +1,4 @@
--obj-y := shutdown.o
-+obj-y := shutdown.o power-dpm.o
- obj-$(CONFIG_PM) += main.o suspend.o resume.o runtime.o sysfs.o
-
- ifeq ($(CONFIG_DEBUG_DRIVER),y)
-Index: linux-2.6.16/drivers/base/power/power-dpm.c
-===================================================================
---- linux-2.6.16.orig/drivers/base/power/power-dpm.c 1970-01-01 00:00:00.000000000 +0000
-+++ linux-2.6.16/drivers/base/power/power-dpm.c 2006-04-11 06:35:28.000000000 +0000
-@@ -0,0 +1,473 @@
-+/*
-+ * power-dpm.c -- Dynamic Power Management LDM power hooks
-+ *
-+ * (c) 2003 MontaVista Software, Inc. This file is licensed under the
-+ * terms of the GNU General Public License version 2. This program is
-+ * licensed "as is" without any warranty of any kind, whether express or
-+ * implied.
-+ */
-+
-+#include <linux/device.h>
-+#include <linux/pm.h>
-+#include <linux/dpm.h>
-+#include <linux/sched.h>
-+#include <linux/init.h>
-+#include <linux/mm.h>
-+#include <linux/slab.h>
-+
-+#include "power.h"
-+
-+/*
-+ * power hotplug events
-+ */
-+
-+#define BUFFER_SIZE 1024 /* should be enough memory for the env */
-+#define NUM_ENVP 32 /* number of env pointers */
-+static unsigned long sequence_num;
-+static spinlock_t sequence_lock = SPIN_LOCK_UNLOCKED;
-+
-+void power_event(char *eventstr)
-+{
-+ char *argv [3];
-+ char **envp = NULL;
-+ char *buffer = NULL;
-+ char *scratch;
-+ int i = 0;
-+ int retval;
-+ unsigned long seq;
-+
-+ if (!uevent_helper[0])
-+ return;
-+
-+ envp = kmalloc(NUM_ENVP * sizeof (char *), GFP_KERNEL);
-+ if (!envp)
-+ return;
-+ memset (envp, 0x00, NUM_ENVP * sizeof (char *));
-+
-+ buffer = kmalloc(BUFFER_SIZE, GFP_KERNEL);
-+ if (!buffer)
-+ goto exit;
-+
-+ argv [0] = uevent_helper;
-+ argv [1] = "power";
-+ argv [2] = 0;
-+
-+ /* minimal command environment */
-+ envp [i++] = "HOME=/";
-+ envp [i++] = "PATH=/sbin:/bin:/usr/sbin:/usr/bin";
-+
-+ scratch = buffer;
-+
-+ envp [i++] = scratch;
-+ scratch += sprintf(scratch, "ACTION=event") + 1;
-+
-+ spin_lock(&sequence_lock);
-+ seq = sequence_num++;
-+ spin_unlock(&sequence_lock);
-+
-+ envp [i++] = scratch;
-+ scratch += sprintf(scratch, "SEQNUM=%ld", seq) + 1;
-+ envp [i++] = scratch;
-+ scratch += sprintf(scratch, "EVENT=%s", eventstr) + 1;
-+
-+ pr_debug ("%s: %s %s %s %s %s %s %s\n", __FUNCTION__, argv[0], argv[1],
-+ envp[0], envp[1], envp[2], envp[3], envp[4]);
-+ retval = call_usermodehelper (argv[0], argv, envp, 0);
-+ if (retval)
-+ pr_debug ("%s - call_usermodehelper returned %d\n",
-+ __FUNCTION__, retval);
-+
-+exit:
-+ kfree(buffer);
-+ kfree(envp);
-+ return;
-+}
-+
-+void device_power_event(struct device * dev, char *eventstr)
-+{
-+ char *argv [3];
-+ char **envp = NULL;
-+ char *buffer = NULL;
-+ char *scratch;
-+ int i = 0;
-+ int retval;
-+ unsigned long seq;
-+
-+ if (!uevent_helper[0])
-+ return;
-+
-+ envp = kmalloc(NUM_ENVP * sizeof (char *), GFP_KERNEL);
-+ if (!envp)
-+ return;
-+ memset (envp, 0x00, NUM_ENVP * sizeof (char *));
-+
-+ buffer = kmalloc(BUFFER_SIZE, GFP_KERNEL);
-+ if (!buffer)
-