namei.c (87a0b2fafc09766d8c55461a18345a1cfb10a7fe) | namei.c (5298d4bfe80f6ae6ae2777bcd1357b0022d98573) |
---|---|
1// SPDX-License-Identifier: GPL-2.0 2/* 3 * fs/f2fs/namei.c 4 * 5 * Copyright (c) 2012 Samsung Electronics Co., Ltd. 6 * http://www.samsung.com/ 7 */ 8#include <linux/fs.h> --- 547 unchanged lines hidden (view full) --- 556 (S_ISDIR(inode->i_mode) || S_ISLNK(inode->i_mode)) && 557 !fscrypt_has_permitted_context(dir, inode)) { 558 f2fs_warn(F2FS_I_SB(inode), "Inconsistent encryption contexts: %lu/%lu", 559 dir->i_ino, inode->i_ino); 560 err = -EPERM; 561 goto out_iput; 562 } 563out_splice: | 1// SPDX-License-Identifier: GPL-2.0 2/* 3 * fs/f2fs/namei.c 4 * 5 * Copyright (c) 2012 Samsung Electronics Co., Ltd. 6 * http://www.samsung.com/ 7 */ 8#include <linux/fs.h> --- 547 unchanged lines hidden (view full) --- 556 (S_ISDIR(inode->i_mode) || S_ISLNK(inode->i_mode)) && 557 !fscrypt_has_permitted_context(dir, inode)) { 558 f2fs_warn(F2FS_I_SB(inode), "Inconsistent encryption contexts: %lu/%lu", 559 dir->i_ino, inode->i_ino); 560 err = -EPERM; 561 goto out_iput; 562 } 563out_splice: |
564#ifdef CONFIG_UNICODE | 564#if IS_ENABLED(CONFIG_UNICODE) |
565 if (!inode && IS_CASEFOLDED(dir)) { 566 /* Eventually we want to call d_add_ci(dentry, NULL) 567 * for negative dentries in the encoding case as 568 * well. For now, prevent the negative dentry 569 * from being cached. 570 */ 571 trace_f2fs_lookup_end(dir, dentry, ino, err); 572 return NULL; --- 44 unchanged lines hidden (view full) --- 617 f2fs_lock_op(sbi); 618 err = f2fs_acquire_orphan_inode(sbi); 619 if (err) { 620 f2fs_unlock_op(sbi); 621 f2fs_put_page(page, 0); 622 goto fail; 623 } 624 f2fs_delete_entry(de, page, dir, inode); | 565 if (!inode && IS_CASEFOLDED(dir)) { 566 /* Eventually we want to call d_add_ci(dentry, NULL) 567 * for negative dentries in the encoding case as 568 * well. For now, prevent the negative dentry 569 * from being cached. 570 */ 571 trace_f2fs_lookup_end(dir, dentry, ino, err); 572 return NULL; --- 44 unchanged lines hidden (view full) --- 617 f2fs_lock_op(sbi); 618 err = f2fs_acquire_orphan_inode(sbi); 619 if (err) { 620 f2fs_unlock_op(sbi); 621 f2fs_put_page(page, 0); 622 goto fail; 623 } 624 f2fs_delete_entry(de, page, dir, inode); |
625#ifdef CONFIG_UNICODE | 625#if IS_ENABLED(CONFIG_UNICODE) |
626 /* VFS negative dentries are incompatible with Encoding and 627 * Case-insensitiveness. Eventually we'll want avoid 628 * invalidating the dentries here, alongside with returning the 629 * negative dentries at f2fs_lookup(), when it is better 630 * supported by the VFS for the CI case. 631 */ 632 if (IS_CASEFOLDED(dir)) 633 d_invalidate(dentry); --- 744 unchanged lines hidden --- | 626 /* VFS negative dentries are incompatible with Encoding and 627 * Case-insensitiveness. Eventually we'll want avoid 628 * invalidating the dentries here, alongside with returning the 629 * negative dentries at f2fs_lookup(), when it is better 630 * supported by the VFS for the CI case. 631 */ 632 if (IS_CASEFOLDED(dir)) 633 d_invalidate(dentry); --- 744 unchanged lines hidden --- |