* Re: [KJ] [Patch] kzalloc conversion in fs/proc
2006-02-21 23:01 [KJ] [Patch] kzalloc conversion in fs/proc Eric Sesterhenn
@ 2006-02-21 23:13 ` Jesper Juhl
2006-02-22 0:01 ` Eric Sesterhenn
` (9 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: Jesper Juhl @ 2006-02-21 23:13 UTC (permalink / raw)
To: kernel-janitors
On 2/22/06, Eric Sesterhenn <snakebyte@gmx.de> wrote:
> hi,
>
> this converts fs/proc to kzalloc() usage.
>
> Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de>
>
[snip]
>
> static struct vmcore* __init get_new_element(void)
> {
> - struct vmcore *p;
> -
> - p = kmalloc(sizeof(*p), GFP_KERNEL);
> - if (p)
> - memset(p, 0, sizeof(*p));
> - return p;
> + return = kzalloc(sizeof(struct vmcore), GFP_KERNEL);
This looks broken - did you even compile test that patch?
Don't you mean :
return kzalloc(sizeof(struct vmcore), GFP_KERNEL);
???
--
Jesper Juhl <jesper.juhl@gmail.com>
Don't top-post http://www.catb.org/~esr/jargon/html/T/top-post.html
Plain text mails only, please http://www.expita.com/nomime.html
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors
^ permalink raw reply [flat|nested] 12+ messages in thread* Re: [KJ] [Patch] kzalloc conversion in fs/proc
2006-02-21 23:01 [KJ] [Patch] kzalloc conversion in fs/proc Eric Sesterhenn
2006-02-21 23:13 ` Jesper Juhl
@ 2006-02-22 0:01 ` Eric Sesterhenn
2006-02-22 0:14 ` Jesper Juhl
` (8 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: Eric Sesterhenn @ 2006-02-22 0:01 UTC (permalink / raw)
To: kernel-janitors
[-- Attachment #1: Type: text/plain, Size: 1820 bytes --]
On Wed, 2006-02-22 at 00:13 +0100, Jesper Juhl wrote:
> This looks broken - did you even compile test that patch?
>
> Don't you mean :
>
> return kzalloc(sizeof(struct vmcore), GFP_KERNEL);
*yuck*, sorry for this, didnt compile test since it doesnt build
with my config. fixed patch below.
Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de>
--- linux-2.6.16-rc4/fs/proc/kcore.c.orig 2006-02-21 23:58:12.000000000 +0100
+++ linux-2.6.16-rc4/fs/proc/kcore.c 2006-02-21 23:58:48.000000000 +0100
@@ -282,12 +282,11 @@ read_kcore(struct file *file, char __use
tsz = elf_buflen - *fpos;
if (buflen < tsz)
tsz = buflen;
- elf_buf = kmalloc(elf_buflen, GFP_ATOMIC);
+ elf_buf = kzalloc(elf_buflen, GFP_ATOMIC);
if (!elf_buf) {
read_unlock(&kclist_lock);
return -ENOMEM;
}
- memset(elf_buf, 0, elf_buflen);
elf_kcore_store_hdr(elf_buf, nphdr, elf_buflen);
read_unlock(&kclist_lock);
if (copy_to_user(buffer, elf_buf + *fpos, tsz)) {
@@ -333,10 +332,9 @@ read_kcore(struct file *file, char __use
unsigned long curstart = start;
unsigned long cursize = tsz;
- elf_buf = kmalloc(tsz, GFP_KERNEL);
+ elf_buf = kzalloc(tsz, GFP_KERNEL);
if (!elf_buf)
return -ENOMEM;
- memset(elf_buf, 0, tsz);
read_lock(&vmlist_lock);
for (m=vmlist; m && cursize; m=m->next) {
--- linux-2.6.16-rc4/fs/proc/vmcore.c.orig 2006-02-21 23:54:00.000000000 +0100
+++ linux-2.6.16-rc4/fs/proc/vmcore.c 2006-02-21 23:54:59.000000000 +0100
@@ -179,12 +179,7 @@ struct file_operations proc_vmcore_opera
static struct vmcore* __init get_new_element(void)
{
- struct vmcore *p;
-
- p = kmalloc(sizeof(*p), GFP_KERNEL);
- if (p)
- memset(p, 0, sizeof(*p));
- return p;
+ return kzalloc(sizeof(struct vmcore), GFP_KERNEL);
}
static u64 __init get_vmcore_size_elf64(char *elfptr)
[-- Attachment #2: Type: text/plain, Size: 168 bytes --]
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors
^ permalink raw reply [flat|nested] 12+ messages in thread* Re: [KJ] [Patch] kzalloc conversion in fs/proc
2006-02-21 23:01 [KJ] [Patch] kzalloc conversion in fs/proc Eric Sesterhenn
2006-02-21 23:13 ` Jesper Juhl
2006-02-22 0:01 ` Eric Sesterhenn
@ 2006-02-22 0:14 ` Jesper Juhl
2006-02-22 0:14 ` Randy.Dunlap
` (7 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: Jesper Juhl @ 2006-02-22 0:14 UTC (permalink / raw)
To: kernel-janitors
On 2/22/06, Eric Sesterhenn <snakebyte@gmx.de> wrote:
> On Wed, 2006-02-22 at 00:13 +0100, Jesper Juhl wrote:
> > This looks broken - did you even compile test that patch?
> >
> > Don't you mean :
> >
> > return kzalloc(sizeof(struct vmcore), GFP_KERNEL);
>
> *yuck*, sorry for this, didnt compile test since it doesnt build
> with my config. fixed patch below.
>
Hmm, a simple
$ make allyesconfig
$ make fs/proc/kcore.o
or
$ make fs/proc/
builds it for me. No reason why you couldn't have made the same test.
In any case, noting in the email with the patch what level of testing
you've done is usually a good idea.
Just a simple line saying "compile tested" or "compile & run tested"
(meaning you've build a kernel with the patch and test booted it), or
if you've done even more testing than that, then a line or two
specifying exactely what testing you've done, is usually a good idea.
And if you've done no testing at all, then a line stating "patch is
untested" is really nice.
It helps other people looking over your changes, but it also helps
yourself - it's a nice mental "stop-post" when you write the testing
info you (at least I know I do) usually look over the patch once more
and think about if the testing you've done is sufficient.
At least consider it :)
Anyway, the fixed patch looks good to me.
--
Jesper Juhl <jesper.juhl@gmail.com>
Don't top-post http://www.catb.org/~esr/jargon/html/T/top-post.html
Plain text mails only, please http://www.expita.com/nomime.html
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors
^ permalink raw reply [flat|nested] 12+ messages in thread* Re: [KJ] [Patch] kzalloc conversion in fs/proc
2006-02-21 23:01 [KJ] [Patch] kzalloc conversion in fs/proc Eric Sesterhenn
` (2 preceding siblings ...)
2006-02-22 0:14 ` Jesper Juhl
@ 2006-02-22 0:14 ` Randy.Dunlap
2006-02-22 19:14 ` Alexey Dobriyan
` (6 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: Randy.Dunlap @ 2006-02-22 0:14 UTC (permalink / raw)
To: kernel-janitors
[-- Attachment #1: Type: TEXT/PLAIN, Size: 2181 bytes --]
On Wed, 22 Feb 2006, Eric Sesterhenn wrote:
> On Wed, 2006-02-22 at 00:13 +0100, Jesper Juhl wrote:
> > This looks broken - did you even compile test that patch?
> >
> > Don't you mean :
> >
> > return kzalloc(sizeof(struct vmcore), GFP_KERNEL);
>
> *yuck*, sorry for this, didnt compile test since it doesnt build
> with my config. fixed patch below.
Your config is really easy to change to that it will build,
isn't it?
Let's see, PROC_KCORE requires PROC_FS and MMU.
Does your kernel build with MMU enabled?
Cause PROC_FS is really easy to change...
> Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de>
>
> --- linux-2.6.16-rc4/fs/proc/kcore.c.orig 2006-02-21 23:58:12.000000000 +0100
> +++ linux-2.6.16-rc4/fs/proc/kcore.c 2006-02-21 23:58:48.000000000 +0100
> @@ -282,12 +282,11 @@ read_kcore(struct file *file, char __use
> tsz = elf_buflen - *fpos;
> if (buflen < tsz)
> tsz = buflen;
> - elf_buf = kmalloc(elf_buflen, GFP_ATOMIC);
> + elf_buf = kzalloc(elf_buflen, GFP_ATOMIC);
> if (!elf_buf) {
> read_unlock(&kclist_lock);
> return -ENOMEM;
> }
> - memset(elf_buf, 0, elf_buflen);
> elf_kcore_store_hdr(elf_buf, nphdr, elf_buflen);
> read_unlock(&kclist_lock);
> if (copy_to_user(buffer, elf_buf + *fpos, tsz)) {
> @@ -333,10 +332,9 @@ read_kcore(struct file *file, char __use
> unsigned long curstart = start;
> unsigned long cursize = tsz;
>
> - elf_buf = kmalloc(tsz, GFP_KERNEL);
> + elf_buf = kzalloc(tsz, GFP_KERNEL);
> if (!elf_buf)
> return -ENOMEM;
> - memset(elf_buf, 0, tsz);
>
> read_lock(&vmlist_lock);
> for (m=vmlist; m && cursize; m=m->next) {
> --- linux-2.6.16-rc4/fs/proc/vmcore.c.orig 2006-02-21 23:54:00.000000000 +0100
> +++ linux-2.6.16-rc4/fs/proc/vmcore.c 2006-02-21 23:54:59.000000000 +0100
> @@ -179,12 +179,7 @@ struct file_operations proc_vmcore_opera
>
> static struct vmcore* __init get_new_element(void)
> {
> - struct vmcore *p;
> -
> - p = kmalloc(sizeof(*p), GFP_KERNEL);
> - if (p)
> - memset(p, 0, sizeof(*p));
> - return p;
> + return kzalloc(sizeof(struct vmcore), GFP_KERNEL);
> }
>
> static u64 __init get_vmcore_size_elf64(char *elfptr)
>
>
>
--
~Randy
[-- Attachment #2: Type: text/plain, Size: 168 bytes --]
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors
^ permalink raw reply [flat|nested] 12+ messages in thread* Re: [KJ] [Patch] kzalloc conversion in fs/proc
2006-02-21 23:01 [KJ] [Patch] kzalloc conversion in fs/proc Eric Sesterhenn
` (3 preceding siblings ...)
2006-02-22 0:14 ` Randy.Dunlap
@ 2006-02-22 19:14 ` Alexey Dobriyan
2006-02-22 19:29 ` Eric Sesterhenn
` (5 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: Alexey Dobriyan @ 2006-02-22 19:14 UTC (permalink / raw)
To: kernel-janitors
[-- Attachment #1: Type: text/plain, Size: 1600 bytes --]
On Wed, Feb 22, 2006 at 01:14:39AM +0100, Jesper Juhl wrote:
> On 2/22/06, Eric Sesterhenn <snakebyte@gmx.de> wrote:
> > On Wed, 2006-02-22 at 00:13 +0100, Jesper Juhl wrote:
> > > This looks broken - did you even compile test that patch?
> > >
> > > Don't you mean :
> > >
> > > return kzalloc(sizeof(struct vmcore), GFP_KERNEL);
> >
> > *yuck*, sorry for this, didnt compile test since it doesnt build
> > with my config. fixed patch below.
> >
>
> Hmm, a simple
>
> $ make allyesconfig
> $ make fs/proc/kcore.o
How on earth did this succeed? I always, always get
$ make fs/proc/kcore.o
SPLIT include/linux/autoconf.h -> include/config/*
HOSTCC scripts/genksyms/genksyms.o
SHIPPED scripts/genksyms/lex.c
SHIPPED scripts/genksyms/parse.h
SHIPPED scripts/genksyms/keywords.c
HOSTCC scripts/genksyms/lex.o
SHIPPED scripts/genksyms/parse.c
HOSTCC scripts/genksyms/parse.o
HOSTLD scripts/genksyms/genksyms
CC scripts/mod/empty.o
HOSTCC scripts/mod/mk_elfconfig
MKELF scripts/mod/elfconfig.h
HOSTCC scripts/mod/file2alias.o
HOSTCC scripts/mod/modpost.o
HOSTCC scripts/mod/sumversion.o
HOSTLD scripts/mod/modpost
HOSTCC scripts/kallsyms
HOSTCC scripts/pnmtologo
HOSTCC scripts/conmakehash
HOSTCC scripts/bin2c
CC fs/proc/kcore.o
In file included from include/linux/mm.h:4,
from fs/proc/kcore.c:13:
include/linux/sched.h:4:36: asm/param.h: No such file or directory
Some secret agreement with devil you've signed?
> or
>
> $ make fs/proc/
>
> builds it for me. No reason why you couldn't have made the same test.
[-- Attachment #2: Type: text/plain, Size: 168 bytes --]
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors
^ permalink raw reply [flat|nested] 12+ messages in thread* Re: [KJ] [Patch] kzalloc conversion in fs/proc
2006-02-21 23:01 [KJ] [Patch] kzalloc conversion in fs/proc Eric Sesterhenn
` (4 preceding siblings ...)
2006-02-22 19:14 ` Alexey Dobriyan
@ 2006-02-22 19:29 ` Eric Sesterhenn
2006-02-22 19:29 ` Nishanth Aravamudan
` (4 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: Eric Sesterhenn @ 2006-02-22 19:29 UTC (permalink / raw)
To: kernel-janitors
[-- Attachment #1: Type: text/plain, Size: 300 bytes --]
> > $ make allyesconfig
> > $ make fs/proc/kcore.o
>
> How on earth did this succeed? I always, always get
works for me too... maybe there were some values
still set and not changed by allyesconfig?
if you want to compare .configs, i placed mine at
http://www.snake-basket.de/misc/config
cu Eric
[-- Attachment #2: Type: text/plain, Size: 168 bytes --]
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors
^ permalink raw reply [flat|nested] 12+ messages in thread* Re: [KJ] [Patch] kzalloc conversion in fs/proc
2006-02-21 23:01 [KJ] [Patch] kzalloc conversion in fs/proc Eric Sesterhenn
` (5 preceding siblings ...)
2006-02-22 19:29 ` Eric Sesterhenn
@ 2006-02-22 19:29 ` Nishanth Aravamudan
2006-02-22 19:51 ` Jaco Kroon
` (3 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: Nishanth Aravamudan @ 2006-02-22 19:29 UTC (permalink / raw)
To: kernel-janitors
[-- Attachment #1: Type: text/plain, Size: 923 bytes --]
On 22.02.2006 [22:14:25 +0300], Alexey Dobriyan wrote:
> On Wed, Feb 22, 2006 at 01:14:39AM +0100, Jesper Juhl wrote:
> > On 2/22/06, Eric Sesterhenn <snakebyte@gmx.de> wrote:
> > > On Wed, 2006-02-22 at 00:13 +0100, Jesper Juhl wrote:
> > > > This looks broken - did you even compile test that patch?
> > > >
> > > > Don't you mean :
> > > >
> > > > return kzalloc(sizeof(struct vmcore), GFP_KERNEL);
> > >
> > > *yuck*, sorry for this, didnt compile test since it doesnt build
> > > with my config. fixed patch below.
> > >
> >
> > Hmm, a simple
> >
> > $ make allyesconfig
> > $ make fs/proc/kcore.o
>
> How on earth did this succeed? I always, always get
I'm guessing it might have been a tree he's already built a kernel in
before? You usually need to let a normal make go through a few steps
before trying this, so that the asm->asm-$arch symlink is created and a
few other files are generated, IIRC.
Thanks,
Nish
[-- Attachment #2: Type: text/plain, Size: 168 bytes --]
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors
^ permalink raw reply [flat|nested] 12+ messages in thread* Re: [KJ] [Patch] kzalloc conversion in fs/proc
2006-02-21 23:01 [KJ] [Patch] kzalloc conversion in fs/proc Eric Sesterhenn
` (6 preceding siblings ...)
2006-02-22 19:29 ` Nishanth Aravamudan
@ 2006-02-22 19:51 ` Jaco Kroon
2006-02-22 20:24 ` Nishanth Aravamudan
` (2 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: Jaco Kroon @ 2006-02-22 19:51 UTC (permalink / raw)
To: kernel-janitors
[-- Attachment #1.1: Type: text/plain, Size: 1401 bytes --]
Nishanth Aravamudan wrote:
> On 22.02.2006 [22:14:25 +0300], Alexey Dobriyan wrote:
>
>>On Wed, Feb 22, 2006 at 01:14:39AM +0100, Jesper Juhl wrote:
>>
>>>On 2/22/06, Eric Sesterhenn <snakebyte@gmx.de> wrote:
>>>
>>>>On Wed, 2006-02-22 at 00:13 +0100, Jesper Juhl wrote:
>>>>
>>>>>This looks broken - did you even compile test that patch?
>>>>>
>>>>>Don't you mean :
>>>>>
>>>>>return kzalloc(sizeof(struct vmcore), GFP_KERNEL);
>>>>
>>>>*yuck*, sorry for this, didnt compile test since it doesnt build
>>>>with my config. fixed patch below.
>>>>
>>>
>>>Hmm, a simple
>>>
>>>$ make allyesconfig
>>>$ make fs/proc/kcore.o
>>
>>How on earth did this succeed? I always, always get
>
>
> I'm guessing it might have been a tree he's already built a kernel in
> before? You usually need to let a normal make go through a few steps
> before trying this, so that the asm->asm-$arch symlink is created and a
> few other files are generated, IIRC.
That imho constitutes a dependancy bug in the build process. After all,
it is rather obvious from the error that include/linux/sched.h depends
on asm/param.h, but obviously param.h doesn't exist yet. Presumably
this is due to the asm link not being created yet. But surely there is
a way to "force" the issue with make?
Jaco
--
There are only 10 kinds of people in this world,
those that understand binary and those that don't.
http://www.kroon.co.za/
[-- Attachment #1.2: S/MIME Cryptographic Signature --]
[-- Type: application/x-pkcs7-signature, Size: 3233 bytes --]
[-- Attachment #2: Type: text/plain, Size: 168 bytes --]
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors
^ permalink raw reply [flat|nested] 12+ messages in thread* Re: [KJ] [Patch] kzalloc conversion in fs/proc
2006-02-21 23:01 [KJ] [Patch] kzalloc conversion in fs/proc Eric Sesterhenn
` (7 preceding siblings ...)
2006-02-22 19:51 ` Jaco Kroon
@ 2006-02-22 20:24 ` Nishanth Aravamudan
2006-02-22 21:01 ` Alexey Dobriyan
2006-02-22 23:55 ` Jesper Juhl
10 siblings, 0 replies; 12+ messages in thread
From: Nishanth Aravamudan @ 2006-02-22 20:24 UTC (permalink / raw)
To: kernel-janitors
[-- Attachment #1: Type: text/plain, Size: 1698 bytes --]
On 22.02.2006 [21:51:27 +0200], Jaco Kroon wrote:
> Nishanth Aravamudan wrote:
> > On 22.02.2006 [22:14:25 +0300], Alexey Dobriyan wrote:
> >
> >>On Wed, Feb 22, 2006 at 01:14:39AM +0100, Jesper Juhl wrote:
> >>
> >>>On 2/22/06, Eric Sesterhenn <snakebyte@gmx.de> wrote:
> >>>
> >>>>On Wed, 2006-02-22 at 00:13 +0100, Jesper Juhl wrote:
> >>>>
> >>>>>This looks broken - did you even compile test that patch?
> >>>>>
> >>>>>Don't you mean :
> >>>>>
> >>>>>return kzalloc(sizeof(struct vmcore), GFP_KERNEL);
> >>>>
> >>>>*yuck*, sorry for this, didnt compile test since it doesnt build
> >>>>with my config. fixed patch below.
> >>>>
> >>>
> >>>Hmm, a simple
> >>>
> >>>$ make allyesconfig
> >>>$ make fs/proc/kcore.o
> >>
> >>How on earth did this succeed? I always, always get
> >
> >
> > I'm guessing it might have been a tree he's already built a kernel
> > in before? You usually need to let a normal make go through a few
> > steps before trying this, so that the asm->asm-$arch symlink is
> > created and a few other files are generated, IIRC.
>
> That imho constitutes a dependancy bug in the build process. After
> all, it is rather obvious from the error that include/linux/sched.h
> depends on asm/param.h, but obviously param.h doesn't exist yet.
> Presumably this is due to the asm link not being created yet. But
> surely there is a way to "force" the issue with make?
Could be... I'll wait to hear what Alexey says (an ls -l include in
the kernel source dir is sufficient). I would have that the make
fs/proc/kcore.o would have done whatever it needed, as well, but maybe
not. Like I said, the easiest way is to just let plan "make" do its
thing for a few steps.
Thanks,
Nish
[-- Attachment #2: Type: text/plain, Size: 168 bytes --]
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors
^ permalink raw reply [flat|nested] 12+ messages in thread* Re: [KJ] [Patch] kzalloc conversion in fs/proc
2006-02-21 23:01 [KJ] [Patch] kzalloc conversion in fs/proc Eric Sesterhenn
` (8 preceding siblings ...)
2006-02-22 20:24 ` Nishanth Aravamudan
@ 2006-02-22 21:01 ` Alexey Dobriyan
2006-02-22 23:55 ` Jesper Juhl
10 siblings, 0 replies; 12+ messages in thread
From: Alexey Dobriyan @ 2006-02-22 21:01 UTC (permalink / raw)
To: kernel-janitors
[-- Attachment #1: Type: text/plain, Size: 2192 bytes --]
On Wed, Feb 22, 2006 at 12:24:42PM -0800, Nishanth Aravamudan wrote:
> On 22.02.2006 [21:51:27 +0200], Jaco Kroon wrote:
> > Nishanth Aravamudan wrote:
> > > On 22.02.2006 [22:14:25 +0300], Alexey Dobriyan wrote:
> > >
> > >>On Wed, Feb 22, 2006 at 01:14:39AM +0100, Jesper Juhl wrote:
> > >>
> > >>>On 2/22/06, Eric Sesterhenn <snakebyte@gmx.de> wrote:
> > >>>
> > >>>>On Wed, 2006-02-22 at 00:13 +0100, Jesper Juhl wrote:
> > >>>>
> > >>>>>This looks broken - did you even compile test that patch?
> > >>>>>
> > >>>>>Don't you mean :
> > >>>>>
> > >>>>>return kzalloc(sizeof(struct vmcore), GFP_KERNEL);
> > >>>>
> > >>>>*yuck*, sorry for this, didnt compile test since it doesnt build
> > >>>>with my config. fixed patch below.
> > >>>>
> > >>>
> > >>>Hmm, a simple
> > >>>
> > >>>$ make allyesconfig
> > >>>$ make fs/proc/kcore.o
> > >>
> > >>How on earth did this succeed? I always, always get
> > >
> > >
> > > I'm guessing it might have been a tree he's already built a kernel
> > > in before? You usually need to let a normal make go through a few
> > > steps before trying this, so that the asm->asm-$arch symlink is
> > > created and a few other files are generated, IIRC.
> >
> > That imho constitutes a dependancy bug in the build process. After
> > all, it is rather obvious from the error that include/linux/sched.h
> > depends on asm/param.h, but obviously param.h doesn't exist yet.
> > Presumably this is due to the asm link not being created yet. But
> > surely there is a way to "force" the issue with make?
>
> Could be... I'll wait to hear what Alexey says (an ls -l include in
> the kernel source dir is sufficient). I would have that the make
> fs/proc/kcore.o would have done whatever it needed, as well, but maybe
> not. Like I said, the easiest way is to just let plan "make" do its
> thing for a few steps.
Umm. That's me assuming clean tree from the beggining. Actually I think,
if
make allyesconfig
make fs/proc/kcore.o
complains, it's a bug. And, IIRC,
make allyesconfig
make archprepare
make fs/proc/kcore.o
doesn't work on some non-x86 targets, so I've given up on archprepare
for my cross-build scripts long ago. I'll make some buzz on l-k.
[-- Attachment #2: Type: text/plain, Size: 168 bytes --]
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors
^ permalink raw reply [flat|nested] 12+ messages in thread* Re: [KJ] [Patch] kzalloc conversion in fs/proc
2006-02-21 23:01 [KJ] [Patch] kzalloc conversion in fs/proc Eric Sesterhenn
` (9 preceding siblings ...)
2006-02-22 21:01 ` Alexey Dobriyan
@ 2006-02-22 23:55 ` Jesper Juhl
10 siblings, 0 replies; 12+ messages in thread
From: Jesper Juhl @ 2006-02-22 23:55 UTC (permalink / raw)
To: kernel-janitors
On 2/22/06, Alexey Dobriyan <adobriyan@gmail.com> wrote:
> On Wed, Feb 22, 2006 at 01:14:39AM +0100, Jesper Juhl wrote:
> > On 2/22/06, Eric Sesterhenn <snakebyte@gmx.de> wrote:
> > > On Wed, 2006-02-22 at 00:13 +0100, Jesper Juhl wrote:
> > > > This looks broken - did you even compile test that patch?
> > > >
> > > > Don't you mean :
> > > >
> > > > return kzalloc(sizeof(struct vmcore), GFP_KERNEL);
> > >
> > > *yuck*, sorry for this, didnt compile test since it doesnt build
> > > with my config. fixed patch below.
> > >
> >
> > Hmm, a simple
> >
> > $ make allyesconfig
> > $ make fs/proc/kcore.o
>
> How on earth did this succeed? I always, always get
>
[snip build failure]
>
> Some secret agreement with devil you've signed?
>
I took a second look at my tree and it turns out I did a previous
$ make allyesconfig
$ make
in there. I'd completely forgotten to clean it first, I just deleted
the .o file, so what I actually did turns out to be:
$ make allyesconfig
$ make
$ rm fs/proc/kcore.o
$ make allyesconfig
$ make fs/proc/kcore.o
--
Jesper Juhl <jesper.juhl@gmail.com>
Don't top-post http://www.catb.org/~esr/jargon/html/T/top-post.html
Plain text mails only, please http://www.expita.com/nomime.html
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors
^ permalink raw reply [flat|nested] 12+ messages in thread