mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-11 04:18:39 +08:00
fs/ntfs3: Fix formatting, change comments, renaming
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 <chenhuacai@loongson.cn> Signed-off-by: Konstantin Komarov <almaz.alexandrovich@paragon-software.com>
This commit is contained in:
parent
2fef55d8f7
commit
911daf695a
@ -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;
|
||||
|
@ -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)
|
||||
|
@ -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)
|
||||
|
@ -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);
|
||||
|
@ -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)
|
||||
|
Loading…
Reference in New Issue
Block a user