Fix the so-called "half-baked-probe" code that I wrote a long time ago
to properly clear the interrupt register on the no error case. Also, set the mcr register to zero when we find we can't support the chip. This fixes the hang on sio driver attach problem in the new pci pccard code that some people have reported. At least on my machine. I'd like to get this into 4.4. Submitted by: bde PR: kern/29742 MFC after: 1 day
This commit is contained in:
parent
dda035d1fc
commit
1865c617e4
@ -950,11 +950,13 @@ sioprobe(dev, xrid)
|
||||
} else {
|
||||
/* Unknown, Just omit this chip.. XXX */
|
||||
result = ENXIO;
|
||||
sio_setreg(com, com_mcr, 0);
|
||||
}
|
||||
} else {
|
||||
/* OK. this is well-known guys */
|
||||
CLR_FLAG(dev, COM_C_IIR_TXRDYBUG);
|
||||
}
|
||||
sio_setreg(com, com_ier, 0);
|
||||
sio_setreg(com, com_cfcr, CFCR_8BITS);
|
||||
mtx_unlock_spin(&sio_lock);
|
||||
bus_release_resource(dev, SYS_RES_IOPORT, rid, port);
|
||||
|
@ -950,11 +950,13 @@ sioprobe(dev, xrid)
|
||||
} else {
|
||||
/* Unknown, Just omit this chip.. XXX */
|
||||
result = ENXIO;
|
||||
sio_setreg(com, com_mcr, 0);
|
||||
}
|
||||
} else {
|
||||
/* OK. this is well-known guys */
|
||||
CLR_FLAG(dev, COM_C_IIR_TXRDYBUG);
|
||||
}
|
||||
sio_setreg(com, com_ier, 0);
|
||||
sio_setreg(com, com_cfcr, CFCR_8BITS);
|
||||
mtx_unlock_spin(&sio_lock);
|
||||
bus_release_resource(dev, SYS_RES_IOPORT, rid, port);
|
||||
|
Loading…
x
Reference in New Issue
Block a user