[lm-sensors] [PATCH] k8temp: Unset driver data in exit_remove

Andre Prendel andre.prendel at gmx.de
Wed May 6 09:17:41 CEST 2009

Hi Jean, Rudolf,

after infiltrating the sensors user space part, I think it's time to
dive into kernel space. So I took a look at some of the sensor drivers
to get an understanding. Unfortunately I couldn't find a bug to fix,
so I had to do something else :)

I don't know whether this patch is worth to be applied, but I have to
start somewhere.

I'm very interested in doing more kernel stuff. So if you have some
work to do, please tell me about it.


At the exit_free label in k8temp_probe() the driver data is set to
NULL. This field isn't set before. So this should be done in

Signed-off-by: Andre Prendel <andre.prendel at gmx.de>

--- linux-2.6.orig/drivers/hwmon/k8temp.c	2009-05-05 21:31:44.000000000 +0200
+++ linux-2.6/drivers/hwmon/k8temp.c	2009-05-05 21:35:03.000000000 +0200
@@ -281,8 +281,8 @@
 	device_remove_file(&pdev->dev, &dev_attr_name);
 	dev_set_drvdata(&pdev->dev, NULL);
 	return err;

More information about the lm-sensors mailing list