From: deraadt Date: Wed, 28 Jul 2010 18:31:51 +0000 (+0000) Subject: the default pciide chip needs no additional register restores; tested by jcs on one... X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=a31709212f2ea52b4900a4bca7fdaf1ecdc747a1;p=openbsd the default pciide chip needs no additional register restores; tested by jcs on one model --- diff --git a/sys/dev/pci/pciide.c b/sys/dev/pci/pciide.c index 03935087713..1205508e898 100644 --- a/sys/dev/pci/pciide.c +++ b/sys/dev/pci/pciide.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pciide.c,v 1.312 2010/07/28 15:50:19 deraadt Exp $ */ +/* $OpenBSD: pciide.c,v 1.313 2010/07/28 18:31:51 deraadt Exp $ */ /* $NetBSD: pciide.c,v 1.127 2001/08/03 01:31:08 tsutsui Exp $ */ /* @@ -1439,7 +1439,9 @@ pciide_activate(struct device *self, int act) PCI_MAPREG_END + 0x18 + (i * 4), sc->sc_save[i]); - if (sc->sc_pp->chip_map == sch_chip_map) { + if (sc->sc_pp->chip_map == default_chip_map) { + /* nothing more to restore */ + } else if (sc->sc_pp->chip_map == sch_chip_map) { pci_conf_write(sc->sc_pc, sc->sc_tag, SCH_D0TIM, sc->sc_save2[0]); pci_conf_write(sc->sc_pc, sc->sc_tag,