if (qdb & htole32((AMI_QIDB_EXEC | AMI_QIDB_ACK)))
if (qdb & (AMI_QIDB_EXEC | AMI_QIDB_ACK)) { AMI_DPRINTF(AMI_D_CMD, ("qidb=%x ", qdb));
ami_quartz_done(sc, mbox)	struct ami_softc *sc;	struct ami_iocmd *mbox;{	u_int32_t qdb;	/* do not scramble the busy mailbox */	if (sc->sc_mbox->acc_busy)		return (0);	qdb = bus_space_read_4(sc->iot, sc->ioh, AMI_QIDB);	if (qdb & htole32((AMI_QIDB_EXEC | AMI_QIDB_ACK)))		return (0);	qdb = bus_space_read_4(sc->iot, sc->ioh, AMI_QODB);	if (letoh32(qdb) == AMI_QODB_READY) {		bus_dmamap_sync(sc->dmat, sc->sc_cmdmap, BUS_DMASYNC_POSTREAD);		*mbox = *sc->sc_mbox;		/* ack interrupt */		bus_space_write_4(sc->iot, sc->ioh, AMI_QODB, AMI_QODB_READY);		qdb = sc->sc_mbox_pa | AMI_QIDB_ACK;		bus_space_write_4(sc->iot, sc->ioh, AMI_QIDB, htole32(qdb));		DELAY(10);		return (1);	}	return (0);}