From: Anton Blanchard <anton@samba.org>
To: torvalds@transmeta.com
Cc: akpm@digeo.com, linux-kernel@vger.kernel.org
Subject: [PATCH] fix return value after hugetlb mmap failure
Date: Mon, 30 Jun 2003 11:01:16 +1000 [thread overview]
Message-ID: <20030630010116.GA1784@krispykreme> (raw)
Hi,
At the moment no one uses is_aligned_hugepage_range or is_hugepage_only_range,
but it is reasonable to assume they return true or false.
On error we want to return -EINVAL back to userspace.
Anton
===== /mnt/kernels/linux-2.5/mm/mmap.c 1.86 vs edited =====
--- 1.86/mm/mmap.c Thu Jun 26 09:30:53 2003
+++ edited//mnt/kernels/linux-2.5/mm/mmap.c Mon Jun 30 10:56:22 2003
@@ -846,7 +846,7 @@
ret = is_hugepage_only_range(addr, len);
}
if (ret)
- return ret;
+ return -EINVAL;
return addr;
}
reply other threads:[~2003-06-30 0:50 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=20030630010116.GA1784@krispykreme \
--to=anton@samba.org \
--cc=akpm@digeo.com \
--cc=linux-kernel@vger.kernel.org \
--cc=torvalds@transmeta.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