lkml.org 
[lkml]   [1996]   [Dec]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject/dev/kmem PATCH for kernel 2.1.15

HELLO:!

The following patch will make the /dev/kmem and /dev/mem work again!
If unsure:

Just try out the ksyms app from the modules-2.1.13 suite before and
after. Or look at the last line of the same procedure to which the
patch applies. There is exactly the complementary __va(p).

It applies to the whole series of 2.1.x kernels.


Please include it into the next official patch-release.

Many thank's in advance:

Marcin

PS.:
kurwa ma"c, took it long to find this one liner!


diff -ur linux-old/drivers/char/mem.c linux/drivers/char/mem.c
--- linux-old/drivers/char/mem.c Mon Oct 28 13:29:20 1996
+++ linux/drivers/char/mem.c Thu Dec 12 22:57:57 1996
@@ -49,7 +52,7 @@
static long read_mem(struct inode * inode, struct file * file,
char * buf, unsigned long count)
{
- unsigned long p = file->f_pos;
+ unsigned long p = __pa(file->f_pos);
unsigned long end_mem;
int read;

\
 
 \ /
  Last update: 2005-03-22 13:38    [W:0.917 / U:1.104 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site