HomeFreeBSD

Fix a sleepable malloc in ndastart. We shouldn't be sleeping

Description

Fix a sleepable malloc in ndastart. We shouldn't be sleeping
here. Return ENOMEM when we can't malloc a buffer for the DSM
TRIM. This should fix the WITNESS warnings similar to the following:

uma_zalloc_arg: zone "16" with the following non-sleepable locks held:
exclusive sleep mutex CAM device lock (CAM device lock) r = 0 (0xfffff800080c34d0) locked @ /usr/src/sys/cam/nvme/nvme_da.c:351

Reviewed by: scottl@
Sponsored by: Netflix

Details

Provenance
impAuthored on
Parents
rS328451: MFC (conceptually) r327991, r328009: Don't clobber FDT enroute to the kernel
Branches
Unknown
Tags
Unknown