nata - properly teardown interrupts on ENXIO
commitf84b6523c9856679a830769a159e6ba0d7627c32
authorMatthew Dillon <dillon@apollo.backplane.com>
Fri, 29 Oct 2010 06:23:48 +0000 (28 23:23 -0700)
committerMatthew Dillon <dillon@apollo.backplane.com>
Fri, 29 Oct 2010 06:26:17 +0000 (28 23:26 -0700)
tree21b4ec22fae28e2340856dde23648d85f8f12722
parent03156add49be0a9e4ee67b546d708ceaf15e10fd
nata - properly teardown interrupts on ENXIO

* When a ata controller cannot be attached (e.g. due to AHCI having
  already taken its resources) be sure to teardown and release any
  resources that had been obtained.

* This fixes a panic on certain motherboards (e.g. gigabyte / phenomX6)
  where the ata controller ENXIO'd but left interrupt handlers setup.
  An interrupt would then occur, access stale memory, and blow the machine
  up.
sys/dev/disk/nata/ata-chipset.c
sys/dev/disk/nata/ata-pci.c