Make AHCI less chatty at boot.
authorDan Cross <crossd@gmail.com>
Thu, 1 Dec 2016 17:48:34 +0000 (12:48 -0500)
committerBarret Rhoden <brho@cs.berkeley.edu>
Fri, 2 Dec 2016 15:24:56 +0000 (10:24 -0500)
Change the debugging print statements to emit less output.
In particular, don't print anything when we don't find a
relevant device.

Change-Id: I3a8dfc3d9194a594c4c8c4bf580b0836c4ab944b
Signed-off-by: Dan Cross <crossd@gmail.com>
Signed-off-by: Barret Rhoden <brho@cs.berkeley.edu>
kern/drivers/dev/sdiahci.c

index 811fc05..367f6d8 100644 (file)
@@ -2095,8 +2095,6 @@ static void iasetupahci(struct ctlr *c)
 
 static int didtype(struct pci_device *p)
 {
-       printd("ahci: %s: ven_id=0x%04x, dev_id=0x%04x\n", __func__, p->ven_id,
-              p->dev_id);
        switch (p->ven_id) {
        case Vintel:
                if ((p->dev_id & 0xfffc) == 0x2680)
@@ -2207,9 +2205,10 @@ static struct sdev *iapnp(void)
        head = tail = NULL;
        STAILQ_FOREACH(p, &pci_devices, all_dev) {
                type = didtype(p);
-               printd("didtype: %d\n", type);
                if (type == -1)
                        continue;
+               printd("ahci: %s: ven_id=0x%04x, dev_id=0x%04x, didtype=%d\n",
+                      __func__, p->ven_id, p->dev_id, type);
                if (p->bar[Abar].mmio_base32 == 0)
                        continue;
                if (niactlr == NCtlr) {