Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c38778c3 authored by Dave Jones's avatar Dave Jones Committed by Jeff Garzik
Browse files

[PATCH] Fix reference of uninitialised memory in ata_device_add()



ata_device_add fails, calls ata_host_remove with pointers to unitialized
memory.

Signed-off-by: default avatarDave Jones <davej@redhat.com>
Cc: Jeff Garzik <jeff@garzik.org>
Cc: Tejun Heo <htejun@gmail.com>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarJeff Garzik <jeff@garzik.org>
parent bda30288
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -5478,11 +5478,10 @@ int ata_device_add(const struct ata_probe_ent *ent)
		int irq_line = ent->irq;

		ap = ata_port_add(ent, host, i);
		host->ports[i] = ap;
		if (!ap)
			goto err_out;

		host->ports[i] = ap;

		/* dummy? */
		if (ent->dummy_port_mask & (1 << i)) {
			ata_port_printk(ap, KERN_INFO, "DUMMY\n");