summaryrefslogtreecommitdiff
path: root/sys/dev
diff options
context:
space:
mode:
authorStefan Sperling <stsp@cvs.openbsd.org>2014-09-30 18:09:24 +0000
committerStefan Sperling <stsp@cvs.openbsd.org>2014-09-30 18:09:24 +0000
commit1c19dc0045ef937fd0a95845c877731f48bfd231 (patch)
tree31adef5ac29591487aa906c80f801b2513c7843d /sys/dev
parentb80c0aaef252aa7807089d91ed82f7db25d68bc9 (diff)
Fix another Ricoh SD controller which needs to be put into slow mode to work.
reported by mlarkin@; ok mlarkin@ deraadt@
Diffstat (limited to 'sys/dev')
-rw-r--r--sys/dev/pci/sdhc_pci.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/sys/dev/pci/sdhc_pci.c b/sys/dev/pci/sdhc_pci.c
index bbbd5cda427..38f5fb9a0ba 100644
--- a/sys/dev/pci/sdhc_pci.c
+++ b/sys/dev/pci/sdhc_pci.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: sdhc_pci.c,v 1.16 2014/09/26 13:00:39 deraadt Exp $ */
+/* $OpenBSD: sdhc_pci.c,v 1.17 2014/09/30 18:09:23 stsp Exp $ */
/*
* Copyright (c) 2006 Uwe Stuehler <uwe@openbsd.org>
@@ -128,7 +128,8 @@ sdhc_pci_attach(struct device *parent, struct device *self, void *aux)
/* Some RICOH controllers need to be bumped into the right mode. */
if (PCI_VENDOR(pa->pa_id) == PCI_VENDOR_RICOH &&
- PCI_PRODUCT(pa->pa_id) == PCI_PRODUCT_RICOH_R5U823)
+ (PCI_PRODUCT(pa->pa_id) == PCI_PRODUCT_RICOH_R5U822 ||
+ PCI_PRODUCT(pa->pa_id) == PCI_PRODUCT_RICOH_R5U823))
sdhc_ricohfix(sc);
if (pci_intr_map(pa, &ih)) {
@@ -196,7 +197,8 @@ sdhc_pci_activate(struct device *self, int act)
case DVACT_RESUME:
/* Some RICOH controllers need to be bumped into the right mode. */
if (PCI_VENDOR(sc->sc_id) == PCI_VENDOR_RICOH &&
- PCI_PRODUCT(sc->sc_id) == PCI_PRODUCT_RICOH_R5U823)
+ (PCI_PRODUCT(sc->sc_id) == PCI_PRODUCT_RICOH_R5U822 ||
+ PCI_PRODUCT(sc->sc_id) == PCI_PRODUCT_RICOH_R5U823))
sdhc_ricohfix(sc);
rv = sdhc_activate(self, act);
break;