]> Git Repo - J-linux.git/commitdiff
fs/ntfs3: Fix formatting, change comments, renaming
authorKonstantin Komarov <[email protected]>
Wed, 26 Jun 2024 12:26:18 +0000 (15:26 +0300)
committerKonstantin Komarov <[email protected]>
Thu, 11 Jul 2024 09:19:46 +0000 (12:19 +0300)
Huacai Chen:
The label end_reply is obviously a typo. It should be "replay" in this
context. So rename end_reply to end_replay.

Suggested-by: Huacai Chen <[email protected]>
Signed-off-by: Konstantin Komarov <[email protected]>
fs/ntfs3/attrib.c
fs/ntfs3/file.c
fs/ntfs3/fslog.c
fs/ntfs3/inode.c
fs/ntfs3/namei.c

index 1d63e1c9469b99b09dcbfcebb397c5f4a52f4bed..6ede3e924deca55dccdd5f6223b04d7150a7bc45 100644 (file)
@@ -291,9 +291,9 @@ int attr_make_nonresident(struct ntfs_inode *ni, struct ATTRIB *attr,
                        struct address_space *mapping = ni->vfs_inode.i_mapping;
                        struct folio *folio;
 
-                       folio = __filemap_get_folio(mapping, 0,
-                                       FGP_LOCK | FGP_ACCESSED | FGP_CREAT,
-                                       mapping_gfp_mask(mapping));
+                       folio = __filemap_get_folio(
+                               mapping, 0, FGP_LOCK | FGP_ACCESSED | FGP_CREAT,
+                               mapping_gfp_mask(mapping));
                        if (IS_ERR(folio)) {
                                err = PTR_ERR(folio);
                                goto out2;
index 1ba837b2749770b4c90f9f8f995f65ebd10ee21e..ca1ddc46bd8664b88b716ce5a9f84652adddcfb1 100644 (file)
@@ -105,6 +105,9 @@ int ntfs_fileattr_set(struct mnt_idmap *idmap, struct dentry *dentry,
        return 0;
 }
 
+/*
+ * ntfs_ioctl - file_operations::unlocked_ioctl
+ */
 long ntfs_ioctl(struct file *filp, u32 cmd, unsigned long arg)
 {
        struct inode *inode = file_inode(filp);
@@ -260,9 +263,9 @@ static int ntfs_zero_range(struct inode *inode, u64 vbo, u64 vbo_to)
                                                       PAGE_SIZE;
                iblock = page_off >> inode->i_blkbits;
 
-               folio = __filemap_get_folio(mapping, idx,
-                               FGP_LOCK | FGP_ACCESSED | FGP_CREAT,
-                               mapping_gfp_constraint(mapping, ~__GFP_FS));
+               folio = __filemap_get_folio(
+                       mapping, idx, FGP_LOCK | FGP_ACCESSED | FGP_CREAT,
+                       mapping_gfp_constraint(mapping, ~__GFP_FS));
                if (IS_ERR(folio))
                        return PTR_ERR(folio);
 
@@ -887,7 +890,8 @@ static int ntfs_get_frame_pages(struct address_space *mapping, pgoff_t index,
                struct folio *folio;
 
                folio = __filemap_get_folio(mapping, index,
-                               FGP_LOCK | FGP_ACCESSED | FGP_CREAT, gfp_mask);
+                                           FGP_LOCK | FGP_ACCESSED | FGP_CREAT,
+                                           gfp_mask);
                if (IS_ERR(folio)) {
                        while (npages--) {
                                folio = page_folio(pages[npages]);
@@ -1258,7 +1262,7 @@ static int ntfs_file_release(struct inode *inode, struct file *file)
 }
 
 /*
- * ntfs_fiemap - file_operations::fiemap
+ * ntfs_fiemap - inode_operations::fiemap
  */
 int ntfs_fiemap(struct inode *inode, struct fiemap_extent_info *fieinfo,
                __u64 start, __u64 len)
index 5ee923904b6afb28446a2ad1bb5663e2b9ed2995..c64dd114ac652f236353b5affd73c271b76a47d9 100644 (file)
@@ -724,8 +724,8 @@ static bool check_rstbl(const struct RESTART_TABLE *rt, size_t bytes)
 
        if (!rsize || rsize > bytes ||
            rsize + sizeof(struct RESTART_TABLE) > bytes || bytes < ts ||
-           le16_to_cpu(rt->total) > ne ||
-                       ff > ts - sizeof(__le32) || lf > ts - sizeof(__le32) ||
+           le16_to_cpu(rt->total) > ne || ff > ts - sizeof(__le32) ||
+           lf > ts - sizeof(__le32) ||
            (ff && ff < sizeof(struct RESTART_TABLE)) ||
            (lf && lf < sizeof(struct RESTART_TABLE))) {
                return false;
@@ -4690,7 +4690,7 @@ end_log_records_enumerate:
         * table are not empty.
         */
        if ((!dptbl || !dptbl->total) && (!trtbl || !trtbl->total))
-               goto end_reply;
+               goto end_replay;
 
        sbi->flags |= NTFS_FLAGS_NEED_REPLAY;
        if (is_ro)
@@ -5119,7 +5119,7 @@ undo_action_done:
 
        sbi->flags &= ~NTFS_FLAGS_NEED_REPLAY;
 
-end_reply:
+end_replay:
 
        err = 0;
        if (is_ro)
index 77ae0dccbd5c54ea22ffe48c7fa32caecd20983f..6b0bdc474e763f2361118d47dc372aa43549eef7 100644 (file)
@@ -578,6 +578,7 @@ static noinline int ntfs_get_block_vbo(struct inode *inode, u64 vbo,
                bh->b_blocknr = RESIDENT_LCN;
                bh->b_size = block_size;
                if (!folio) {
+                       /* direct io (read) or bmap call */
                        err = 0;
                } else {
                        ni_lock(ni);
@@ -911,9 +912,9 @@ int ntfs_write_begin(struct file *file, struct address_space *mapping,
 
        *pagep = NULL;
        if (is_resident(ni)) {
-               struct folio *folio = __filemap_get_folio(mapping,
-                               pos >> PAGE_SHIFT, FGP_WRITEBEGIN,
-                               mapping_gfp_mask(mapping));
+               struct folio *folio = __filemap_get_folio(
+                       mapping, pos >> PAGE_SHIFT, FGP_WRITEBEGIN,
+                       mapping_gfp_mask(mapping));
 
                if (IS_ERR(folio)) {
                        err = PTR_ERR(folio);
index cc04be9a4394720ba6fe0b947b6a4c97c0bf06ad..f16d318c4372a4c446a08cd82a6fcbb0b31e9c40 100644 (file)
@@ -112,9 +112,7 @@ static int ntfs_create(struct mnt_idmap *idmap, struct inode *dir,
 }
 
 /*
- * ntfs_mknod
- *
- * inode_operations::mknod
+ * ntfs_mknod - inode_operations::mknod
  */
 static int ntfs_mknod(struct mnt_idmap *idmap, struct inode *dir,
                      struct dentry *dentry, umode_t mode, dev_t rdev)
This page took 0.067532 seconds and 4 git commands to generate.