Skip to content

Commit 4746258

Browse files
author
Eric Biggers
committed
fscrypt: Remove gfp_t argument from fscrypt_encrypt_block_inplace()
This argument is no longer used, so remove it. Reviewed-by: Alex Markuze <amarkuze@redhat.com> Link: https://lore.kernel.org/r/20250710060754.637098-6-ebiggers@kernel.org Signed-off-by: Eric Biggers <ebiggers@kernel.org>
1 parent a9a95ec commit 4746258

4 files changed

Lines changed: 5 additions & 8 deletions

File tree

fs/ceph/crypto.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -523,8 +523,7 @@ int ceph_fscrypt_encrypt_block_inplace(const struct inode *inode,
523523

524524
doutc(cl, "%p %llx.%llx len %u offs %u blk %llu\n", inode,
525525
ceph_vinop(inode), len, offs, lblk_num);
526-
return fscrypt_encrypt_block_inplace(inode, page, len, offs, lblk_num,
527-
gfp_flags);
526+
return fscrypt_encrypt_block_inplace(inode, page, len, offs, lblk_num);
528527
}
529528

530529
/**

fs/crypto/crypto.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,6 @@ EXPORT_SYMBOL(fscrypt_encrypt_pagecache_blocks);
217217
* @offs: Byte offset within @page at which the block to encrypt begins
218218
* @lblk_num: Filesystem logical block number of the block, i.e. the 0-based
219219
* number of the block within the file
220-
* @gfp_flags: Memory allocation flags
221220
*
222221
* Encrypt a possibly-compressed filesystem block that is located in an
223222
* arbitrary page, not necessarily in the original pagecache page. The @inode
@@ -229,7 +228,7 @@ EXPORT_SYMBOL(fscrypt_encrypt_pagecache_blocks);
229228
*/
230229
int fscrypt_encrypt_block_inplace(const struct inode *inode, struct page *page,
231230
unsigned int len, unsigned int offs,
232-
u64 lblk_num, gfp_t gfp_flags)
231+
u64 lblk_num)
233232
{
234233
if (WARN_ON_ONCE(inode->i_sb->s_cop->supports_subblock_data_units))
235234
return -EOPNOTSUPP;

fs/ubifs/crypto.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ int ubifs_encrypt(const struct inode *inode, struct ubifs_data_node *dn,
5151
memset(p + in_len, 0, pad_len - in_len);
5252

5353
err = fscrypt_encrypt_block_inplace(inode, virt_to_page(p), pad_len,
54-
offset_in_page(p), block, GFP_NOFS);
54+
offset_in_page(p), block);
5555
if (err) {
5656
ubifs_err(c, "fscrypt_encrypt_block_inplace() failed: %d", err);
5757
return err;

include/linux/fscrypt.h

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -314,7 +314,7 @@ struct page *fscrypt_encrypt_pagecache_blocks(struct folio *folio,
314314
size_t len, size_t offs, gfp_t gfp_flags);
315315
int fscrypt_encrypt_block_inplace(const struct inode *inode, struct page *page,
316316
unsigned int len, unsigned int offs,
317-
u64 lblk_num, gfp_t gfp_flags);
317+
u64 lblk_num);
318318

319319
int fscrypt_decrypt_pagecache_blocks(struct folio *folio, size_t len,
320320
size_t offs);
@@ -487,8 +487,7 @@ static inline struct page *fscrypt_encrypt_pagecache_blocks(struct folio *folio,
487487
static inline int fscrypt_encrypt_block_inplace(const struct inode *inode,
488488
struct page *page,
489489
unsigned int len,
490-
unsigned int offs, u64 lblk_num,
491-
gfp_t gfp_flags)
490+
unsigned int offs, u64 lblk_num)
492491
{
493492
return -EOPNOTSUPP;
494493
}

0 commit comments

Comments
 (0)