HomeFreeBSD

LinuxKPI: fix READ_ONCE() -Wcast-equal warnings

Description

LinuxKPI: fix READ_ONCE() -Wcast-equal warnings

Rather than using ACCESS_ONCE() in READ_ONCE() add a missing cast
to const in order to satisfy -Wcast-equal by gcc.
Sadly we cannot do the same to WRITE_ONCE() which still is very
noisy.

Sponsored by: The FreeBSD Foundation
Reviewed by: hselasky
Differential Revision: https://reviews.freebsd.org/D39706

(cherry picked from commit 74e908b3c63b28de1d590dc42502fbe959a6da2e)

Details

Provenance
bzAuthored on Apr 19 2023, 9:43 PM
Reviewer
hselasky
Differential Revision
D39706: LinuxKPI: fix READ_ONCE() -Wcast-equal warnings
Parents
rGde40bc6f3d6b: LinuxKPI: skbuff.h: fix -Warray-bounds warnings
Branches
Unknown
Tags
Unknown