aboutsummaryrefslogtreecommitdiff
path: root/sys/i4b
diff options
context:
space:
mode:
authorGary Jennejohn <gj@FreeBSD.org>2004-07-18 20:13:31 +0000
committerGary Jennejohn <gj@FreeBSD.org>2004-07-18 20:13:31 +0000
commiteab6e771a0fa29ee3951c39f5a1df052f8753b91 (patch)
tree1ed8eda21ae6fc178cd0e3ffa9f22bc617028579 /sys/i4b
parent8bbfdc98e41f72e2809909d34e9c1232da8c8d69 (diff)
downloadsrc-eab6e771a0fa29ee3951c39f5a1df052f8753b91.tar.gz
src-eab6e771a0fa29ee3951c39f5a1df052f8753b91.zip
Fix a possible hang which apparently occurs during a warm boot (cold boot
does not display the symptom). Evidently the ifpi2 controller needs to be massaged more than it was. Note that this does not close the PR since it was filed against 4.9. MFC: 5 days PR: kern/68756 Submitted by: Ari Suutari <ari.suutari@syncrontech.com>
Notes
Notes: svn path=/head/; revision=132363
Diffstat (limited to 'sys/i4b')
-rw-r--r--sys/i4b/layer1/ifpi2/i4b_ifpi2_pci.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/sys/i4b/layer1/ifpi2/i4b_ifpi2_pci.c b/sys/i4b/layer1/ifpi2/i4b_ifpi2_pci.c
index 3f83859241d2..89a7c1413a69 100644
--- a/sys/i4b/layer1/ifpi2/i4b_ifpi2_pci.c
+++ b/sys/i4b/layer1/ifpi2/i4b_ifpi2_pci.c
@@ -148,6 +148,7 @@ struct l1_softc *ifpi2_scp[IFPI2_MAXUNIT];
/*
* AVM PCI Status Latch 0 read only bits
*/
+#define ASL_RESET 0x01
#define ASL_TIMERRESET 0x04
#define ASL_ENABLE_INT 0x08
@@ -559,6 +560,13 @@ avma1pp2_attach_avma1pp(device_t dev)
printf("avma1pp2_attach: 1 HSCX_STAT %x\n", v);
#endif
+ bus_space_write_1(btag, bhandle, STAT0_OFFSET, 0);
+ DELAY(SEC_DELAY/100); /* 10 ms */
+ bus_space_write_1(btag, bhandle, STAT0_OFFSET, ASL_RESET);
+ DELAY(SEC_DELAY/100); /* 10 ms */
+ bus_space_write_1(btag, bhandle, STAT0_OFFSET, 0);
+ DELAY(SEC_DELAY/100); /* 10 ms */
+
bus_space_write_1(btag, bhandle, STAT0_OFFSET, ASL_TIMERRESET);
DELAY(SEC_DELAY/100); /* 10 ms */
bus_space_write_1(btag, bhandle, STAT0_OFFSET, ASL_ENABLE_INT);