search for: access_process_vm

Displaying 16 results from an estimated 16 matches for "access_process_vm".

2007 Sep 10
1
[PATCH] Add macros for acessing lguest fields
...(-) diff --git a/drivers/lguest/io.c b/drivers/lguest/io.c index ea68613..70bab38 100644 --- a/drivers/lguest/io.c +++ b/drivers/lguest/io.c @@ -247,7 +247,7 @@ static int lgread_other(struct lguest *lg, void *buf, u32 addr, unsigned bytes) { if (!lguest_address_ok(lg, addr, bytes) - || access_process_vm(lg->tsk, addr, buf, bytes, 0) != bytes) { + || access_process_vm(lguest_task(lg), addr, buf, bytes, 0) != bytes) { memset(buf, 0, bytes); kill_guest(lg, "bad address in registered DMA struct"); return 0; @@ -261,7 +261,7 @@ static int lgwrite_other(struct lguest *lg, u32 a...
2007 Sep 10
1
[PATCH] Add macros for acessing lguest fields
...(-) diff --git a/drivers/lguest/io.c b/drivers/lguest/io.c index ea68613..70bab38 100644 --- a/drivers/lguest/io.c +++ b/drivers/lguest/io.c @@ -247,7 +247,7 @@ static int lgread_other(struct lguest *lg, void *buf, u32 addr, unsigned bytes) { if (!lguest_address_ok(lg, addr, bytes) - || access_process_vm(lg->tsk, addr, buf, bytes, 0) != bytes) { + || access_process_vm(lguest_task(lg), addr, buf, bytes, 0) != bytes) { memset(buf, 0, bytes); kill_guest(lg, "bad address in registered DMA struct"); return 0; @@ -261,7 +261,7 @@ static int lgwrite_other(struct lguest *lg, u32 a...
2007 May 09
0
[patch 1/9] lguest: export symbols for lguest as a module
...ules don't need: math_state_restore: When the guest triggers a Device Not Available fault, we need to be able to restore the FPU __put_task_struct: We need to hold a reference to another task for inter-guest I/O, and put_task_struct() is an inline function which calls __put_task_struct. access_process_vm: We need to access another task for inter-guest I/O. map_vm_area & __get_vm_area: We need to map the switcher shim (ie. monitor) at 0xFFC01000. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> --- arch/i386/kernel/tr...
2007 May 09
0
[patch 1/9] lguest: export symbols for lguest as a module
...ules don't need: math_state_restore: When the guest triggers a Device Not Available fault, we need to be able to restore the FPU __put_task_struct: We need to hold a reference to another task for inter-guest I/O, and put_task_struct() is an inline function which calls __put_task_struct. access_process_vm: We need to access another task for inter-guest I/O. map_vm_area & __get_vm_area: We need to map the switcher shim (ie. monitor) at 0xFFC01000. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> --- arch/i386/kernel/tr...
2007 Apr 18
0
[RFC/PATCH LGUEST X86_64 02/13] hvvm export page utils
...rostedt@redhat.com> Cc: Glauber de Oliveira Costa <glommer@gmail.com> Cc: Chris Wright <chrisw@sous-sol.org> Index: work-pv/mm/memory.c =================================================================== --- work-pv.orig/mm/memory.c +++ work-pv/mm/memory.c @@ -2798,3 +2798,10 @@ int access_process_vm(struct task_struct return buf - old_buf; } EXPORT_SYMBOL_GPL(access_process_vm); + +/* temp until we put the hv vm stuff into the kernel */ +EXPORT_SYMBOL_GPL(__pud_alloc); +EXPORT_SYMBOL_GPL(__pmd_alloc); +EXPORT_SYMBOL_GPL(__pte_alloc_kernel); +EXPORT_SYMBOL_GPL(pmd_clear_bad); +EXPORT_SYMBOL...
2007 Apr 18
0
[RFC/PATCH LGUEST X86_64 02/13] hvvm export page utils
...rostedt@redhat.com> Cc: Glauber de Oliveira Costa <glommer@gmail.com> Cc: Chris Wright <chrisw@sous-sol.org> Index: work-pv/mm/memory.c =================================================================== --- work-pv.orig/mm/memory.c +++ work-pv/mm/memory.c @@ -2798,3 +2798,10 @@ int access_process_vm(struct task_struct return buf - old_buf; } EXPORT_SYMBOL_GPL(access_process_vm); + +/* temp until we put the hv vm stuff into the kernel */ +EXPORT_SYMBOL_GPL(__pud_alloc); +EXPORT_SYMBOL_GPL(__pmd_alloc); +EXPORT_SYMBOL_GPL(__pte_alloc_kernel); +EXPORT_SYMBOL_GPL(pmd_clear_bad); +EXPORT_SYMBOL...
2007 Apr 26
1
[PATCH] Fix lguest oops when guest dies while receiving I/O
lguest needs to hold a reference to its task in case it exits while another Guest is sending it I/O. Otherwise we can oops in access_process_vm->get_task_mm->task_lock(). Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> --- drivers/lguest/lguest_user.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) =================================================================== --- a/drivers/lguest/lguest_user.c +++ b/dr...
2008 Mar 20
1
[RFC/PATCH 01/15] preparation: provide hook to enable pgstes in user pagetable
From: Martin Schwidefsky <schwidefsky at de.ibm.com> The SIE instruction on s390 uses the 2nd half of the page table page to virtualize the storage keys of a guest. This patch offers the s390_enable_sie function, which reorganizes the page tables of a single-threaded process to reserve space in the page table: s390_enable_sie makes sure that the process is single threaded and then uses
2007 Apr 18
0
[RFC/PATCH LGUEST X86_64 09/13] lguest64 devices
...urrent->mm->mmap_sem); + mutex_unlock(&lguest_lock); + return ret; +} +/* lhread from another guest */ +static int lhread_other(struct lguest_guest_info *linfo, + void *buf, u32 addr, unsigned bytes) +{ + if (addr + bytes < addr + || !lguest_address_ok(linfo, addr+bytes) + || access_process_vm(linfo->tsk, addr, buf, bytes, 0) != bytes) { + memset(buf, 0, bytes); + kill_guest(linfo, "bad address in registered DMA struct"); + return 0; + } + return 1; +} + +/* lhwrite to another guest */ +static int lhwrite_other(struct lguest_guest_info *linfo, u32 addr, + const void *b...
2007 Apr 18
0
[RFC/PATCH LGUEST X86_64 09/13] lguest64 devices
...urrent->mm->mmap_sem); + mutex_unlock(&lguest_lock); + return ret; +} +/* lhread from another guest */ +static int lhread_other(struct lguest_guest_info *linfo, + void *buf, u32 addr, unsigned bytes) +{ + if (addr + bytes < addr + || !lguest_address_ok(linfo, addr+bytes) + || access_process_vm(linfo->tsk, addr, buf, bytes, 0) != bytes) { + memset(buf, 0, bytes); + kill_guest(linfo, "bad address in registered DMA struct"); + return 0; + } + return 1; +} + +/* lhwrite to another guest */ +static int lhwrite_other(struct lguest_guest_info *linfo, u32 addr, + const void *b...
2007 Apr 18
2
[PATCH 19/21] i386 Kprobes semaphore fix
...atic inline int is_at_popf(struct task_struct *child, struct pt_regs *regs) { int i, copied; unsigned char opcode[16]; - unsigned long addr = convert_eip_to_linear(child, regs); - + unsigned long addr = convert_eip_to_linear(regs, regs->eip, &child->mm->context, NULL); copied = access_process_vm(child, addr, opcode, sizeof(opcode), 0); for (i = 0; i < copied; i++) { switch (opcode[i]) { Index: linux-2.6.14-zach-work/arch/i386/mm/fault.c =================================================================== --- linux-2.6.14-zach-work.orig/arch/i386/mm/fault.c 2005-11-04 19:25:27.000000...
2007 Apr 18
2
[PATCH 19/21] i386 Kprobes semaphore fix
...atic inline int is_at_popf(struct task_struct *child, struct pt_regs *regs) { int i, copied; unsigned char opcode[16]; - unsigned long addr = convert_eip_to_linear(child, regs); - + unsigned long addr = convert_eip_to_linear(regs, regs->eip, &child->mm->context, NULL); copied = access_process_vm(child, addr, opcode, sizeof(opcode), 0); for (i = 0; i < copied; i++) { switch (opcode[i]) { Index: linux-2.6.14-zach-work/arch/i386/mm/fault.c =================================================================== --- linux-2.6.14-zach-work.orig/arch/i386/mm/fault.c 2005-11-04 19:25:27.000000...
2007 May 09
1
[patch 3/9] lguest: the host code
...k; + } + } + drop_futex_key_refs(&key); +unlock: + up_read(fshared); + mutex_unlock(&lguest_lock); + return ret; +} + +/* lgread from another guest */ +static int lgread_other(struct lguest *lg, + void *buf, u32 addr, unsigned bytes) +{ + if (!lguest_address_ok(lg, addr, bytes) + || access_process_vm(lg->tsk, addr, buf, bytes, 0) != bytes) { + memset(buf, 0, bytes); + kill_guest(lg, "bad address in registered DMA struct"); + return 0; + } + return 1; +} + +/* lgwrite to another guest */ +static int lgwrite_other(struct lguest *lg, u32 addr, + const void *buf, unsigned bytes)...
2007 May 09
1
[patch 3/9] lguest: the host code
...k; + } + } + drop_futex_key_refs(&key); +unlock: + up_read(fshared); + mutex_unlock(&lguest_lock); + return ret; +} + +/* lgread from another guest */ +static int lgread_other(struct lguest *lg, + void *buf, u32 addr, unsigned bytes) +{ + if (!lguest_address_ok(lg, addr, bytes) + || access_process_vm(lg->tsk, addr, buf, bytes, 0) != bytes) { + memset(buf, 0, bytes); + kill_guest(lg, "bad address in registered DMA struct"); + return 0; + } + return 1; +} + +/* lgwrite to another guest */ +static int lgwrite_other(struct lguest *lg, u32 addr, + const void *buf, unsigned bytes)...
2007 Sep 25
50
[patch 00/43] lguest: Patches for 2.6.24 (and patchbomb test)
Hi all, These are the patches I'm planning to submit for 2.6.24. Comments gratefully accepted. Along with the usual cleanups and improvements are Jes' de-i386-ification patches, and a new "virtio" mechanism designed to be shared with KVM (and hopefully other hypervisors). Cheers, Rusty. Documentation/lguest/Makefile | 30 Documentation/lguest/lguest.c
2007 Sep 25
50
[patch 00/43] lguest: Patches for 2.6.24 (and patchbomb test)
Hi all, These are the patches I'm planning to submit for 2.6.24. Comments gratefully accepted. Along with the usual cleanups and improvements are Jes' de-i386-ification patches, and a new "virtio" mechanism designed to be shared with KVM (and hopefully other hypervisors). Cheers, Rusty. Documentation/lguest/Makefile | 30 Documentation/lguest/lguest.c