Date: Sun, 16 Nov 2008 22:59:57 GMT From: Nathan Whitehorn <nwhitehorn@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 153060 for review Message-ID: <200811162259.mAGMxvlw026231@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=153060 Change 153060 by nwhitehorn@nwhitehorn_trantor on 2008/11/16 22:59:28 Fix interrupt-cells detection on Grackle. Affected files ... .. //depot/projects/ppc-g5/sys/powerpc/powermac/grackle.c#7 edit Differences ... ==== //depot/projects/ppc-g5/sys/powerpc/powermac/grackle.c#7 (text+ko) ==== @@ -255,10 +255,12 @@ ofw_bus_setup_iinfo(node, &sc->sc_pci_iinfo, sizeof(cell_t)); /* We need the number of interrupt cells to read the imap */ - sc->sc_icells = 2; - if (OF_getprop(node, "interrupt-parent", &iparent,sizeof(iparent)) > 0) - OF_getprop(iparent,"#interrupt-cells",&sc->sc_icells, - sizeof(sc->sc_icells)); + if (OF_getprop(node, "interrupt-parent", &iparent,sizeof(iparent)) <= 0) + iparent = node; + + if (OF_getprop(iparent,"#interrupt-cells",&sc->sc_icells, + sizeof(sc->sc_icells)) <= 0); + sc->sc_icells = 1; device_add_child(dev, "pci", device_get_unit(dev)); return (bus_generic_attach(dev));
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200811162259.mAGMxvlw026231>