Messages in this thread Patch in this message | | | Subject | [PATCH] fix adm9240 oops | From | Jonathan Corbet <> | Date | Thu, 25 Aug 2005 14:56:29 -0600 |
| |
The adm9240 driver, in adm9240_detect(), allocates a structure. The error path attempts to kfree() a subfield of that structure, resulting in an oops (or slab corruption) if the hardware is not present. This one seems worth fixing for 2.6.13.
jon
Signed-off-by: Jonathan Corbet <corbet@lwn.net>
--- 2.6.13-rc7/drivers/hwmon/adm9240.c.orig 2005-08-25 14:30:04.000000000 -0600 +++ 2.6.13-rc7/drivers/hwmon/adm9240.c 2005-08-25 14:30:26.000000000 -0600 @@ -616,7 +616,7 @@ static int adm9240_detect(struct i2c_ada return 0; exit_free: - kfree(new_client); + kfree(data); exit: return err; } - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |