Page MenuHomeFreeBSD

ena: Make first_interrupt a uint8_t
ClosedPublic

Authored by markj on Jun 30 2022, 6:56 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Apr 8, 5:04 PM
Unknown Object (File)
Sat, Apr 6, 11:03 AM
Unknown Object (File)
Sat, Apr 6, 2:09 AM
Unknown Object (File)
Feb 18 2024, 4:36 AM
Unknown Object (File)
Jan 16 2024, 9:27 PM
Unknown Object (File)
Dec 27 2023, 1:15 AM
Unknown Object (File)
Dec 22 2023, 11:03 PM
Unknown Object (File)
Dec 13 2023, 5:29 AM
Subscribers

Details

Summary

Avoid passing vars of type bool to atomic(9) routines. The size of bool
is not fixed by the C standard, even though it's one byte by convention.

This fixes the KASAN and KMSAN builds, which fail because the compiler
refuses to silently cast a _Bool * to a uint8_t * when calling the
atomic(9) interceptors.

Fixes: 0ac122c388d9 ("ena: Use atomic_load/store functions for first_interrupt variable")

Test Plan

build GENERIC-KASAN and GENERIC-KMSAN amd64 kernels

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable