mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Tania Oka <tania@centurysys.co.jp>
To: linux-kernel@vger.kernel.org
Cc: glenn@centurysys.co.jp
Subject: boundary condition bug in do_mmap()
Date: Wed, 30 May 2001 17:47:30 +0900	[thread overview]
Message-ID: <3B14B3A2.2843422E@centurysys.co.jp> (raw)

Hello

There seems to be a boundary condition bug in do_mmap()
(include/linux/mm.h).  It is in kernels as late as 2.4.4 (not sure about
later).   I saw it reported on a mailing list a year ago but I guess it
didn't make it to the right place.

In the inline function do_mmap(), there is a check for overflow of the
topmost address (line 449 of include/linux/mm.h in the 2.4.4 kernel I
have):

    if ((offset + PAGE_ALIGN(len)) < offset)

This test causes the function to return -EINVAL if offset is 0xfffff000
and len is 0x1000, although these should be valid values to map the last
4K according to the mmap() man page.

Please forward this to the right place.  I couldn't find anyone specific
in the MAINTAINERS file.

Thank you,
Tania


             reply	other threads:[~2001-05-30  8:53 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-05-30  8:47 Tania Oka [this message]
2001-05-30 20:12 ` Rik van Riel

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=3B14B3A2.2843422E@centurysys.co.jp \
    --to=tania@centurysys.co.jp \
    --cc=glenn@centurysys.co.jp \
    --cc=linux-kernel@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 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®