From: Fengguang Wu <fengguang.wu@intel.com>
To: kernel-janitors@vger.kernel.org
Subject: kernel/sys.c:1868:2: warning: passing argument 2 of 'access_ok' makes pointer from integer without a
Date: Sun, 07 Oct 2012 00:20:16 +0000 [thread overview]
Message-ID: <20121007002016.GA5678@localhost> (raw)
Hi Cyrill,
FYI, there are new compile warnings show up in
commit: 20e61e149ba9a4fe4c4867a76e399879d802e669 prctl: use access_ok() instead of TASK_SIZE in prctl_set_mm()
config: m68k-allmodconfig
All warnings:
kernel/sys.c: In function 'prctl_set_mm':
kernel/sys.c:1868:2: warning: passing argument 2 of 'access_ok' makes pointer from integer without a cast [enabled by default]
arch/m68k/include/asm/uaccess_mm.h:17:19: note: expected 'const void *' but argument is of type 'long unsigned int'
vim +1868 kernel/sys.c
028ee4be (Cyrill Gorcunov 2012-01-12 1852) unsigned long arg4, unsigned long arg5)
028ee4be (Cyrill Gorcunov 2012-01-12 1853) {
028ee4be (Cyrill Gorcunov 2012-01-12 1854) unsigned long rlim = rlimit(RLIMIT_DATA);
028ee4be (Cyrill Gorcunov 2012-01-12 1855) struct mm_struct *mm = current->mm;
fe8c7f5c (Cyrill Gorcunov 2012-05-31 1856) struct vm_area_struct *vma;
fe8c7f5c (Cyrill Gorcunov 2012-05-31 1857) int error;
028ee4be (Cyrill Gorcunov 2012-01-12 1858)
fe8c7f5c (Cyrill Gorcunov 2012-05-31 1859) if (arg5 || (arg4 && opt != PR_SET_MM_AUXV))
028ee4be (Cyrill Gorcunov 2012-01-12 1860) return -EINVAL;
028ee4be (Cyrill Gorcunov 2012-01-12 1861)
79f0713d (Cyrill Gorcunov 2012-03-15 1862) if (!capable(CAP_SYS_RESOURCE))
028ee4be (Cyrill Gorcunov 2012-01-12 1863) return -EPERM;
028ee4be (Cyrill Gorcunov 2012-01-12 1864)
b32dfe37 (Cyrill Gorcunov 2012-05-31 1865) if (opt = PR_SET_MM_EXE_FILE)
b32dfe37 (Cyrill Gorcunov 2012-05-31 1866) return prctl_set_mm_exe_file(mm, (unsigned int)addr);
b32dfe37 (Cyrill Gorcunov 2012-05-31 1867)
20e61e14 (Cyrill Gorcunov 2012-09-26 @1868) if (!access_ok(VERIFY_READ, addr, sizeof(addr)) || addr < mmap_min_addr)
028ee4be (Cyrill Gorcunov 2012-01-12 1869) return -EINVAL;
028ee4be (Cyrill Gorcunov 2012-01-12 1870)
fe8c7f5c (Cyrill Gorcunov 2012-05-31 1871) error = -EINVAL;
fe8c7f5c (Cyrill Gorcunov 2012-05-31 1872)
028ee4be (Cyrill Gorcunov 2012-01-12 1873) down_read(&mm->mmap_sem);
028ee4be (Cyrill Gorcunov 2012-01-12 1874) vma = find_vma(mm, addr);
028ee4be (Cyrill Gorcunov 2012-01-12 1875)
028ee4be (Cyrill Gorcunov 2012-01-12 1876) switch (opt) {
---
0-DAY kernel build testing backend Open Source Technology Center
Fengguang Wu, Yuanhan Liu Intel Corporation
next reply other threads:[~2012-10-07 0:20 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-10-07 0:20 Fengguang Wu [this message]
2012-10-07 21:36 ` kernel/sys.c:1868:2: warning: passing argument 2 of 'access_ok' makes pointer from integer witho Cyrill Gorcunov
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=20121007002016.GA5678@localhost \
--to=fengguang.wu@intel.com \
--cc=kernel-janitors@vger.kernel.org \
/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.