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)
Sat, Dec 21, 9:14 PM
Unknown Object (File)
Nov 22 2024, 7:09 PM
Unknown Object (File)
Nov 22 2024, 5:44 AM
Unknown Object (File)
Nov 4 2024, 8:48 PM
Unknown Object (File)
Oct 25 2024, 7:38 PM
Unknown Object (File)
Sep 22 2024, 7:00 PM
Unknown Object (File)
Sep 21 2024, 1:23 PM
Unknown Object (File)
Sep 18 2024, 8:49 PM
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