From: kbuild test robot <lkp@intel.com>
To: Chao Yu <yuchao0@huawei.com>
Cc: kbuild-all@01.org, jaegeuk@kernel.org,
linux-f2fs-devel@lists.sourceforge.net,
linux-kernel@vger.kernel.org, chao@kernel.org,
Chao Yu <yuchao0@huawei.com>
Subject: Re: [PATCH] f2fs: don't allow rename unencrypted file to encrypted directory
Date: Sat, 11 Mar 2017 06:14:28 +0800 [thread overview]
Message-ID: <201703110650.BowGPcBb%fengguang.wu@intel.com> (raw)
In-Reply-To: <20170308120820.86785-1-yuchao0@huawei.com>
[-- Attachment #1: Type: text/plain, Size: 3746 bytes --]
Hi Chao,
[auto build test WARNING on f2fs/dev]
[also build test WARNING on v4.11-rc1 next-20170309]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]
url: https://github.com/0day-ci/linux/commits/Chao-Yu/f2fs-don-t-allow-rename-unencrypted-file-to-encrypted-directory/20170311-052705
base: https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs.git dev
config: x86_64-randconfig-n0-03110505 (attached as .config)
compiler: gcc-4.8 (Debian 4.8.4-1) 4.8.4
reproduce:
# save the attached .config to linux build tree
make ARCH=x86_64
All warnings (new ones prefixed by >>):
In file included from include/linux/linkage.h:4:0,
from include/linux/fs.h:4,
from fs/f2fs/namei.c:11:
fs/f2fs/namei.c: In function 'f2fs_cross_rename':
fs/f2fs/namei.c:858:36: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
if (f2fs_encrypted_inode(old_dir) && !f2fs_encrypted_inode(new_inode) ||
^
include/linux/compiler.h:160:30: note: in definition of macro '__trace_if'
if (__builtin_constant_p(!!(cond)) ? !!(cond) : \
^
>> fs/f2fs/namei.c:858:2: note: in expansion of macro 'if'
if (f2fs_encrypted_inode(old_dir) && !f2fs_encrypted_inode(new_inode) ||
^
fs/f2fs/namei.c:858:36: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
if (f2fs_encrypted_inode(old_dir) && !f2fs_encrypted_inode(new_inode) ||
^
include/linux/compiler.h:160:42: note: in definition of macro '__trace_if'
if (__builtin_constant_p(!!(cond)) ? !!(cond) : \
^
>> fs/f2fs/namei.c:858:2: note: in expansion of macro 'if'
if (f2fs_encrypted_inode(old_dir) && !f2fs_encrypted_inode(new_inode) ||
^
fs/f2fs/namei.c:858:36: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
if (f2fs_encrypted_inode(old_dir) && !f2fs_encrypted_inode(new_inode) ||
^
include/linux/compiler.h:171:16: note: in definition of macro '__trace_if'
______r = !!(cond); \
^
>> fs/f2fs/namei.c:858:2: note: in expansion of macro 'if'
if (f2fs_encrypted_inode(old_dir) && !f2fs_encrypted_inode(new_inode) ||
^
vim +/if +858 fs/f2fs/namei.c
842 struct f2fs_sb_info *sbi = F2FS_I_SB(old_dir);
843 struct inode *old_inode = d_inode(old_dentry);
844 struct inode *new_inode = d_inode(new_dentry);
845 struct page *old_dir_page, *new_dir_page;
846 struct page *old_page, *new_page;
847 struct f2fs_dir_entry *old_dir_entry = NULL, *new_dir_entry = NULL;
848 struct f2fs_dir_entry *old_entry, *new_entry;
849 int old_nlink = 0, new_nlink = 0;
850 int err = -ENOENT;
851
852 if ((f2fs_encrypted_inode(old_dir) &&
853 !fscrypt_has_encryption_key(old_dir)) ||
854 (f2fs_encrypted_inode(new_dir) &&
855 !fscrypt_has_encryption_key(new_dir)))
856 return -ENOKEY;
857
> 858 if (f2fs_encrypted_inode(old_dir) && !f2fs_encrypted_inode(new_inode) ||
859 f2fs_encrypted_inode(new_dir) && !f2fs_encrypted_inode(old_inode))
860 return -EPERM;
861
862 if ((f2fs_encrypted_inode(old_dir) || f2fs_encrypted_inode(new_dir)) &&
863 (old_dir != new_dir) &&
864 (!fscrypt_has_permitted_context(new_dir, old_inode) ||
865 !fscrypt_has_permitted_context(old_dir, new_inode)))
866 return -EPERM;
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 26748 bytes --]
prev parent reply other threads:[~2017-03-10 22:15 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-08 12:08 Chao Yu
2017-03-08 13:35 ` [f2fs-dev] " Kinglong Mee
2017-03-09 1:33 ` Chao Yu
2017-03-10 21:49 ` kbuild test robot
2017-03-10 22:14 ` kbuild test robot [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=201703110650.BowGPcBb%fengguang.wu@intel.com \
--to=lkp@intel.com \
--cc=chao@kernel.org \
--cc=jaegeuk@kernel.org \
--cc=kbuild-all@01.org \
--cc=linux-f2fs-devel@lists.sourceforge.net \
--cc=linux-kernel@vger.kernel.org \
--cc=yuchao0@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®