All of lore.kernel.org
 help / color / mirror / Atom feed
* [lm-sensors] [PATCH] k8temp: Unset driver data in exit_remove
@ 2009-05-06  7:17 Andre Prendel
  2009-05-06  7:36 ` Jean Delvare
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: Andre Prendel @ 2009-05-06  7:17 UTC (permalink / raw)
  To: lm-sensors

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.

Thanks
Andre
---

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
exit_remove.

Signed-off-by: Andre Prendel <andre.prendel@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,
 			   &sensor_dev_attr_temp4_input.dev_attr);
 	device_remove_file(&pdev->dev, &dev_attr_name);
-exit_free:
 	dev_set_drvdata(&pdev->dev, NULL);
+exit_free:
 	kfree(data);
 exit:
 	return err;


_______________________________________________
lm-sensors mailing list
lm-sensors@lm-sensors.org
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2009-05-06 14:03 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-05-06  7:17 [lm-sensors] [PATCH] k8temp: Unset driver data in exit_remove Andre Prendel
2009-05-06  7:36 ` Jean Delvare
2009-05-06  7:54 ` Andre Prendel
2009-05-06  7:54 ` Hans de Goede
2009-05-06  8:59 ` Andre Prendel
2009-05-06 14:03 ` Hans de Goede

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.