From: kernel test robot <lkp@intel.com>
To: oe-kbuild@lists.linux.dev
Cc: lkp@intel.com, Dan Carpenter <error27@gmail.com>
Subject: [jj-apparmor:apparmor-next 16/32] security/apparmor/mount.c:734 aa_pivotroot() warn: passing zero to 'PTR_ERR'
Date: Mon, 15 Jun 2026 09:03:25 +0800 [thread overview]
Message-ID: <202606150836.fltLXObQ-lkp@intel.com> (raw)
BCC: lkp@intel.com
CC: oe-kbuild-all@lists.linux.dev
TO: John Johansen <john.johansen@canonical.com>
CC: Georgia Garcia <georgia.garcia@canonical.com>
tree: https://git.kernel.org/pub/scm/linux/kernel/git/jj/linux-apparmor.git apparmor-next
head: d0691bd5dcaec2350039ecb04fa70faa91ac142d
commit: ed7cc1c6f240a0c2838c0617afb2b0466edd236f [16/32] apparmor: change fn_label_build() call to not return NULL
:::::: branch date: 22 hours ago
:::::: commit date: 22 hours ago
config: m68k-randconfig-r072-20260615 (https://download.01.org/0day-ci/archive/20260615/202606150836.fltLXObQ-lkp@intel.com/config)
compiler: m68k-linux-gcc (GCC) 11.5.0
smatch: v0.5.0-9185-gbcc58b9c
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Reported-by: Dan Carpenter <error27@gmail.com>
| Closes: https://lore.kernel.org/r/202606150836.fltLXObQ-lkp@intel.com/
New smatch warnings:
security/apparmor/mount.c:734 aa_pivotroot() warn: passing zero to 'PTR_ERR'
security/apparmor/domain.c:902 handle_onexec() warn: passing zero to 'PTR_ERR'
security/apparmor/domain.c:978 apparmor_bprm_creds_for_exec() warn: passing zero to 'PTR_ERR'
security/apparmor/domain.c:1229 change_hat() warn: passing zero to 'PTR_ERR'
security/apparmor/domain.c:1561 aa_change_profile() warn: passing zero to 'PTR_ERR'
Old smatch warnings:
arch/m68k/include/asm/io_no.h:50 __cf_internalio() warn: always true condition '(addr <= 3758096384 + 536870912 - 1) => (0-u32max <= u32max)'
arch/m68k/include/asm/io_no.h:50 __cf_internalio() warn: always true condition '(addr <= 3758096384 + 536870912 - 1) => (0-u32max <= u32max)'
security/apparmor/domain.c:787 profile_transition() warn: passing zero to 'ERR_PTR'
security/apparmor/domain.c:920 handle_onexec() warn: passing zero to 'ERR_PTR'
vim +/PTR_ERR +734 security/apparmor/mount.c
2ea3ffb7782a84 John Johansen 2017-07-18 715
90c436a64a6e20 John Johansen 2022-09-19 716 int aa_pivotroot(const struct cred *subj_cred, struct aa_label *label,
90c436a64a6e20 John Johansen 2022-09-19 717 const struct path *old_path,
2ea3ffb7782a84 John Johansen 2017-07-18 718 const struct path *new_path)
2ea3ffb7782a84 John Johansen 2017-07-18 719 {
2ea3ffb7782a84 John Johansen 2017-07-18 720 struct aa_profile *profile;
2ea3ffb7782a84 John Johansen 2017-07-18 721 struct aa_label *target = NULL;
2ea3ffb7782a84 John Johansen 2017-07-18 722 char *old_buffer = NULL, *new_buffer = NULL, *info = NULL;
2ea3ffb7782a84 John Johansen 2017-07-18 723 int error;
2ea3ffb7782a84 John Johansen 2017-07-18 724
2ea3ffb7782a84 John Johansen 2017-07-18 725 AA_BUG(!label);
2ea3ffb7782a84 John Johansen 2017-07-18 726 AA_BUG(!old_path);
2ea3ffb7782a84 John Johansen 2017-07-18 727 AA_BUG(!new_path);
2ea3ffb7782a84 John Johansen 2017-07-18 728
341c1fda5e1715 John Johansen 2019-09-14 729 old_buffer = aa_get_buffer(false);
341c1fda5e1715 John Johansen 2019-09-14 730 new_buffer = aa_get_buffer(false);
df323337e507a0 Sebastian Andrzej Siewior 2019-05-03 731 error = -ENOMEM;
df323337e507a0 Sebastian Andrzej Siewior 2019-05-03 732 if (!old_buffer || !new_buffer)
df323337e507a0 Sebastian Andrzej Siewior 2019-05-03 733 goto out;
8ac2ca328ec935 Sebastian Andrzej Siewior 2019-04-05 @734 target = fn_label_build(label, profile, GFP_KERNEL,
:::::: The code at line 734 was first introduced by commit
:::::: 8ac2ca328ec9356f56d0dad3aa350d9600db951a apparmor: Switch to GFP_KERNEL where possible
:::::: TO: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
:::::: CC: John Johansen <john.johansen@canonical.com>
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
reply other threads:[~2026-06-15 1:04 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=202606150836.fltLXObQ-lkp@intel.com \
--to=lkp@intel.com \
--cc=error27@gmail.com \
--cc=oe-kbuild@lists.linux.dev \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.