Files
linux/drivers
Nagendra Singh Tomar 017f2e37ae [SCSI] sd: udev accessing an uninitialized scsi_disk field results in a crash
sd_probe() calls class_device_add() even before initializing the
sdkp->device variable. class_device_add() eventually results in the user mode
udev program to be called. udev program can read the the allow_restart
attribute of the newly created scsi device. This is resulting in a crash as
the show function for allow_restart (i.e sd_show_allow_restart) returns the
attribute value by reading the sdkp->device->allow_restart variable. As the
sdkp->device is not initialized before calling the user mode hotplug helper,
this results in a crash.
	The patch below solves it by calling class_device_add() only after the
necessary fields in the scsi_disk structure are initialized properly.

Signed-off-by: Nagendra Singh Tomar <nagendra_tomar@adaptec.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
2007-02-02 19:45:41 -06:00
..
2007-01-26 13:50:58 -08:00
2007-01-26 17:27:40 -05:00
2007-01-23 11:09:49 -08:00
2006-12-10 09:55:40 -08:00
2006-12-07 08:39:24 -08:00
2006-10-11 11:14:25 -07:00
2007-01-06 09:32:49 -06:00
2007-01-15 06:44:03 +01:00
2007-01-25 15:49:56 -08:00
2007-01-22 12:00:54 -08:00
2006-12-11 13:49:53 +11:00
2006-10-03 22:31:37 +02:00
2006-10-17 08:18:42 -07:00
2006-12-08 08:28:57 -08:00
2007-01-23 11:09:49 -08:00
2006-12-13 09:05:48 -08:00
2006-12-08 08:28:50 -08:00
2006-12-10 09:57:22 -08:00
2006-12-10 09:57:22 -08:00