Re: 2.5.58 Oops when booting from initrd - kobject_del

From: Valdis.Kletnieks@vt.edu
Date: Wed Jan 15 2003 - 00:52:28 EST


On Tue, 14 Jan 2003 15:53:26 CST, Patrick Mochel said:
> Could you please try the following patch and see if it fixes the problem?

This fix worked for me.. am on 2.5.58 right now.... Many thanks..

/Valdis

> ===== drivers/block/elevator.c 1.36 vs edited =====
> --- 1.36/drivers/block/elevator.c Sun Jan 12 08:10:40 2003
> +++ edited/drivers/block/elevator.c Tue Jan 14 15:46:00 2003
> @@ -431,10 +431,13 @@
> void elv_unregister_queue(struct gendisk *disk)
> {
> request_queue_t *q = disk->queue;
> - elevator_t *e = &q->elevator;
> + elevator_t *e;
>
> - kobject_unregister(&e->kobj);
> - kobject_put(&disk->kobj);
> + if (q) {
> + e = &q->elevator;
> + kobject_unregister(&e->kobj);
> + kobject_put(&disk->kobj);
> + }
> }
>
> elevator_t elevator_noop = {
>
>



-
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/



This archive was generated by hypermail 2b29 : Wed Jan 15 2003 - 22:00:53 EST