2003-03-09 03:47:25

by Roman Zippel

[permalink] [raw]
Subject: [PATCH] kconfig update

Hi,

It took a bit longer than I wanted, but here is finally another kconfig
update. There are two important changes: I included Romain's gtk front
end and the support for the menuconfig keyword. Unfortunately the first is
lacking a bit support for the latter. Romain, you have to check that menu
entries of type P_MENU can now also have a config symbol. I looked a bit
at it myself but my gtk knowledge is insufficient. :)
Other changes are small parser fixes and the config list in qconf has a
parent entry, so it should be more obvious, how to get to a parent menu.
I don't expect bigger problems, so I want to send this patch soon to
Linus.
The patch is at http://www.xs4all.nl/~zippel/lc/patches/kconfig-2.5.64.diff

bye, Roman


2003-03-09 08:48:40

by Christoph Hellwig

[permalink] [raw]
Subject: Re: [PATCH] kconfig update

On Sun, Mar 09, 2003 at 04:57:54AM +0100, Roman Zippel wrote:
> Hi,
>
> It took a bit longer than I wanted, but here is finally another kconfig
> update. There are two important changes: I included Romain's gtk front
> end and the support for the menuconfig keyword.

Any chance you could take a look at the patch that links lxdialog directly
to menuconfig instead of requiring the separate binary? It has been
around for a long time and seems like a very worthwhile change, imho.

2003-03-09 12:03:44

by Petr Baudis

[permalink] [raw]
Subject: Re: [PATCH] kconfig update

Dear diary, on Sun, Mar 09, 2003 at 09:59:15AM CET, I got a letter,
where Christoph Hellwig <[email protected]> told me, that...
> On Sun, Mar 09, 2003 at 04:57:54AM +0100, Roman Zippel wrote:
> > Hi,
> >
> > It took a bit longer than I wanted, but here is finally another kconfig
> > update. There are two important changes: I included Romain's gtk front
> > end and the support for the menuconfig keyword.
>
> Any chance you could take a look at the patch that links lxdialog directly
> to menuconfig instead of requiring the separate binary? It has been
> around for a long time and seems like a very worthwhile change, imho.

It is me responsible for the delays and not being integrated yet, unfortunately
I didn't have time for proper debugging one problem in it yet :-( (broken
window resizing handler; Roman proposed some solution which I didn't manage to
try yet). I hope I will finally give it a final kick really soon.

Kind regards,

--

Petr "Pasky" Baudis
.
When in doubt, use brute force.
-- Ken Thompson
.
Crap: http://pasky.ji.cz/

2003-03-09 12:35:45

by Roman Zippel

[permalink] [raw]
Subject: Re: [PATCH] kconfig update

Hi,

On Sun, 9 Mar 2003, Roman Zippel wrote:

> It took a bit longer than I wanted, but here is finally another kconfig
> update. There are two important changes: I included Romain's gtk front
> end and the support for the menuconfig keyword.

BTW here is a simple menuconfig example, if someone wants to know, how it
looks like:

--- linux-2.5/arch/i386/Kconfig 2003-03-08 22:35:23.000000000 +0100
+++ linux-2.5-lc/arch/i386/Kconfig 2003-03-09 13:35:04.000000000 +0100
@@ -1305,9 +1305,7 @@
endmenu


-menu "SCSI device support"
-
-config SCSI
+menuconfig SCSI
tristate "SCSI device support"
---help---
If you want to use a SCSI hard disk, SCSI tape drive, SCSI CD-ROM or
@@ -1329,8 +1327,6 @@

source "drivers/scsi/Kconfig"

-endmenu
-

menu "Old CD-ROM drivers (not SCSI, not IDE)"
depends on ISA

> The patch is at http://www.xs4all.nl/~zippel/lc/patches/kconfig-2.5.64.diff

bye, Roman

2003-03-09 18:50:28

by Sam Ravnborg

[permalink] [raw]
Subject: Re: [PATCH] kconfig update

On Sun, Mar 09, 2003 at 04:57:54AM +0100, Roman Zippel wrote:
> Hi,
>
> It took a bit longer than I wanted, but here is finally another kconfig
> update.

Hi Roman.
Is it on your TODO list to make is more quiet?
Today kconfig dumps out a lot of info when run, making sure no-one even
notices the warnings that occur in the beginning.
When executing
$ make defconfig
$ make V=0
kconfig count for almost half of the output.

It would be really good if the following targets were quiet:
oldconfig, defconfig, all*config.
oldconfig obviously needs to display some info when asking users
for new options.

Also try executing conf with no arguments...

Sam

2003-03-09 19:19:32

by Roman Zippel

[permalink] [raw]
Subject: Re: [PATCH] kconfig update

Hi,

On Sun, 9 Mar 2003, Sam Ravnborg wrote:

> Hi Roman.
> Is it on your TODO list to make is more quiet?
> Today kconfig dumps out a lot of info when run, making sure no-one even
> notices the warnings that occur in the beginning.
> When executing
> $ make defconfig
> $ make V=0
> kconfig count for almost half of the output.

What do you mean? 2.5.64 has no V option.

bye, Roman

2003-03-09 19:24:03

by Sam Ravnborg

[permalink] [raw]
Subject: Re: [PATCH] kconfig update

On Sun, Mar 09, 2003 at 08:30:02PM +0100, Roman Zippel wrote:
> What do you mean? 2.5.64 has no V option.

It is only present in linus-BK-latest - sorry.
"make V=0" is a shorthand for "make KBUILD_VERBOSE=0".
In other words a way to disable the 'noise' generated
when building the kernel.

Sam

2003-03-09 20:08:03

by Roman Zippel

[permalink] [raw]
Subject: Re: [PATCH] kconfig update

Hi,

On Sun, 9 Mar 2003, Sam Ravnborg wrote:

> It is only present in linus-BK-latest - sorry.
> "make V=0" is a shorthand for "make KBUILD_VERBOSE=0".
> In other words a way to disable the 'noise' generated
> when building the kernel.

I still don't see what you mean. :)
Which noise exactly do you want to disable? With "make KBUILD_VERBOSE=0" I
only see normal build messages.

bye, Roman

2003-03-09 21:04:42

by Sam Ravnborg

[permalink] [raw]
Subject: Re: [PATCH] kconfig update

On Sun, Mar 09, 2003 at 09:18:30PM +0100, Roman Zippel wrote:
> I still don't see what you mean. :)

Sample output:
$ make mrproper
$ make KBUILD_VERBOSE=0 defconfig
HOSTCC scripts/fixdep
HOSTCC scripts/split-include
.....
HOSTLD scripts/kconfig/conf
SAM> Until here, just normal build output
./scripts/kconfig/conf -d arch/i386/Kconfig
SAM> OK, we run conf
./arch/i386/defconfig:544: trying to assign nonexistent symbol NET_PCMCIA_RADIO
SAM> One warning, but not fatal so we proceed
*
* Linux Kernel Configuration
*
Support for paging of anonymous memory (SWAP) [Y/n/?] y

SAM> Snipped ~890 lines

Cryptographic API (CRYPTO) [N/y/?] n
*
* Library routines
*
CRC32 functions (CRC32) [N/m/y/?] n
$ _

So executing "make KBUILD_VERBOSE=0 defconfig"
results in ~930 lines of output, including one warning message.

What I request is that conf outputs essential stuff only, for example
warnings.
That would remove 900 lines of output when building a kernel,
and maybe people actually paid attention to the warnings generated
by kconfig.

In general I prefer minimum output when building the kernel, without
loosing the ability to follow progress.
One reason why we have some of the warnings left all around in the kernel is
due to the fact people does not see them when building their drivers etc.
With default options to make, warnings simply does not show up as visible,
and when the build proceeds the relevant parts scroll out.

See my point now?

Also speaking about warnings. How about sticking in a "warning:",
to make the format gcc compatible.
Something like attacted patch.

Sam

===== scripts/kconfig/confdata.c 1.4 vs edited =====
--- 1.4/scripts/kconfig/confdata.c Sun Dec 8 05:14:02 2002
+++ edited/scripts/kconfig/confdata.c Sun Mar 9 22:11:37 2003
@@ -148,7 +148,7 @@
*p2 = 0;
sym = sym_find(line + 7);
if (!sym) {
- fprintf(stderr, "%s:%d: trying to assign nonexistent symbol %s\n", name, lineno, line + 7);
+ fprintf(stderr, "%s:%d: warning: trying to assign nonexistent symbol %s\n", name, lineno, line + 7);
break;
}
switch (sym->type) {
@@ -181,7 +181,7 @@
memmove(p2, p2 + 1, strlen(p2));
}
if (!p2) {
- fprintf(stderr, "%s:%d: invalid string found\n", name, lineno);
+ fprintf(stderr, "%s:%d: error: invalid string found\n", name, lineno);
exit(1);
}
case S_INT:
@@ -190,7 +190,7 @@
S_VAL(sym->def) = strdup(p);
sym->flags &= ~SYMBOL_NEW;
} else {
- fprintf(stderr, "%s:%d: symbol value '%s' invalid for %s\n", name, lineno, p, sym->name);
+ fprintf(stderr, "%s:%d: error: symbol value '%s' invalid for %s\n", name, lineno, p, sym->name);
exit(1);
}
break;

2003-03-10 09:49:42

by Roman Zippel

[permalink] [raw]
Subject: Re: [PATCH] kconfig update

Hi,

On Sun, 9 Mar 2003, Sam Ravnborg wrote:

> $ make KBUILD_VERBOSE=0 defconfig

defconfig is special case (like all{yes,no,mod}config). They basically
set all options to a new value and print out the new config.
oldconfig could be less verbose and actually there is already a less
verbose mode. If you skip the oldconfig step, the config tool is called
anyway and checks the configuration and only asks as necessary. The same
mode could be used for oldconfig, but I didn't want to change the
behaviour needlessly. OTOH for oldconfig it should be no problem to call
conf with '-s' instead of '-o' for the KBUILD_VERBOSE=0 case.

> if (!p2) {
> - fprintf(stderr, "%s:%d: invalid string found\n", name, lineno);
> + fprintf(stderr, "%s:%d: error: invalid string found\n", name, lineno);
> exit(1);

Um, my gcc doesn't produce any "error:" prefix.

bye, Roman

2003-03-10 19:02:07

by Sam Ravnborg

[permalink] [raw]
Subject: Re: [PATCH] kconfig update

On Mon, Mar 10, 2003 at 11:00:02AM +0100, Roman Zippel wrote:

> verbose mode. If you skip the oldconfig step, the config tool is called
> anyway and checks the configuration and only asks as necessary. The same
> mode could be used for oldconfig, but I didn't want to change the
> behaviour needlessly.

The reason to respond is that all the output from conf looks useless.
What is the usage of conf being so verbose?
If it is required then keep it. But making conf that verbose only
because configure was that verbose . There is no point in that.

Not a needlessly change, but more in the area - it was about time..

Sam