Skip to contentSkip to conversation

replaced io_remap_page_range() with io_remap_pfn_range()

PATCH In review Freddy Spierenburg 2 participants 5 messages Feb 17, 2006 – Feb 18, 2006

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 replaced io_remap_page_range() with io_remap_pfn_range()

Hi,

Replaced the no longer existing io_remap_page_range() routine with the io_remap_pfn_range() routine. Did not have a chance yet to test the functionality of the driver, but at least the kernel compiles cleanly again.

Signature · 4 lines
$ cat ~/.signature
Freddy Spierenburg <[email protected]> http://snarl.nl/~freddy/
GnuPG: 0x7941D1E1=C948 5851 26D2 FA5C 39F1  E588 6F17 FD5D 7941 D1E1
$ # Please read http://www.ietf.org/rfc/rfc2015.txt before complain!
drivers/video/au1100fb.c +2 -1
diff -Naur master.orig/drivers/video/au1100fb.c master.good/drivers/video/au1100fb.c
@@ -50,6 +50,7 @@
 #include <linux/interrupt.h>
 #include <linux/ctype.h>
 #include <linux/dma-mapping.h>
+#include <linux/platform_device.h>
 
 #include <asm/mach-au1x00/au1000.h>
 
@@ -407,7 +408,7 @@
 
 	vma->vm_flags |= VM_IO;
     
-	if (io_remap_page_range(vma, vma->vm_start, off,
+	if (io_remap_pfn_range(vma, vma->vm_start, off >> PAGE_SHIFT,
 				vma->vm_end - vma->vm_start,
 				vma->vm_page_prot)) {
 		return -EAGAIN;
#1 lore raw

I do believe that this fix is already upstream. Are you playing with the latest kernel?

Signature · 4 lines
Jordan Crouse
Senior Linux Engineer
AMD - Personal Connectivity Solutions Group
<www.amd.com/embeddedprocessors>
#2 lore raw

Hi Jordan,

Quoted 2 lines · Jordan Crouse

I do believe that this fix is already upstream. Are you playing with the latest kernel?

I played with the latest git repository which I did got from:

	$ git clone rsync://ftp.linux-mips.org/pub/scm/linux.git linux.git

and which I today updated using:

	$ git pull git://ftp.linux-mips.org/pub/scm/linux.git

And just to make sure it's not upstream I checked out:

	$ cg-clone git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git

and just to be 100% sure linux-2.6.15.4.tar.bz2 with patch-2.6.16-rc3.bz2 too.

I now think I covered it all, or am I still missing something? Anyway, I did not find the problem fixed in any of these repositories or tarballs so hence I shall send the patch to Antonino Daplas later tonight or tomorrow.

Signature · 4 lines
$ cat ~/.signature
Freddy Spierenburg <[email protected]> http://snarl.nl/~freddy/
GnuPG: 0x7941D1E1=C948 5851 26D2 FA5C 39F1  E588 6F17 FD5D 7941 D1E1
$ # Please read http://www.ietf.org/rfc/rfc2015.txt before complain!
#3 lore raw
Quoted 4 lines · Freddy Spierenburg

I now think I covered it all, or am I still missing something? Anyway, I did not find the problem fixed in any of these repositories or tarballs so hence I shall send the patch to Antonino Daplas later tonight or tomorrow.

Well, won't hurt, but don't be surprised if he says its fixed. I'm looking at the lmo tree right now, and its very definately fixed at au1200fb.c:1280. Either way, thanks for the patch.

Jordan

Signature · 4 lines
Jordan Crouse
Senior Linux Engineer
AMD - Personal Connectivity Solutions Group
<www.amd.com/embeddedprocessors>
#4 lore raw

Hi Jordan,

Quoted 2 lines · Jordan Crouse

I'm looking at the lmo tree right now, and its very definately fixed at au1200fb.c:1280.

You are right when you say that au1200fb.c is fixed.That one was fixed in all my source too. But I'm talking about au1100fb.c, which was probably forgotten. Maybe I should have stated that in my email, that it's about au1100fb.c. Sorry for the confusion!

Signature · 4 lines
$ cat ~/.signature
Freddy Spierenburg <[email protected]> http://snarl.nl/~freddy/
GnuPG: 0x7941D1E1=C948 5851 26D2 FA5C 39F1  E588 6F17 FD5D 7941 D1E1
$ # Please read http://www.ietf.org/rfc/rfc2015.txt before complain!