All the mail mirrored from lore.kernel.org
 help / color / mirror / Atom feed
* + acerhdf-driver-didnt-verify-the-pointers-in-which-it-got-product-information.patch added to -mm tree
@ 2010-06-21 21:56 akpm
  0 siblings, 0 replies; only message in thread
From: akpm @ 2010-06-21 21:56 UTC (permalink / raw
  To: mm-commits; +Cc: rkc, andi, lenb, mjg, peter, petkovbb


The patch titled
     acerhdf: driver didn't verify the pointers in which it got product information
has been added to the -mm tree.  Its filename is
     acerhdf-driver-didnt-verify-the-pointers-in-which-it-got-product-information.patch

Before you just go and hit "reply", please:
   a) Consider who else should be cc'ed
   b) Prefer to cc a suitable mailing list as well
   c) Ideally: find the original patch on the mailing list and do a
      reply-to-all to that, adding suitable additional cc's

*** Remember to use Documentation/SubmitChecklist when testing your code ***

See http://userweb.kernel.org/~akpm/stuff/added-to-mm.txt to find
out what to do about this

The current -mm tree may be found at http://userweb.kernel.org/~akpm/mmotm/

------------------------------------------------------
Subject: acerhdf: driver didn't verify the pointers in which it got product information
From: Rahul Chaturvedi <rkc@chromium.org>

Driver didn't verify the pointers in which it got product information back
from DMI; on QEMU one of the pointers came back null, which made the
driver crash and subsequently caused a kernel panic.

Signed-off-by: Rahul Chaturvedi <rkc@chromium.org>
Signed-off-by: Peter Feuerer <peter@piie.net>
Cc: Borislav Petkov <petkovbb@gmail.com>
Cc: Andreas Mohr <andi@lisas.de>
Cc: Len Brown <lenb@kernel.org>
Cc: Matthew Garrett <mjg@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---

 drivers/platform/x86/acerhdf.c |    4 ++++
 1 file changed, 4 insertions(+)

diff -puN drivers/platform/x86/acerhdf.c~acerhdf-driver-didnt-verify-the-pointers-in-which-it-got-product-information drivers/platform/x86/acerhdf.c
--- a/drivers/platform/x86/acerhdf.c~acerhdf-driver-didnt-verify-the-pointers-in-which-it-got-product-information
+++ a/drivers/platform/x86/acerhdf.c
@@ -524,6 +524,10 @@ static int acerhdf_check_hardware(void)
 	version = dmi_get_system_info(DMI_BIOS_VERSION);
 	product = dmi_get_system_info(DMI_PRODUCT_NAME);
 
+	if (!vendor || !version || !product) {
+		pr_err("error getting hardware information\n");
+		return -EINVAL;
+	}
 
 	pr_info("Acer Aspire One Fan driver, v.%s\n", DRV_VER);
 
_

Patches currently in -mm which might be from rkc@chromium.org are

acerhdf-driver-didnt-verify-the-pointers-in-which-it-got-product-information.patch


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2010-06-21 21:56 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-06-21 21:56 + acerhdf-driver-didnt-verify-the-pointers-in-which-it-got-product-information.patch added to -mm tree akpm

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.