Make it compile with kernel 2.6.11

Tue Apr  5 14:34:43 2005  Søren Sandmann  <sandmann@redhat.com>

	* sysprof-module.c (x_access_process_vm): Make it compile with
	kernel 2.6.11

	* TODO: updates
This commit is contained in:
Søren Sandmann
2005-04-05 18:37:13 +00:00
committed by Søren Sandmann Pedersen
parent 4a4a5fc5ca
commit 700cf9c967
3 changed files with 20 additions and 3 deletions

View File

@ -17,6 +17,7 @@
#include "sysprof-module.h"
#include <linux/version.h>
MODULE_LICENSE("GPL");
MODULE_AUTHOR("Soeren Sandmann (sandmann@daimi.au.dk)");
@ -115,8 +116,12 @@ static int x_access_process_vm(struct task_struct *tsk, unsigned long addr, void
if (bytes > PAGE_SIZE-offset)
bytes = PAGE_SIZE-offset;
#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,11)
flush_cache_page(vma, addr);
#endif
maddr = kmap(page);
if (write) {
copy_to_user_page(vma, page, addr,