From: William Lee Irwin III <wli@holomorphy.com>
To: Linus Torvalds <torvalds@osdl.org>
Cc: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: Make drivers/char/mem.c use remap_pfn_range()
Date: Fri, 22 Oct 2004 07:37:14 -0700 [thread overview]
Message-ID: <20041022143714.GT17038@holomorphy.com> (raw)
In-Reply-To: <Pine.LNX.4.58.0410220720220.2101@ppc970.osdl.org>
On Thu, 21 Oct 2004, William Lee Irwin III wrote:
>> Odd. I doublechecked the patches I submitted and they actually
>> covered this.
On Fri, Oct 22, 2004 at 07:24:34AM -0700, Linus Torvalds wrote:
> Andrew had a broken patch that shifted the wrong argument by PAGE_SHIFT,
> do you want to take the blame for that one (it shifted the size, not the
> pfn)?
What I posted shifted the correct argument, though vma->vm_pgoff would
have been been better, as it shifted offset right by PAGE_SHIFT, where
offset could have overflowed. I have no idea what you're referring to
about shifting the wrong argument.
This hunk appeared verbatim in my posted patch,
Message-ID: <20040925075102.GG9106@holomorphy.com>:
Index: mm3-2.6.9-rc2/drivers/char/mem.c
===================================================================
--- mm3-2.6.9-rc2.orig/drivers/char/mem.c 2004-09-25 00:21:50.622348424 -0700
+++ mm3-2.6.9-rc2/drivers/char/mem.c 2004-09-25 00:21:57.538297040 -0700
@@ -227,7 +227,7 @@
*/
vma->vm_flags |= VM_RESERVED|VM_IO;
- if (remap_page_range(vma, vma->vm_start, offset,
+ if (remap_pfn_range(vma, vma->vm_start, offset >> PAGE_SHIFT,
vma->vm_end-vma->vm_start, vma->vm_page_prot))
return -EAGAIN;
return 0;
next prev parent reply other threads:[~2004-10-22 14:37 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <200410220206.i9M26gUi016689@hera.kernel.org>
2004-10-22 2:19 ` Make drivers/char/mem.c use remap_pfn_range() William Lee Irwin III
2004-10-22 14:24 ` Linus Torvalds
2004-10-22 14:37 ` William Lee Irwin III [this message]
2004-10-22 15:09 ` Linus Torvalds
2004-10-22 15:13 ` William Lee Irwin III
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=20041022143714.GT17038@holomorphy.com \
--to=wli@holomorphy.com \
--cc=linux-kernel@vger.kernel.org \
--cc=torvalds@osdl.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