Skip to content

Commit e5e038b

Browse files
committed
Merge tag 'fs_for_v6.9-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/jack/linux-fs
Pull ext2, isofs, udf, and quota updates from Jan Kara: "A lot of material this time: - removal of a lot of GFP_NOFS usage from ext2, udf, quota (either it was legacy or replaced with scoped memalloc_nofs_*() API) - removal of BUG_ONs in quota code - conversion of UDF to the new mount API - tightening quota on disk format verification - fix some potentially unsafe use of RCU pointers in quota code and annotate everything properly to make sparse happy - a few other small quota, ext2, udf, and isofs fixes" * tag 'fs_for_v6.9-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/jack/linux-fs: (26 commits) udf: remove SLAB_MEM_SPREAD flag usage quota: remove SLAB_MEM_SPREAD flag usage isofs: remove SLAB_MEM_SPREAD flag usage ext2: remove SLAB_MEM_SPREAD flag usage ext2: mark as deprecated udf: convert to new mount API udf: convert novrs to an option flag MAINTAINERS: add missing git address for ext2 entry quota: Detect loops in quota tree quota: Properly annotate i_dquot arrays with __rcu quota: Fix rcu annotations of inode dquot pointers isofs: handle CDs with bad root inode but good Joliet root directory udf: Avoid invalid LVID used on mount quota: Fix potential NULL pointer dereference quota: Drop GFP_NOFS instances under dquot->dq_lock and dqio_sem quota: Set nofs allocation context when acquiring dqio_sem ext2: Remove GFP_NOFS use in ext2_xattr_cache_insert() ext2: Drop GFP_NOFS use in ext2_get_blocks() ext2: Drop GFP_NOFS allocation from ext2_init_block_alloc_info() udf: Remove GFP_NOFS allocation in udf_expand_file_adinicb() ...
2 parents 1715f71 + a78e41a commit e5e038b

32 files changed

+608
-423
lines changed

MAINTAINERS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8021,6 +8021,7 @@ M: Jan Kara <jack@suse.com>
80218021
L: linux-ext4@vger.kernel.org
80228022
S: Maintained
80238023
F: Documentation/filesystems/ext2.rst
8024+
T: git git://git.kernel.org/pub/scm/linux/kernel/git/jack/linux-fs.git
80248025
F: fs/ext2/
80258026
F: include/linux/ext2*
80268027

fs/ext2/Kconfig

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,23 @@
11
# SPDX-License-Identifier: GPL-2.0-only
22
config EXT2_FS
3-
tristate "Second extended fs support"
3+
tristate "Second extended fs support (DEPRECATED)"
44
select BUFFER_HEAD
55
select FS_IOMAP
66
select LEGACY_DIRECT_IO
77
help
88
Ext2 is a standard Linux file system for hard disks.
99

10-
To compile this file system support as a module, choose M here: the
11-
module will be called ext2.
10+
This filesystem driver is deprecated because it does not properly
11+
support inode time stamps beyond 03:14:07 UTC on 19 January 2038.
1212

13-
If unsure, say Y.
13+
Ext2 users are advised to use ext4 driver to access their filesystem.
14+
The driver is fully compatible, supports filesystems without journal
15+
or extents, and also supports larger time stamps if the filesystem
16+
is created with at least 256 byte inodes.
17+
18+
This code is kept as a simple reference for filesystem developers.
19+
20+
If unsure, say N.
1421

1522
config EXT2_FS_XATTR
1623
bool "Ext2 extended attributes"

fs/ext2/balloc.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -412,7 +412,7 @@ void ext2_init_block_alloc_info(struct inode *inode)
412412
struct ext2_block_alloc_info *block_i;
413413
struct super_block *sb = inode->i_sb;
414414

415-
block_i = kmalloc(sizeof(*block_i), GFP_NOFS);
415+
block_i = kmalloc(sizeof(*block_i), GFP_KERNEL);
416416
if (block_i) {
417417
struct ext2_reserve_window_node *rsv = &block_i->rsv_window_node;
418418

fs/ext2/ext2.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -674,7 +674,7 @@ struct ext2_inode_info {
674674
struct inode vfs_inode;
675675
struct list_head i_orphan; /* unlinked but open inodes */
676676
#ifdef CONFIG_QUOTA
677-
struct dquot *i_dquot[MAXQUOTAS];
677+
struct dquot __rcu *i_dquot[MAXQUOTAS];
678678
#endif
679679
};
680680

fs/ext2/inode.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -754,7 +754,7 @@ static int ext2_get_blocks(struct inode *inode,
754754
*/
755755
err = sb_issue_zeroout(inode->i_sb,
756756
le32_to_cpu(chain[depth-1].key), count,
757-
GFP_NOFS);
757+
GFP_KERNEL);
758758
if (err) {
759759
mutex_unlock(&ei->truncate_mutex);
760760
goto cleanup;

fs/ext2/super.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -319,7 +319,7 @@ static ssize_t ext2_quota_read(struct super_block *sb, int type, char *data, siz
319319
static ssize_t ext2_quota_write(struct super_block *sb, int type, const char *data, size_t len, loff_t off);
320320
static int ext2_quota_on(struct super_block *sb, int type, int format_id,
321321
const struct path *path);
322-
static struct dquot **ext2_get_dquots(struct inode *inode)
322+
static struct dquot __rcu **ext2_get_dquots(struct inode *inode)
323323
{
324324
return EXT2_I(inode)->i_dquot;
325325
}

fs/ext2/xattr.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -874,7 +874,7 @@ ext2_xattr_cache_insert(struct mb_cache *cache, struct buffer_head *bh)
874874
__u32 hash = le32_to_cpu(HDR(bh)->h_hash);
875875
int error;
876876

877-
error = mb_cache_entry_create(cache, GFP_NOFS, hash, bh->b_blocknr,
877+
error = mb_cache_entry_create(cache, GFP_KERNEL, hash, bh->b_blocknr,
878878
true);
879879
if (error) {
880880
if (error == -EBUSY) {

fs/ext4/ext4.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1158,7 +1158,7 @@ struct ext4_inode_info {
11581158
tid_t i_datasync_tid;
11591159

11601160
#ifdef CONFIG_QUOTA
1161-
struct dquot *i_dquot[MAXQUOTAS];
1161+
struct dquot __rcu *i_dquot[MAXQUOTAS];
11621162
#endif
11631163

11641164
/* Precomputed uuid+inum+igen checksum for seeding inode checksums */

fs/ext4/super.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1599,7 +1599,7 @@ static ssize_t ext4_quota_write(struct super_block *sb, int type,
15991599
static int ext4_quota_enable(struct super_block *sb, int type, int format_id,
16001600
unsigned int flags);
16011601

1602-
static struct dquot **ext4_get_dquots(struct inode *inode)
1602+
static struct dquot __rcu **ext4_get_dquots(struct inode *inode)
16031603
{
16041604
return EXT4_I(inode)->i_dquot;
16051605
}

fs/f2fs/f2fs.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -830,7 +830,7 @@ struct f2fs_inode_info {
830830
spinlock_t i_size_lock; /* protect last_disk_size */
831831

832832
#ifdef CONFIG_QUOTA
833-
struct dquot *i_dquot[MAXQUOTAS];
833+
struct dquot __rcu *i_dquot[MAXQUOTAS];
834834

835835
/* quota space reservation, managed internally by quota code */
836836
qsize_t i_reserved_quota;

0 commit comments

Comments
 (0)