HomeFreeBSD

ata_kauai: Fix support for "shasta" controllers.

Description

ata_kauai: Fix support for "shasta" controllers.

The probe routine was setting a value in the softc, but since the
probe routine was not returning zero, this value was lost since the
softc was reallocated (and re-zeroed) when the device was attached.
This is similar in nature to the fixes from
965205eb66cae3fd5de75a70a3aef2f014f98020.

To fix, move the code to set the 'shasta' flag to the start of attach
along with related code to set an IRQ resource on some non-shasta
devices. The IRQ resource still "worked" being in the probe routine
as the IRQ resource persisted after probe returned, but it is cleaner
to go ahead and move it to attach after setting the 'shasta' flag.

I have no way to test this, but noticed this while reading the code.

Reviewed by: jhibbits
Differential Revision: https://reviews.freebsd.org/D34888

(cherry picked from commit d5472cd4b3a3fedd56589a16a96f997d1d8fa1dc)

Details

Provenance
jhbAuthored on Apr 18 2022, 7:06 PM
Reviewer
jhibbits
Differential Revision
D34888: ata_kauai: Fix support for "shasta" controllers.
Parents
rGd32888f4fefa: ix: Remove cpu_id and related code from ixgbe_if_msix_intr_assign.
Branches
Unknown
Tags
Unknown