aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/s3c24xx/patches-2.6.24/1163-Fix-possible-null-pointer-dereference-in-s3c24xx_i2c.patch
diff options
context:
space:
mode:
authorMirko Vogt <mirko@openwrt.org>2008-12-12 11:58:53 +0000
committerMirko Vogt <mirko@openwrt.org>2008-12-12 11:58:53 +0000
commitfac7f7f84f3771c5247c7fdee825c092077984f5 (patch)
tree54644c1229434d7ee13c5872bda4129e34337fc0 /target/linux/s3c24xx/patches-2.6.24/1163-Fix-possible-null-pointer-dereference-in-s3c24xx_i2c.patch
parenta34279723a9cf0796f9261f2fb90bea18cd95711 (diff)
downloadmaster-187ad058-fac7f7f84f3771c5247c7fdee825c092077984f5.tar.gz
master-187ad058-fac7f7f84f3771c5247c7fdee825c092077984f5.tar.bz2
master-187ad058-fac7f7f84f3771c5247c7fdee825c092077984f5.zip
changed Makefile and profiles, added patches for kernel 2.6.24
(stable-branch of Openmoko) git-svn-id: svn://svn.openwrt.org/openwrt/trunk@13613 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/s3c24xx/patches-2.6.24/1163-Fix-possible-null-pointer-dereference-in-s3c24xx_i2c.patch')
-rw-r--r--target/linux/s3c24xx/patches-2.6.24/1163-Fix-possible-null-pointer-dereference-in-s3c24xx_i2c.patch36
1 files changed, 36 insertions, 0 deletions
diff --git a/target/linux/s3c24xx/patches-2.6.24/1163-Fix-possible-null-pointer-dereference-in-s3c24xx_i2c.patch b/target/linux/s3c24xx/patches-2.6.24/1163-Fix-possible-null-pointer-dereference-in-s3c24xx_i2c.patch
new file mode 100644
index 0000000000..8161aae416
--- /dev/null
+++ b/target/linux/s3c24xx/patches-2.6.24/1163-Fix-possible-null-pointer-dereference-in-s3c24xx_i2c.patch
@@ -0,0 +1,36 @@
+From 7d34adf0df1f105c73c6ecdee50a7ad6a6dbfd2b Mon Sep 17 00:00:00 2001
+From: Holger Freyther <zecke@openmoko.org>
+Date: Tue, 3 Jun 2008 10:46:48 +0100
+Subject: [PATCH] Fix possible null pointer dereference in s3c24xx_i2c_resume
+
+From 0b9bae6aed5268707b348e48a01411ba420844e1 Mon Sep 17 00:00:00 2001
+From: Holger Freyther <zecke@openmoko.org>
+Date: Tue, 27 May 2008 14:41:35 +0200
+Subject: [PATCH] [janitor] Fix possible null pointer dereference
+ Judging by the control flow of the resume method i2c->suspended++ could
+ lead to a null pointer dereference.
+---
+ drivers/i2c/busses/i2c-s3c2410.c | 6 +++---
+ 1 files changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/drivers/i2c/busses/i2c-s3c2410.c b/drivers/i2c/busses/i2c-s3c2410.c
+index 5ac8309..bd69127 100644
+--- a/drivers/i2c/busses/i2c-s3c2410.c
++++ b/drivers/i2c/busses/i2c-s3c2410.c
+@@ -919,10 +919,10 @@ static int s3c24xx_i2c_resume(struct platform_device *dev)
+ {
+ struct s3c24xx_i2c *i2c = platform_get_drvdata(dev);
+
+- if (i2c != NULL)
++ if (i2c != NULL) {
+ s3c24xx_i2c_init(i2c);
+-
+- i2c->suspended--;
++ i2c->suspended--;
++ }
+
+ return 0;
+ }
+--
+1.5.6.5
+