--- /dev/null
+From 67fe63b0715ccfaefa0af8a6e705c5470ee5cada Mon Sep 17 00:00:00 2001
+From: Bjorn Helgaas <bjorn.helgaas@hp.com>
+Date: Thu, 7 Jan 2010 12:58:51 -0700
+Subject: agp/hp: fixup hp agp after ACPI changes
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+From: Bjorn Helgaas <bjorn.helgaas@hp.com>
+
+commit 67fe63b0715ccfaefa0af8a6e705c5470ee5cada upstream.
+
+Commit 15b8dd53f5ffa changed the string in info->hardware_id from a static
+array to a pointer and added a length field. But instead of changing
+"sizeof(array)" to "length", we changed it to "sizeof(length)" (== 4),
+which corrupts the string we're trying to null-terminate.
+
+We no longer even need to null-terminate the string, but we *do* need to
+check whether we found a HID. If there's no HID, we used to have an empty
+array, but now we have a null pointer.
+
+The combination of these defects causes this oops:
+
+ Unable to handle kernel NULL pointer dereference (address 0000000000000003)
+ modprobe[895]: Oops 8804682956800 [1]
+ ip is at zx1_gart_probe+0xd0/0xcc0 [hp_agp]
+
+ http://marc.info/?l=linux-ia64&m=126264484923647&w=2
+
+Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
+Reported-by: Émeric Maschino <emeric.maschino@gmail.com>
+Signed-off-by: Dave Airlie <airlied@redhat.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/char/agp/hp-agp.c | 3 +--
+ 1 file changed, 1 insertion(+), 2 deletions(-)
+
+--- a/drivers/char/agp/hp-agp.c
++++ b/drivers/char/agp/hp-agp.c
+@@ -488,9 +488,8 @@ zx1_gart_probe (acpi_handle obj, u32 dep
+ handle = obj;
+ do {
+ status = acpi_get_object_info(handle, &info);
+- if (ACPI_SUCCESS(status)) {
++ if (ACPI_SUCCESS(status) && (info->valid & ACPI_VALID_HID)) {
+ /* TBD check _CID also */
+- info->hardware_id.string[sizeof(info->hardware_id.length)-1] = '\0';
+ match = (strcmp(info->hardware_id.string, "HWP0001") == 0);
+ kfree(info);
+ if (match) {
+++ /dev/null
-From 5e28d8eb68c12eab9c4a47b42ba993a6420d71d3 Mon Sep 17 00:00:00 2001
-From: Chase Douglas <chase.douglas@canonical.com>
-Date: Mon, 5 Apr 2010 22:29:08 -0700
-Subject: Input: ALPS - add signature for HP Pavilion dm3 laptops
-
-From: Chase Douglas <chase.douglas@canonical.com>
-
-commit 5e28d8eb68c12eab9c4a47b42ba993a6420d71d3 upstream.
-
-Tested by a user running Ubuntu 9.10 in the following bug report.
-
-BugLink: http://bugs.launchpad.net/bugs/545307
-
-Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
-Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- drivers/input/mouse/alps.c | 1 +
- 1 file changed, 1 insertion(+)
-
---- a/drivers/input/mouse/alps.c
-+++ b/drivers/input/mouse/alps.c
-@@ -62,6 +62,7 @@ static const struct alps_model_info alps
- { { 0x62, 0x02, 0x14 }, 0xcf, 0xcf,
- ALPS_PASS | ALPS_DUALPOINT | ALPS_PS2_INTERLEAVED },
- { { 0x73, 0x02, 0x50 }, 0xcf, 0xcf, ALPS_FW_BK_1 }, /* Dell Vostro 1400 */
-+ { { 0x73, 0x02, 0x64 }, 0xf8, 0xf8, 0 }, /* HP Pavilion dm3 */
- { { 0x52, 0x01, 0x14 }, 0xff, 0xff,
- ALPS_PASS | ALPS_DUALPOINT | ALPS_PS2_INTERLEAVED }, /* Toshiba Tecra A11-11L */
- };
sched-fix-sched_getaffinity.patch
nfsv4-fall-back-to-ordinary-lookup-if-nfs4_atomic_open-returns-eisdir.patch
nfsv4-fix-delegated-locking.patch
-input-alps-add-signature-for-hp-pavilion-dm3-laptops.patch
alsa-hda-add-a-quirk-for-clevo-m570u-laptop.patch
alsa-usb-fix-oops-after-usb-midi-disconnection.patch
hwmon-sht15-fix-sht15_calc_temp-interpolation-function.patch
b43-allow-pio-mode-to-be-selected-at-module-load.patch
b43-fall-back-gracefully-to-pio-mode-after-fatal-dma-errors.patch
alsa-hda-add-position_fix-quirk-for-biostar-mobo.patch
+agp-hp-fixup-hp-agp-after-acpi-changes.patch
+++ /dev/null
-From 5e28d8eb68c12eab9c4a47b42ba993a6420d71d3 Mon Sep 17 00:00:00 2001
-From: Chase Douglas <chase.douglas@canonical.com>
-Date: Mon, 5 Apr 2010 22:29:08 -0700
-Subject: Input: ALPS - add signature for HP Pavilion dm3 laptops
-
-From: Chase Douglas <chase.douglas@canonical.com>
-
-commit 5e28d8eb68c12eab9c4a47b42ba993a6420d71d3 upstream.
-
-Tested by a user running Ubuntu 9.10 in the following bug report.
-
-BugLink: http://bugs.launchpad.net/bugs/545307
-
-Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
-Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
-Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-
----
- drivers/input/mouse/alps.c | 1 +
- 1 file changed, 1 insertion(+)
-
---- a/drivers/input/mouse/alps.c
-+++ b/drivers/input/mouse/alps.c
-@@ -63,6 +63,7 @@ static const struct alps_model_info alps
- { { 0x62, 0x02, 0x14 }, 0xcf, 0xcf,
- ALPS_PASS | ALPS_DUALPOINT | ALPS_PS2_INTERLEAVED },
- { { 0x73, 0x02, 0x50 }, 0xcf, 0xcf, ALPS_FOUR_BUTTONS }, /* Dell Vostro 1400 */
-+ { { 0x73, 0x02, 0x64 }, 0xf8, 0xf8, 0 }, /* HP Pavilion dm3 */
- { { 0x52, 0x01, 0x14 }, 0xff, 0xff,
- ALPS_PASS | ALPS_DUALPOINT | ALPS_PS2_INTERLEAVED }, /* Toshiba Tecra A11-11L */
- };
nfsv4-fix-delegated-locking.patch
input-wacom-switch-mode-upon-system-resume.patch
input-sparse-keymap-free-the-right-keymap-on-error.patch
-input-alps-add-signature-for-hp-pavilion-dm3-laptops.patch
alsa-hda-add-a-quirk-for-clevo-m570u-laptop.patch
alsa-usb-fix-oops-after-usb-midi-disconnection.patch
hwmon-sht15-fix-sht15_calc_temp-interpolation-function.patch