HomeFreeBSD

bcm_dma: attach at an earlier bus pass

Description

bcm_dma: attach at an earlier bus pass

The sdhci_bcm driver attach routine relies on bcm_dma already being
attached, in order to allocate a DMA channel. However, both drivers
attached at the default pass so this is not guaranteed. Newer RPI
firmware exposes this assumption, and the result is a NULL-dereference
in bcm_dma_allocate().

To fix this, use BUS_PASS_SUPPORTDEV for bcm_dma.

PR: 268835
Reviewed by: mhorne
MFC after: 1 week

(cherry picked from commit 9873b171697033f9f19608d98bcd1c16cacb92af)

Details

Provenance
markmi_dsl-only.netAuthored on Feb 17 2023, 8:30 PM
mhorneCommitted on Mar 7 2023, 4:55 PM
Parents
rG7b37e83e4c8f: lockmgr: upgrade panic return checks
Branches
Unknown
Tags
Unknown