ichsmb: shutdown interrupts to prevent spurious interrupts after kexec
Obtained from: Hewlett Packard Enterprise Rebiewed by: jhb, jhibbits
This commit is contained in:
@@ -703,4 +703,15 @@ ichsmb_detach(device_t dev)
|
||||
return 0;
|
||||
}
|
||||
|
||||
int
|
||||
ichsmb_shutdown(device_t dev)
|
||||
{
|
||||
const sc_p sc = device_get_softc(dev);
|
||||
|
||||
/* Disable interrupts */
|
||||
bus_write_1(sc->io_res, ICH_HST_CNT, 0);
|
||||
|
||||
return (0);
|
||||
}
|
||||
|
||||
DRIVER_MODULE(smbus, ichsmb, smbus_driver, 0, 0);
|
||||
|
||||
@@ -243,6 +243,7 @@ static device_method_t ichsmb_pci_methods[] = {
|
||||
DEVMETHOD(device_probe, ichsmb_pci_probe),
|
||||
DEVMETHOD(device_attach, ichsmb_pci_attach),
|
||||
DEVMETHOD(device_detach, ichsmb_detach),
|
||||
DEVMETHOD(device_shutdown, ichsmb_shutdown),
|
||||
|
||||
/* SMBus methods */
|
||||
DEVMETHOD(smbus_callback, ichsmb_callback),
|
||||
|
||||
@@ -84,6 +84,7 @@ extern void ichsmb_release_resources(sc_p sc);
|
||||
extern int ichsmb_probe(device_t dev);
|
||||
extern int ichsmb_attach(device_t dev);
|
||||
extern int ichsmb_detach(device_t dev);
|
||||
extern int ichsmb_shutdown(device_t dev);
|
||||
|
||||
#endif /* _DEV_ICHSMB_ICHSMB_VAR_H */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user