search for: read_ldt

Displaying 12 results from an estimated 12 matches for "read_ldt".

Did you mean: load_ldt
2007 Apr 18
2
[PATCH 3/6] i386 virtualization - Make ldt a desc struct
...ontext.size*LDT_ENTRY_SIZE > PAGE_SIZE) > + ClearPagesLDT(mm->context.ldt, pages); > + if (pages > 1) > vfree(mm->context.ldt); > else > kfree(mm->context.ldt); > - mm->context.size = 0; > + mm->context.ldt_pages = 0; > } > > static int read_ldt(void __user * ptr, unsigned long bytecount) > @@ -113,13 +114,13 @@ > unsigned long size; > struct mm_struct * mm = current->mm; > > - if (!mm->context.size) > + if (!mm->context.ldt_pages) > return 0; > if (bytecount > LDT_ENTRY_SIZE*LDT_ENTRIES) >...
2007 Apr 18
2
[PATCH 3/6] i386 virtualization - Make ldt a desc struct
...ontext.size*LDT_ENTRY_SIZE > PAGE_SIZE) > + ClearPagesLDT(mm->context.ldt, pages); > + if (pages > 1) > vfree(mm->context.ldt); > else > kfree(mm->context.ldt); > - mm->context.size = 0; > + mm->context.ldt_pages = 0; > } > > static int read_ldt(void __user * ptr, unsigned long bytecount) > @@ -113,13 +114,13 @@ > unsigned long size; > struct mm_struct * mm = current->mm; > > - if (!mm->context.size) > + if (!mm->context.ldt_pages) > return 0; > if (bytecount > LDT_ENTRY_SIZE*LDT_ENTRIES) >...
2007 Apr 18
0
[PATCH 12/12] xen-ldt
...itable(mm->context.ldt, + (mm->context.size * LDT_ENTRY_SIZE) / + PAGE_SIZE); if (mm->context.size*LDT_ENTRY_SIZE > PAGE_SIZE) vfree(mm->context.ldt); else kfree(mm->context.ldt); mm->context.size = 0; } + del_context_from_unpinned(mm); } static int read_ldt(void __user * ptr, unsigned long bytecount) Index: linux-2.6.13/include/asm-i386/mach-default/hypervisor_hooks.h =================================================================== --- linux-2.6.13.orig/include/asm-i386/mach-default/hypervisor_hooks.h 2005-08-08 21:12:55.000000000 -0700 +++ linux-2...
2007 Apr 18
0
[PATCH 12/12] xen-ldt
...itable(mm->context.ldt, + (mm->context.size * LDT_ENTRY_SIZE) / + PAGE_SIZE); if (mm->context.size*LDT_ENTRY_SIZE > PAGE_SIZE) vfree(mm->context.ldt); else kfree(mm->context.ldt); mm->context.size = 0; } + del_context_from_unpinned(mm); } static int read_ldt(void __user * ptr, unsigned long bytecount) Index: linux-2.6.13/include/asm-i386/mach-default/hypervisor_hooks.h =================================================================== --- linux-2.6.13.orig/include/asm-i386/mach-default/hypervisor_hooks.h 2005-08-08 21:12:55.000000000 -0700 +++ linux-2...
2007 Apr 18
2
[PATCH 21/21] i386 Ldt context inline
....ldt)) { - retval = copy_ldt(&mm->context, &old_mm->context); - } - return retval; -} - -/* - * No need to lock the MM as we are the last user - */ -void destroy_context(struct mm_struct *mm) -{ - if (unlikely(mm->context.ldt)) - destroy_ldt(&mm->context); -} - static int read_ldt(void __user * ptr, unsigned long bytecount) { int err;
2007 Apr 18
2
[PATCH 21/21] i386 Ldt context inline
....ldt)) { - retval = copy_ldt(&mm->context, &old_mm->context); - } - return retval; -} - -/* - * No need to lock the MM as we are the last user - */ -void destroy_context(struct mm_struct *mm) -{ - if (unlikely(mm->context.ldt)) - destroy_ldt(&mm->context); -} - static int read_ldt(void __user * ptr, unsigned long bytecount) { int err;
2007 Apr 18
2
[PATCH 12/12; UPDATED] xen-ldt
...itable(mm->context.ldt, + (mm->context.size * LDT_ENTRY_SIZE) / + PAGE_SIZE); if (mm->context.size*LDT_ENTRY_SIZE > PAGE_SIZE) vfree(mm->context.ldt); else kfree(mm->context.ldt); mm->context.size = 0; } + del_context_from_unpinned(mm); } static int read_ldt(void __user * ptr, unsigned long bytecount) Index: linux-2.6.13/include/asm-i386/mach-default/hypervisor_hooks.h =================================================================== --- linux-2.6.13.orig/include/asm-i386/mach-default/hypervisor_hooks.h 2005-08-08 21:16:15.000000000 -0700 +++ linux-2...
2007 Apr 18
2
[PATCH 12/12; UPDATED] xen-ldt
...itable(mm->context.ldt, + (mm->context.size * LDT_ENTRY_SIZE) / + PAGE_SIZE); if (mm->context.size*LDT_ENTRY_SIZE > PAGE_SIZE) vfree(mm->context.ldt); else kfree(mm->context.ldt); mm->context.size = 0; } + del_context_from_unpinned(mm); } static int read_ldt(void __user * ptr, unsigned long bytecount) Index: linux-2.6.13/include/asm-i386/mach-default/hypervisor_hooks.h =================================================================== --- linux-2.6.13.orig/include/asm-i386/mach-default/hypervisor_hooks.h 2005-08-08 21:16:15.000000000 -0700 +++ linux-2...
2007 Apr 18
0
[PATCH 12/14] i386 / Move context switch inline
...destroy_context(struct mm_struct *mm) -{ - if (mm->context.size) { - if (mm == current->active_mm) - clear_LDT(); - if (mm->context.size*LDT_ENTRY_SIZE > PAGE_SIZE) - vfree(mm->context.ldt); - else - kfree(mm->context.ldt); - mm->context.size = 0; - } } static int read_ldt(void __user * ptr, unsigned long bytecount) @@ -200,7 +179,8 @@ down(&mm->context.sem); if (ldt_info.entry_number >= mm->context.size) { - error = alloc_ldt(&current->mm->context, ldt_info.entry_number+1, 1); + error = alloc_ldt(&current->mm->context, mm-&gt...
2007 Apr 18
0
[PATCH 12/14] i386 / Move context switch inline
...destroy_context(struct mm_struct *mm) -{ - if (mm->context.size) { - if (mm == current->active_mm) - clear_LDT(); - if (mm->context.size*LDT_ENTRY_SIZE > PAGE_SIZE) - vfree(mm->context.ldt); - else - kfree(mm->context.ldt); - mm->context.size = 0; - } } static int read_ldt(void __user * ptr, unsigned long bytecount) @@ -200,7 +179,8 @@ down(&mm->context.sem); if (ldt_info.entry_number >= mm->context.size) { - error = alloc_ldt(&current->mm->context, ldt_info.entry_number+1, 1); + error = alloc_ldt(&current->mm->context, mm-&gt...
2007 Apr 18
0
[PATCH 20/21] i386 Ldt cleanups 3
...if (mm == current->active_mm) - clear_LDT(); - if (mm->context.size*LDT_ENTRY_SIZE > PAGE_SIZE) - vfree(mm->context.ldt); - else - kfree(mm->context.ldt); - mm->context.size = 0; - } + if (unlikely(mm->context.ldt)) + destroy_ldt(&mm->context); } static int read_ldt(void __user * ptr, unsigned long bytecount) { int err; unsigned long size; - struct mm_struct * mm = current->mm; + mm_context_t *pc = &current->mm->context; - if (!mm->context.size) + if (!pc->ldt_pages) return 0; if (bytecount > LDT_ENTRY_SIZE*LDT_ENTRIES) byt...
2007 Apr 18
0
[PATCH 20/21] i386 Ldt cleanups 3
...if (mm == current->active_mm) - clear_LDT(); - if (mm->context.size*LDT_ENTRY_SIZE > PAGE_SIZE) - vfree(mm->context.ldt); - else - kfree(mm->context.ldt); - mm->context.size = 0; - } + if (unlikely(mm->context.ldt)) + destroy_ldt(&mm->context); } static int read_ldt(void __user * ptr, unsigned long bytecount) { int err; unsigned long size; - struct mm_struct * mm = current->mm; + mm_context_t *pc = &current->mm->context; - if (!mm->context.size) + if (!pc->ldt_pages) return 0; if (bytecount > LDT_ENTRY_SIZE*LDT_ENTRIES) byt...