linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@oracle.com>
To: Cyrill Gorcunov <gorcunov@gmail.com>
Cc: kbuild@01.org, Linux Memory Management List <linux-mm@kvack.org>
Subject: Re: [next:master 2131/2422] kernel/sys.c:1888 prctl_set_mm_map() warn: maybe return -EFAULT instead of the bytes remaining?
Date: Wed, 27 Aug 2014 13:24:39 +0300	[thread overview]
Message-ID: <20140827102439.GO5100@mwanda> (raw)
In-Reply-To: <20140827100909.GA8692@moon>

On Wed, Aug 27, 2014 at 02:09:09PM +0400, Cyrill Gorcunov wrote:

> Not really sure I'm follow. @error is error code either 0 (on success) or
> any other if some problem happened.


It's complaining about this:

kernel/sys.c
  1846          if (prctl_map.auxv_size) {
  1847                  up_read(&mm->mmap_sem);
  1848                  memset(user_auxv, 0, sizeof(user_auxv));
  1849                  error = copy_from_user(user_auxv,
  1850                                         (const void __user *)prctl_map.auxv,
  1851                                         prctl_map.auxv_size);
  1852                  down_read(&mm->mmap_sem);
  1853                  if (error)
  1854                          goto out;
  1855          }

It should say:

			if (error) {
				error = -EFAULT;
				goto out;
			}

regards,
dan carpenter

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

  reply	other threads:[~2014-08-27 10:24 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-08-27  9:56 [next:master 2131/2422] kernel/sys.c:1888 prctl_set_mm_map() warn: maybe return -EFAULT instead of the bytes remaining? Dan Carpenter
2014-08-27 10:09 ` Cyrill Gorcunov
2014-08-27 10:24   ` Dan Carpenter [this message]
2014-08-27 10:28     ` 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=20140827102439.GO5100@mwanda \
    --to=dan.carpenter@oracle.com \
    --cc=gorcunov@gmail.com \
    --cc=kbuild@01.org \
    --cc=linux-mm@kvack.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).