mirror of
https://github.com/freebsd/freebsd-src
synced 2024-09-06 09:10:28 +00:00
Refactoring the interrupt setup code introduced a bug where the drivers
would attempt to re-allocate interrupts during a chip reset without first de-allocating them. Doing that right is going to be tricky, so just band-aid it for now so that a re-init doesn't guarantee a failure due to resource re-use. Reported by: gallatin Sponsored by: Netflix
This commit is contained in:
parent
72130735d8
commit
1069541760
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=325667
|
@ -677,7 +677,11 @@ mpr_iocfacts_allocate(struct mpr_softc *sc, uint8_t attaching)
|
|||
return (error);
|
||||
}
|
||||
|
||||
if ((error = mpr_pci_setup_interrupts(sc)) != 0) {
|
||||
/*
|
||||
* XXX If the number of MSI-X vectors changes during re-init, this
|
||||
* won't see it and adjust.
|
||||
*/
|
||||
if (attaching && (error = mpr_pci_setup_interrupts(sc)) != 0) {
|
||||
mpr_dprint(sc, MPR_INIT|MPR_ERROR,
|
||||
"Failed to setup interrupts\n");
|
||||
mpr_free(sc);
|
||||
|
|
|
@ -665,7 +665,11 @@ mps_iocfacts_allocate(struct mps_softc *sc, uint8_t attaching)
|
|||
return (error);
|
||||
}
|
||||
|
||||
if ((error = mps_pci_setup_interrupts(sc)) != 0) {
|
||||
/*
|
||||
* XXX If the number of MSI-X vectors changes during re-init, this
|
||||
* won't see it and adjust.
|
||||
*/
|
||||
if (attaching && (error = mps_pci_setup_interrupts(sc)) != 0) {
|
||||
mps_dprint(sc, MPS_INIT|MPS_FAULT, "Failed to setup "
|
||||
"interrupts\n");
|
||||
mps_free(sc);
|
||||
|
|
Loading…
Reference in a new issue