From c6a14b32c9ba041fbe043aa30ebd5c6b467d6518 Mon Sep 17 00:00:00 2001 From: Eric Biggers Date: Sat, 14 Jun 2025 15:13:01 -0700 Subject: [PATCH] fscrypt: Explicitly include Fix build warnings with W=1 that started appearing after commit a934a57a42f6 ("scripts/misc-check: check missing #include when W=1"). While at it, also sort the include lists alphabetically. Link: https://lore.kernel.org/r/20250614221301.100803-1-ebiggers@kernel.org Signed-off-by: Eric Biggers --- fs/crypto/bio.c | 6 ++++-- fs/crypto/crypto.c | 8 +++++--- fs/crypto/fname.c | 6 ++++-- fs/crypto/hkdf.c | 2 +- fs/crypto/hooks.c | 2 ++ fs/crypto/inline_crypt.c | 1 + fs/crypto/keyring.c | 5 +++-- fs/crypto/keysetup.c | 1 + fs/crypto/policy.c | 4 +++- 9 files changed, 24 insertions(+), 11 deletions(-) diff --git a/fs/crypto/bio.c b/fs/crypto/bio.c index 0ad8c30b8fa5..13ad2dd771b6 100644 --- a/fs/crypto/bio.c +++ b/fs/crypto/bio.c @@ -7,10 +7,12 @@ * Copyright (C) 2015, Motorola Mobility */ -#include -#include #include +#include +#include #include +#include + #include "fscrypt_private.h" /** diff --git a/fs/crypto/crypto.c b/fs/crypto/crypto.c index b74b5937e695..ddf6991d46da 100644 --- a/fs/crypto/crypto.c +++ b/fs/crypto/crypto.c @@ -20,12 +20,14 @@ * Special Publication 800-38E and IEEE P1619/D16. */ -#include +#include +#include #include #include -#include +#include #include -#include +#include + #include "fscrypt_private.h" static unsigned int num_prealloc_crypto_pages = 32; diff --git a/fs/crypto/fname.c b/fs/crypto/fname.c index 010f9c0a4c2f..fb01dde0f2e5 100644 --- a/fs/crypto/fname.c +++ b/fs/crypto/fname.c @@ -11,11 +11,13 @@ * This has not yet undergone a rigorous security audit. */ -#include -#include #include #include #include +#include +#include +#include + #include "fscrypt_private.h" /* diff --git a/fs/crypto/hkdf.c b/fs/crypto/hkdf.c index 0f3028adc9c7..5c095c8aa3b5 100644 --- a/fs/crypto/hkdf.c +++ b/fs/crypto/hkdf.c @@ -8,8 +8,8 @@ */ #include -#include #include +#include #include "fscrypt_private.h" diff --git a/fs/crypto/hooks.c b/fs/crypto/hooks.c index d8d5049b8fe1..e0b32ac841f7 100644 --- a/fs/crypto/hooks.c +++ b/fs/crypto/hooks.c @@ -5,6 +5,8 @@ * Encryption hooks for higher-level filesystem operations. */ +#include + #include "fscrypt_private.h" /** diff --git a/fs/crypto/inline_crypt.c b/fs/crypto/inline_crypt.c index 1d008c440cb6..caaff809765b 100644 --- a/fs/crypto/inline_crypt.c +++ b/fs/crypto/inline_crypt.c @@ -15,6 +15,7 @@ #include #include #include +#include #include #include #include diff --git a/fs/crypto/keyring.c b/fs/crypto/keyring.c index ace369f13068..7557f6a88b8f 100644 --- a/fs/crypto/keyring.c +++ b/fs/crypto/keyring.c @@ -18,12 +18,13 @@ * information about these ioctls. */ -#include #include +#include #include -#include #include +#include #include +#include #include "fscrypt_private.h" diff --git a/fs/crypto/keysetup.c b/fs/crypto/keysetup.c index 0d71843af946..a67e20d126c9 100644 --- a/fs/crypto/keysetup.c +++ b/fs/crypto/keysetup.c @@ -9,6 +9,7 @@ */ #include +#include #include #include "fscrypt_private.h" diff --git a/fs/crypto/policy.c b/fs/crypto/policy.c index 701259991277..6ad30ae07c06 100644 --- a/fs/crypto/policy.c +++ b/fs/crypto/policy.c @@ -10,11 +10,13 @@ * Modified by Eric Biggers, 2019 for v2 policy support. */ +#include #include +#include #include #include #include -#include + #include "fscrypt_private.h" /** -- 2.51.0