[PATCH] rpaphp doesn't initialize slot's name

Rolf Eike Beer eike-hotplug at sf-tec.de
Wed May 5 01:07:06 EST 2004


Am Dienstag, 4. Mai 2004 17:03 schrieb Rolf Eike Beer:
> Am Dienstag, 4. Mai 2004 17:17 schrieb Linda Xie:
> > Hi Greg,
> >
> > Attached patch was made against the lastest
> > kernel.bkbits.net/gregkh/linux/pci-2.6.
> > It  contains the following fixes:
> >
> > - Remove an unused label(error_slot defined, but not used)
> > - Correct a typo(replace hoslot with hpslot)
>
> Oops, this looks like I broke it. Your fix is not correct.
>
> Please apply this patch and rediff. Greg, you need it first, too.

Ok, I broke it again. I diffed it from wrong place, this one should apply.

Eike

--- linux-2.6.6-rc3/drivers/pci/hotplug/rpaphp_slot.c.orig	2004-05-04 16:59:10.000000000 +0200
+++ linux-2.6.6-rc3/drivers/pci/hotplug/rpaphp_slot.c	2004-05-04 16:59:45.000000000 +0200
@@ -89,12 +89,12 @@ struct slot *alloc_slot_struct(struct de
 	memset(slot, 0, sizeof (struct slot));
 	slot->hotplug_slot = kmalloc(sizeof (struct hotplug_slot), GFP_KERNEL);
 	if (!slot->hotplug_slot)
-		goto error_hpslot;
+		goto error_slot;
 	memset(slot->hotplug_slot, 0, sizeof (struct hotplug_slot));
 	slot->hotplug_slot->info = kmalloc(sizeof (struct hotplug_slot_info),
 					   GFP_KERNEL);
 	if (!slot->hotplug_slot->info)
-		goto error_hoslot;
+		goto error_hpslot;
 	memset(slot->hotplug_slot->info, 0, sizeof (struct hotplug_slot_info));
 	slot->hotplug_slot->name = kmalloc(BUS_ID_SIZE + 1, GFP_KERNEL);
 	if (!slot->hotplug_slot->name)

** Sent via the linuxppc64-dev mail list. See http://lists.linuxppc.org/





More information about the Linuxppc64-dev mailing list