From 4cfe4ccf1608dd8cf29e36ec1eab59cdb2eb9125 Mon Sep 17 00:00:00 2001 From: Alexander Motin Date: Mon, 28 May 2012 14:33:15 +0000 Subject: [PATCH] Make legacy ATA to not call device_add_child() with unit number but without driver name. This fixed legacy ATA breakage by r235978. MFC after: 1 week --- sys/dev/ata/ata-all.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/ata/ata-all.c b/sys/dev/ata/ata-all.c index 3caad019faed..6bee48d5b1a2 100644 --- a/sys/dev/ata/ata-all.c +++ b/sys/dev/ata/ata-all.c @@ -887,7 +887,7 @@ ata_add_child(device_t parent, struct ata_device *atadev, int unit) { device_t child; - if ((child = device_add_child(parent, NULL, unit))) { + if ((child = device_add_child(parent, (unit < 0) ? NULL : "ad", unit))) { device_set_softc(child, atadev); device_quiet(child); atadev->dev = child;