mp += mlen / 4; len -= mlen; iparent = *mp++; if (OF_getprop(iparent, "#interrupt-cells", &icells, 4) != 4) return -1;
mp1 = mp + n_mlen;
find_node_intr(node, addr, intr)	int node;	u_int32_t *addr, *intr;{	int parent, iparent, len, mlen;	int match, i;	u_int32_t map[64], *mp;	u_int32_t imask[8], maskedaddr[8];	u_int32_t icells;	len = OF_getprop(node, "AAPL,interrupts", intr, 4);	if (len == 4)		return 1;	parent = OF_parent(node);	len = OF_getprop(parent, "interrupt-map", map, sizeof(map));	mlen = OF_getprop(parent, "interrupt-map-mask", imask, sizeof(imask));	if ((len == -1) || (mlen == -1))		goto nomap;	for (i = 0; i < (mlen / 4); i++) {		maskedaddr[i] = addr[i] & imask[i];	}	mp = map;	while (len > mlen) {		match = bcmp(maskedaddr, mp, mlen);		mp += mlen / 4;		len -= mlen;		iparent = *mp++;		if (OF_getprop(iparent, "#interrupt-cells", &icells, 4) != 4)			return -1;		if (match == 0) {			/* multiple irqs? */			*intr = *mp;			return 1;		}		mp += icells;		len -= icells * 4;	}	return -1;nomap:	return -1;}