linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Re: linux-2.4.6-pre6: numerous dep_{bool,tristate} $CONFIG_ARCH_xxx bugs
@ 2001-06-30 14:57 Adam J. Richter
  2001-06-30 15:01 ` Russell King
  0 siblings, 1 reply; 26+ messages in thread
From: Adam J. Richter @ 2001-06-30 14:57 UTC (permalink / raw)
  To: alan; +Cc: kaos, linux-kernel, rmk

I am following up my own message here.

>>> = Adam Richter
>>  = Alan Cox
>   = Adam Richter

>>> 	Argh!  I just accidentally sent and older version of my
>>> patch.  Here is the current version.  Sorry about that.

>>This just breaks stuff

>>> +for var in $(cat arch/*/config.in |
>>> +	     egrep -w -v '^[ 	]*int' |
>>> +             tr '   $"' '\n\n\n' |
>>> +	     egrep '^CONFIG_[A-Z0-9_]*$' |
>>> +	     sort -u) ; do
>>> +	define_bool "$var" "n"
>>> +done
>>> +set -f
>>>  

>>You've changed the entire semantics of dep_tristate by doing this

>	Please provide a real example.

	Although I am curious about what you had in mind about
dep_tristate, I no longer need to see this example to see a problem
with my patch.  My patch breaks detection of "new" variables in
arch/*/config.in by "make oldconfig."

	So, I guess something like Keith Owens's patch would be the
way to go, with some additional definitions (CONFIG_AGP, CONFIG_PCI,
CONFIG_ISA, CONFIG_EISA, CONFIG_PCMCIA, and possibly others).  I am
not sure which other conditionals might also be incorrectly ignored by
some instances of dep_xxx.  Below, I have included a list of the 52
CONFIG_* variables that are used as arguments to dep_xxx in 2.4.6-pre6
and appear in arch/*/config.in.

Adam J. Richter     __     ______________   4880 Stevens Creek Blvd, Suite 104
adam@yggdrasil.com     \ /                  San Jose, California 95129-1034
+1 408 261-6630         | g g d r a s i l   United States of America
fax +1 408 261-6631      "Free Software For The Rest Of Us."

CONFIG_ACPI
CONFIG_AGP
CONFIG_AMIGA
CONFIG_ARCH_ACORN
CONFIG_ARCH_ARCA5K
CONFIG_ARCH_CLPS711X
CONFIG_ARCH_FOOTBRIDGE
CONFIG_ARCH_NETWINDER
CONFIG_ARCH_SA1100
CONFIG_ATARI
CONFIG_ATM
CONFIG_BLK_DEV_IDE
CONFIG_BLK_DEV_LOOP
CONFIG_BLK_DEV_RAM
CONFIG_BUSMOUSE
CONFIG_CPU_26
CONFIG_CPU_32
CONFIG_DEBUG_LL
CONFIG_DEVFS_FS
CONFIG_DRM
CONFIG_EISA
CONFIG_EXPERIMENTAL
CONFIG_FOOTBRIDGE
CONFIG_GVPIOEXT
CONFIG_IDE
CONFIG_IEEE1394
CONFIG_IEEE1394_OHCI1394
CONFIG_INPUT
CONFIG_ISA
CONFIG_ISDN
CONFIG_MAC
CONFIG_MCA
CONFIG_MD
CONFIG_MODULES
CONFIG_NET
CONFIG_PARPORT
CONFIG_PCI
CONFIG_PCMCIA
CONFIG_PM
CONFIG_PPP
CONFIG_PROC_FS
CONFIG_SA1100_ASSABET
CONFIG_SBUS
CONFIG_SCSI
CONFIG_SERIAL
CONFIG_SGI
CONFIG_SOUND
CONFIG_SPARC64
CONFIG_UNIX98_PTYS
CONFIG_VIDEO_DEV
CONFIG_X86
CONFIG_ZORRO

^ permalink raw reply	[flat|nested] 26+ messages in thread
* Re: [PATCH] Re: 2.4.6p6: dep_{bool,tristate} $CONFIG_ARCH_xxx bugs
@ 2001-07-02  2:25 Adam J. Richter
  2001-07-02  2:48 ` Keith Owens
  0 siblings, 1 reply; 26+ messages in thread
From: Adam J. Richter @ 2001-07-02  2:25 UTC (permalink / raw)
  To: kaos, rhw; +Cc: linux-kernel, rmk

	Does anyone know if there is any code that would break if
we put quotation marks around the $CONFIG_xxxx references in the
dep_xxx commands in all of the Config.in files?  In other words,
change all commands of the form

dep_tristate  CONFIG_FOO 'Foo on x86/pci machines'  $CONFIG_PCI $CONFIG_X86

to

dep_tristate  CONFIG_FOO 'Foo on x86/pci machines'  "$CONFIG_PCI" "$CONFIG_X86"

      Then, we could change dep_{bool,tristate} to only treat "" as "n",
in its dependency parameters without effecting how undefined variables
are treated elsewhere.  For example, CONFIG_FOO being undefined would
still cause "make oldconfig" to treat it as "NEW" and ask the user
about it.

Adam J. Richter     __     ______________   4880 Stevens Creek Blvd, Suite 104
adam@yggdrasil.com     \ /                  San Jose, California 95129-1034
+1 408 261-6630         | g g d r a s i l   United States of America
fax +1 408 261-6631      "Free Software For The Rest Of Us."


^ permalink raw reply	[flat|nested] 26+ messages in thread
* Re: [PATCH] Re: 2.4.6p6: dep_{bool,tristate} $CONFIG_ARCH_xxx bugs
@ 2001-07-02  3:34 Adam J. Richter
  0 siblings, 0 replies; 26+ messages in thread
From: Adam J. Richter @ 2001-07-02  3:34 UTC (permalink / raw)
  To: kaos; +Cc: linux-kernel, rhw, rmk

Keith Owens <kaos@ocs.com.au> writes:
>On Sun, 1 Jul 2001 19:25:11 -0700, 
>"Adam J. Richter" <adam@yggdrasil.com> wrote:
>>	Does anyone know if there is any code that would break if
>>we put quotation marks around the $CONFIG_xxxx references in the
>>dep_xxx commands in all of the Config.in files?

>That has the same problem that AC was worried about.  Variables that
>used to be treated as "undefined, don't care" are now treated as
>"undefined, assume n and forbid".

	What variables?  Please show me a real example.

Adam J. Richter     __     ______________   4880 Stevens Creek Blvd, Suite 104
adam@yggdrasil.com     \ /                  San Jose, California 95129-1034
+1 408 261-6630         | g g d r a s i l   United States of America
fax +1 408 261-6631      "Free Software For The Rest Of Us."

^ permalink raw reply	[flat|nested] 26+ messages in thread
* Re: [PATCH] Re: 2.4.6p6: dep_{bool,tristate} $CONFIG_ARCH_xxx bugs
@ 2001-07-02  4:46 Adam J. Richter
  2001-07-02  4:51 ` Keith Owens
  0 siblings, 1 reply; 26+ messages in thread
From: Adam J. Richter @ 2001-07-02  4:46 UTC (permalink / raw)
  To: kaos; +Cc: alan, linux-kernel, rhw, rmk

>>>>       Does anyone know if there is any code that would break if
>>>>we put quotation marks around the $CONFIG_xxxx references in the
>>>>dep_xxx commands in all of the Config.in files?

>>>That has the same problem that AC was worried about.  Variables that
>>>used to be treated as "undefined, don't care" are now treated as
>>>"undefined, assume n and forbid".

>>	What variables?  Please show me a real example.

>Not my job.  If you want to make a global change to the meaning of
>undefined config variables, it is your responsibility to show that the
>change has no unwanted side effects.  Assuming there are no side
>effects is unsatisfactory in a stable kernel, especially with all the
>config variables in patch sets outside the kernel.

	That's not reasonable in the face of what appears to be
completely fabricated myth.  You generally can't prove this
kind of a negative for anything.  Either you or Alan Cox should
show an example.  Can you even show me the code that such an
example would exercise.  Can you even write a hypothetical example?

Adam J. Richter     __     ______________   4880 Stevens Creek Blvd, Suite 104
adam@yggdrasil.com     \ /                  San Jose, California 95129-1034
+1 408 261-6630         | g g d r a s i l   United States of America
fax +1 408 261-6631      "Free Software For The Rest Of Us."

^ permalink raw reply	[flat|nested] 26+ messages in thread
* Re: [PATCH] Re: 2.4.6p6: dep_{bool,tristate} $CONFIG_ARCH_xxx bugs
@ 2001-07-02  5:52 Adam J. Richter
  2001-07-02  6:21 ` Keith Owens
  2001-07-02 10:14 ` Alan Cox
  0 siblings, 2 replies; 26+ messages in thread
From: Adam J. Richter @ 2001-07-02  5:52 UTC (permalink / raw)
  To: kaos; +Cc: alan, linux-kernel, rhw, rmk

>On Sun, 1 Jul 2001 21:46:04 -0700, 
>"Adam J. Richter" <adam@yggdrasil.com> wrote:
>>Can you even write a hypothetical example?

>if [ "$CONFIG_foo" = "n" -a "$CONFIG_bar" = "n" ]; then
>  define_bool "$CONFIG_ALLOW_foo_bar n
>fi
>....
>dep_tristate CONFIG_baz $CONFIG_ALLOW_foo_bar

	In linux-2.4.6-pre8, there are only three configuration variables
that are defined with an indented 'define_bool' statement
(CONFIG_BLK_DEV_IDE{DMA,PCI}, and CONFIG_PCI), and the conditional
code execute by all "if" statements in all of the config.in files
appears to be indented (or at least the first statement in the block
is indented).  None of these three variables has the semantics that
I think you you described above.

	If you want to check, I determined this by the following shell
commands:

% find . -iname config.in | xargs egrep dep_tristate | tr '   ' '\n\n' | egrep '^\$CONFIG_' | sort -u > /tmp/config-dependencies 
% find . -iname config.in | xargs egrep '^[   ].*define_bool' | fgrep -f /tmp/config-dependencies  | awk '{print $(NF-1)}' | sort -u
CONFIG_BLK_DEV_IDEDMA
CONFIG_BLK_DEV_IDEPCI
CONFIG_PCI
% find /usr/src/linux/ -iname config.in | xargs egrep -A 2 ^if | egrep -v -e -- | egrep '^-[^         ]'
%
 

Adam J. Richter     __     ______________   4880 Stevens Creek Blvd, Suite 104
adam@yggdrasil.com     \ /                  San Jose, California 95129-1034
+1 408 261-6630         | g g d r a s i l   United States of America
fax +1 408 261-6631      "Free Software For The Rest Of Us."

^ permalink raw reply	[flat|nested] 26+ messages in thread
* Re: [PATCH] Re: 2.4.6p6: dep_{bool,tristate} $CONFIG_ARCH_xxx bugs
@ 2001-07-02  6:03 Adam J. Richter
  0 siblings, 0 replies; 26+ messages in thread
From: Adam J. Richter @ 2001-07-02  6:03 UTC (permalink / raw)
  To: kaos; +Cc: alan, linux-kernel, rhw, rmk

I have minor correction to make.  I wrote:
>        In linux-2.4.6-pre8, there are only three configuration variables
>that are defined with an indented 'define_bool' statement
>(CONFIG_BLK_DEV_IDE{DMA,PCI}, and CONFIG_PCI),

I meant three configuration variables that are defined with an
indented 'define_bool' statement _and are used as arguments to
a dep_* command_.

Adam J. Richter     __     ______________   4880 Stevens Creek Blvd, Suite 104
adam@yggdrasil.com     \ /                  San Jose, California 95129-1034
+1 408 261-6630         | g g d r a s i l   United States of America
fax +1 408 261-6631      "Free Software For The Rest Of Us."

^ permalink raw reply	[flat|nested] 26+ messages in thread
* Re: [PATCH] Re: 2.4.6p6: dep_{bool,tristate} $CONFIG_ARCH_xxx bugs
@ 2001-07-02  9:29 Adam J. Richter
  0 siblings, 0 replies; 26+ messages in thread
From: Adam J. Richter @ 2001-07-02  9:29 UTC (permalink / raw)
  To: kaos; +Cc: alan, linux-kernel, rhw, rmk

Keith,

	Copping out with "not my job" and then demanding essentially a
mathematical proof of correctness is unpersuasive, but I have no
objection to your change (some select "define_bool xxx no" lines in
a common file that every architecture reads), as long as we have
established that it seems to get along with "make xconfig" after all.
If that is the case, then I'd be just as happy that Linus apply your patch.

	So, with that lame endorsement and nobody else still objecting
to your patch (right?), how about if you submit your patch to Linus,
or is there some other way you want to proceed?

Adam J. Richter     __     ______________   4880 Stevens Creek Blvd, Suite 104
adam@yggdrasil.com     \ /                  San Jose, California 95129-1034
+1 408 261-6630         | g g d r a s i l   United States of America
fax +1 408 261-6631      "Free Software For The Rest Of Us."

^ permalink raw reply	[flat|nested] 26+ messages in thread

end of thread, other threads:[~2001-07-02 16:29 UTC | newest]

Thread overview: 26+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-06-30 14:57 linux-2.4.6-pre6: numerous dep_{bool,tristate} $CONFIG_ARCH_xxx bugs Adam J. Richter
2001-06-30 15:01 ` Russell King
2001-06-30 20:36   ` 2.4.6p6: " Riley Williams
2001-07-01  3:00     ` Keith Owens
2001-07-01 23:04       ` [PATCH] Re: 2.4.6p6: " Riley Williams
2001-07-02  0:39         ` Keith Owens
2001-07-02  7:16           ` Riley Williams
2001-07-02  7:23             ` Keith Owens
2001-07-02  8:25               ` Riley Williams
2001-07-02  9:41                 ` Russell King
2001-07-02 12:40                   ` Riley Williams
2001-07-02 15:03                     ` Russell King
2001-07-02 16:28                       ` Nicolas Pitre
2001-07-01  2:39   ` linux-2.4.6-pre6: numerous " Keith Owens
2001-07-02  2:25 [PATCH] Re: 2.4.6p6: " Adam J. Richter
2001-07-02  2:48 ` Keith Owens
2001-07-02  7:22   ` Riley Williams
2001-07-02  3:34 Adam J. Richter
2001-07-02  4:46 Adam J. Richter
2001-07-02  4:51 ` Keith Owens
2001-07-02  9:29   ` Andrzej Krzysztofowicz
2001-07-02  5:52 Adam J. Richter
2001-07-02  6:21 ` Keith Owens
2001-07-02 10:14 ` Alan Cox
2001-07-02  6:03 Adam J. Richter
2001-07-02  9:29 Adam J. Richter

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).