From: Ritesh Harjani <ritesh.list@gmail.com>
To: linux-ext4@vger.kernel.org
Cc: linux-fscrypt@vger.kernel.org, Theodore Ts'o <tytso@mit.edu>,
Eric Biggers <ebiggers@kernel.org>, Jan Kara <jack@suse.cz>,
Ritesh Harjani <ritesh.list@gmail.com>
Subject: [PATCHv2 0/3] ext4/crypto: Move out crypto related ops to crypto.c
Date: Sat, 14 May 2022 22:52:45 +0530 [thread overview]
Message-ID: <cover.1652539361.git.ritesh.list@gmail.com> (raw)
Hello,
This is 1st in the series to cleanup ext4/super.c, since it has grown quite
large. This moves out crypto related ops and few fs encryption related
definitions to fs/ext4/crypto.c
I have tested "-g encrypt" xfstests group and don't see any surprises there.
The changes are relatively straight forward since it is just moving/refactoring.
Currently these patches apply cleanly on ext4 tree's dev branch.
Since in these series test_dummy_encryption related changes are dropped, hence
I don't think that this should give any major conflict with Eric's series.
NOTE: I noticed we could move both ext4 & f2fs to use uuid_t lib API from
include/linux/uuid.h for managing sb->s_encrypt_pw_salt.
That should kill custom implementations of uuid_is_zero()/uuid_is_nonzero().
But since I noticed it while writing this cover letter, so I would like to
do those changes in a seperate patch series if that is ok. That way maybe we
could cleanup tree wide changes in fs/ (if there are others too).
RFC -> v2
==========
1. Dropped all test_dummy_encryption related changes
(Eric has separately submitted a v3 for fixing more general problems with
that mount option).
2. Addressed Eric comments to:-
1. rename ext4_crypto.c -> crypto.c
2. Refactor out ext4_ioc_get_encryption_pwsalt() into crypto.c
3. Made ext4_fname_from_fscrypt_name() static since it is only being called
from within crypto.c functions.
[RFC] - https://lore.kernel.org/linux-ext4/cover.1650517532.git.ritesh.list@gmail.com/
Ritesh Harjani (3):
ext4: Move ext4 crypto code to its own file crypto.c
ext4: Cleanup function defs from ext4.h into crypto.c
ext4: Refactor and move ext4_ioc_get_encryption_pwsalt()
fs/ext4/Makefile | 1 +
fs/ext4/crypto.c | 245 +++++++++++++++++++++++++++++++++++++++++++++++
fs/ext4/ext4.h | 79 ++++-----------
fs/ext4/ioctl.c | 58 +----------
fs/ext4/super.c | 122 -----------------------
5 files changed, 264 insertions(+), 241 deletions(-)
create mode 100644 fs/ext4/crypto.c
--
2.31.1
next reply other threads:[~2022-05-14 17:23 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-14 17:22 Ritesh Harjani [this message]
2022-05-14 17:22 ` [PATCHv2 1/3] ext4: Move ext4 crypto code to its own file crypto.c Ritesh Harjani
2022-05-15 3:33 ` Eric Biggers
2022-05-15 4:45 ` Ritesh Harjani
2022-05-14 17:22 ` [PATCHv2 2/3] ext4: Cleanup function defs from ext4.h into crypto.c Ritesh Harjani
2022-05-15 3:40 ` Eric Biggers
2022-05-15 4:49 ` Ritesh Harjani
2022-05-14 17:22 ` [PATCHv2 3/3] ext4: Refactor and move ext4_ioc_get_encryption_pwsalt() Ritesh Harjani
2022-05-15 3:42 ` Eric Biggers
2022-05-15 4:51 ` Ritesh Harjani
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=cover.1652539361.git.ritesh.list@gmail.com \
--to=ritesh.list@gmail.com \
--cc=ebiggers@kernel.org \
--cc=jack@suse.cz \
--cc=linux-ext4@vger.kernel.org \
--cc=linux-fscrypt@vger.kernel.org \
--cc=tytso@mit.edu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).