apparmor: Remove use of the double lock
authorJohn Johansen <john.johansen@canonical.com>
Tue, 1 Apr 2025 22:28:13 +0000 (15:28 -0700)
committerJohn Johansen <john.johansen@canonical.com>
Wed, 16 Jul 2025 05:39:43 +0000 (22:39 -0700)
commitbc6e5f6933b8e7b74858ac830d5b9b4ca10a099a
treeb2b4148be773a973325f3785d2c956a59f12564a
parent6afb0a7bc95a61e40c38c58e2bcf6c88fff68d67
apparmor: Remove use of the double lock

The use of the double lock is not necessary and problematic. Instead
pull the bits that need locks into their own sections and grab the
needed references.

Fixes: c05e705812d1 ("apparmor: add fine grained af_unix mediation")
Signed-off-by: John Johansen <john.johansen@canonical.com>
security/apparmor/af_unix.c
security/apparmor/include/af_unix.h
security/apparmor/include/audit.h
security/apparmor/lsm.c
security/apparmor/net.c