X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=fs%2Fbinfmt_flat.c;h=42c958ea51c7c349022343cefc46cda90e80f250;hb=8e8ece46a861c84343256819eaec77e608ff9217;hp=c8113cc235f79c15061ba7a1b667e41e8b7ff713;hpb=a8e794ca871505c8ea96cc102f4ad555c5231d7f;p=linux-2.6.git diff --git a/fs/binfmt_flat.c b/fs/binfmt_flat.c index c8113cc23..42c958ea5 100644 --- a/fs/binfmt_flat.c +++ b/fs/binfmt_flat.c @@ -36,11 +36,11 @@ #include #include #include +#include #include #include #include -#include #include #include @@ -487,7 +487,7 @@ static int load_flat_file(struct linux_binprm * bprm, * size limits imposed on them by creating programs with large * arrays in the data or bss. */ - rlim = current->rlim[RLIMIT_DATA].rlim_cur; + rlim = current->signal->rlim[RLIMIT_DATA].rlim_cur; if (rlim >= RLIM_INFINITY) rlim = ~0; if (data_len + bss_len > rlim) @@ -651,7 +651,6 @@ static int load_flat_file(struct linux_binprm * bprm, current->mm->start_brk = datapos + data_len + bss_len; current->mm->brk = (current->mm->start_brk + 3) & ~3; current->mm->context.end_brk = memp + ksize((void *) memp) - stack_len; - // current->mm->rss = 0; vx_rsspages_sub(current->mm, current->mm->rss); } @@ -724,7 +723,7 @@ static int load_flat_file(struct linux_binprm * bprm, return -ENOEXEC; /* Get the pointer's value. */ - addr = flat_get_addr_from_rp(rp, relval); + addr = flat_get_addr_from_rp(rp, relval, flags); if (addr != 0) { /* * Do the relocation. PIC relocs in the data section are @@ -897,7 +896,7 @@ static void __exit exit_flat_binfmt(void) /****************************************************************************/ -module_init(init_flat_binfmt); +core_initcall(init_flat_binfmt); module_exit(exit_flat_binfmt); /****************************************************************************/