[patch 2/3, resend] kbuild: improve option checking, Kbuild.include cleanup

2007-02-05 Thread Oleg Verych
kbuild: improve option checking, Kbuild.include cleanup

 GNU binutils, root users, tmpfiles, external modules ro builds must
 be fixed to do the right thing now.

Cc: Roman Zippel [EMAIL PROTECTED]
Cc: Sam Ravnborg [EMAIL PROTECTED]
Cc: Horst Schirmeier [EMAIL PROTECTED]
Cc: Jan Beulich [EMAIL PROTECTED]
Cc: Daniel Drake [EMAIL PROTECTED]
Cc: Andi Kleen [EMAIL PROTECTED]
Cc: Randy Dunlap [EMAIL PROTECTED]
Signed-off-by: Oleg Verych [EMAIL PROTECTED]
---

-- all checks by shell united in one macro -- checker-shell;
-- one disposable output sym. link to /dev/null per shell,
   thus no racing, `-Z' is removed;
-- modules' build output directory is used, if supplied;
-- every option checking function calls shell wrapper, acquires probe;
-- `echo -e' bashizm substituted (people with sh != bash have distinct
   CC options!);
-- some spelling and sense added to the comments;
-- small shuffle of whitespace.

Mostly all people, discussing this back in October are in the Cc list.
Sam Ravnborg have not much time to reply. I've added Roman Zippel, as
a very kind reviewer and commiter of previous fix. Comments and
testing are appreciated. Thanks.

 scripts/Kbuild.include | 96 +++--
 1 file changed, 53 insertions(+), 43 deletions(-)

Index: linux-2.6.20/scripts/Kbuild.include
===
--- linux-2.6.20.orig/scripts/Kbuild.include2007-02-06 02:12:37.543828750 
+0100
+++ linux-2.6.20/scripts/Kbuild.include 2007-02-06 02:14:37.575330250 +0100
@@ -2,5 +2,5 @@
 # kbuild: Generic definitions
 
-# Convinient variables
+# Convenient constants
 comma   := ,
 squote  := '
@@ -57,38 +57,44 @@ endef
 # See documentation in Documentation/kbuild/makefiles.txt
 
-# output directory for tests below
-TMPOUT := $(if $(KBUILD_EXTMOD),$(firstword $(KBUILD_EXTMOD))/)
+# checker-shell
+# Usage: option = $(call checker-shell, $(CC)...-o $$OUT, option-ok, otherwise)
+# Exit code chooses option. $$OUT is safe location for needless output.
+define checker-shell
+  $(shell set -e; \
+DIR=$(KBUILD_EXTMOD); \
+cd $${DIR:-$(objtree)}; \
+OUT=$$PWD/..null; \
+\
+ln -s /dev/null $$OUT; \
+if $(1) /dev/null 21; \
+  then echo $(2); \
+  else echo $(3); \
+fi; \
+rm -f $$OUT)
+endef
 
 # as-option
 # Usage: cflags-y += $(call as-option, -Wa$(comma)-isa=foo,)
-
-as-option = $(shell if $(CC) $(CFLAGS) $(1) -Wa,-Z -c -o /dev/null \
--xassembler /dev/null  /dev/null 21; then echo $(1); \
-else echo $(2); fi ;)
+as-option = $(call checker-shell, \
+   $(CC) $(CFLAGS) $(1) -c -xassembler /dev/null -o $$OUT, $(1), $(2))
 
 # as-instr
 # Usage: cflags-y += $(call as-instr, instr, option1, option2)
-
-as-instr = $(shell if echo -e $(1) | \
- $(CC) $(AFLAGS) -c -xassembler - \
-   -o $(TMPOUT)astest.out  /dev/null 21; \
-  then rm $(TMPOUT)astest.out; echo $(2); \
-  else echo $(3); fi)
+as-instr = $(call checker-shell, \
+   printf $(1) | $(CC) $(AFLAGS) -c -xassembler -o $$OUT -, $(2), $(3))
 
 # cc-option
 # Usage: cflags-y += $(call cc-option, -march=winchip-c6, -march=i586)
-
-cc-option = $(shell if $(CC) $(CFLAGS) $(1) -S -o /dev/null -xc /dev/null \
-  /dev/null 21; then echo $(1); else echo $(2); fi ;)
+cc-option = $(call checker-shell, \
+   $(CC) $(CFLAGS) $(if $(3),$(3),$(1)) -S -xc /dev/null -o $$OUT, $(1), $(2))
 
 # cc-option-yn
 # Usage: flag := $(call cc-option-yn, -march=winchip-c6)
-cc-option-yn = $(shell if $(CC) $(CFLAGS) $(1) -S -o /dev/null -xc /dev/null \
- /dev/null 21; then echo y; else echo n; fi;)
+cc-option-yn = $(call cc-option, y, n, $(1))
 
 # cc-option-align
 # Prefix align with either -falign or -malign
 cc-option-align = $(subst -functions=0,,\
-   $(call cc-option,-falign-functions=0,-malign-functions=0))
+   $(call cc-option,-falign-functions=0,-malign-functions=0))
 
 # cc-version
@@ -98,15 +104,13 @@ cc-version = $(shell $(CONFIG_SHELL) $(s
 # cc-ifversion
 # Usage:  EXTRA_CFLAGS += $(call cc-ifversion, -lt, 0402, -O1)
-cc-ifversion = $(shell if [ $(call cc-version, $(CC)) $(1) $(2) ]; then \
-   echo $(3); fi;)
+cc-ifversion = $(shell [ $(call cc-version, $(CC)) $(1) $(2) ]  echo $(3))
 
 # ld-option
 # Usage: ldflags += $(call ld-option, -Wl$(comma)--hash-style=both)
-ld-option = $(shell if $(CC) $(1) -nostdlib -xc /dev/null \
--o $(TMPOUT)ldtest.out  /dev/null 21; \
- then rm $(TMPOUT)ldtest.out; echo $(1); \
- else echo $(2); fi)
+ld-option = $(call checker-shell, \
+   $(CC) $(1) -nostdlib -xc /dev/null -o $$OUT, $(1), $(2))
+
+##
 
-###
 # Shorthand for $(Q)$(MAKE) -f scripts/Makefile.build obj=
 # Usage:
@@ -114,17 +118,26 @@ ld-option = $(shell if $(CC) $(1) -nostd
 build := -f $(if $(KBUILD_SRC),$(srctree)/)scripts/Makefile.build obj
 
-# Prefix -I

Re: Free Linux Driver Development!

2007-02-04 Thread Oleg Verych
> From: devzero web.de
> Newsgroups: gmane.linux.kernel
> Subject: Re: Free Linux Driver Development!
> Date: Sun, 04 Feb 2007 22:37:33 +0100
> Organization: http://freemail.web.de/
> Archived-At: 

> First off, compliments to this announcement, I liked it very much!
>
> Some comment regarding those "volunteers, waiting to get some real work" :)
>
>> > OK, but why isn't your army of volunteers fixing them?
>
>> They don't know about them, or they don't have the hardware to test?
>> Seriously, let the kernel-janitor's project know about any issues you
>> have and they will be glad to jump on it.  Those people are just
>> chomping a the bit to do something a bit bigger than "compiler warning
>> cleanups" :)
>
> So many times i have seen good ideas brought up, kernel patches being 
> written, posted to lkml, being developed outside mainline for a while and 
> then being forgotten some time later due to lack of energy of some individual 
> to get this into mainline.
>
> If there is an noticeably number of talented programmers (unfortunately, i`m 
> not) , so why not "feeding" them the right way ? Where is those public and 
> transparent and moderated Linux-Kernel "ToDo"- or "Keep an eye on"-list, 
> sorted by priorities, with sort of a "vote for this feature"-button, so those 
> guys have something they can pick up? There is so much great stuff and ideas 
> out there where they could put their work onto or getting involved, it just 
> needs to be found or sort of being "managed" a little bit better.
>
> For myself, i`m waiting for so quite some things to get "one step further", 
> but they are more or less tied to some single individuals, for which you just 
> cannot send some "hey, what`s up with your project"-message every second day. 
> The interest in many nice projects often is quite low and evolution quite 
> slow, but not only because of the fact that they aren`t great, but more 
> because of not getting widely known. It`s not always missing specs, it`s also 
> some missing noise/feedback for different features or missing of some 
> "driving force" to bring things forward. How should one developer know that 
> somebody needs a feature if those who could probably need it don`t request 
> it? Maybe just because of the fact that they even imagine that such feature 
> would be possible ?
>
> Where is those efforts for fixing/integrating fantastic cowloop?
> What about badram/badmem patch ?
> Compressed Ccaching ?
> Somebody helping with development of dm-loop or extend loop.c to support more 
> than 256 devices ?
> Replacement of proprietary, unstable and unelegant vmware-lopp for being able 
> to mount vmware .vmdk files ? Internal Spec for this is open, dm-userspace 
> could be some infrastructure for this, but the author seems to have other 
> priorities
> dm-cow, zfs-fuse - anybody ?
> Kernel based target for AoE (Ata over Ethernet) ?  (there are two independent 
> implementations, but both got stuck at some early experimental stage) 

A quick answer for philosophers:
   

For example, i don't know if somebody volunteered to be a bug-buddy in
google, see Andrew's 2.6.20-rc6-mm1 announcement. It seems no, as he
still forwards bugzilla reports to developers/maintainers.

I myself am new. But anyway, i can write a little bit of HOWTO

-- effectively handle (among others) LKML, to break free from myths,

-- to not afraid emacs as good editor for issues like symbol-searching (TAGS),
   whitespace, spell (typos) and such,

-- having linux tree up-today with small bandwidth: mirrors, patches, quilt

of course if such things prevent people from participating.

[:(ot) As for Greg's message, imho somebody was bored. There is plenty  ;]
[: of work *in* the kernel, not only in drivers/ related part of it...  ;]

> Just my 2 cents. 

So my.


Greetings.
--
-o--=O`C  info emacs : not found  /. .\ ( is there any reason to live? )
 #oo'L O  info make  : not found  o (yes --- R.I.P. FSF+RMS)
<___=E M  man gcc: not found`-- ( viva Debian Operating System )

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [patch] kbuild: correctly skip tilded backups in localversion files

2007-02-04 Thread Oleg Verych
On Wed, Jan 31, 2007 at 06:43:29PM -0800, Andrew Morton wrote:
> On Thu, 1 Feb 2007 03:37:17 +0100 Oleg Verych <[EMAIL PROTECTED]> wrote:
> 
> > On Wed, Jan 31, 2007 at 03:56:51PM -0800, Andrew Morton wrote:
> > > On Wed, 31 Jan 2007 07:11:04 +
> > > Oleg Verych <[EMAIL PROTECTED]> wrote:
> > > 
> > > > kbuild: correctly skip tilded backups in localversion files
> > > 
> > > Does this patch replace Bastian's patch, below?
> > 
> > Along with "Message-ID: <[EMAIL PROTECTED]>" -- yes.
> > 
> 
> OK.  Just to avoid mistakes, can you please resend everything, against
> 2.6.20-rc7?

I've resent patches, that i wanted to be in -mm, even without anyone,
who can ack or even test them. But it seems, they not made it to lkml.


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [patch] kbuild: correctly skip tilded backups in localversion files

2007-02-04 Thread Oleg Verych
On Wed, Jan 31, 2007 at 06:43:29PM -0800, Andrew Morton wrote:
 On Thu, 1 Feb 2007 03:37:17 +0100 Oleg Verych [EMAIL PROTECTED] wrote:
 
  On Wed, Jan 31, 2007 at 03:56:51PM -0800, Andrew Morton wrote:
   On Wed, 31 Jan 2007 07:11:04 +
   Oleg Verych [EMAIL PROTECTED] wrote:
   
kbuild: correctly skip tilded backups in localversion files
   
   Does this patch replace Bastian's patch, below?
  
  Along with Message-ID: [EMAIL PROTECTED] -- yes.
  
 
 OK.  Just to avoid mistakes, can you please resend everything, against
 2.6.20-rc7?

I've resent patches, that i wanted to be in -mm, even without anyone,
who can ack or even test them. But it seems, they not made it to lkml.


-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: Free Linux Driver Development!

2007-02-04 Thread Oleg Verych
 From: devzero web.de
 Newsgroups: gmane.linux.kernel
 Subject: Re: Free Linux Driver Development!
 Date: Sun, 04 Feb 2007 22:37:33 +0100
 Organization: http://freemail.web.de/
 Archived-At: http://permalink.gmane.org/gmane.linux.kernel/489586

 First off, compliments to this announcement, I liked it very much!

 Some comment regarding those volunteers, waiting to get some real work :)

  OK, but why isn't your army of volunteers fixing them?

 They don't know about them, or they don't have the hardware to test?
 Seriously, let the kernel-janitor's project know about any issues you
 have and they will be glad to jump on it.  Those people are just
 chomping a the bit to do something a bit bigger than compiler warning
 cleanups :)

 So many times i have seen good ideas brought up, kernel patches being 
 written, posted to lkml, being developed outside mainline for a while and 
 then being forgotten some time later due to lack of energy of some individual 
 to get this into mainline.

 If there is an noticeably number of talented programmers (unfortunately, i`m 
 not) , so why not feeding them the right way ? Where is those public and 
 transparent and moderated Linux-Kernel ToDo- or Keep an eye on-list, 
 sorted by priorities, with sort of a vote for this feature-button, so those 
 guys have something they can pick up? There is so much great stuff and ideas 
 out there where they could put their work onto or getting involved, it just 
 needs to be found or sort of being managed a little bit better.

 For myself, i`m waiting for so quite some things to get one step further, 
 but they are more or less tied to some single individuals, for which you just 
 cannot send some hey, what`s up with your project-message every second day. 
 The interest in many nice projects often is quite low and evolution quite 
 slow, but not only because of the fact that they aren`t great, but more 
 because of not getting widely known. It`s not always missing specs, it`s also 
 some missing noise/feedback for different features or missing of some 
 driving force to bring things forward. How should one developer know that 
 somebody needs a feature if those who could probably need it don`t request 
 it? Maybe just because of the fact that they even imagine that such feature 
 would be possible ?

 Where is those efforts for fixing/integrating fantastic cowloop?
 What about badram/badmem patch ?
 Compressed Ccaching ?
 Somebody helping with development of dm-loop or extend loop.c to support more 
 than 256 devices ?
 Replacement of proprietary, unstable and unelegant vmware-lopp for being able 
 to mount vmware .vmdk files ? Internal Spec for this is open, dm-userspace 
 could be some infrastructure for this, but the author seems to have other 
 priorities
 dm-cow, zfs-fuse - anybody ?
 Kernel based target for AoE (Ata over Ethernet) ?  (there are two independent 
 implementations, but both got stuck at some early experimental stage) 

A quick answer for philosophers:
   http://www.linuxjournal.com/article/7272

For example, i don't know if somebody volunteered to be a bug-buddy in
google, see Andrew's 2.6.20-rc6-mm1 announcement. It seems no, as he
still forwards bugzilla reports to developers/maintainers.

I myself am new. But anyway, i can write a little bit of HOWTO

-- effectively handle (among others) LKML, to break free from myths,

-- to not afraid emacs as good editor for issues like symbol-searching (TAGS),
   whitespace, spell (typos) and such,

-- having linux tree up-today with small bandwidth: mirrors, patches, quilt

of course if such things prevent people from participating.

[:(ot) As for Greg's message, imho somebody was bored. There is plenty  ;]
[: of work *in* the kernel, not only in drivers/ related part of it...  ;]

 Just my 2 cents. 

So my.


Greetings.
--
-o--=O`C  info emacs : not found  /. .\ ( is there any reason to live? )
 #oo'L O  info make  : not found  o (yes --- R.I.P. FSF+RMS)
___=E M  man gcc: not found`-- ( viva Debian Operating System )

-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: scripts/makelst: bc -> shell Re: sed _s_gnu_alternatives_ (Re: [rft] (g)awk substitution)

2007-02-03 Thread Oleg Verych
On Sat, Feb 03, 2007 at 12:24:59PM +0100, David Weinehall wrote:
> On Sat, Jan 27, 2007 at 06:38:36AM +0000, Oleg Verych wrote:
> [snip]
> > ,-*- diff snip -*-
> > |-t4=`echo $t3 | gawk '{ print $1 }'`
> > |-t5=`echo $t1 | gawk '{ print $1 }'`
> > |+t4=`pos_param 1 $t3`
> > |+t5=`pos_param 1 $t1`
> > 5 t6=`echo $t4 - $t5 | tr a-f A-F`
> > 6 t7=`( echo  ibase=16 ; echo $t6 ) | bc`
> > `-*-
> > 
> > I've just noticed, that things on lines 5 and 6 may be optimized.
> > 
> > t7=`printf "%lu" $(( 0x$t4 - 0x$t5 ))`
> 
> %lu does not seem to agree with SuSv3:
> 
> http://www.opengroup.org/onlinepubs/009695399/utilities/printf.html
> http://www.opengroup.org/onlinepubs/009695399/basedefs/xbd_chap05.html

,-*- xbd_chap05.html -*-
| The EXTENDED DESCRIPTION section almost exactly matches the
| printf() function in the ISO C standard, although it is described
| in terms of the file format notation in the Base Definitions volume
| of IEEE Std 1003.1-2001, Chapter 5, File Format Notation.
`-*-
In other words, it does *not* match it at all. How it can without
the length modifiers?

As for me, "shalls" and "shoulds", "Implementations are encouraged" are
standard terms of The Standards.

Thus, i think, "%ul" is more "implementation wise":

,-*- printf test on bash, dash, busybox -*-
|[EMAIL PROTECTED]:~$
|[EMAIL PROTECTED]:~$ printf "%u \n" 0x
|18446744073709551615
|[EMAIL PROTECTED]:~$ printf "%u \n" 0xA
|bash: printf: warning: 0xA: Numerical result out of range
|18446744073709551615
|[EMAIL PROTECTED]:~$
|[EMAIL PROTECTED]:~$ echo $BASH_VERSION
|3.1.17(1)-release
|[EMAIL PROTECTED]:~$
|[EMAIL PROTECTED]:~$ /bin/dash
|flower:-$ printf "%u \n" 0x
|18446744073709551615
|flower:-$ printf "%u \n" 0xA
|printf: 2: 0xA: Numerical result out of range
|18446744073709551615
|flower:-$
|flower:-$ /bin/busybox sh
|
|
|BusyBox v1.1.3 (Debian 1:1.1.3-4) Built-in shell (ash)
|Enter 'help' for a list of built-in commands.
|
|flower:-$
|flower:-$
|flower:-$ printf "%u \n" 0x
|4294967295
|flower:-$ printf "%u \n" 0xA
|0xA4294967295
|flower:-$ printf "%lu \n" 0x
|18446744073709551615
|flower:-$ printf "%lu \n" 0xA
|0xA18446744073709551615
|flower:-$
|flower:-$
`-*-


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: scripts/makelst: bc - shell Re: sed _s_gnu_alternatives_ (Re: [rft] (g)awk substitution)

2007-02-03 Thread Oleg Verych
On Sat, Feb 03, 2007 at 12:24:59PM +0100, David Weinehall wrote:
 On Sat, Jan 27, 2007 at 06:38:36AM +, Oleg Verych wrote:
 [snip]
  ,-*- diff snip -*-
  |-t4=`echo $t3 | gawk '{ print $1 }'`
  |-t5=`echo $t1 | gawk '{ print $1 }'`
  |+t4=`pos_param 1 $t3`
  |+t5=`pos_param 1 $t1`
  5 t6=`echo $t4 - $t5 | tr a-f A-F`
  6 t7=`( echo  ibase=16 ; echo $t6 ) | bc`
  `-*-
  
  I've just noticed, that things on lines 5 and 6 may be optimized.
  
  t7=`printf %lu $(( 0x$t4 - 0x$t5 ))`
 
 %lu does not seem to agree with SuSv3:
 
 http://www.opengroup.org/onlinepubs/009695399/utilities/printf.html
 http://www.opengroup.org/onlinepubs/009695399/basedefs/xbd_chap05.html

,-*- xbd_chap05.html -*-
| The EXTENDED DESCRIPTION section almost exactly matches the
| printf() function in the ISO C standard, although it is described
| in terms of the file format notation in the Base Definitions volume
| of IEEE Std 1003.1-2001, Chapter 5, File Format Notation.
`-*-
In other words, it does *not* match it at all. How it can without
the length modifiers?

As for me, shalls and shoulds, Implementations are encouraged are
standard terms of The Standards.

Thus, i think, %ul is more implementation wise:

,-*- printf test on bash, dash, busybox -*-
|[EMAIL PROTECTED]:~$
|[EMAIL PROTECTED]:~$ printf %u \n 0x
|18446744073709551615
|[EMAIL PROTECTED]:~$ printf %u \n 0xA
|bash: printf: warning: 0xA: Numerical result out of range
|18446744073709551615
|[EMAIL PROTECTED]:~$
|[EMAIL PROTECTED]:~$ echo $BASH_VERSION
|3.1.17(1)-release
|[EMAIL PROTECTED]:~$
|[EMAIL PROTECTED]:~$ /bin/dash
|flower:-$ printf %u \n 0x
|18446744073709551615
|flower:-$ printf %u \n 0xA
|printf: 2: 0xA: Numerical result out of range
|18446744073709551615
|flower:-$
|flower:-$ /bin/busybox sh
|
|
|BusyBox v1.1.3 (Debian 1:1.1.3-4) Built-in shell (ash)
|Enter 'help' for a list of built-in commands.
|
|flower:-$
|flower:-$
|flower:-$ printf %u \n 0x
|4294967295
|flower:-$ printf %u \n 0xA
|0xA4294967295
|flower:-$ printf %lu \n 0x
|18446744073709551615
|flower:-$ printf %lu \n 0xA
|0xA18446744073709551615
|flower:-$
|flower:-$
`-*-


-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH] sed s/gawk/awk/ scripts/gen_init_ramfs.sh

2007-02-02 Thread Oleg Verych
> From: Adrian Bunk
> Newsgroups: gmane.linux.kernel
> Subject: Re: [PATCH] sed s/gawk/awk/ scripts/gen_init_ramfs.sh
> Date: Fri, 2 Feb 2007 17:36:20 +0100
[]
> On Tue, Jan 23, 2007 at 04:49:44PM -0800, Andrew Morton wrote:
>> On Mon, 15 Jan 2007 23:11:46 +0100
>> Sam Ravnborg <[EMAIL PROTECTED]> wrote:
>> 
>> > On Mon, Jan 15, 2007 at 04:24:17PM -0500, Rob Landley wrote:
>> > > Signed-off-by: Rob Landley <[EMAIL PROTECTED]>
>> > Acked-by: Sam Ravnborg <[EMAIL PROTECTED]>
>> > 
>> > > Use "awk" instead of "gawk".
>> > > 
>> > > -- 
>> > > 
>> > > There's a symlink from awk to gawk if you're using the gnu tools, but no
>> > > symlink from gawk to awk if you're using BusyBox or some such.  (There's 
>> > > a
>> > > reason for the existence of standard names.  Can we use them please?)
>> 
>> If the kernel is being compiled on a non-Linux system (eg: legacy Unix)
>> then it is, I guess, possible for `awk' and `gawk' to offer different
>> features.  If the kernel's use of gawk uses GNU extensions then this patch
>> might break things on such a system.
>> 
>> I guess we'll find out...
>
> Not only legacy systems.
>
> E.g. in Debian GNU/Linux you must have at least one AWK implementation 
> installed, and awk is a symlink to one of them (both is done by the 
> package manager).
>
> Available AWK implementations are:
> - GNU AWK 
> - Mawk
> - the original AWK

Well, i'm looking for anyone to comment on my respond to this "issue".
Probably noone has much time to do this. Anyway, please see my patch:

 Message-ID: <[EMAIL PROTECTED]>
 Archived-At: 

Thanks.



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: lirc: igorplususb error handling cleanup

2007-02-02 Thread Oleg Verych
> From: Pekka J Enberg
> Newsgroups: gmane.linux.kernel
> Subject: lirc: igorplususb error handling cleanup
> Date: Fri, 2 Feb 2007 11:15:15 +0200 (EET)
> Archived-At: 

Hallo.

> Use goto instead of a big ugly switch for error handling. Convert some 
> kmalloc + memset pairs to kzalloc too.

IMHO, goto ugly 2. But this isn't issue here. Let's try to optimize
all this a little bit:

> Index: lirc-0.8.1/drivers/lirc_igorplugusb/lirc_igorplugusb.c
>===
> --- lirc-0.8.1.orig/drivers/lirc_igorplugusb/lirc_igorplugusb.c
> +++ lirc-0.8.1/drivers/lirc_igorplugusb/lirc_igorplugusb.c
> @@ -405,7 +405,7 @@ static int usb_remote_probe(struct usb_i
>   int minor = 0;
>   char buf[63], name[128]="";
>   int mem_failure = 0;
> - int ret;
> + int ret, err;
>  
>   dprintk(DRIVER_NAME ": usb probe called.\n");
>  
> @@ -430,67 +430,44 @@ static int usb_remote_probe(struct usb_i
>   devnum, bytes_in_key, maxp);
>  
>  
> - /* allocate kernel memory */
> - mem_failure = 0;
> - if (!(ir = kmalloc(sizeof(struct irctl), GFP_KERNEL))) {
> - mem_failure = 1;
> - } else {
> - memset(ir, 0, sizeof(struct irctl));
> -
> - if (!(plugin = kmalloc(sizeof(struct lirc_plugin), 
> GFP_KERNEL))) {
> - mem_failure = 2;
> - } else if (!(rbuf = kmalloc(sizeof(struct lirc_buffer), 
> GFP_KERNEL))) {
> - mem_failure = 3;

If size of all structs, allocated here is 3-4 pages (say, 4096 bytes
one), then, i think something like, allocating all at once may be
utilized:

,-*-
|struct ir_stuff_t {
|   struct irctl *ir;
|   struct lirc_plugin *plugin;
|   struct lirc_buffer *rbuf;
|} ir_stuff;
|
|ir_stuff = kzalloc(...);
|
|if(!ir_stuff)
|   error;
`-*-   

then join buffer init, usb init together and final register, after
it. Thus to have second erroneous path.

So, lucky path may be faster, erroneous, with more *free() stuff slower,
but who cares?

Finally i would put first stage in do { ...if (error) break; ...} while(0),
second in if (error) ... break.

What about that? (ENOPATCH, but i have no lirc ATM ;)

> - } else if (lirc_buffer_init(rbuf, bytes_in_key, 
> - DEVICE_BUFLEN+ADDITIONAL_LIRC_BYTES)) {
> - mem_failure = 4;
> - } else if (!(ir->buf_in = usb_buffer_alloc(dev, 
> - DEVICE_BUFLEN+DEVICE_HEADERLEN, 
> -GFP_ATOMIC, >dma_in))) {
> - mem_failure = 5;
> - } else {
> -
> - memset(plugin, 0, sizeof(struct lirc_plugin));
> -
> - strcpy(plugin->name, DRIVER_NAME " ");
> - plugin->minor = -1;
> - plugin->code_length = bytes_in_key*8; /* in bits */
> - plugin->features = LIRC_CAN_REC_MODE2;
> - plugin->data = ir;
> - plugin->rbuf = rbuf;
> - plugin->set_use_inc = _use_inc;
> - plugin->set_use_dec = _use_dec;
> - plugin->sample_rate = SAMPLE_RATE;/* per second */
> - plugin->add_to_buf = _remote_poll;
> - plugin->owner = THIS_MODULE;
> -
> - init_MUTEX(>lock);
> - init_waitqueue_head(>wait_out);
> -
> - if ((minor = lirc_register_plugin(plugin)) < 0) {
> - mem_failure = 9;
> - }
> - }
> - }
> -
> - /* free allocated memory in case of failure */
> - switch (mem_failure) {
> - case 9:
> - usb_buffer_free(dev, DEVICE_BUFLEN+DEVICE_HEADERLEN, 
> - ir->buf_in, ir->dma_in);
> - case 5:
> - lirc_buffer_free(rbuf);
> - case 4:
> - kfree(rbuf);
> - case 3:
> - kfree(plugin);
> - case 2:
> - kfree(ir);
> - case 1:
> - printk(DRIVER_NAME "[%d]: out of memory (code=%d)\n",
> - devnum, mem_failure);
> - return -ENOMEM;
> - }
> + ir = kzalloc(sizeof(struct irctl), GFP_KERNEL);
> + if (!ir)
> + goto failed_ctl_alloc;
> +
> + plugin = kzalloc(sizeof(struct lirc_plugin), GFP_KERNEL);
> + if (!plugin)
> + goto failed_plugin_alloc;
> + rbuf = kmalloc(sizeof(struct lirc_buffer), GFP_KERNEL);
> + if (!rbuf)
> + goto failed_rbuf_alloc;
> +
> + err = lirc_buffer_init(rbuf, bytes_in_key, DEVICE_BUFLEN +
> +ADDITIONAL_LIRC_BYTES);
> + if (err)
> + goto failed_buffer_init;
> +
> + ir->buf_in = usb_buffer_alloc(dev, DEVICE_BUFLEN+DEVICE_HEADERLEN, 
> GFP_ATOMIC, >dma_in);
> + if (!ir->buf_in)
> +

Re: lirc: igorplususb error handling cleanup

2007-02-02 Thread Oleg Verych
 From: Pekka J Enberg
 Newsgroups: gmane.linux.kernel
 Subject: lirc: igorplususb error handling cleanup
 Date: Fri, 2 Feb 2007 11:15:15 +0200 (EET)
 Archived-At: http://permalink.gmane.org/gmane.linux.kernel/488937

Hallo.

 Use goto instead of a big ugly switch for error handling. Convert some 
 kmalloc + memset pairs to kzalloc too.

IMHO, goto ugly 2. But this isn't issue here. Let's try to optimize
all this a little bit:

 Index: lirc-0.8.1/drivers/lirc_igorplugusb/lirc_igorplugusb.c
===
 --- lirc-0.8.1.orig/drivers/lirc_igorplugusb/lirc_igorplugusb.c
 +++ lirc-0.8.1/drivers/lirc_igorplugusb/lirc_igorplugusb.c
 @@ -405,7 +405,7 @@ static int usb_remote_probe(struct usb_i
   int minor = 0;
   char buf[63], name[128]=;
   int mem_failure = 0;
 - int ret;
 + int ret, err;
  
   dprintk(DRIVER_NAME : usb probe called.\n);
  
 @@ -430,67 +430,44 @@ static int usb_remote_probe(struct usb_i
   devnum, bytes_in_key, maxp);
  
  
 - /* allocate kernel memory */
 - mem_failure = 0;
 - if (!(ir = kmalloc(sizeof(struct irctl), GFP_KERNEL))) {
 - mem_failure = 1;
 - } else {
 - memset(ir, 0, sizeof(struct irctl));
 -
 - if (!(plugin = kmalloc(sizeof(struct lirc_plugin), 
 GFP_KERNEL))) {
 - mem_failure = 2;
 - } else if (!(rbuf = kmalloc(sizeof(struct lirc_buffer), 
 GFP_KERNEL))) {
 - mem_failure = 3;

If size of all structs, allocated here is 3-4 pages (say, 4096 bytes
one), then, i think something like, allocating all at once may be
utilized:

,-*-
|struct ir_stuff_t {
|   struct irctl *ir;
|   struct lirc_plugin *plugin;
|   struct lirc_buffer *rbuf;
|} ir_stuff;
|
|ir_stuff = kzalloc(...);
|
|if(!ir_stuff)
|   error;
`-*-   

then join buffer init, usb init together and final register, after
it. Thus to have second erroneous path.

So, lucky path may be faster, erroneous, with more *free() stuff slower,
but who cares?

Finally i would put first stage in do { ...if (error) break; ...} while(0),
second in if (error) ... break.

What about that? (ENOPATCH, but i have no lirc ATM ;)

 - } else if (lirc_buffer_init(rbuf, bytes_in_key, 
 - DEVICE_BUFLEN+ADDITIONAL_LIRC_BYTES)) {
 - mem_failure = 4;
 - } else if (!(ir-buf_in = usb_buffer_alloc(dev, 
 - DEVICE_BUFLEN+DEVICE_HEADERLEN, 
 -GFP_ATOMIC, ir-dma_in))) {
 - mem_failure = 5;
 - } else {
 -
 - memset(plugin, 0, sizeof(struct lirc_plugin));
 -
 - strcpy(plugin-name, DRIVER_NAME  );
 - plugin-minor = -1;
 - plugin-code_length = bytes_in_key*8; /* in bits */
 - plugin-features = LIRC_CAN_REC_MODE2;
 - plugin-data = ir;
 - plugin-rbuf = rbuf;
 - plugin-set_use_inc = set_use_inc;
 - plugin-set_use_dec = set_use_dec;
 - plugin-sample_rate = SAMPLE_RATE;/* per second */
 - plugin-add_to_buf = usb_remote_poll;
 - plugin-owner = THIS_MODULE;
 -
 - init_MUTEX(ir-lock);
 - init_waitqueue_head(ir-wait_out);
 -
 - if ((minor = lirc_register_plugin(plugin))  0) {
 - mem_failure = 9;
 - }
 - }
 - }
 -
 - /* free allocated memory in case of failure */
 - switch (mem_failure) {
 - case 9:
 - usb_buffer_free(dev, DEVICE_BUFLEN+DEVICE_HEADERLEN, 
 - ir-buf_in, ir-dma_in);
 - case 5:
 - lirc_buffer_free(rbuf);
 - case 4:
 - kfree(rbuf);
 - case 3:
 - kfree(plugin);
 - case 2:
 - kfree(ir);
 - case 1:
 - printk(DRIVER_NAME [%d]: out of memory (code=%d)\n,
 - devnum, mem_failure);
 - return -ENOMEM;
 - }
 + ir = kzalloc(sizeof(struct irctl), GFP_KERNEL);
 + if (!ir)
 + goto failed_ctl_alloc;
 +
 + plugin = kzalloc(sizeof(struct lirc_plugin), GFP_KERNEL);
 + if (!plugin)
 + goto failed_plugin_alloc;
 + rbuf = kmalloc(sizeof(struct lirc_buffer), GFP_KERNEL);
 + if (!rbuf)
 + goto failed_rbuf_alloc;
 +
 + err = lirc_buffer_init(rbuf, bytes_in_key, DEVICE_BUFLEN +
 +ADDITIONAL_LIRC_BYTES);
 + if (err)
 + goto failed_buffer_init;
 +
 + ir-buf_in = usb_buffer_alloc(dev, DEVICE_BUFLEN+DEVICE_HEADERLEN, 
 GFP_ATOMIC, ir-dma_in);
 + if (!ir-buf_in)
 + goto failed_buf_in_alloc;
 +
 + strcpy(plugin-name, DRIVER_NAME  );
 + plugin-minor = -1;
 + 

Re: [PATCH] sed s/gawk/awk/ scripts/gen_init_ramfs.sh

2007-02-02 Thread Oleg Verych
 From: Adrian Bunk
 Newsgroups: gmane.linux.kernel
 Subject: Re: [PATCH] sed s/gawk/awk/ scripts/gen_init_ramfs.sh
 Date: Fri, 2 Feb 2007 17:36:20 +0100
[]
 On Tue, Jan 23, 2007 at 04:49:44PM -0800, Andrew Morton wrote:
 On Mon, 15 Jan 2007 23:11:46 +0100
 Sam Ravnborg [EMAIL PROTECTED] wrote:
 
  On Mon, Jan 15, 2007 at 04:24:17PM -0500, Rob Landley wrote:
   Signed-off-by: Rob Landley [EMAIL PROTECTED]
  Acked-by: Sam Ravnborg [EMAIL PROTECTED]
  
   Use awk instead of gawk.
   
   -- 
   
   There's a symlink from awk to gawk if you're using the gnu tools, but no
   symlink from gawk to awk if you're using BusyBox or some such.  (There's 
   a
   reason for the existence of standard names.  Can we use them please?)
 
 If the kernel is being compiled on a non-Linux system (eg: legacy Unix)
 then it is, I guess, possible for `awk' and `gawk' to offer different
 features.  If the kernel's use of gawk uses GNU extensions then this patch
 might break things on such a system.
 
 I guess we'll find out...

 Not only legacy systems.

 E.g. in Debian GNU/Linux you must have at least one AWK implementation 
 installed, and awk is a symlink to one of them (both is done by the 
 package manager).

 Available AWK implementations are:
 - GNU AWK 
 - Mawk
 - the original AWK

Well, i'm looking for anyone to comment on my respond to this issue.
Probably noone has much time to do this. Anyway, please see my patch:

 Message-ID: [EMAIL PROTECTED]
 Archived-At: http://permalink.gmane.org/gmane.linux.kernel/488044

Thanks.



-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: PROBLEM: Crash on device_shutdown

2007-02-01 Thread Oleg Verych
> From: Julien RF
> Newsgroups: gmane.linux.kernel
> Subject: PROBLEM: Crash on device_shutdown
> Date: Mon, 29 Jan 2007 00:03:49 +0100
> Archived-At: 

Hallo, Julien.

Do you have such problem with more recent kernels, or mm one?

Also, if would be good to have at least some of the stack trace.

You can set up serial console for purpose of logging all information
to remote host.

> One line summary of the problem:
> Crash on device_shutdown
>
>
> Full description of the problem/report:
> When I shut down the system, I get a crash on the device_shutdown function 
> (called by kernel_shutdown_prepare).
> Since the bug happens when the system is almost shutted down, I can't get the 
> log...
> I partially copied it by hand, ask me if you need further details :
> Will now halt.
> BUG: unable to handle kernel NULL pointer dereference at virtual adress 
> 0128
> ...
> EIP is at device_shutdown + 0x49/0x6c
> ...
> Process halt
> ...
> /etc/rc0.d/S90halt: line 21: 11198 Segmentation fault halt -d -f $shutdown 
> $poweroff $hddown
>
> Julien Richard-Foy

p.s. Please, care to honor "Mail-Followup-To" header information. Thanks.


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


2.6.20-rc7 (Re: [patch] kbuild: correctly skip tilded backups in localversion files)

2007-02-01 Thread Oleg Verych
kbuild: correctly skip tilded backups in localversion files

 Tildes as in path as in filenames are handled correctly now:
 only files, containing tilde '~', are backups, thus are not valid.

 [KJ]:
 Definition of `space' was removed, scripts/Kbuild.include has one.
 This definition was taken right from GNU make manual, while Kbuild's
 version is original.

Cc: Roman Zippel <[EMAIL PROTECTED]>
Cc: Bastian Blank <[EMAIL PROTECTED]>
Cc: Sam Ravnborg <[EMAIL PROTECTED]>
Signed-off-by: Oleg Verych <[EMAIL PROTECTED]>
---

 My using of the `sh' rides from willing to have more portable,
 understandable implementation (and due to GFDL make's docs ;)

Original report by Bastian Blank:

 The following patch fixes the problem that localversion files where
 ignored if the tree lives in a path which contains a ~. It changes the
 test to apply to the filename only.
 
 Debian allows versions which contains ~ in it. The upstream part of the
 version is in the directory name of the build tree and we got weird
 results because the localversion files was just got ignored in this
 case.

---
 linux-2.6.20-rc7/Makefile |   17 ++---
 1 file changed, 6 insertions(+), 11 deletions(-)

Index: kernel.org/linux-2.6.20-rc7/Makefile
===
--- kernel.org.orig/linux-2.6.20-rc7/Makefile   2007-02-01 16:20:54.214174250 
+0100
+++ kernel.org/linux-2.6.20-rc7/Makefile2007-02-01 16:21:40.649076250 
+0100
@@ -777,5 +777,5 @@ $(vmlinux-dirs): prepare scripts
 #  $(localver-full)
 #$(localver)
-#  localversion*   (all localversion* files)
+#  localversion*   (files without backups, containing '~')
 #  $(CONFIG_LOCALVERSION)  (from kernel config setting)
 #$(localver-auto)  (only if CONFIG_LOCALVERSION_AUTO is 
set)
@@ -788,15 +788,10 @@ $(vmlinux-dirs): prepare scripts
 # scripts/setlocalversion and add the appropriate checks as needed.
 
-nullstring :=
-space  := $(nullstring) # end of line
+pattern = ".*/localversion[^~]*"
+string  = $(shell cat /dev/null \
+  `find $(objtree) $(srctree) -maxdepth 1 -regex $(pattern) | sort`)
 
-___localver = $(objtree)/localversion* $(srctree)/localversion*
-__localver  = $(sort $(wildcard $(___localver)))
-# skip backup files (containing '~')
-_localver = $(foreach f, $(__localver), $(if $(findstring ~, $(f)),,$(f)))
-
-localver = $(subst $(space),, \
-  $(shell cat /dev/null $(_localver)) \
-  $(patsubst "%",%,$(CONFIG_LOCALVERSION)))
+localver = $(subst $(space),, $(string) \
+ $(patsubst "%",%,$(CONFIG_LOCALVERSION)))
 
 # If CONFIG_LOCALVERSION_AUTO is set scripts/setlocalversion is called
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [patch, rfc] kbuild: implement checksrc without building Cources...

2007-02-01 Thread Oleg Verych
> From: Oleg Verych
> Newsgroups: gmane.linux.kernel,gmane.linux.kbuild.devel
> Subject: Re:[patch, rfc] kbuild: implement checksrc without building 
> Cources...
> Date: Thu, 26 Oct 2006 15:07:20 +0200
> Archived-At: <http://permalink.gmane.org/gmane.linux.kernel/460736>

> On Tue, Oct 24, 2006 at 01:45:08PM -0700, Randy Dunlap wrote:
>> On Tue, 24 Oct 2006 19:43:40 + (UTC) Oleg Verych wrote:
>> > This doesn't work, use ifs instead. Updated.
>> > I have no idea what to do with generated sources and headers.
>> > One may be: check target `if_changed' to be %.c or %.h and let it be
>> > built.
>> 
>> Hi Oleg,
>> 
>> Yes, it works for me, with the exception of host-generated
>> files, as you mentioned.  I ran into those with:
>> IKCONFIG (the one that you mentioned), ATM_FORE200E firmware,
>> IEEE 1394 OUI database (which I sent a patch for -- it should
>> not be generated when the config option is not enabled),
>> RAID456 tables, VIDEO_LOGO files, and CRC32 table.
>
> I'm glad, that semi-working thing was helpful. But it's ugly hack.
>
> Idea is to substitute objects (*.o) with sparse output, thus targets
> like
> ,--
>|%.o : %.c
> +--
> will be updated and new check will pass them (force check may be applied).
> Also having results in files (even in so messy called *.o) is good for
> collecting and sorting errors. Headers will be generated as needed.
>
> Finally short statistics maybe printed in the end of the check:
> [(stat -c %s *.o > 0 | wc -l) / find --name *.o]
>   ^ with error file size > 0  / overall error files
>
> But implementing all this in non-hack way isn't easy. Maybe Sam will
> came back and will do it magically quickly. Until that, i'll try to
> fight with current makefiles myself.
>
>> Thanks for your time and effort.  Maybe Sam will have some ideas.
>
> I've found "sparse" and read some philosophy from README. Nice.
> Thanks you also !
> 

So far nothing has changed. Is it still worth to try to make more
comprehensive solution ?

p.s. Note. Please honor "Mail-Followup-To" header. Thanks.


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


2.6.20-rc7 (Re: [patch] kbuild: correctly skip tilded backups in localversion files)

2007-02-01 Thread Oleg Verych
kbuild: correctly skip tilded backups in localversion files

 Tildes as in path as in filenames are handled correctly now:
 only files, containing tilde '~', are backups, thus are not valid.

 [KJ]:
 Definition of `space' was removed, scripts/Kbuild.include has one.
 This definition was taken right from GNU make manual, while Kbuild's
 version is original.

Cc: Roman Zippel [EMAIL PROTECTED]
Cc: Bastian Blank [EMAIL PROTECTED]
Cc: Sam Ravnborg [EMAIL PROTECTED]
Signed-off-by: Oleg Verych [EMAIL PROTECTED]
---

 My using of the `sh' rides from willing to have more portable,
 understandable implementation (and due to GFDL make's docs ;)

Original report by Bastian Blank:

 The following patch fixes the problem that localversion files where
 ignored if the tree lives in a path which contains a ~. It changes the
 test to apply to the filename only.
 
 Debian allows versions which contains ~ in it. The upstream part of the
 version is in the directory name of the build tree and we got weird
 results because the localversion files was just got ignored in this
 case.

---
 linux-2.6.20-rc7/Makefile |   17 ++---
 1 file changed, 6 insertions(+), 11 deletions(-)

Index: kernel.org/linux-2.6.20-rc7/Makefile
===
--- kernel.org.orig/linux-2.6.20-rc7/Makefile   2007-02-01 16:20:54.214174250 
+0100
+++ kernel.org/linux-2.6.20-rc7/Makefile2007-02-01 16:21:40.649076250 
+0100
@@ -777,5 +777,5 @@ $(vmlinux-dirs): prepare scripts
 #  $(localver-full)
 #$(localver)
-#  localversion*   (all localversion* files)
+#  localversion*   (files without backups, containing '~')
 #  $(CONFIG_LOCALVERSION)  (from kernel config setting)
 #$(localver-auto)  (only if CONFIG_LOCALVERSION_AUTO is 
set)
@@ -788,15 +788,10 @@ $(vmlinux-dirs): prepare scripts
 # scripts/setlocalversion and add the appropriate checks as needed.
 
-nullstring :=
-space  := $(nullstring) # end of line
+pattern = .*/localversion[^~]*
+string  = $(shell cat /dev/null \
+  `find $(objtree) $(srctree) -maxdepth 1 -regex $(pattern) | sort`)
 
-___localver = $(objtree)/localversion* $(srctree)/localversion*
-__localver  = $(sort $(wildcard $(___localver)))
-# skip backup files (containing '~')
-_localver = $(foreach f, $(__localver), $(if $(findstring ~, $(f)),,$(f)))
-
-localver = $(subst $(space),, \
-  $(shell cat /dev/null $(_localver)) \
-  $(patsubst %,%,$(CONFIG_LOCALVERSION)))
+localver = $(subst $(space),, $(string) \
+ $(patsubst %,%,$(CONFIG_LOCALVERSION)))
 
 # If CONFIG_LOCALVERSION_AUTO is set scripts/setlocalversion is called
-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: PROBLEM: Crash on device_shutdown

2007-02-01 Thread Oleg Verych
 From: Julien RF
 Newsgroups: gmane.linux.kernel
 Subject: PROBLEM: Crash on device_shutdown
 Date: Mon, 29 Jan 2007 00:03:49 +0100
 Archived-At: http://permalink.gmane.org/gmane.linux.kernel/487140

Hallo, Julien.

Do you have such problem with more recent kernels, or mm one?

Also, if would be good to have at least some of the stack trace.

You can set up serial console for purpose of logging all information
to remote host.

 One line summary of the problem:
 Crash on device_shutdown


 Full description of the problem/report:
 When I shut down the system, I get a crash on the device_shutdown function 
 (called by kernel_shutdown_prepare).
 Since the bug happens when the system is almost shutted down, I can't get the 
 log...
 I partially copied it by hand, ask me if you need further details :
 Will now halt.
 BUG: unable to handle kernel NULL pointer dereference at virtual adress 
 0128
 ...
 EIP is at device_shutdown + 0x49/0x6c
 ...
 Process halt
 ...
 /etc/rc0.d/S90halt: line 21: 11198 Segmentation fault halt -d -f $shutdown 
 $poweroff $hddown

 Julien Richard-Foy

p.s. Please, care to honor Mail-Followup-To header information. Thanks.


-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [patch, rfc] kbuild: implement checksrc without building Cources...

2007-02-01 Thread Oleg Verych
 From: Oleg Verych
 Newsgroups: gmane.linux.kernel,gmane.linux.kbuild.devel
 Subject: Re:[patch, rfc] kbuild: implement checksrc without building 
 Cources...
 Date: Thu, 26 Oct 2006 15:07:20 +0200
 Archived-At: http://permalink.gmane.org/gmane.linux.kernel/460736

 On Tue, Oct 24, 2006 at 01:45:08PM -0700, Randy Dunlap wrote:
 On Tue, 24 Oct 2006 19:43:40 + (UTC) Oleg Verych wrote:
  This doesn't work, use ifs instead. Updated.
  I have no idea what to do with generated sources and headers.
  One may be: check target `if_changed' to be %.c or %.h and let it be
  built.
 
 Hi Oleg,
 
 Yes, it works for me, with the exception of host-generated
 files, as you mentioned.  I ran into those with:
 IKCONFIG (the one that you mentioned), ATM_FORE200E firmware,
 IEEE 1394 OUI database (which I sent a patch for -- it should
 not be generated when the config option is not enabled),
 RAID456 tables, VIDEO_LOGO files, and CRC32 table.

 I'm glad, that semi-working thing was helpful. But it's ugly hack.

 Idea is to substitute objects (*.o) with sparse output, thus targets
 like
 ,--
|%.o : %.c
 +--
 will be updated and new check will pass them (force check may be applied).
 Also having results in files (even in so messy called *.o) is good for
 collecting and sorting errors. Headers will be generated as needed.

 Finally short statistics maybe printed in the end of the check:
 [(stat -c %s *.o  0 | wc -l) / find --name *.o]
   ^ with error file size  0  / overall error files

 But implementing all this in non-hack way isn't easy. Maybe Sam will
 came back and will do it magically quickly. Until that, i'll try to
 fight with current makefiles myself.

 Thanks for your time and effort.  Maybe Sam will have some ideas.

 I've found sparse and read some philosophy from README. Nice.
 Thanks you also !
 

So far nothing has changed. Is it still worth to try to make more
comprehensive solution ?

p.s. Note. Please honor Mail-Followup-To header. Thanks.


-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [patch] kbuild: correctly skip tilded backups in localversion files

2007-01-31 Thread Oleg Verych
On Wed, Jan 31, 2007 at 03:56:51PM -0800, Andrew Morton wrote:
> On Wed, 31 Jan 2007 07:11:04 +
> Oleg Verych <[EMAIL PROTECTED]> wrote:
> 
> > kbuild: correctly skip tilded backups in localversion files
> 
> Does this patch replace Bastian's patch, below?

Along with "Message-ID: <[EMAIL PROTECTED]>" -- yes.

Note, that they also make a little bit of cleanup to top makefile's mess,
And, i think, have more elegant, portable, clean solution.

Roman commented on another my patch, saying, that tilde in the end isn't
the only way to name backups. Filename, containing '~' is a backup in the
sources, thus i'm proposing new patch.

Unfortunately still no more comments from anybody. Roman joined, but
seems busy now, to comment on such minor stuff.

Anyway, thanks.


> From: Bastian Blank <[EMAIL PROTECTED]>
> 
> Fix the problem that localversion files were ignored if the tree lives in
> a path which contains a ~.  It changes the test to apply to the filename
> only.
> 
> Debian allows versions which contains ~ in it.  The upstream part of the
> version is in the directory name of the build tree and we got weird results
> because the localversion files was just got ignored in this case.
> 
> Cc: Sam Ravnborg <[EMAIL PROTECTED]>
> Cc: Roman Zippel <[EMAIL PROTECTED]>
> Signed-off-by: Andrew Morton <[EMAIL PROTECTED]>
> ---
> 
>  Makefile |2 +-
>  1 files changed, 1 insertion(+), 1 deletion(-)
> 
> diff -puN 
> Makefile~kbuild-dont-ignore-localversion-files-if-the-path-includes-a Makefile
> --- a/Makefile~kbuild-dont-ignore-localversion-files-if-the-path-includes-a
> +++ a/Makefile
> @@ -793,7 +793,7 @@ space  := $(nullstring) # end of lin
>  ___localver = $(objtree)/localversion* $(srctree)/localversion*
>  __localver  = $(sort $(wildcard $(___localver)))
>  # skip backup files (containing '~')
> -_localver = $(foreach f, $(__localver), $(if $(findstring ~, $(f)),,$(f)))
> +_localver = $(foreach f, $(__localver), $(if $(findstring ~, $(notdir 
> $(f))),,$(f)))
>  
>  localver = $(subst $(space),, \
>  $(shell cat /dev/null $(_localver)) \
> _
> 
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[patch] update for (kbuild: correctly skip tilded backups in localversion files)

2007-01-31 Thread Oleg Verych
kbuild: finally correctly skip tilded backups in localversion files


Signed-off-by: Oleg Verych <[EMAIL PROTECTED]>
---

 Final addition. Why i want to maximize usage of shell, rather, than
 `make'? Just because i think, it's more portable, clear way.

 Thanks.

--- linux-2.6.20-rc6/Makefile~4tilde-backups~   2007-01-31 07:46:18.696404500 
+0100
+++ linux-2.6.20-rc6/Makefile   2007-01-31 10:19:18.406100500 +0100
@@ -788,10 +788,10 @@ $(vmlinux-dirs): prepare scripts
 # scripts/setlocalversion and add the appropriate checks as needed.
 
-localversion = $(objtree)/localversion $(srctree)/localversion
-ext_versions = $(objtree)/localversion[^~]* $(srctree)/localversion[!~]*
-versions = $(localversion) $(ext_versions)
-localver = $(subst $(space),, \
-  $(shell cat /dev/null $(sort $(wildcard $(versions \
-  $(patsubst "%",%,$(CONFIG_LOCALVERSION)))
+pattern = ".*/localversion[^~]*"
+string  = $(shell cat /dev/null \
+  `find $(objtree) $(srctree) -maxdepth 1 -regex $(pattern) | sort`)
+
+localver = $(subst $(space),, $(string) \
+ $(patsubst "%",%,$(CONFIG_LOCALVERSION)))
 
 # If CONFIG_LOCALVERSION_AUTO is set scripts/setlocalversion is called
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[patch] update for (kbuild: correctly skip tilded backups in localversion files)

2007-01-31 Thread Oleg Verych
kbuild: finally correctly skip tilded backups in localversion files


Signed-off-by: Oleg Verych [EMAIL PROTECTED]
---

 Final addition. Why i want to maximize usage of shell, rather, than
 `make'? Just because i think, it's more portable, clear way.

 Thanks.

--- linux-2.6.20-rc6/Makefile~4tilde-backups~   2007-01-31 07:46:18.696404500 
+0100
+++ linux-2.6.20-rc6/Makefile   2007-01-31 10:19:18.406100500 +0100
@@ -788,10 +788,10 @@ $(vmlinux-dirs): prepare scripts
 # scripts/setlocalversion and add the appropriate checks as needed.
 
-localversion = $(objtree)/localversion $(srctree)/localversion
-ext_versions = $(objtree)/localversion[^~]* $(srctree)/localversion[!~]*
-versions = $(localversion) $(ext_versions)
-localver = $(subst $(space),, \
-  $(shell cat /dev/null $(sort $(wildcard $(versions \
-  $(patsubst %,%,$(CONFIG_LOCALVERSION)))
+pattern = .*/localversion[^~]*
+string  = $(shell cat /dev/null \
+  `find $(objtree) $(srctree) -maxdepth 1 -regex $(pattern) | sort`)
+
+localver = $(subst $(space),, $(string) \
+ $(patsubst %,%,$(CONFIG_LOCALVERSION)))
 
 # If CONFIG_LOCALVERSION_AUTO is set scripts/setlocalversion is called
-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [patch] kbuild: correctly skip tilded backups in localversion files

2007-01-31 Thread Oleg Verych
On Wed, Jan 31, 2007 at 03:56:51PM -0800, Andrew Morton wrote:
 On Wed, 31 Jan 2007 07:11:04 +
 Oleg Verych [EMAIL PROTECTED] wrote:
 
  kbuild: correctly skip tilded backups in localversion files
 
 Does this patch replace Bastian's patch, below?

Along with Message-ID: [EMAIL PROTECTED] -- yes.

Note, that they also make a little bit of cleanup to top makefile's mess,
And, i think, have more elegant, portable, clean solution.

Roman commented on another my patch, saying, that tilde in the end isn't
the only way to name backups. Filename, containing '~' is a backup in the
sources, thus i'm proposing new patch.

Unfortunately still no more comments from anybody. Roman joined, but
seems busy now, to comment on such minor stuff.

Anyway, thanks.


 From: Bastian Blank [EMAIL PROTECTED]
 
 Fix the problem that localversion files were ignored if the tree lives in
 a path which contains a ~.  It changes the test to apply to the filename
 only.
 
 Debian allows versions which contains ~ in it.  The upstream part of the
 version is in the directory name of the build tree and we got weird results
 because the localversion files was just got ignored in this case.
 
 Cc: Sam Ravnborg [EMAIL PROTECTED]
 Cc: Roman Zippel [EMAIL PROTECTED]
 Signed-off-by: Andrew Morton [EMAIL PROTECTED]
 ---
 
  Makefile |2 +-
  1 files changed, 1 insertion(+), 1 deletion(-)
 
 diff -puN 
 Makefile~kbuild-dont-ignore-localversion-files-if-the-path-includes-a Makefile
 --- a/Makefile~kbuild-dont-ignore-localversion-files-if-the-path-includes-a
 +++ a/Makefile
 @@ -793,7 +793,7 @@ space  := $(nullstring) # end of lin
  ___localver = $(objtree)/localversion* $(srctree)/localversion*
  __localver  = $(sort $(wildcard $(___localver)))
  # skip backup files (containing '~')
 -_localver = $(foreach f, $(__localver), $(if $(findstring ~, $(f)),,$(f)))
 +_localver = $(foreach f, $(__localver), $(if $(findstring ~, $(notdir 
 $(f))),,$(f)))
  
  localver = $(subst $(space),, \
  $(shell cat /dev/null $(_localver)) \
 _
 
-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[patch] kbuild: correctly skip tilded backups in localversion files

2007-01-30 Thread Oleg Verych
kbuild: correctly skip tilded backups in localversion files

 Tildes as in path as in filenames are handled correctly now.

 Definition of `space' was removed, scripts/Kbuild.include has one.
 This definition was taken right from GNU make manual, while Kbuild's
 version is original.

Cc: Roman Zippel <[EMAIL PROTECTED]>
Cc: Bastian Blank <[EMAIL PROTECTED]>
Cc: Sam Ravnborg <[EMAIL PROTECTED]>
Signed-off-by: Oleg Verych <[EMAIL PROTECTED]>
---
Another try.

Original report and fix by Bastian Blank:

 The following patch fixes the problem that localversion files where
 ignored if the tree lives in a path which contains a ~. It changes the
 test to apply to the filename only.
 
 Debian allows versions which contains ~ in it. The upstream part of the
 version is in the directory name of the build tree and we got weird
 results because the localversion files was just got ignored in this
 case.

 Makefile |   15 +--
 1 file changed, 5 insertions(+), 10 deletions(-)

--- linux-2.6.20-rc6/Makefile~4tilde-backups~   2007-01-30 23:33:45.781462750 
+0100
+++ linux-2.6.20-rc6/Makefile   2007-01-31 07:46:18.696404500 +0100
@@ -777,5 +777,5 @@ $(vmlinux-dirs): prepare scripts
 #  $(localver-full)
 #$(localver)
-#  localversion*   (all localversion* files)
+#  localversion*   (files, without backups containing '~')
 #  $(CONFIG_LOCALVERSION)  (from kernel config setting)
 #$(localver-auto)  (only if CONFIG_LOCALVERSION_AUTO is 
set)
@@ -788,14 +788,9 @@ $(vmlinux-dirs): prepare scripts
 # scripts/setlocalversion and add the appropriate checks as needed.
 
-nullstring :=
-space  := $(nullstring) # end of line
-
-___localver = $(objtree)/localversion* $(srctree)/localversion*
-__localver  = $(sort $(wildcard $(___localver)))
-# skip backup files (containing '~')
-_localver = $(foreach f, $(__localver), $(if $(findstring ~, $(f)),,$(f)))
-
+localversion = $(objtree)/localversion $(srctree)/localversion
+ext_versions = $(objtree)/localversion[^~]* $(srctree)/localversion[!~]*
+versions = $(localversion) $(ext_versions)
 localver = $(subst $(space),, \
-  $(shell cat /dev/null $(_localver)) \
+  $(shell cat /dev/null $(sort $(wildcard $(versions \
   $(patsubst "%",%,$(CONFIG_LOCALVERSION)))
 
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[patch] kbuild: improving gcc option checking

2007-01-30 Thread Oleg Verych
kbuild: improving option checking, Kbuild.include cleanup

 GNU binutils, root users, tmpfiles, external modules ro builds must
 be fixed to do the right thing now.

Cc: Roman Zippel <[EMAIL PROTECTED]>
Cc: Sam Ravnborg <[EMAIL PROTECTED]>
Cc: Horst Schirmeier <[EMAIL PROTECTED]>
Cc: Jan Beulich <[EMAIL PROTECTED]>
Cc: Daniel Drake <[EMAIL PROTECTED]>
Cc: Andi Kleen <[EMAIL PROTECTED]>
Cc: Randy Dunlap <[EMAIL PROTECTED]>
Signed-off-by: Oleg Verych <[EMAIL PROTECTED]>
---

-- all checks by shell united in one macro -- checker-shell;
-- one disposable output sym. link to /dev/null per shell,
   thus no racing, `-Z' is removed;
-- modules' build output directory is used, if supplied;
-- every option checking function calls shell wrapper, acquires probe;
-- `echo -e' bashizm substituted (people with sh != bash have distinct
   CC options!);
-- some spelling and sense added to the comments;
-- small shuffle of whitespace.

Mostly all people, discussing this back in October are in the CC list.
Sam Ravnborg have not much time to reply. I've added Roman Zippel, as
a very kind reviewer and commiter of previous fix. Comments and
testing are appreciated. Thanks.

Note. `Mail-Followup-To' header is used to supply reply-to list.

-o--=O`C
 #oo'L O
<___=E M

--- linux-2.6.20-rc6/scripts/Kbuild.include~4-gcc-option-check  2007-01-12 
19:54:26.0 +0100
+++ linux-2.6.20-rc6/scripts/Kbuild.include 2007-01-31 05:56:58.942445500 
+0100
@@ -2,5 +2,5 @@
 # kbuild: Generic definitions
 
-# Convinient variables
+# Convenient constants
 comma   := ,
 squote  := '
@@ -57,38 +57,44 @@ endef
 # See documentation in Documentation/kbuild/makefiles.txt
 
-# output directory for tests below
-TMPOUT := $(if $(KBUILD_EXTMOD),$(firstword $(KBUILD_EXTMOD))/)
+# checker-shell
+# Usage: option = $(call checker-shell, $(CC)...-o $$OUT, option-ok, otherwise)
+# Exit code chooses option. $$OUT is safe location for needless output.
+define checker-shell
+  $(shell set -e; \
+DIR=$(KBUILD_EXTMOD); \
+cd $${DIR:-$(objtree)}; \
+OUT=$$PWD/..null; \
+\
+ln -s /dev/null $$OUT; \
+if $(1) >/dev/null 2>&1; \
+  then echo "$(2)"; \
+  else echo "$(3)"; \
+fi; \
+rm -f $$OUT)
+endef
 
 # as-option
 # Usage: cflags-y += $(call as-option, -Wa$(comma)-isa=foo,)
-
-as-option = $(shell if $(CC) $(CFLAGS) $(1) -Wa,-Z -c -o /dev/null \
--xassembler /dev/null > /dev/null 2>&1; then echo "$(1)"; \
-else echo "$(2)"; fi ;)
+as-option = $(call checker-shell, \
+   $(CC) $(CFLAGS) $(1) -c -xassembler /dev/null -o $$OUT, $(1), $(2))
 
 # as-instr
 # Usage: cflags-y += $(call as-instr, instr, option1, option2)
-
-as-instr = $(shell if echo -e "$(1)" | \
- $(CC) $(AFLAGS) -c -xassembler - \
-   -o $(TMPOUT)astest.out > /dev/null 2>&1; \
-  then rm $(TMPOUT)astest.out; echo "$(2)"; \
-  else echo "$(3)"; fi)
+as-instr = $(call checker-shell, \
+   printf "$(1)" | $(CC) $(AFLAGS) -c -xassembler -o $$OUT -, $(2), $(3))
 
 # cc-option
 # Usage: cflags-y += $(call cc-option, -march=winchip-c6, -march=i586)
-
-cc-option = $(shell if $(CC) $(CFLAGS) $(1) -S -o /dev/null -xc /dev/null \
- > /dev/null 2>&1; then echo "$(1)"; else echo "$(2)"; fi ;)
+cc-option = $(call checker-shell, \
+   $(CC) $(CFLAGS) $(if $(3),$(3),$(1)) -S -xc /dev/null -o $$OUT, $(1), $(2))
 
 # cc-option-yn
 # Usage: flag := $(call cc-option-yn, -march=winchip-c6)
-cc-option-yn = $(shell if $(CC) $(CFLAGS) $(1) -S -o /dev/null -xc /dev/null \
-> /dev/null 2>&1; then echo "y"; else echo "n"; fi;)
+cc-option-yn = $(call cc-option, "y", "n", $(1))
 
 # cc-option-align
 # Prefix align with either -falign or -malign
 cc-option-align = $(subst -functions=0,,\
-   $(call cc-option,-falign-functions=0,-malign-functions=0))
+   $(call cc-option,-falign-functions=0,-malign-functions=0))
 
 # cc-version
@@ -98,15 +104,13 @@ cc-version = $(shell $(CONFIG_SHELL) $(s
 # cc-ifversion
 # Usage:  EXTRA_CFLAGS += $(call cc-ifversion, -lt, 0402, -O1)
-cc-ifversion = $(shell if [ $(call cc-version, $(CC)) $(1) $(2) ]; then \
-   echo $(3); fi;)
+cc-ifversion = $(shell [ $(call cc-version, $(CC)) $(1) $(2) ] && echo $(3))
 
 # ld-option
 # Usage: ldflags += $(call ld-option, -Wl$(comma)--hash-style=both)
-ld-option = $(shell if $(CC) $(1) -nostdlib -xc /dev/null \
--o $(TMPOUT)ldtest.out > /dev/null 2>&1; \
- then rm $(TMPOUT)ldtest.out; echo "$(1)"; \
- else echo "$(2)"; fi)
+ld-option = $(call checker-shell, \
+   $(CC) $(1) -nostdlib -xc /dev/null -o $$OUT, $(1), $(2))
+

[patch] some scripts: replace gawk, head, bc with shell, update

2007-01-30 Thread Oleg Verych
scripts: replace gawk, head, bc with shell, update

  Replacing overhead of using some (external) programs
  instead of good old `sh'.

Cc: Roman Zippel <[EMAIL PROTECTED]>
Cc: Sam Ravnborg <[EMAIL PROTECTED]>
Cc: William Stearns <[EMAIL PROTECTED]>
Cc: Martin Schlemmer <[EMAIL PROTECTED]>
Signed-off-by: Oleg Verych <[EMAIL PROTECTED]>
---
-o--=O`C
 #oo'L O
<___=E M

 scripts/gen_initramfs_list.sh | 44 +-
 scripts/makelst   | 34 
 2 files changed, 40 insertions(+), 38 deletions(-)

--- linux-2.6.20-rc6/scripts/makelst~4-update-gawk-bc-head-rip  2007-01-12 
19:54:26.0 +0100
+++ linux-2.6.20-rc6/scripts/makelst2007-01-31 03:02:53.433642000 +0100
@@ -1,31 +1,31 @@
-#!/bin/bash
+#!/bin/sh
 # A script to dump mixed source code & assembly
 # with correct relocations from System.map
-# Requires the following lines in Rules.make.
-# Author(s): DJ Barrow ([EMAIL PROTECTED],[EMAIL PROTECTED]) 
-#William Stearns <[EMAIL PROTECTED]>
+# Requires the following lines in makefile:
 #%.lst: %.c
 #  $(CC) $(CFLAGS) $(EXTRA_CFLAGS) $(CFLAGS_$@) -g -c -o $*.o $<
-#  $(TOPDIR)/scripts/makelst $*.o $(TOPDIR)/System.map $(OBJDUMP)
+#  $(srctree)/scripts/makelst $*.o $(objtree)/System.map $(OBJDUMP)
 #
-#Copyright (C) 2000 IBM Corporation
-#Author(s): DJ Barrow ([EMAIL PROTECTED],[EMAIL PROTECTED]) 
+# Copyright (C) 2000 IBM Corporation
+# Author(s): DJ Barrow ([EMAIL PROTECTED],[EMAIL PROTECTED])
+#William Stearns <[EMAIL PROTECTED]>
 #
 
-t1=`$3 --syms $1 | grep .text | grep " F " | head -n 1`
+# awk style field access
+field() {
+  shift $1 ; echo $1
+}
+
+t1=`$3 --syms $1 | grep .text | grep -m1 " F "`
 if [ -n "$t1" ]; then
-  t2=`echo $t1 | gawk '{ print $6 }'`
+  t2=`field 6 $t1`
   if [ ! -r $2 ]; then
 echo "No System.map" >&2
-t7=0
   else
 t3=`grep $t2 $2`
-t4=`echo $t3 | gawk '{ print $1 }'`
-t5=`echo $t1 | gawk '{ print $1 }'`
-t6=`echo $t4 - $t5 | tr a-f A-F`
-t7=`( echo  ibase=16 ; echo $t6 ) | bc`
+t4=`field 1 $t3`
+t5=`field 1 $t1`
+t6=`printf "%lu" $((0x$t4 - 0x$t5))`
   fi
-else
-  t7=0
 fi
-$3 -r --source --adjust-vma=$t7 $1
+$3 -r --source --adjust-vma=${t6:-0} $1


--- linux-2.6.20-rc6/scripts/gen_initramfs_list.sh~4gawk-rip2007-01-12 
19:54:26.0 +0100
+++ linux-2.6.20-rc6/scripts/gen_initramfs_list.sh  2007-01-31 
03:02:25.847918000 +0100
@@ -1,5 +1,5 @@
 #!/bin/bash
 # Copyright (C) Martin Schlemmer <[EMAIL PROTECTED]>
-# Copyright (c) 2006   Sam Ravnborg <[EMAIL PROTECTED]>
+# Copyright (C) 2006 Sam Ravnborg <[EMAIL PROTECTED]>
 #
 # Released under the terms of the GNU GPL
@@ -18,13 +18,13 @@ Usage:
 $0 [-o ] [-u ] [-g ] {-d | } ...
-o   Create gzipped initramfs file named  using
-  gen_init_cpio and gzip
+  gen_init_cpio and gzip
-uUser ID to map to user ID 0 (root).
-   is only meaningful if 
-  is a directory.
+   is only meaningful if 
+  is a directory.
-gGroup ID to map to group ID 0 (root).
-   is only meaningful if 
-  is a directory.
+   is only meaningful if 
+  is a directory.
  File list or directory for cpio archive.
-  If  is a .cpio file it will be used
+  If  is a .cpio file it will be used
   as direct input to initramfs.
-d Output the default cpio list.
@@ -37,4 +37,11 @@ EOF
 }
 
+# awk style field access
+# $1 - field number; rest is argument string
+field() {
+   shift $1
+   echo $1
+}
+
 list_default_initramfs() {
# echo usr/kinit/kinit
@@ -120,23 +127,18 @@ parse() {
;;
"nod")
-   local dev_type=
-   local maj=$(LC_ALL=C ls -l "${location}" | \
-   gawk '{sub(/,/, "", $5); print $5}')
-   local min=$(LC_ALL=C ls -l "${location}" | \
-   gawk '{print $6}')
-
-   if [ -b "${location}" ]; then
-   dev_type="b"
-   else
-   dev_type="c"
-   fi
-   str="${ftype} ${name} ${str} ${dev_type} ${maj} ${min}"
+   local dev=`LC_ALL=C ls -l "${location}"`
+   local maj=`field 5 ${dev}`
+   local min=`field 6 ${dev}`
+   maj=${maj%,}
+
+   

Re: [Ksummit-2007-discuss] 2007 Linux Kernel Summit

2007-01-30 Thread Oleg Verych
> From: "Dave Airlie"
> Newsgroups: gmane.linux.kernel
> Subject: Re: [Ksummit-2007-discuss] 2007 Linux Kernel Summit
> Date: Tue, 30 Jan 2007 20:44:49 +1100
[]
>> Rather, than "business class ;-)", i whould like to see comments about
>> good quality video coverage of the KS, which (KS) is that, as you
>> described here:
>>
>
> KS isn't a conference that lends itself to recording ppl a lot of
> people seem to think it is like a mini-OLS or mini-LCA, it is more
> discussion based (or at least should be...), it isn't held in a
> lecture theatre, people aren't meant to do slides beyond talking
> points

1. To setup quality coverage, is hard and (i think) expensive (news media
company needed). Hackers with webcams, where nothing can be seen and
heard, isn't that i expect in the 21th century, the century of the
telecommunication.

2. It's believed to be "high bandwidth" discussion, and i think it's much
better, than slides, talk, (?wtf was in)Q/(here's your)A. Because this
may obligate you to think fast, to think what you (invited person) say,
and say what you think.

3. As for everyone, who listen English speech only in Hollywood
movies (yea, that's me, and i'm writing this to you now ;), such kind of
conversation with fights, debates, etc. is a worth material. (I don't
want to compare this to _some_ scientific confs, where people reading
their mouney-has-been-spent-OK reports).

> It mainly involves ppl sitting around tables talking about stuff with
> some mics... I think we could hold KS as an open non-invite event if
> it wasn't attached to a major conference and was held somewhere no-one
> wants to go :-)

4. If there will be good ideas and real items for TODOs, technical
details, fun, etc. why not to share it? Do you have something to hide, or
you think, after seeng that, some employer will shrink somebody's travel
budget (:?

I think Linux Kernel has just became mature, as its long-time developers
have. And i think, mini/maxi conferences must become more mature ether.

And donig paper work here, like slides, abstracts, articles, isn't a
first requirement (again, after the end of the Cold War, cheap PC,
Microsoft Word in the Windows, the most scientific work had finallt
became A Paper Work (patent pending)). AFAIK Linus doen't like this
either, rather than to (verbally) discuss things.

Maybe [1] isn't that companies, like Red Hat, will like to do,
because, this is part of their paid business, but [2]-[4] may have
more weight against this.

> Dave.



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


hunting on open source developers (Re: [Ksummit-2006-discuss] 2007 Linux Kernel Summit)

2007-01-30 Thread Oleg Verych
> From: Theodore Tso
> Newsgroups: gmane.linux.kernel
> Subject: Re: [Ksummit-2006-discuss] 2007 Linux Kernel Summit
> Date: Thu, 25 Jan 2007 22:28:49 -0500
[]
> (Unless perhaps in some conspiracy theory scenario where Microsoft pays
> $$$ to some VC company to sponsor an event in Moskow, and then
> contracts out to the KGB to fill the meeting room with an aerosolized
> powder of Polonium 210 to kill off all of the top Linux developers in
> one fell swoop.  But that sort of thing only happens in spy novels.
> :-)

BTW, after some information was published here



i don't think it's funny or "only happens in spy novels"...



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [Ksummit-2007-discuss] 2007 Linux Kernel Summit

2007-01-30 Thread Oleg Verych
> From: Theodore Tso
> Newsgroups: gmane.linux.kernel
> Subject: Re: [Ksummit-2006-discuss] 2007 Linux Kernel Summit
> Date: Thu, 25 Jan 2007 22:28:49 -0500

[]
> I did give you a response.  Find a way to pay for 80+ kernel summit
> invitees to travel to India (preferably in business class :-), and
> we'll talk.  That's not realistic?  Well, then perhaps having the
> concept of holding Kernel Summit in India is not realistic.

Rather, than "business class ;-)", i whould like to see comments about
good quality video coverage of the KS, which (KS) is that, as you
described here:

> As Dirk has pointed out, the Kernel Summit is a little unusual
> compared to events such as FOSDEM or FISL, where there are 4000-5000
> attendees, and the emphasis is on the power of a large number of
> people in the OSS community.  The Kernel Summit is a very different
> event, in that it is by-invitation with less than 100 people.  The
> whole point is to get the top contributors together to be able to talk
> amongst themselves in a high bandwidth environment.  You can't do that
> amongst a crowd of 800, never mind 2000 or 4000.

Even if dot.coms days are over and money aren't falling from skies
(growing on trees), this would be the best thing to do in first place.

Even for your memory, IMHO, as have read this thread below.

I wish you will care about this, wherever you will meet this time.

Thanks.



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [Ksummit-2007-discuss] 2007 Linux Kernel Summit

2007-01-30 Thread Oleg Verych
 From: Theodore Tso
 Newsgroups: gmane.linux.kernel
 Subject: Re: [Ksummit-2006-discuss] 2007 Linux Kernel Summit
 Date: Thu, 25 Jan 2007 22:28:49 -0500

[]
 I did give you a response.  Find a way to pay for 80+ kernel summit
 invitees to travel to India (preferably in business class :-), and
 we'll talk.  That's not realistic?  Well, then perhaps having the
 concept of holding Kernel Summit in India is not realistic.

Rather, than business class ;-), i whould like to see comments about
good quality video coverage of the KS, which (KS) is that, as you
described here:

 As Dirk has pointed out, the Kernel Summit is a little unusual
 compared to events such as FOSDEM or FISL, where there are 4000-5000
 attendees, and the emphasis is on the power of a large number of
 people in the OSS community.  The Kernel Summit is a very different
 event, in that it is by-invitation with less than 100 people.  The
 whole point is to get the top contributors together to be able to talk
 amongst themselves in a high bandwidth environment.  You can't do that
 amongst a crowd of 800, never mind 2000 or 4000.

Even if dot.coms days are over and money aren't falling from skies
(growing on trees), this would be the best thing to do in first place.

Even for your memory, IMHO, as have read this thread below.

I wish you will care about this, wherever you will meet this time.

Thanks.



-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


hunting on open source developers (Re: [Ksummit-2006-discuss] 2007 Linux Kernel Summit)

2007-01-30 Thread Oleg Verych
 From: Theodore Tso
 Newsgroups: gmane.linux.kernel
 Subject: Re: [Ksummit-2006-discuss] 2007 Linux Kernel Summit
 Date: Thu, 25 Jan 2007 22:28:49 -0500
[]
 (Unless perhaps in some conspiracy theory scenario where Microsoft pays
 $$$ to some VC company to sponsor an event in Moskow, and then
 contracts out to the KGB to fill the meeting room with an aerosolized
 powder of Polonium 210 to kill off all of the top Linux developers in
 one fell swoop.  But that sort of thing only happens in spy novels.
 :-)

BTW, after some information was published here

http://www.iowaconsumercase.org/

i don't think it's funny or only happens in spy novels...



-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [Ksummit-2007-discuss] 2007 Linux Kernel Summit

2007-01-30 Thread Oleg Verych
 From: Dave Airlie
 Newsgroups: gmane.linux.kernel
 Subject: Re: [Ksummit-2007-discuss] 2007 Linux Kernel Summit
 Date: Tue, 30 Jan 2007 20:44:49 +1100
[]
 Rather, than business class ;-), i whould like to see comments about
 good quality video coverage of the KS, which (KS) is that, as you
 described here:


 KS isn't a conference that lends itself to recording ppl a lot of
 people seem to think it is like a mini-OLS or mini-LCA, it is more
 discussion based (or at least should be...), it isn't held in a
 lecture theatre, people aren't meant to do slides beyond talking
 points

1. To setup quality coverage, is hard and (i think) expensive (news media
company needed). Hackers with webcams, where nothing can be seen and
heard, isn't that i expect in the 21th century, the century of the
telecommunication.

2. It's believed to be high bandwidth discussion, and i think it's much
better, than slides, talk, (?wtf was in)Q/(here's your)A. Because this
may obligate you to think fast, to think what you (invited person) say,
and say what you think.

3. As for everyone, who listen English speech only in Hollywood
movies (yea, that's me, and i'm writing this to you now ;), such kind of
conversation with fights, debates, etc. is a worth material. (I don't
want to compare this to _some_ scientific confs, where people reading
their mouney-has-been-spent-OK reports).

 It mainly involves ppl sitting around tables talking about stuff with
 some mics... I think we could hold KS as an open non-invite event if
 it wasn't attached to a major conference and was held somewhere no-one
 wants to go :-)

4. If there will be good ideas and real items for TODOs, technical
details, fun, etc. why not to share it? Do you have something to hide, or
you think, after seeng that, some employer will shrink somebody's travel
budget (:?

I think Linux Kernel has just became mature, as its long-time developers
have. And i think, mini/maxi conferences must become more mature ether.

And donig paper work here, like slides, abstracts, articles, isn't a
first requirement (again, after the end of the Cold War, cheap PC,
Microsoft Word in the Windows, the most scientific work had finallt
became A Paper Work (patent pending)). AFAIK Linus doen't like this
either, rather than to (verbally) discuss things.

Maybe [1] isn't that companies, like Red Hat, will like to do,
because, this is part of their paid business, but [2]-[4] may have
more weight against this.

 Dave.



-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[patch] some scripts: replace gawk, head, bc with shell, update

2007-01-30 Thread Oleg Verych
scripts: replace gawk, head, bc with shell, update

  Replacing overhead of using some (external) programs
  instead of good old `sh'.

Cc: Roman Zippel [EMAIL PROTECTED]
Cc: Sam Ravnborg [EMAIL PROTECTED]
Cc: William Stearns [EMAIL PROTECTED]
Cc: Martin Schlemmer [EMAIL PROTECTED]
Signed-off-by: Oleg Verych [EMAIL PROTECTED]
---
-o--=O`C
 #oo'L O
___=E M

 scripts/gen_initramfs_list.sh | 44 +-
 scripts/makelst   | 34 
 2 files changed, 40 insertions(+), 38 deletions(-)

--- linux-2.6.20-rc6/scripts/makelst~4-update-gawk-bc-head-rip  2007-01-12 
19:54:26.0 +0100
+++ linux-2.6.20-rc6/scripts/makelst2007-01-31 03:02:53.433642000 +0100
@@ -1,31 +1,31 @@
-#!/bin/bash
+#!/bin/sh
 # A script to dump mixed source code  assembly
 # with correct relocations from System.map
-# Requires the following lines in Rules.make.
-# Author(s): DJ Barrow ([EMAIL PROTECTED],[EMAIL PROTECTED]) 
-#William Stearns [EMAIL PROTECTED]
+# Requires the following lines in makefile:
 #%.lst: %.c
 #  $(CC) $(CFLAGS) $(EXTRA_CFLAGS) $(CFLAGS_$@) -g -c -o $*.o $
-#  $(TOPDIR)/scripts/makelst $*.o $(TOPDIR)/System.map $(OBJDUMP)
+#  $(srctree)/scripts/makelst $*.o $(objtree)/System.map $(OBJDUMP)
 #
-#Copyright (C) 2000 IBM Corporation
-#Author(s): DJ Barrow ([EMAIL PROTECTED],[EMAIL PROTECTED]) 
+# Copyright (C) 2000 IBM Corporation
+# Author(s): DJ Barrow ([EMAIL PROTECTED],[EMAIL PROTECTED])
+#William Stearns [EMAIL PROTECTED]
 #
 
-t1=`$3 --syms $1 | grep .text | grep  F  | head -n 1`
+# awk style field access
+field() {
+  shift $1 ; echo $1
+}
+
+t1=`$3 --syms $1 | grep .text | grep -m1  F `
 if [ -n $t1 ]; then
-  t2=`echo $t1 | gawk '{ print $6 }'`
+  t2=`field 6 $t1`
   if [ ! -r $2 ]; then
 echo No System.map 2
-t7=0
   else
 t3=`grep $t2 $2`
-t4=`echo $t3 | gawk '{ print $1 }'`
-t5=`echo $t1 | gawk '{ print $1 }'`
-t6=`echo $t4 - $t5 | tr a-f A-F`
-t7=`( echo  ibase=16 ; echo $t6 ) | bc`
+t4=`field 1 $t3`
+t5=`field 1 $t1`
+t6=`printf %lu $((0x$t4 - 0x$t5))`
   fi
-else
-  t7=0
 fi
-$3 -r --source --adjust-vma=$t7 $1
+$3 -r --source --adjust-vma=${t6:-0} $1


--- linux-2.6.20-rc6/scripts/gen_initramfs_list.sh~4gawk-rip2007-01-12 
19:54:26.0 +0100
+++ linux-2.6.20-rc6/scripts/gen_initramfs_list.sh  2007-01-31 
03:02:25.847918000 +0100
@@ -1,5 +1,5 @@
 #!/bin/bash
 # Copyright (C) Martin Schlemmer [EMAIL PROTECTED]
-# Copyright (c) 2006   Sam Ravnborg [EMAIL PROTECTED]
+# Copyright (C) 2006 Sam Ravnborg [EMAIL PROTECTED]
 #
 # Released under the terms of the GNU GPL
@@ -18,13 +18,13 @@ Usage:
 $0 [-o file] [-u uid] [-g gid] {-d | cpio_source} ...
-o file  Create gzipped initramfs file named file using
-  gen_init_cpio and gzip
+  gen_init_cpio and gzip
-u uid   User ID to map to user ID 0 (root).
-  uid is only meaningful if cpio_source
-  is a directory.
+  uid is only meaningful if cpio_source
+  is a directory.
-g gid   Group ID to map to group ID 0 (root).
-  gid is only meaningful if cpio_source
-  is a directory.
+  gid is only meaningful if cpio_source
+  is a directory.
cpio_source  File list or directory for cpio archive.
-  If cpio_source is a .cpio file it will be used
+  If cpio_source is a .cpio file it will be used
   as direct input to initramfs.
-d Output the default cpio list.
@@ -37,4 +37,11 @@ EOF
 }
 
+# awk style field access
+# $1 - field number; rest is argument string
+field() {
+   shift $1
+   echo $1
+}
+
 list_default_initramfs() {
# echo usr/kinit/kinit
@@ -120,23 +127,18 @@ parse() {
;;
nod)
-   local dev_type=
-   local maj=$(LC_ALL=C ls -l ${location} | \
-   gawk '{sub(/,/, , $5); print $5}')
-   local min=$(LC_ALL=C ls -l ${location} | \
-   gawk '{print $6}')
-
-   if [ -b ${location} ]; then
-   dev_type=b
-   else
-   dev_type=c
-   fi
-   str=${ftype} ${name} ${str} ${dev_type} ${maj} ${min}
+   local dev=`LC_ALL=C ls -l ${location}`
+   local maj=`field 5 ${dev}`
+   local min=`field 6 ${dev}`
+   maj=${maj%,}
+
+   [ -b ${location} ]  dev=b || dev=c
+
+   str=${ftype} ${name} ${str} ${dev} ${maj} ${min

[patch] kbuild: improving gcc option checking

2007-01-30 Thread Oleg Verych
kbuild: improving option checking, Kbuild.include cleanup

 GNU binutils, root users, tmpfiles, external modules ro builds must
 be fixed to do the right thing now.

Cc: Roman Zippel [EMAIL PROTECTED]
Cc: Sam Ravnborg [EMAIL PROTECTED]
Cc: Horst Schirmeier [EMAIL PROTECTED]
Cc: Jan Beulich [EMAIL PROTECTED]
Cc: Daniel Drake [EMAIL PROTECTED]
Cc: Andi Kleen [EMAIL PROTECTED]
Cc: Randy Dunlap [EMAIL PROTECTED]
Signed-off-by: Oleg Verych [EMAIL PROTECTED]
---

-- all checks by shell united in one macro -- checker-shell;
-- one disposable output sym. link to /dev/null per shell,
   thus no racing, `-Z' is removed;
-- modules' build output directory is used, if supplied;
-- every option checking function calls shell wrapper, acquires probe;
-- `echo -e' bashizm substituted (people with sh != bash have distinct
   CC options!);
-- some spelling and sense added to the comments;
-- small shuffle of whitespace.

Mostly all people, discussing this back in October are in the CC list.
Sam Ravnborg have not much time to reply. I've added Roman Zippel, as
a very kind reviewer and commiter of previous fix. Comments and
testing are appreciated. Thanks.

Note. `Mail-Followup-To' header is used to supply reply-to list.

-o--=O`C
 #oo'L O
___=E M

--- linux-2.6.20-rc6/scripts/Kbuild.include~4-gcc-option-check  2007-01-12 
19:54:26.0 +0100
+++ linux-2.6.20-rc6/scripts/Kbuild.include 2007-01-31 05:56:58.942445500 
+0100
@@ -2,5 +2,5 @@
 # kbuild: Generic definitions
 
-# Convinient variables
+# Convenient constants
 comma   := ,
 squote  := '
@@ -57,38 +57,44 @@ endef
 # See documentation in Documentation/kbuild/makefiles.txt
 
-# output directory for tests below
-TMPOUT := $(if $(KBUILD_EXTMOD),$(firstword $(KBUILD_EXTMOD))/)
+# checker-shell
+# Usage: option = $(call checker-shell, $(CC)...-o $$OUT, option-ok, otherwise)
+# Exit code chooses option. $$OUT is safe location for needless output.
+define checker-shell
+  $(shell set -e; \
+DIR=$(KBUILD_EXTMOD); \
+cd $${DIR:-$(objtree)}; \
+OUT=$$PWD/..null; \
+\
+ln -s /dev/null $$OUT; \
+if $(1) /dev/null 21; \
+  then echo $(2); \
+  else echo $(3); \
+fi; \
+rm -f $$OUT)
+endef
 
 # as-option
 # Usage: cflags-y += $(call as-option, -Wa$(comma)-isa=foo,)
-
-as-option = $(shell if $(CC) $(CFLAGS) $(1) -Wa,-Z -c -o /dev/null \
--xassembler /dev/null  /dev/null 21; then echo $(1); \
-else echo $(2); fi ;)
+as-option = $(call checker-shell, \
+   $(CC) $(CFLAGS) $(1) -c -xassembler /dev/null -o $$OUT, $(1), $(2))
 
 # as-instr
 # Usage: cflags-y += $(call as-instr, instr, option1, option2)
-
-as-instr = $(shell if echo -e $(1) | \
- $(CC) $(AFLAGS) -c -xassembler - \
-   -o $(TMPOUT)astest.out  /dev/null 21; \
-  then rm $(TMPOUT)astest.out; echo $(2); \
-  else echo $(3); fi)
+as-instr = $(call checker-shell, \
+   printf $(1) | $(CC) $(AFLAGS) -c -xassembler -o $$OUT -, $(2), $(3))
 
 # cc-option
 # Usage: cflags-y += $(call cc-option, -march=winchip-c6, -march=i586)
-
-cc-option = $(shell if $(CC) $(CFLAGS) $(1) -S -o /dev/null -xc /dev/null \
-  /dev/null 21; then echo $(1); else echo $(2); fi ;)
+cc-option = $(call checker-shell, \
+   $(CC) $(CFLAGS) $(if $(3),$(3),$(1)) -S -xc /dev/null -o $$OUT, $(1), $(2))
 
 # cc-option-yn
 # Usage: flag := $(call cc-option-yn, -march=winchip-c6)
-cc-option-yn = $(shell if $(CC) $(CFLAGS) $(1) -S -o /dev/null -xc /dev/null \
- /dev/null 21; then echo y; else echo n; fi;)
+cc-option-yn = $(call cc-option, y, n, $(1))
 
 # cc-option-align
 # Prefix align with either -falign or -malign
 cc-option-align = $(subst -functions=0,,\
-   $(call cc-option,-falign-functions=0,-malign-functions=0))
+   $(call cc-option,-falign-functions=0,-malign-functions=0))
 
 # cc-version
@@ -98,15 +104,13 @@ cc-version = $(shell $(CONFIG_SHELL) $(s
 # cc-ifversion
 # Usage:  EXTRA_CFLAGS += $(call cc-ifversion, -lt, 0402, -O1)
-cc-ifversion = $(shell if [ $(call cc-version, $(CC)) $(1) $(2) ]; then \
-   echo $(3); fi;)
+cc-ifversion = $(shell [ $(call cc-version, $(CC)) $(1) $(2) ]  echo $(3))
 
 # ld-option
 # Usage: ldflags += $(call ld-option, -Wl$(comma)--hash-style=both)
-ld-option = $(shell if $(CC) $(1) -nostdlib -xc /dev/null \
--o $(TMPOUT)ldtest.out  /dev/null 21; \
- then rm $(TMPOUT)ldtest.out; echo $(1); \
- else echo $(2); fi)
+ld-option = $(call checker-shell, \
+   $(CC) $(1) -nostdlib -xc /dev/null -o $$OUT, $(1), $(2))
+
+##
 
-###
 # Shorthand for $(Q)$(MAKE) -f scripts/Makefile.build obj=
 # Usage:
@@ -114,17 +118,26 @@ ld-option = $(shell if $(CC) $(1) -nostd
 build := -f $(if $(KBUILD_SRC),$(srctree)/)scripts/Makefile.build obj
 
-# Prefix -I with $(srctree) if it is not an absolute path
-addtree = $(if $(filter-out -I/%,$(1)),$(patsubst -I%,-I$(srctree)/%,$(1

[patch] kbuild: correctly skip tilded backups in localversion files

2007-01-30 Thread Oleg Verych
kbuild: correctly skip tilded backups in localversion files

 Tildes as in path as in filenames are handled correctly now.

 Definition of `space' was removed, scripts/Kbuild.include has one.
 This definition was taken right from GNU make manual, while Kbuild's
 version is original.

Cc: Roman Zippel [EMAIL PROTECTED]
Cc: Bastian Blank [EMAIL PROTECTED]
Cc: Sam Ravnborg [EMAIL PROTECTED]
Signed-off-by: Oleg Verych [EMAIL PROTECTED]
---
Another try.

Original report and fix by Bastian Blank:

 The following patch fixes the problem that localversion files where
 ignored if the tree lives in a path which contains a ~. It changes the
 test to apply to the filename only.
 
 Debian allows versions which contains ~ in it. The upstream part of the
 version is in the directory name of the build tree and we got weird
 results because the localversion files was just got ignored in this
 case.

 Makefile |   15 +--
 1 file changed, 5 insertions(+), 10 deletions(-)

--- linux-2.6.20-rc6/Makefile~4tilde-backups~   2007-01-30 23:33:45.781462750 
+0100
+++ linux-2.6.20-rc6/Makefile   2007-01-31 07:46:18.696404500 +0100
@@ -777,5 +777,5 @@ $(vmlinux-dirs): prepare scripts
 #  $(localver-full)
 #$(localver)
-#  localversion*   (all localversion* files)
+#  localversion*   (files, without backups containing '~')
 #  $(CONFIG_LOCALVERSION)  (from kernel config setting)
 #$(localver-auto)  (only if CONFIG_LOCALVERSION_AUTO is 
set)
@@ -788,14 +788,9 @@ $(vmlinux-dirs): prepare scripts
 # scripts/setlocalversion and add the appropriate checks as needed.
 
-nullstring :=
-space  := $(nullstring) # end of line
-
-___localver = $(objtree)/localversion* $(srctree)/localversion*
-__localver  = $(sort $(wildcard $(___localver)))
-# skip backup files (containing '~')
-_localver = $(foreach f, $(__localver), $(if $(findstring ~, $(f)),,$(f)))
-
+localversion = $(objtree)/localversion $(srctree)/localversion
+ext_versions = $(objtree)/localversion[^~]* $(srctree)/localversion[!~]*
+versions = $(localversion) $(ext_versions)
 localver = $(subst $(space),, \
-  $(shell cat /dev/null $(_localver)) \
+  $(shell cat /dev/null $(sort $(wildcard $(versions \
   $(patsubst %,%,$(CONFIG_LOCALVERSION)))
 
-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH] `make help' in build tree doesn't show headers_* targets

2007-01-29 Thread Oleg Verych

> From: Geert Uytterhoeven
> Newsgroups: gmane.linux.kernel
> Subject: [PATCH] `make help' in build tree doesn't show headers_* targets
> Date: Mon, 29 Jan 2007 13:47:01 +0100 (CET)

> `make help' in the build tree doesn't show the help texts about the
> `headers_install' and `headers_check' targets because it looks for
> include/asm-$(ARCH)/Kbuild in the wrong place.
> Add the missing `$(srctree)' prefixes to fix this.
> Also move the printing of the default install path for the headers inside the
> `if/fi', where it belongs.
>
> Signed-off-by: Geert Uytterhoeven <[EMAIL PROTECTED]>
> ---
>  Makefile |6 +++---
>  1 files changed, 3 insertions(+), 3 deletions(-)

Acked-by: Oleg Verych <[EMAIL PROTECTED]>


> --- ps3-linux-src-2.6.20-rc6.orig/Makefile
> +++ ps3-linux-src-2.6.20-rc6/Makefile
> @@ -1116,15 +1116,15 @@ help:
>   @echo  '  cscope  - Generate cscope index'
>   @echo  '  kernelrelease   - Output the release version string'
>   @echo  '  kernelversion   - Output the version stored in Makefile'
> - @if [ -r include/asm-$(ARCH)/Kbuild ]; then \
> + @if [ -r $(srctree)/include/asm-$(ARCH)/Kbuild ]; then \
>echo  '  headers_install - Install sanitised kernel headers to 
> INSTALL_HDR_PATH'; \
> +  echo  '(default: $(INSTALL_HDR_PATH))'; \
>fi
> - @echo  '(default: $(INSTALL_HDR_PATH))'
>   @echo  ''
>   @echo  'Static analysers'
>   @echo  '  checkstack  - Generate a list of stack hogs'
>   @echo  '  namespacecheck  - Name space analysis on compiled kernel'
> - @if [ -r include/asm-$(ARCH)/Kbuild ]; then \
> + @if [ -r $(srctree)/include/asm-$(ARCH)/Kbuild ]; then \
>echo  '  headers_check   - Sanity check on exported headers'; \
>fi
>   @echo  ''
>
> Gr{oetje,eeting}s,
>
>   Geert
>
> --
> Geert Uytterhoeven -- Sony Network and Software Technology Center Europe 
> (NSCE)
> [EMAIL PROTECTED] --- The Corporate Village, Da Vincilaan 7-D1
> Voice +32-2-7008453 Fax +32-2-7008622  B-1935 Zaventem, 
> Belgium

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH] `make help' in build tree doesn't show headers_* targets

2007-01-29 Thread Oleg Verych

 From: Geert Uytterhoeven
 Newsgroups: gmane.linux.kernel
 Subject: [PATCH] `make help' in build tree doesn't show headers_* targets
 Date: Mon, 29 Jan 2007 13:47:01 +0100 (CET)

 `make help' in the build tree doesn't show the help texts about the
 `headers_install' and `headers_check' targets because it looks for
 include/asm-$(ARCH)/Kbuild in the wrong place.
 Add the missing `$(srctree)' prefixes to fix this.
 Also move the printing of the default install path for the headers inside the
 `if/fi', where it belongs.

 Signed-off-by: Geert Uytterhoeven [EMAIL PROTECTED]
 ---
  Makefile |6 +++---
  1 files changed, 3 insertions(+), 3 deletions(-)

Acked-by: Oleg Verych [EMAIL PROTECTED]


 --- ps3-linux-src-2.6.20-rc6.orig/Makefile
 +++ ps3-linux-src-2.6.20-rc6/Makefile
 @@ -1116,15 +1116,15 @@ help:
   @echo  '  cscope  - Generate cscope index'
   @echo  '  kernelrelease   - Output the release version string'
   @echo  '  kernelversion   - Output the version stored in Makefile'
 - @if [ -r include/asm-$(ARCH)/Kbuild ]; then \
 + @if [ -r $(srctree)/include/asm-$(ARCH)/Kbuild ]; then \
echo  '  headers_install - Install sanitised kernel headers to 
 INSTALL_HDR_PATH'; \
 +  echo  '(default: $(INSTALL_HDR_PATH))'; \
fi
 - @echo  '(default: $(INSTALL_HDR_PATH))'
   @echo  ''
   @echo  'Static analysers'
   @echo  '  checkstack  - Generate a list of stack hogs'
   @echo  '  namespacecheck  - Name space analysis on compiled kernel'
 - @if [ -r include/asm-$(ARCH)/Kbuild ]; then \
 + @if [ -r $(srctree)/include/asm-$(ARCH)/Kbuild ]; then \
echo  '  headers_check   - Sanity check on exported headers'; \
fi
   @echo  ''

 Gr{oetje,eeting}s,

   Geert

 --
 Geert Uytterhoeven -- Sony Network and Software Technology Center Europe 
 (NSCE)
 [EMAIL PROTECTED] --- The Corporate Village, Da Vincilaan 7-D1
 Voice +32-2-7008453 Fax +32-2-7008622  B-1935 Zaventem, 
 Belgium

-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [SCRIPT] Remove "space damage" from patches

2007-01-28 Thread Oleg Verych
On Mon, Jan 29, 2007 at 03:00:35AM +0100, Richard Knutsson wrote:
> Oleg Verych wrote:
> >On Mon, Jan 29, 2007 at 02:26:04AM +0100, Richard Knutsson wrote:
> >[]
> >  
> >>I also guess you saw that the script is _not_ for cleaning up 
> >>source-files (can be intrusive and is better to be fixed when fixing 
> >>something else), but patches.
> >>
> >
> >IMHO it's dealing with consequences, not cause, and it's even worse.
> >  
> How many patches is not to fix bugs, it is worse then some strayed 
> whitespace but it is due to reality.
> The best is, of course, if neither happened but the next best thing is 

1. Patches are signed-off (not by you).
2. Maybe Andrew Morton under his sign-off add such feature.

> >> (otherwise I believe they just deleted my mail ;) ).
> >>
> >
> >I would like to discuss, would you?
> >  
> I like to discuss but I am not sure what the result would be. Force 
> people to use the editors of our choice?
> As long people uses valid e-mail-clients when sending patches (or they 
> use the script "sendpatchset"), I'm think we have to be satisfied.
> But if you have any ideas, I'm listening.

Open-source worker, hammering his fingers? Please, let me out it ;D

> Richard Knutsson
> 

_
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: The mbox format archives of linux-kernel are gone.

2007-01-28 Thread Oleg Verych
On Sun, Jan 28, 2007 at 03:17:06PM -0800, Andrew Morton wrote:
> On Sun, 28 Jan 2007 22:46:32 +
> Oleg Verych <[EMAIL PROTECTED]> wrote:
> 
> > If somebody will get lkml mbox archive, can you import it into gmane,
> > please.
> 
> http://userweb.kernel.org/~akpm/lkml-mbox-archives/

I think, whole set, possibly from most active start years, say 1993, 1994
or so, must be collected, then i can contact Lars to try to import all
this into Gmane with current web links being preserved.

BTW, donwloading (big) sets of archives _from_ Gmane is strongly
discouraged.


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [SCRIPT] Remove "space damage" from patches

2007-01-28 Thread Oleg Verych
On Mon, Jan 29, 2007 at 02:26:04AM +0100, Richard Knutsson wrote:
[]
> I also guess you saw that the script is _not_ for cleaning up 
> source-files (can be intrusive and is better to be fixed when fixing 
> something else), but patches.

IMHO it's dealing with consequences, not cause, and it's even worse.

> So if a maintainer does not have anything to easily fix those, they
> might want a simple script to do the work (otherwise I believe they
> just deleted my mail ;) ).

I would like to discuss, would you?


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: unfixed regression in 2.6.20-rc6 (since 2.6.19)

2007-01-28 Thread Oleg Verych
> From: Rainer Weikusat
> Newsgroups: gmane.linux.kernel
> Subject: Re: unfixed regression in 2.6.20-rc6 (since 2.6.19)
> Date: Sun, 28 Jan 2007 14:34:56 +0100

Hallo.

> Greg KH <[EMAIL PROTECTED]> writes:
[]
>> Please work to see what is wrong with the existing patch.  Is there
>> anything that I can do to help you out?
>
> This thing has consumed something like sixteen hours of my life in
> total, with a gain-to-be-expected of exactly zero (I don't need to run
> 'current' kernels on my work machine, I have just grown into the habit
> of doing so) and those sixteen hours cannot come back (and I even have
> had these type of discussions around 'should it rather look like math
> or rather like text' in sufficent quantities :->), so, except that I
> would be very much obliged to you if a fix for this issue could go
> into the 'official' tree rather sooner than later, no.

It's hot here.

I'm in similar situation (even *usb-serial* driver [TI USB] led me there;)

In short, it turned, that usb drivers aren't drivers at all, they are
just "USB interface drivers", i.e. managers of the particular USB
interface *in* the device.

Problem is: after changing ti-usb-serial's firmware, it is being reset
and apears with new device ID. It's OK so far, but even this may be
better (from USB hardware implementation point of view). Then this
device, after being caught with new ID by the same "driver" requires
seting USB configuration #2, in order to be usb-serial converter. Day was
lost to make this happen _inside_ driver (kernel 2.6.18). It turned, that
only way to do so is SYSFS, that set up by udev, and
"usb_set_configuration()" function is being used for that.

1. Why it's not called "sysfs_usb_set_configuration()"?

2. Why

   [USB device view]: vID:dID -- bNumConfigurations -- bNumInterfaces

is being only device IDs tables in usb drivers?

3. Where's configuration and/or interfaces choosing? Yes, this may be not
so wide used, but hey, it's design issue! There's a big cave in device
setup and configuration chain!

Look at 2.6.19 with "usb_driver_set_configuration()" to see it.

And don't say, USB device requires userspace to setup (external
firmware is another question). I can be young and stupid, and this is
very wired only for my understanding. Simple NULL by default or set
table of {num_usb_conf, num_interface} for "drivers" will be enough.

> Apart from that, I make a (fairly miserable) living by adapting open
> source code to be usable in specific situations (ie adding or
> modifying features, fixing bugs, writing drivers etc)

So and i. I wanted to adopt request_firmware() for TI USB serial, but
i became very confused and upset.

--
-o--=O`C
 #oo'L O
<___=E M

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [SCRIPT] Remove "space damage" from patches

2007-01-28 Thread Oleg Verych
29-01-2007, Richard Knutsson:
> Oleg Verych wrote:
>> Nack, big and fat. It's userspace problem.
>>
>> If our "developers" can't use or update their every-day-tools, it's a
>> shame. And this is not trolling: i'm using Jed and GNU Emacs, both are
>> ok with whitespace "production".
> Oh, I hope I didn't give the impression I wanted it in the kernel (that 
> is why i labeled it as SCRIPT and not PATCH), as you said it is a 
> userspace problem. I just thought a simple script to remove those 
> whitespace could help in an imperfect world. I prefer kate since then 
> you can see where the tabs begins (and other features).

Just to give you idea, how imperfect it is:
<http://marc.theaimsgroup.com/?l=linux-mm-commits=116198944205036=2>

Anyway, i still think programmers *must* take care of it, if they think
they _are_ Programmers. IMHO LKML already gives obligation to be one.

> Richard Knutsson
>


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [SCRIPT] Remove "space damage" from patches

2007-01-28 Thread Oleg Verych
> From: Richard Knutsson
> Newsgroups: gmane.linux.kernel
> Subject: [SCRIPT] Remove "space damage" from patches
> Date: Sun, 28 Jan 2007 22:37:01 +0100

> Hello Andrew and all

Hallo.

> I recently tried "git-apply" on the 2.6.20-rc6-mm1 patch and found it to 
> complain about white-spaces.
> So as a mean to (hopefully) cut down on these nasty white-spaces (and 
> sometimes tabs) I wrote this
> little script. All it does is checking (lines that are going to be added) for 
> spaces before tabs
> and trailing spaces/tabs. I tried it on 2.6.20-rc6-mm1 and it seem to work 
> well
>
> If there is someone interested, _please_ take it. Any suggestion are welcomed 
> :)
>
> Richard Knutsson

Nack, big and fat. It's userspace problem.

If our "developers" can't use or update their every-day-tools, it's a
shame. And this is not trolling: i'm using Jed and GNU Emacs, both are
ok with whitespace "production". 



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: git.kernel.org move (finally)... estimated week of Feb 5

2007-01-28 Thread Oleg Verych
> From: "Parag Warudkar"
> Newsgroups: gmane.linux.kernel
> Subject: Re: git.kernel.org move (finally)... estimated week of Feb 5
> Date: Sun, 28 Jan 2007 11:51:34 -0500
[]
> Actually that's a good idea - why don't we put up a
> donation-for-hardware appeal on kernel.org and may be someplace more
> visible to raise around 8K USD for a 2x2 AMD64 machine with say 8Gig
> of RAM? May be the disks etc. stuff can be shared/re-used off the
> DL380 G2?
>
> The KDE guys did something like that a little while ago. I pledge my
> USD 100 upfront and I don't think we should have trouble getting 80
> people donating USD 100 each.

And Mozilla Org. (Corp.) did bad joke with this.
I mean in terms of open source, Debian in particular (there's no fox
there any more).

> Parag


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: The mbox format archives of linux-kernel are gone.

2007-01-28 Thread Oleg Verych
> Path: news.gmane.org!not-for-mail
> From: Andrey Borzenkov <[EMAIL PROTECTED]>
> Newsgroups: gmane.linux.kernel
> Date: Sun, 28 Jan 2007 20:24:43 +0300

Hallo.

> Benny Amorsen wrote:
>
>>> "DK" == Dave Kleikamp <[EMAIL PROTECTED]> writes:
>> 
>> DK> On Sun, 2007-01-28 at 10:17 +0100, Benny Amorsen wrote:
  Perhaps nntp://news.gmane.org/gmane.linux.kernel can help, even if
 it isn't exactly what you asked for.
>> 
>> DK> I like to read the mailing list this way, but it's not a good
>> DK> method if you want to reply to an email. You're email was only
>> DK> sent to the list and not to the Dirk, who you were replying to.
>> 
>> True. There has been a few flame wars over whether it is good
>> netiquette to send both to the list and to the person though -- and
>> some newsreaders can be told to send courtesy copies by email.
>> 
>
> It is not newgroup, it is lkml where keeping Cc list is standard. Answering
> via gmane unfortunately completely trims Cc list, keeping at most sender
> and list but not recipients of message. May be other newsreaders behave
> better (using Knode)

Yes. LKML is a list, list with heavy load. For better tracking of
threads, MUA maybe better, sometimes.

Problem with Cc list isn't problem, actually:


("Reply-To" is forbidden by vger)

If this will be adopted by all Mail/News UAs, it will be OK.

As for my slrn, it lets me to edit whole message, i.e. incuding
headers, so until i will implement something in the sources, i can
copy "MAil-Followup-To" by hands ;D

If somebody will get lkml mbox archive, can you import it into gmane,
please.

> -andrey
>


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: git.kernel.org move (finally)... estimated week of Feb 5

2007-01-28 Thread Oleg Verych
27-01-2007, H. Peter Anvin:
[]
> Sure... it's the DL380 G2 that used to be zeus.kernel.org.  It's not 
> ideal (in particular, I would have preferred a 64-bit machine), but it 
> has the advantage that it's proven itself rock-solid over the years, it 
> has all the hands-off management features, we have it, and it has 6 GB RAM.
>
> As far as filesystem is concerned, we might decide to use this machine 
> to test out XFS.  Haven't made the formal decision yet.

AMD64 with XFS.

IMHO 64 bits are on desktop and laptops over two years. So, i would like
to assign (my small, but maybe not only one due of) 50-70 EUR to help
with new hardware, if you wish.



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: git.kernel.org move (finally)... estimated week of Feb 5

2007-01-28 Thread Oleg Verych
27-01-2007, H. Peter Anvin:
[]
 Sure... it's the DL380 G2 that used to be zeus.kernel.org.  It's not 
 ideal (in particular, I would have preferred a 64-bit machine), but it 
 has the advantage that it's proven itself rock-solid over the years, it 
 has all the hands-off management features, we have it, and it has 6 GB RAM.

 As far as filesystem is concerned, we might decide to use this machine 
 to test out XFS.  Haven't made the formal decision yet.

AMD64 with XFS.

IMHO 64 bits are on desktop and laptops over two years. So, i would like
to assign (my small, but maybe not only one due of) 50-70 EUR to help
with new hardware, if you wish.



-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: The mbox format archives of linux-kernel are gone.

2007-01-28 Thread Oleg Verych
 Path: news.gmane.org!not-for-mail
 From: Andrey Borzenkov [EMAIL PROTECTED]
 Newsgroups: gmane.linux.kernel
 Date: Sun, 28 Jan 2007 20:24:43 +0300

Hallo.

 Benny Amorsen wrote:

 DK == Dave Kleikamp [EMAIL PROTECTED] writes:
 
 DK On Sun, 2007-01-28 at 10:17 +0100, Benny Amorsen wrote:
  Perhaps nntp://news.gmane.org/gmane.linux.kernel can help, even if
 it isn't exactly what you asked for.
 
 DK I like to read the mailing list this way, but it's not a good
 DK method if you want to reply to an email. You're email was only
 DK sent to the list and not to the Dirk, who you were replying to.
 
 True. There has been a few flame wars over whether it is good
 netiquette to send both to the list and to the person though -- and
 some newsreaders can be told to send courtesy copies by email.
 

 It is not newgroup, it is lkml where keeping Cc list is standard. Answering
 via gmane unfortunately completely trims Cc list, keeping at most sender
 and list but not recipients of message. May be other newsreaders behave
 better (using Knode)

Yes. LKML is a list, list with heavy load. For better tracking of
threads, MUA maybe better, sometimes.

Problem with Cc list isn't problem, actually:
http://cr.yp.to/proto/replyto.html

(Reply-To is forbidden by vger)

If this will be adopted by all Mail/News UAs, it will be OK.

As for my slrn, it lets me to edit whole message, i.e. incuding
headers, so until i will implement something in the sources, i can
copy MAil-Followup-To by hands ;D

If somebody will get lkml mbox archive, can you import it into gmane,
please.

 -andrey



-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: git.kernel.org move (finally)... estimated week of Feb 5

2007-01-28 Thread Oleg Verych
 From: Parag Warudkar
 Newsgroups: gmane.linux.kernel
 Subject: Re: git.kernel.org move (finally)... estimated week of Feb 5
 Date: Sun, 28 Jan 2007 11:51:34 -0500
[]
 Actually that's a good idea - why don't we put up a
 donation-for-hardware appeal on kernel.org and may be someplace more
 visible to raise around 8K USD for a 2x2 AMD64 machine with say 8Gig
 of RAM? May be the disks etc. stuff can be shared/re-used off the
 DL380 G2?

 The KDE guys did something like that a little while ago. I pledge my
 USD 100 upfront and I don't think we should have trouble getting 80
 people donating USD 100 each.

And Mozilla Org. (Corp.) did bad joke with this.
I mean in terms of open source, Debian in particular (there's no fox
there any more).

 Parag


-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [SCRIPT] Remove space damage from patches

2007-01-28 Thread Oleg Verych
 From: Richard Knutsson
 Newsgroups: gmane.linux.kernel
 Subject: [SCRIPT] Remove space damage from patches
 Date: Sun, 28 Jan 2007 22:37:01 +0100

 Hello Andrew and all

Hallo.

 I recently tried git-apply on the 2.6.20-rc6-mm1 patch and found it to 
 complain about white-spaces.
 So as a mean to (hopefully) cut down on these nasty white-spaces (and 
 sometimes tabs) I wrote this
 little script. All it does is checking (lines that are going to be added) for 
 spaces before tabs
 and trailing spaces/tabs. I tried it on 2.6.20-rc6-mm1 and it seem to work 
 well

 If there is someone interested, _please_ take it. Any suggestion are welcomed 
 :)

 Richard Knutsson

Nack, big and fat. It's userspace problem.

If our developers can't use or update their every-day-tools, it's a
shame. And this is not trolling: i'm using Jed and GNU Emacs, both are
ok with whitespace production. 



-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [SCRIPT] Remove space damage from patches

2007-01-28 Thread Oleg Verych
29-01-2007, Richard Knutsson:
 Oleg Verych wrote:
 Nack, big and fat. It's userspace problem.

 If our developers can't use or update their every-day-tools, it's a
 shame. And this is not trolling: i'm using Jed and GNU Emacs, both are
 ok with whitespace production.
 Oh, I hope I didn't give the impression I wanted it in the kernel (that 
 is why i labeled it as SCRIPT and not PATCH), as you said it is a 
 userspace problem. I just thought a simple script to remove those 
 whitespace could help in an imperfect world. I prefer kate since then 
 you can see where the tabs begins (and other features).

Just to give you idea, how imperfect it is:
http://marc.theaimsgroup.com/?l=linux-mm-commitsm=116198944205036w=2

Anyway, i still think programmers *must* take care of it, if they think
they _are_ Programmers. IMHO LKML already gives obligation to be one.

 Richard Knutsson



-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: unfixed regression in 2.6.20-rc6 (since 2.6.19)

2007-01-28 Thread Oleg Verych
 From: Rainer Weikusat
 Newsgroups: gmane.linux.kernel
 Subject: Re: unfixed regression in 2.6.20-rc6 (since 2.6.19)
 Date: Sun, 28 Jan 2007 14:34:56 +0100

Hallo.

 Greg KH [EMAIL PROTECTED] writes:
[]
 Please work to see what is wrong with the existing patch.  Is there
 anything that I can do to help you out?

 This thing has consumed something like sixteen hours of my life in
 total, with a gain-to-be-expected of exactly zero (I don't need to run
 'current' kernels on my work machine, I have just grown into the habit
 of doing so) and those sixteen hours cannot come back (and I even have
 had these type of discussions around 'should it rather look like math
 or rather like text' in sufficent quantities :-), so, except that I
 would be very much obliged to you if a fix for this issue could go
 into the 'official' tree rather sooner than later, no.

It's hot here.

I'm in similar situation (even *usb-serial* driver [TI USB] led me there;)

In short, it turned, that usb drivers aren't drivers at all, they are
just USB interface drivers, i.e. managers of the particular USB
interface *in* the device.

Problem is: after changing ti-usb-serial's firmware, it is being reset
and apears with new device ID. It's OK so far, but even this may be
better (from USB hardware implementation point of view). Then this
device, after being caught with new ID by the same driver requires
seting USB configuration #2, in order to be usb-serial converter. Day was
lost to make this happen _inside_ driver (kernel 2.6.18). It turned, that
only way to do so is SYSFS, that set up by udev, and
usb_set_configuration() function is being used for that.

1. Why it's not called sysfs_usb_set_configuration()?

2. Why

   [USB device view]: vID:dID -- bNumConfigurations -- bNumInterfaces

is being only device IDs tables in usb drivers?

3. Where's configuration and/or interfaces choosing? Yes, this may be not
so wide used, but hey, it's design issue! There's a big cave in device
setup and configuration chain!

Look at 2.6.19 with usb_driver_set_configuration() to see it.

And don't say, USB device requires userspace to setup (external
firmware is another question). I can be young and stupid, and this is
very wired only for my understanding. Simple NULL by default or set
table of {num_usb_conf, num_interface} for drivers will be enough.

 Apart from that, I make a (fairly miserable) living by adapting open
 source code to be usable in specific situations (ie adding or
 modifying features, fixing bugs, writing drivers etc)

So and i. I wanted to adopt request_firmware() for TI USB serial, but
i became very confused and upset.

--
-o--=O`C
 #oo'L O
___=E M

-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [SCRIPT] Remove space damage from patches

2007-01-28 Thread Oleg Verych
On Mon, Jan 29, 2007 at 02:26:04AM +0100, Richard Knutsson wrote:
[]
 I also guess you saw that the script is _not_ for cleaning up 
 source-files (can be intrusive and is better to be fixed when fixing 
 something else), but patches.

IMHO it's dealing with consequences, not cause, and it's even worse.

 So if a maintainer does not have anything to easily fix those, they
 might want a simple script to do the work (otherwise I believe they
 just deleted my mail ;) ).

I would like to discuss, would you?


-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: The mbox format archives of linux-kernel are gone.

2007-01-28 Thread Oleg Verych
On Sun, Jan 28, 2007 at 03:17:06PM -0800, Andrew Morton wrote:
 On Sun, 28 Jan 2007 22:46:32 +
 Oleg Verych [EMAIL PROTECTED] wrote:
 
  If somebody will get lkml mbox archive, can you import it into gmane,
  please.
 
 http://userweb.kernel.org/~akpm/lkml-mbox-archives/

I think, whole set, possibly from most active start years, say 1993, 1994
or so, must be collected, then i can contact Lars to try to import all
this into Gmane with current web links being preserved.

BTW, donwloading (big) sets of archives _from_ Gmane is strongly
discouraged.


-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [SCRIPT] Remove space damage from patches

2007-01-28 Thread Oleg Verych
On Mon, Jan 29, 2007 at 03:00:35AM +0100, Richard Knutsson wrote:
 Oleg Verych wrote:
 On Mon, Jan 29, 2007 at 02:26:04AM +0100, Richard Knutsson wrote:
 []
   
 I also guess you saw that the script is _not_ for cleaning up 
 source-files (can be intrusive and is better to be fixed when fixing 
 something else), but patches.
 
 
 IMHO it's dealing with consequences, not cause, and it's even worse.
   
 How many patches is not to fix bugs, it is worse then some strayed 
 whitespace but it is due to reality.
 The best is, of course, if neither happened but the next best thing is 

1. Patches are signed-off (not by you).
2. Maybe Andrew Morton under his sign-off add such feature.

  (otherwise I believe they just deleted my mail ;) ).
 
 
 I would like to discuss, would you?
   
 I like to discuss but I am not sure what the result would be. Force 
 people to use the editors of our choice?
 As long people uses valid e-mail-clients when sending patches (or they 
 use the script sendpatchset), I'm think we have to be satisfied.
 But if you have any ideas, I'm listening.

Open-source worker, hammering his fingers? Please, let me out it ;D

 Richard Knutsson
 

_
-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: git.kernel.org move (finally)... estimated week of Feb 5

2007-01-26 Thread Oleg Verych
27-01-2007, H. Peter Anvin:
> Just for everyone's information...
>
> The git performance issues (especially) on kernel.org has been very 
> frustrating, obviously.  We're putting a dedicated git server in place 
> hopefully the week of February 5.

Thanks.

Hope it will have fast git-web face also.



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


scripts/makelst: bc -> shell Re: sed _s_gnu_alternatives_ (Re: [rft] (g)awk substitution)

2007-01-26 Thread Oleg Verych
Hallo.

On Sat, Jan 27, 2007 at 01:18:30AM +0100, Tim Schmielau wrote:
> On Fri, 26 Jan 2007, Oleg Verych wrote:
> 
> > In Debian's version it has no `bc', while native `bc' is producing
> > crap like that:
> > ,-*- bash -*-
> > |[EMAIL PROTECTED]:~$ printf "%u" $(( -1 )) ; echo
> > |18446744073709551615
> > |[EMAIL PROTECTED]:~$ echo -1 | bc
> > |-1
> > |[EMAIL PROTECTED]:~$ printf "%u" $(( 0xFF )) ; echo
> > |255
> > |[EMAIL PROTECTED]:~$ echo FF | bc
> > |99
> > |[EMAIL PROTECTED]:~$ echo F | bc
> > |15
> > |[EMAIL PROTECTED]:~$
> > `-*-
> > 
> > i can't understand the result... I think linux/scripts/makelst may be
> > updated to have sh's version of address calculation ;)
> 
> No, IMHO that should not be a reason to change anything in the kernel.
> Just set ibase=16 or read the fine manual:

Thank you very much ;) Maybe i must use XSLT with 0.99 kernel, or
what?

I'm talking about patch posted here:
Message-ID: <[EMAIL PROTECTED]>
Archived-At: <http://permalink.gmane.org/gmane.linux.kernel/485999>

,-*- diff snip -*-
|-t4=`echo $t3 | gawk '{ print $1 }'`
|-t5=`echo $t1 | gawk '{ print $1 }'`
|+t4=`pos_param 1 $t3`
|+t5=`pos_param 1 $t1`
5 t6=`echo $t4 - $t5 | tr a-f A-F`
6 t7=`( echo  ibase=16 ; echo $t6 ) | bc`
`-*-

I've just noticed, that things on lines 5 and 6 may be optimized.

t7=`printf "%lu" $(( 0x$t4 - 0x$t5 ))`

No tr, no bc, no pipes -- magic!
Better know and use our *fine shell*.

And if you jouined us, Tim, maybe can share your experience and test
patch above and this one, please?
Message-ID: <[EMAIL PROTECTED]>
Archived-At: <http://permalink.gmane.org/gmane.linux.kernel/485984>

It's just my optimization hint. I have no bc, and i'm sure
things, like that will cause silent misinformation.

Anyway, what is so bad in `sh'?

Thanks.

-*- OT -*-
>   info '(bc)About Expressions and Special Variables'
GFDL. Enough of that bull, even Documentation/ is *free* from it.

Good bye.
--
-o--=O`C  info emacs : not found  /. .\ ( is there any reason to live? )
 #oo'L O  info make  : not found  o (yes --- R.I.P. FSF+RMS)
<___=E M  man gcc: not found`-- ( viva Debian Operating System )
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[x86-64, CMOS/RTC] Re: 2.6.19.2: bad reads/writes from/to CMOS clock

2007-01-26 Thread Oleg Verych
26-01-2007:
> I am running 2.6.19.2 kernel from kernel.org.

2.6.18 debian, didn't see before, but maybe it was just big uptime ;)

> This is my first SMP kernel. 
>
> The problem I describe below has not happend with non-SMP kernels ever...
>
> I have installed my new AMD64 x2 4800 CPU just a few days ago. My mobo is 
> Asus A8N SLI
> (Nvidia chipset).

UP ASUS A4K x86-64 CPU Mobile Athlon 64 3200+

> My problem with this new setup is that my CMOS clock is thrown off by varying 
> amounts of time. I have seen system times as long as ten months into future, 
> and as
> long as 25 days in the past. At the moment my system clock has correct 
> hh:mm:ss, but it shows the date Jan 1st, instead of correct 25th.

I saw bad CMOS read, but CMOS itself was OK, after checking it with
hwclock or reboot by magic IRQ.

[]
> I would appreciate any ideas on how to follow-up on this problem. 
>
> I am eager to try things, collect data as needed. Just tell me what to do.
>
> Thanks in advance.

> Yavuz Onder

I don't know, because it was month or so ago. And i'm usual for bugs
(or curved hands ;).


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: sed _s_gnu_alternatives_ (Re: [rft] (g)awk substitution)

2007-01-26 Thread Oleg Verych
On Fri, Jan 26, 2007 at 12:47:20PM -0500, Rob Landley wrote:
> On Thursday 25 January 2007 4:18 pm, Oleg Verych wrote:
> 
> > > As I said, I'm not particularly interested in a more intrusive solution 
> > > solving a problem I haven't actually seen.  I don't see any obvious 
> > > reason 
> > > why it wouldn't work, and yes it would probably also solve my problem, but
> > > I still don't see why you think it's "better" than the three byte fix.
> > 
> > Ehhh. "I'm not guilty" issue. Well, fine ;)
> 
> "guilty"?
> 
> You attempted to hijack my simple observation ("awk is the standard name, 
> gawk 
> is not") into an attempt to replace susv3 standard utilities with extra shell 
> script.  This is a separate agenda, and I have _no_ idea why you think I'm 
> obligated to pursue it for you.
> 
> The motivation for my patch is taht circa 2.6.12 I didn't need gawk on my 
> system to build; the need for it cropped up fairly recently.  This is A) an 
> artificial requirement, B) a regression, C) trivial to fix.
> 
> I could also teach busybox awk to be called as "gawk", but awk is the 
> standard 
> name and gawk is not, and gawk can already be called as awk.  The _clean_ 
> thing to do is send a patch to get Linux to use the standard name, which I 
> did.  This is the minimally intrusive change, and since gawk's install 
> creates an awk symlink it shouldn't affect any existing systems.
> 
> That's what I did.  I am simply not interested in your attempts to do 
> something else, in hopes of fixing a problem I haven't seen and which I'm not 
> convinced actually exists.

IMHO every embedded developer besides size cares about speed and
reducing complexity of simple things. Yes, this is orthogonal to that,
you want to say to me.

Only thing i wanted to have as reasult is ack or nack on my patch.
Everything else is outside LKML.

> > If your current system is IA-32, or you have access to one, would you
> > like to test scripts/makelst for me, as i'm seeing `bc' there. But my 
> > system have not one, i would like to replace it with shell or awk or
> > whatever. TIA.
> 
> According to Posix and SUSv3, a development environment can be expected to 
> have bc:
> http://www.opengroup.org/onlinepubs/009695399/utilities/bc.html
> 
> Would you like to try the one in busybox?

In Debian's version it has no `bc', while native `bc' is producing
crap like that:
,-*- bash -*-
|[EMAIL PROTECTED]:~$ printf "%u" $(( -1 )) ; echo
|18446744073709551615
|[EMAIL PROTECTED]:~$ echo -1 | bc
|-1
|[EMAIL PROTECTED]:~$ printf "%u" $(( 0xFF )) ; echo
|255
|[EMAIL PROTECTED]:~$ echo FF | bc
|99
|[EMAIL PROTECTED]:~$ echo F | bc
|15
|[EMAIL PROTECTED]:~$
`-*-

i can't understand the result... I think linux/scripts/makelst may be
updated to have sh's version of address calculation ;)

> The minimal development environment I can build a working system in is 7 
> packages: linux, gcc, binutils, make, busybox, uClibc, bash.  This is not 
> theoretical: I have actually done this, and I was building systems under this 
> as far back as 2003.  (I became busybox maintainer after spending 2 years 
> upgrading busybox to make this _work_.  I started by rewriting sed.  I didn't 
> _know_ sed at the time, but binutils ./configure used some rather advanced 
> sed scripts to build, so I fixed it.  It works now.)

I'm glad. All i can say in this context: do you know `dash' shell.
It's pretty much OK for not interactive use, small, fast, POSIX
compliant (or should be ;).

> I'm using this to get a minimal native environment on non-x86 target 
> platforms, to minimize the amount of cross compiling I have to do when 
> bootstrapping a new platform.  (I submitted an OLS tutorial proposal on this, 
> although I dunno if they're interested.)

Goodluck!


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: sed _s_gnu_alternatives_ (Re: [rft] (g)awk substitution)

2007-01-26 Thread Oleg Verych
On Fri, Jan 26, 2007 at 12:47:20PM -0500, Rob Landley wrote:
 On Thursday 25 January 2007 4:18 pm, Oleg Verych wrote:
 
   As I said, I'm not particularly interested in a more intrusive solution 
   solving a problem I haven't actually seen.  I don't see any obvious 
   reason 
   why it wouldn't work, and yes it would probably also solve my problem, but
   I still don't see why you think it's better than the three byte fix.
  
  Ehhh. I'm not guilty issue. Well, fine ;)
 
 guilty?
 
 You attempted to hijack my simple observation (awk is the standard name, 
 gawk 
 is not) into an attempt to replace susv3 standard utilities with extra shell 
 script.  This is a separate agenda, and I have _no_ idea why you think I'm 
 obligated to pursue it for you.
 
 The motivation for my patch is taht circa 2.6.12 I didn't need gawk on my 
 system to build; the need for it cropped up fairly recently.  This is A) an 
 artificial requirement, B) a regression, C) trivial to fix.
 
 I could also teach busybox awk to be called as gawk, but awk is the 
 standard 
 name and gawk is not, and gawk can already be called as awk.  The _clean_ 
 thing to do is send a patch to get Linux to use the standard name, which I 
 did.  This is the minimally intrusive change, and since gawk's install 
 creates an awk symlink it shouldn't affect any existing systems.
 
 That's what I did.  I am simply not interested in your attempts to do 
 something else, in hopes of fixing a problem I haven't seen and which I'm not 
 convinced actually exists.

IMHO every embedded developer besides size cares about speed and
reducing complexity of simple things. Yes, this is orthogonal to that,
you want to say to me.

Only thing i wanted to have as reasult is ack or nack on my patch.
Everything else is outside LKML.

  If your current system is IA-32, or you have access to one, would you
  like to test scripts/makelst for me, as i'm seeing `bc' there. But my 
  system have not one, i would like to replace it with shell or awk or
  whatever. TIA.
 
 According to Posix and SUSv3, a development environment can be expected to 
 have bc:
 http://www.opengroup.org/onlinepubs/009695399/utilities/bc.html
 
 Would you like to try the one in busybox?

In Debian's version it has no `bc', while native `bc' is producing
crap like that:
,-*- bash -*-
|[EMAIL PROTECTED]:~$ printf %u $(( -1 )) ; echo
|18446744073709551615
|[EMAIL PROTECTED]:~$ echo -1 | bc
|-1
|[EMAIL PROTECTED]:~$ printf %u $(( 0xFF )) ; echo
|255
|[EMAIL PROTECTED]:~$ echo FF | bc
|99
|[EMAIL PROTECTED]:~$ echo F | bc
|15
|[EMAIL PROTECTED]:~$
`-*-

i can't understand the result... I think linux/scripts/makelst may be
updated to have sh's version of address calculation ;)

 The minimal development environment I can build a working system in is 7 
 packages: linux, gcc, binutils, make, busybox, uClibc, bash.  This is not 
 theoretical: I have actually done this, and I was building systems under this 
 as far back as 2003.  (I became busybox maintainer after spending 2 years 
 upgrading busybox to make this _work_.  I started by rewriting sed.  I didn't 
 _know_ sed at the time, but binutils ./configure used some rather advanced 
 sed scripts to build, so I fixed it.  It works now.)

I'm glad. All i can say in this context: do you know `dash' shell.
It's pretty much OK for not interactive use, small, fast, POSIX
compliant (or should be ;).

 I'm using this to get a minimal native environment on non-x86 target 
 platforms, to minimize the amount of cross compiling I have to do when 
 bootstrapping a new platform.  (I submitted an OLS tutorial proposal on this, 
 although I dunno if they're interested.)

Goodluck!


-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[x86-64, CMOS/RTC] Re: 2.6.19.2: bad reads/writes from/to CMOS clock

2007-01-26 Thread Oleg Verych
26-01-2007:
 I am running 2.6.19.2 kernel from kernel.org.

2.6.18 debian, didn't see before, but maybe it was just big uptime ;)

 This is my first SMP kernel. 

 The problem I describe below has not happend with non-SMP kernels ever...

 I have installed my new AMD64 x2 4800 CPU just a few days ago. My mobo is 
 Asus A8N SLI
 (Nvidia chipset).

UP ASUS A4K x86-64 CPU Mobile Athlon 64 3200+

 My problem with this new setup is that my CMOS clock is thrown off by varying 
 amounts of time. I have seen system times as long as ten months into future, 
 and as
 long as 25 days in the past. At the moment my system clock has correct 
 hh:mm:ss, but it shows the date Jan 1st, instead of correct 25th.

I saw bad CMOS read, but CMOS itself was OK, after checking it with
hwclock or reboot by magic IRQ.

[]
 I would appreciate any ideas on how to follow-up on this problem. 

 I am eager to try things, collect data as needed. Just tell me what to do.

 Thanks in advance.

 Yavuz Onder

I don't know, because it was month or so ago. And i'm usual for bugs
(or curved hands ;).


-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


scripts/makelst: bc - shell Re: sed _s_gnu_alternatives_ (Re: [rft] (g)awk substitution)

2007-01-26 Thread Oleg Verych
Hallo.

On Sat, Jan 27, 2007 at 01:18:30AM +0100, Tim Schmielau wrote:
 On Fri, 26 Jan 2007, Oleg Verych wrote:
 
  In Debian's version it has no `bc', while native `bc' is producing
  crap like that:
  ,-*- bash -*-
  |[EMAIL PROTECTED]:~$ printf %u $(( -1 )) ; echo
  |18446744073709551615
  |[EMAIL PROTECTED]:~$ echo -1 | bc
  |-1
  |[EMAIL PROTECTED]:~$ printf %u $(( 0xFF )) ; echo
  |255
  |[EMAIL PROTECTED]:~$ echo FF | bc
  |99
  |[EMAIL PROTECTED]:~$ echo F | bc
  |15
  |[EMAIL PROTECTED]:~$
  `-*-
  
  i can't understand the result... I think linux/scripts/makelst may be
  updated to have sh's version of address calculation ;)
 
 No, IMHO that should not be a reason to change anything in the kernel.
 Just set ibase=16 or read the fine manual:

Thank you very much ;) Maybe i must use XSLT with 0.99 kernel, or
what?

I'm talking about patch posted here:
Message-ID: [EMAIL PROTECTED]
Archived-At: http://permalink.gmane.org/gmane.linux.kernel/485999

,-*- diff snip -*-
|-t4=`echo $t3 | gawk '{ print $1 }'`
|-t5=`echo $t1 | gawk '{ print $1 }'`
|+t4=`pos_param 1 $t3`
|+t5=`pos_param 1 $t1`
5 t6=`echo $t4 - $t5 | tr a-f A-F`
6 t7=`( echo  ibase=16 ; echo $t6 ) | bc`
`-*-

I've just noticed, that things on lines 5 and 6 may be optimized.

t7=`printf %lu $(( 0x$t4 - 0x$t5 ))`

No tr, no bc, no pipes -- magic!
Better know and use our *fine shell*.

And if you jouined us, Tim, maybe can share your experience and test
patch above and this one, please?
Message-ID: [EMAIL PROTECTED]
Archived-At: http://permalink.gmane.org/gmane.linux.kernel/485984

It's just my optimization hint. I have no bc, and i'm sure
things, like that will cause silent misinformation.

Anyway, what is so bad in `sh'?

Thanks.

-*- OT -*-
   info '(bc)About Expressions and Special Variables'
GFDL. Enough of that bull, even Documentation/ is *free* from it.

Good bye.
--
-o--=O`C  info emacs : not found  /. .\ ( is there any reason to live? )
 #oo'L O  info make  : not found  o (yes --- R.I.P. FSF+RMS)
___=E M  man gcc: not found`-- ( viva Debian Operating System )
-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: git.kernel.org move (finally)... estimated week of Feb 5

2007-01-26 Thread Oleg Verych
27-01-2007, H. Peter Anvin:
 Just for everyone's information...

 The git performance issues (especially) on kernel.org has been very 
 frustrating, obviously.  We're putting a dedicated git server in place 
 hopefully the week of February 5.

Thanks.

Hope it will have fast git-web face also.



-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: sed _s_gnu_alternatives_ (Re: [rft] (g)awk substitution)

2007-01-25 Thread Oleg Verych
On Thu, Jan 25, 2007 at 02:38:02PM -0500, Rob Landley wrote:
> On Thursday 25 January 2007 2:14 pm, Oleg Verych wrote:
> > > I believe "shift 5" is also SUSv3. :)
> > 
> > If you have tested, please send ack or nack to us.
> 
> I have not.  I tested the one I sent.  Today I'm at a different location than 
> that test environment.  All I can try it on here is Ubuntu, and so could you 
> just as easily.
> 
> As I said, I'm not particularly interested in a more intrusive solution 
> solving a problem I haven't actually seen.  I don't see any obvious reason 
> why it wouldn't work, and yes it would probably also solve my problem, but I 
> still don't see why you think it's "better" than the three byte fix.

Ehhh. "I'm not guilty" issue. Well, fine ;)

If your current system is IA-32, or you have access to one, would you
like to test scripts/makelst for me, as i'm seeing `bc' there. But my
system have not one, i would like to replace it with shell or awk or
whatever. TIA.


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: sed _s_gnu_alternatives_ (Re: [rft] (g)awk substitution)

2007-01-25 Thread Oleg Verych
On Thu, Jan 25, 2007 at 01:03:32PM -0500, Rob Landley wrote:
> On Thursday 25 January 2007 4:40 am, Oleg Verych wrote:
> > > Your objection is a bit like saying "and don't use cat".  I'm saying 
> > > don't 
> > > call cat "gcat" when you just mean plain old cat.
> > 
> > No it's not, really. I don't want to see pipes, fork()s, disk seek,
> > when task can be done without it. I know, what awk is, and i hope it
> > will have its better time.
> 
> *shrug*  Making the need for "gawk" go away was my goal, and gawk->awk was 
> the 
> minimal change.  If you want more than that, I'm not objecting, just not 
> personally interested.

Yes making uclibc as a bit more work, than rename things ;D. And my
change is mainly from optimization point of view (say modern embedded ;)

> I believe "shift 5" is also SUSv3. :)

If you have tested, please send ack or nack to us.

Thanks.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: Intel PCI-E bridge ACPI resources and possibly related SATA unstability problems on ASUS A8Js

2007-01-25 Thread Oleg Verych
On Thu, Jan 25, 2007 at 01:28:56PM +0100, Martin Drab wrote:
> On Thu, 25 Jan 2007, Oleg Verych wrote:
> 
> > gmane.linux.kernel:
> > > recently I got my hands on an ASUS A8Js notebook (Core 2 Duo T7200,
> > > Intel 945 PM PCI-E Chipset, for details see attached log). After booting 
> > > the latest 2.6.20-rc5-git3 kernel (but the same behaviour occurs also 
> > > with 
> > > the 2.6.19.2, didn't try any other), some strange behaviour can be 
> > > observed.
> > 
> > There were disscussions about mmconfig and what nightmare it brought to
> > PCI(E) configuration in scope of BIOS, chip bugs. Here's (one of) such:
> > <http://marc.theaimsgroup.com/?l=linux-kernel=116007091004503=2>
> > 
> > > At first the following messages appear in the log:
> > >
> > > ...
  [   40.303154] PCI: BIOS *Bug*: MCFG area at e000 is not E820-reserved
> > > [   40.303157] PCI: Not using MMCONFIG.
> > >
> > > (not sure whether this is really a problem)
> > 
> > I think it may be the major problem.
> 
> Hmm, it may be. Was there suggested any solution (or at least proposal) 
> that I may try?

Try fix BIOS bugs: <http://permalink.gmane.org/gmane.linux.kernel/462632>

> Martin

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: Intel PCI-E bridge ACPI resources and possibly related SATA unstability problems on ASUS A8Js

2007-01-25 Thread Oleg Verych
gmane.linux.kernel:
> Hi,

Hallo.

> recently I got my hands on an ASUS A8Js notebook (Core 2 Duo T7200,
> Intel 945 PM PCI-E Chipset, for details see attached log). After booting 
> the latest 2.6.20-rc5-git3 kernel (but the same behaviour occurs also with 
> the 2.6.19.2, didn't try any other), some strange behaviour can be 
> observed.

There were disscussions about mmconfig and what nightmare it brought to
PCI(E) configuration in scope of BIOS, chip bugs. Here's (one of) such:


> At first the following messages appear in the log:
>
> ...
> [   40.303154] PCI: BIOS Bug: MCFG area at e000 is not E820-reserved
> [   40.303157] PCI: Not using MMCONFIG.
>
> (not sure whether this is really a problem)

I think it may be the major problem.


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


sed _s_gnu_alternatives_ (Re: [rft] (g)awk substitution)

2007-01-25 Thread Oleg Verych
On Wed, Jan 24, 2007 at 08:51:32PM -0500, Rob Landley wrote:
> On Wednesday 24 January 2007 4:03 pm, Oleg Verych wrote:
> 
> > Let me propose you to test this as solution, that need no awk, only shell:
> 
> Actually awk is one of the standard Single Unix Specification (version 3) 
> utilities and the kernel build uses it in a number of places, such as 
> arch/alpha/boot/Makefile, drivers/eisa/Makefile, scripts/ver_linux.

I saw that. If you will test my first replacements and it will be ok,
i will go to this.

> Your objection is a bit like saying "and don't use cat".  I'm saying don't 
> call cat "gcat" when you just mean plain old cat.

No it's not, really. I don't want to see pipes, fork()s, disk seek,
when task can be done without it. I know, what awk is, and i hope it
will have its better time.

> > p.s. who is going to make alternative to GNU make ? ;D
> 
> Me.  Seriously.  It's on my todo list, as part of the Firmware Linux project:

Well. I didn't expect such answer! So, after my trying to deal with
makefiles (there so many to cleanup and structure), i think it will be
easy to do so. I did contacted (ft)jam developers, but didn't get any
answer on current state of it vs GNU make.

> http://lwn.net/Articles/215941/
> 
> Although as major projects go, it's about fifth down on the list after 
> getting 
> toybox up to speed, writing a proper bash replacement shell, getting tcc to 
> build an unmodified Linux kernel, convincing the uClibc guys to HAVE ANOTHER 
> RELEASE ALREADY (it's been a year and a half, I _sent_ a cake)...

Thanks for information.

> Today, I'm writing a gene2fs that produces streaming output (I.E. it works 
> like tar).  It's not done yet...

Good luck !


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


sed _s_gnu_alternatives_ (Re: [rft] (g)awk substitution)

2007-01-25 Thread Oleg Verych
On Wed, Jan 24, 2007 at 08:51:32PM -0500, Rob Landley wrote:
 On Wednesday 24 January 2007 4:03 pm, Oleg Verych wrote:
 
  Let me propose you to test this as solution, that need no awk, only shell:
 
 Actually awk is one of the standard Single Unix Specification (version 3) 
 utilities and the kernel build uses it in a number of places, such as 
 arch/alpha/boot/Makefile, drivers/eisa/Makefile, scripts/ver_linux.

I saw that. If you will test my first replacements and it will be ok,
i will go to this.

 Your objection is a bit like saying and don't use cat.  I'm saying don't 
 call cat gcat when you just mean plain old cat.

No it's not, really. I don't want to see pipes, fork()s, disk seek,
when task can be done without it. I know, what awk is, and i hope it
will have its better time.

  p.s. who is going to make alternative to GNU make ? ;D
 
 Me.  Seriously.  It's on my todo list, as part of the Firmware Linux project:

Well. I didn't expect such answer! So, after my trying to deal with
makefiles (there so many to cleanup and structure), i think it will be
easy to do so. I did contacted (ft)jam developers, but didn't get any
answer on current state of it vs GNU make.

 http://lwn.net/Articles/215941/
 
 Although as major projects go, it's about fifth down on the list after 
 getting 
 toybox up to speed, writing a proper bash replacement shell, getting tcc to 
 build an unmodified Linux kernel, convincing the uClibc guys to HAVE ANOTHER 
 RELEASE ALREADY (it's been a year and a half, I _sent_ a cake)...

Thanks for information.

 Today, I'm writing a gene2fs that produces streaming output (I.E. it works 
 like tar).  It's not done yet...

Good luck !


-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: Intel PCI-E bridge ACPI resources and possibly related SATA unstability problems on ASUS A8Js

2007-01-25 Thread Oleg Verych
gmane.linux.kernel:
 Hi,

Hallo.

 recently I got my hands on an ASUS A8Js notebook (Core 2 Duo T7200,
 Intel 945 PM PCI-E Chipset, for details see attached log). After booting 
 the latest 2.6.20-rc5-git3 kernel (but the same behaviour occurs also with 
 the 2.6.19.2, didn't try any other), some strange behaviour can be 
 observed.

There were disscussions about mmconfig and what nightmare it brought to
PCI(E) configuration in scope of BIOS, chip bugs. Here's (one of) such:
http://marc.theaimsgroup.com/?l=linux-kernelm=116007091004503w=2

 At first the following messages appear in the log:

 ...
 [   40.303154] PCI: BIOS Bug: MCFG area at e000 is not E820-reserved
 [   40.303157] PCI: Not using MMCONFIG.

 (not sure whether this is really a problem)

I think it may be the major problem.


-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: Intel PCI-E bridge ACPI resources and possibly related SATA unstability problems on ASUS A8Js

2007-01-25 Thread Oleg Verych
On Thu, Jan 25, 2007 at 01:28:56PM +0100, Martin Drab wrote:
 On Thu, 25 Jan 2007, Oleg Verych wrote:
 
  gmane.linux.kernel:
   recently I got my hands on an ASUS A8Js notebook (Core 2 Duo T7200,
   Intel 945 PM PCI-E Chipset, for details see attached log). After booting 
   the latest 2.6.20-rc5-git3 kernel (but the same behaviour occurs also 
   with 
   the 2.6.19.2, didn't try any other), some strange behaviour can be 
   observed.
  
  There were disscussions about mmconfig and what nightmare it brought to
  PCI(E) configuration in scope of BIOS, chip bugs. Here's (one of) such:
  http://marc.theaimsgroup.com/?l=linux-kernelm=116007091004503w=2
  
   At first the following messages appear in the log:
  
   ...
  [   40.303154] PCI: BIOS *Bug*: MCFG area at e000 is not E820-reserved
   [   40.303157] PCI: Not using MMCONFIG.
  
   (not sure whether this is really a problem)
  
  I think it may be the major problem.
 
 Hmm, it may be. Was there suggested any solution (or at least proposal) 
 that I may try?

Try fix BIOS bugs: http://permalink.gmane.org/gmane.linux.kernel/462632

 Martin

-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: sed _s_gnu_alternatives_ (Re: [rft] (g)awk substitution)

2007-01-25 Thread Oleg Verych
On Thu, Jan 25, 2007 at 01:03:32PM -0500, Rob Landley wrote:
 On Thursday 25 January 2007 4:40 am, Oleg Verych wrote:
   Your objection is a bit like saying and don't use cat.  I'm saying 
   don't 
   call cat gcat when you just mean plain old cat.
  
  No it's not, really. I don't want to see pipes, fork()s, disk seek,
  when task can be done without it. I know, what awk is, and i hope it
  will have its better time.
 
 *shrug*  Making the need for gawk go away was my goal, and gawk-awk was 
 the 
 minimal change.  If you want more than that, I'm not objecting, just not 
 personally interested.

Yes making uclibc as a bit more work, than rename things ;D. And my
change is mainly from optimization point of view (say modern embedded ;)

 I believe shift 5 is also SUSv3. :)

If you have tested, please send ack or nack to us.

Thanks.

-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: sed _s_gnu_alternatives_ (Re: [rft] (g)awk substitution)

2007-01-25 Thread Oleg Verych
On Thu, Jan 25, 2007 at 02:38:02PM -0500, Rob Landley wrote:
 On Thursday 25 January 2007 2:14 pm, Oleg Verych wrote:
   I believe shift 5 is also SUSv3. :)
  
  If you have tested, please send ack or nack to us.
 
 I have not.  I tested the one I sent.  Today I'm at a different location than 
 that test environment.  All I can try it on here is Ubuntu, and so could you 
 just as easily.
 
 As I said, I'm not particularly interested in a more intrusive solution 
 solving a problem I haven't actually seen.  I don't see any obvious reason 
 why it wouldn't work, and yes it would probably also solve my problem, but I 
 still don't see why you think it's better than the three byte fix.

Ehhh. I'm not guilty issue. Well, fine ;)

If your current system is IA-32, or you have access to one, would you
like to test scripts/makelst for me, as i'm seeing `bc' there. But my
system have not one, i would like to replace it with shell or awk or
whatever. TIA.


-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[patch, rft] scripts/makelst: replace gawk with shell, update

2007-01-24 Thread Oleg Verych
scripts/makelst: replace gawk with shell, update

Signed-off-by: Oleg Verych <[EMAIL PROTECTED]>
---
-o--=O`C
 #oo'L O
<___=E M

--- linux~2.6.20-rc5/scripts/makelst~   2007-01-12 19:54:26.0 +0100
+++ linux~2.6.20-rc5/scripts/makelst2007-01-24 23:21:33.273657000 +0100
@@ -1,19 +1,22 @@
-#!/bin/bash
+#!/bin/sh
 # A script to dump mixed source code & assembly
 # with correct relocations from System.map
-# Requires the following lines in Rules.make.
-# Author(s): DJ Barrow ([EMAIL PROTECTED],[EMAIL PROTECTED]) 
-#William Stearns <[EMAIL PROTECTED]>
+# Requires the following lines in makefile:
 #%.lst: %.c
 #  $(CC) $(CFLAGS) $(EXTRA_CFLAGS) $(CFLAGS_$@) -g -c -o $*.o $<
-#  $(TOPDIR)/scripts/makelst $*.o $(TOPDIR)/System.map $(OBJDUMP)
+#  $(srctree)/scripts/makelst $*.o $(srctree)/System.map $(OBJDUMP)
 #
-#Copyright (C) 2000 IBM Corporation
-#Author(s): DJ Barrow ([EMAIL PROTECTED],[EMAIL PROTECTED]) 
+# Copyright (C) 2000 IBM Corporation
+# Author(s): DJ Barrow ([EMAIL PROTECTED],[EMAIL PROTECTED])
+#William Stearns <[EMAIL PROTECTED]>
 #
 
+pos_param() {
+  shift $1 ; echo $1
+}
+
 t1=`$3 --syms $1 | grep .text | grep " F " | head -n 1`
 if [ -n "$t1" ]; then
-  t2=`echo $t1 | gawk '{ print $6 }'`
+  t2=`pos_param 6 $t1`
   if [ ! -r $2 ]; then
 echo "No System.map" >&2
@@ -21,6 +24,6 @@
   else
 t3=`grep $t2 $2`
-t4=`echo $t3 | gawk '{ print $1 }'`
-t5=`echo $t1 | gawk '{ print $1 }'`
+t4=`pos_param 1 $t3`
+t5=`pos_param 1 $t1`
 t6=`echo $t4 - $t5 | tr a-f A-F`
 t7=`( echo  ibase=16 ; echo $t6 ) | bc`

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[patch, rft] scripts/gen_initramfs_list.sh: replace gawk with shell, whitespace cleanup

2007-01-24 Thread Oleg Verych
scripts/gen_initramfs_list.sh: replace gawk with shell, whitespace cleanup

Signed-off-by: Oleg Verych <[EMAIL PROTECTED]>
---
-o--=O`C
 #oo'L O
<___=E M

--- linux~2.6.20-rc5/scripts/gen_initramfs_list.sh~ 2007-01-12 
19:54:26.0 +0100
+++ linux~2.6.20-rc5/scripts/gen_initramfs_list.sh  2007-01-24 
22:54:49.721441250 +0100
@@ -1,5 +1,6 @@
 #!/bin/bash
 # Copyright (C) Martin Schlemmer <[EMAIL PROTECTED]>
-# Copyright (c) 2006   Sam Ravnborg <[EMAIL PROTECTED]>
+# Copyright (C) 2006 Sam Ravnborg <[EMAIL PROTECTED]>
+# Copyright (C) 2007 Oleg Verych <[EMAIL PROTECTED]>
 #
 # Released under the terms of the GNU GPL
@@ -18,13 +19,13 @@
 $0 [-o ] [-u ] [-g ] {-d | } ...
-o   Create gzipped initramfs file named  using
-  gen_init_cpio and gzip
+  gen_init_cpio and gzip
-uUser ID to map to user ID 0 (root).
-   is only meaningful if 
-  is a directory.
+   is only meaningful if 
+  is a directory.
-gGroup ID to map to group ID 0 (root).
-   is only meaningful if 
-  is a directory.
+   is only meaningful if 
+  is a directory.
  File list or directory for cpio archive.
-  If  is a .cpio file it will be used
+  If  is a .cpio file it will be used
   as direct input to initramfs.
-d Output the default cpio list.
@@ -95,4 +96,11 @@
 }
 
+# accessing fields, as in `awk'
+# $1 - field number; rest is argument string
+pos_param() {
+   shift $1
+   echo $1
+}
+
 # for each file print a line in following format
 #  
@@ -120,9 +128,7 @@
;;
"nod")
-   local dev_type=
-   local maj=$(LC_ALL=C ls -l "${location}" | \
-   gawk '{sub(/,/, "", $5); print $5}')
-   local min=$(LC_ALL=C ls -l "${location}" | \
-   gawk '{print $6}')
+   maj=`pos_param 5 $(LC_ALL=C ls -l "${location}")`
+   min=`pos_param 6 $(LC_ALL=C ls -l "${location}")`
+   maj=${maj%,}
 
if [ -b "${location}" ]; then
@@ -134,6 +140,5 @@
;;
"slink")
-   local target=$(LC_ALL=C ls -l "${location}" | \
-   gawk '{print $11}')
+   target=`pos_param 11 $(LC_ALL=C ls -l "${location}")`
str="${ftype} ${name} ${target} ${str}"
;;
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[rft] (g)awk substitution (Re: [PATCH] sed s/gawk/awk/scripts/gen_init_ramfs.sh)

2007-01-24 Thread Oleg Verych
> On Tuesday 23 January 2007 7:49 pm, Andrew Morton wrote:
>> If the kernel is being compiled on a non-Linux system (eg: legacy Unix)
>> then it is, I guess, possible for `awk' and `gawk' to offer different
>> features.  If the kernel's use of gawk uses GNU extensions then this patch
>> might break things on such a system.
>> 
>> I guess we'll find out...

OK, this is what (g) awk is needed for:

,-*- diff: shell script -*-
|local maj=$(LC_ALL=C ls -l "${location}" | \
|   -   gawk
|'{sub(/,/, "", $5); print $5}')
|+   awk '{sub(/,/, "", $5); print
|$5}')
|local min=$(LC_ALL=C ls -l "${location}" | \
|   -   gawk
|'{print $6}')
|+   awk '{print $6}')
|
|if [ -b "${location}" ]; then
|   dev_type="b"
|   @@ -134,7
|+134,7 @@
|;;
|   "slink")
|   local
|target=$(LC_ALL=C ls -l "${location}" | \
|-   gawk '{print $11}')
|+   awk '{print $11}')
`-*-

Let me propose you to test this as solution, that need no awk, only shell:
-*- sh -*-
#/bin/sh
# usage: $0 node symlink

nod=$1
sym=$2

pos_param() {
  set -- $@
  shift $1
  echo $1
}

location=${nod}
maj=`pos_param 5 $(LC_ALL=C ls -l "${location}")`
maj=${maj%,}
min=`pos_param 6 $(LC_ALL=C ls -l "${location}")`
echo "maj min:" $maj $min

location=${sym}
target=`pos_param 11 $(LC_ALL=C ls -l "${location}")`
echo "symlink target:" ${target}

-*- Result of testcase -*-
[EMAIL PROTECTED]:/tmp$ ./awkless.sh /dev/null null
maj min: 1 3
symlink target: /dev/null
[EMAIL PROTECTED]:/tmp$
[EMAIL PROTECTED]:/tmp$
-*-

p.s. who is going to make alternative to GNU make ? ;D
---
-o--=O`C  info emacs : not found  /. .\ ( is there any reason to live? )
 #oo'L O  info make  : not found  o (R.I.P. Debian Operating System)
<___=E M  man gcc: not found.-- (  TNX, RMS.   )
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[patch] spell 4 kbuild: improving option checking

2007-01-24 Thread Oleg Verych
Signed-off-by: Oleg Verych <[EMAIL PROTECTED]>

--- linux~2.6.20-rc5/scripts/Kbuild.include~2007-01-24 09:19:01.386426000 
+0100
+++ linux~2.6.20-rc5/scripts/Kbuild.include 2007-01-24 20:07:11.15282 
+0100
@@ -2,5 +2,5 @@
 # kbuild: Generic definitions
 
-# Convinient constants
+# Convenient constants
 comma   := ,
 squote  := '
@@ -171,5 +171,5 @@
 any-prereq = $(filter-out $(PHONY),$?) $(filter-out $(PHONY) $(wildcard $^),$^)
 
-# Execute command if command has changed or prerequisitei(s) are updated
+# Execute command if command has changed or prerequisite(s) are updated
 #
 if_changed = $(if $(strip $(any-prereq) $(arg-check)),   \
@@ -188,5 +188,5 @@
 
 # Usage: $(call if_changed_rule,foo)
-# will check if $(cmd_foo) changed, or any of the prequisites changed,
+# will check if $(cmd_foo) changed, or any of the prerequisites changed,
 # and if so will execute $(rule_foo)
 if_changed_rule = $(if $(strip $(any-prereq) $(arg-check) ), \
@@ -233,2 +233,4 @@
 echo-why = $(call escsq, $(strip $(why)))
 endif
+
+ LocalWords:  prequisites
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[patch] kbuild: improving option checking (Re: [PATCH -mm] replacement for broken kbuild-dont-put-temp-files-in-the-source-tree.patch)

2007-01-24 Thread Oleg Verych
Hallo. Tmpfiles, root users, external mod-builds again.

On Tue, Oct 31, 2006 at 02:51:36PM +0100, olecom wrote:
> On Tue, Oct 31, 2006 at 02:14:16AM +0100, Horst Schirmeier wrote:
> > On Tue, 31 Oct 2006, Andi Kleen wrote:
> > > 
> > > > The problem is, this brings us back to the problem where this whole
> > > > patch orgy began: Gentoo Portage sandbox violations when writing (the
> > > > null symlink) to the kernel tree when building external modules. What
> > > > about using $(M) as a base directory if it is defined?
> > > 
> > > I think Jan's $(objdir)/.tmp proposal would be cleanest. Just someone
> > > has to implement it :)
> > > 
> > > -Andi
> 
> $(objtree) here,
> 
> > I'm not sure what you mean by $(objdir); I just got something to work
> > which creates the /dev/null symlink in a (newly created if necessary)
> > directory named
> 
> $(objtree) is a directory for all possible outputs of the build precess,
> it's set up by `O=' or `KBUILD_OUTPUT', and this is *not* output for ready
> external modules `$(M)'. Try to play with this, please.

Kind of fix has finally landed. Instead for `O=/$dir' a patch...

Anyway i whould like propose my solution of:
-- external modules build without KBUILD_OUTPUT set;
-- /dev/null, GNU binutils and root users;
-- beauty;

For external modules, there must be information after
`make modules_prepare' in shipped linux-sources. Any build output is
put in $(objtree), and i don't understand why you don't using that.
Please, *try* `make O=/tmp/build M=/usr/local/src/nvatia'. Thank you.

As some kind of buga-feature, "null" isn't in any clean/mrproper
target (for a while ;).

-*- patch -*-
kbuild: improving option checking

 GNU binutils, root users, tmpfiles, external modules ro builds must
 be fixed to do the right thing now.

 In "safe" environment new /dev/null replacement may be used as simply as
 `echo > null', `gcc -o null'. In aggressive starting with $(null) is
 recommended.

 Feature: file $(objtree)/null isn't in any "clear" target (yet).

Cc: Roman Zippel <[EMAIL PROTECTED]>
Cc: Sam Ravnborg <[EMAIL PROTECTED]>
Signed-off-by: Oleg Verych <[EMAIL PROTECTED]>
---
-o--=O`C
 #oo'L O
<___=E M

--- linux~2.6.20-rc5/scripts/Kbuild.include~blackhole-4-tmpfiles
2007-01-12 19:54:26.0 +0100
+++ linux~2.6.20-rc5/scripts/Kbuild.include 2007-01-24 09:19:01.386426000 
+0100
@@ -2,5 +2,5 @@
 # kbuild: Generic definitions
 
-# Convinient variables
+# Convinient constants
 comma   := ,
 squote  := '
@@ -8,4 +8,7 @@
 space   := $(empty) $(empty)
 
+# Immortal black-hole for mortals and roots
+null = $(shell test -L null || (rm -f null; ln -s /dev/null null); echo null)
+
 ###
 # Name of target with a '.' as filename prefix. foo/bar.o => foo/.bar.o
@@ -57,33 +60,43 @@
 # See documentation in Documentation/kbuild/makefiles.txt
 
-# output directory for tests below
-TMPOUT := $(if $(KBUILD_EXTMOD),$(firstword $(KBUILD_EXTMOD))/)
-
 # as-option
 # Usage: cflags-y += $(call as-option, -Wa$(comma)-isa=foo,)
-
-as-option = $(shell if $(CC) $(CFLAGS) $(1) -Wa,-Z -c -o /dev/null \
--xassembler /dev/null > /dev/null 2>&1; then echo "$(1)"; \
-else echo "$(2)"; fi ;)
+define as-option
+  $(shell
+if $(CC) $(CFLAGS) $(1) -c -o $(null) -xassembler null >null 2>&1; \
+  then echo $(1); \
+  else echo $(2); \
+fi)
+endef
 
 # as-instr
 # Usage: cflags-y += $(call as-instr, instr, option1, option2)
-
-as-instr = $(shell if echo -e "$(1)" | \
- $(CC) $(AFLAGS) -c -xassembler - \
-   -o $(TMPOUT)astest.out > /dev/null 2>&1; \
-  then rm $(TMPOUT)astest.out; echo "$(2)"; \
-  else echo "$(3)"; fi)
+define as-instr
+  $(shell \
+if printf "$(1)" | $(AS) >$(null) 2>&1 -W -o null; \
+  then echo "$(2)"; \
+  else echo "$(3)"; \
+fi)
+endef
 
 # cc-option
 # Usage: cflags-y += $(call cc-option, -march=winchip-c6, -march=i586)
-
-cc-option = $(shell if $(CC) $(CFLAGS) $(1) -S -o /dev/null -xc /dev/null \
- > /dev/null 2>&1; then echo "$(1)"; else echo "$(2)"; fi ;)
+define cc-option
+  $(shell \
+if $(CC) $(CFLAGS) $(1) -S -o $(null) -xc null >null 2>&1; \
+  then echo "$(1)"; \
+  else echo "$(2)"; \
+fi)
+endef
 
 # cc-option-yn
 # Usage: flag := $(call cc-option-yn, -march=winchip-c6)
-cc-option-yn = $(shell if $(CC) $(CFLAGS) $(1) -S -o /dev/null -xc /dev/null \
-> /dev/null 2>&1; then echo "y"; else echo "n"; fi;)
+define cc-option-yn
+  $(shell \
+if $(CC) $(CFLAGS) $(1) -

[patch] kbuild: improving option checking (Re: [PATCH -mm] replacement for broken kbuild-dont-put-temp-files-in-the-source-tree.patch)

2007-01-24 Thread Oleg Verych
Hallo. Tmpfiles, root users, external mod-builds again.

On Tue, Oct 31, 2006 at 02:51:36PM +0100, olecom wrote:
 On Tue, Oct 31, 2006 at 02:14:16AM +0100, Horst Schirmeier wrote:
  On Tue, 31 Oct 2006, Andi Kleen wrote:
   
The problem is, this brings us back to the problem where this whole
patch orgy began: Gentoo Portage sandbox violations when writing (the
null symlink) to the kernel tree when building external modules. What
about using $(M) as a base directory if it is defined?
   
   I think Jan's $(objdir)/.tmp proposal would be cleanest. Just someone
   has to implement it :)
   
   -Andi
 
 $(objtree) here,
 
  I'm not sure what you mean by $(objdir); I just got something to work
  which creates the /dev/null symlink in a (newly created if necessary)
  directory named
 
 $(objtree) is a directory for all possible outputs of the build precess,
 it's set up by `O=' or `KBUILD_OUTPUT', and this is *not* output for ready
 external modules `$(M)'. Try to play with this, please.

Kind of fix has finally landed. Instead for `O=/$dir' a patch...

Anyway i whould like propose my solution of:
-- external modules build without KBUILD_OUTPUT set;
-- /dev/null, GNU binutils and root users;
-- beauty;

For external modules, there must be information after
`make modules_prepare' in shipped linux-sources. Any build output is
put in $(objtree), and i don't understand why you don't using that.
Please, *try* `make O=/tmp/build M=/usr/local/src/nvatia'. Thank you.

As some kind of buga-feature, null isn't in any clean/mrproper
target (for a while ;).

-*- patch -*-
kbuild: improving option checking

 GNU binutils, root users, tmpfiles, external modules ro builds must
 be fixed to do the right thing now.

 In safe environment new /dev/null replacement may be used as simply as
 `echo  null', `gcc -o null'. In aggressive starting with $(null) is
 recommended.

 Feature: file $(objtree)/null isn't in any clear target (yet).

Cc: Roman Zippel [EMAIL PROTECTED]
Cc: Sam Ravnborg [EMAIL PROTECTED]
Signed-off-by: Oleg Verych [EMAIL PROTECTED]
---
-o--=O`C
 #oo'L O
___=E M

--- linux~2.6.20-rc5/scripts/Kbuild.include~blackhole-4-tmpfiles
2007-01-12 19:54:26.0 +0100
+++ linux~2.6.20-rc5/scripts/Kbuild.include 2007-01-24 09:19:01.386426000 
+0100
@@ -2,5 +2,5 @@
 # kbuild: Generic definitions
 
-# Convinient variables
+# Convinient constants
 comma   := ,
 squote  := '
@@ -8,4 +8,7 @@
 space   := $(empty) $(empty)
 
+# Immortal black-hole for mortals and roots
+null = $(shell test -L null || (rm -f null; ln -s /dev/null null); echo null)
+
 ###
 # Name of target with a '.' as filename prefix. foo/bar.o = foo/.bar.o
@@ -57,33 +60,43 @@
 # See documentation in Documentation/kbuild/makefiles.txt
 
-# output directory for tests below
-TMPOUT := $(if $(KBUILD_EXTMOD),$(firstword $(KBUILD_EXTMOD))/)
-
 # as-option
 # Usage: cflags-y += $(call as-option, -Wa$(comma)-isa=foo,)
-
-as-option = $(shell if $(CC) $(CFLAGS) $(1) -Wa,-Z -c -o /dev/null \
--xassembler /dev/null  /dev/null 21; then echo $(1); \
-else echo $(2); fi ;)
+define as-option
+  $(shell
+if $(CC) $(CFLAGS) $(1) -c -o $(null) -xassembler null null 21; \
+  then echo $(1); \
+  else echo $(2); \
+fi)
+endef
 
 # as-instr
 # Usage: cflags-y += $(call as-instr, instr, option1, option2)
-
-as-instr = $(shell if echo -e $(1) | \
- $(CC) $(AFLAGS) -c -xassembler - \
-   -o $(TMPOUT)astest.out  /dev/null 21; \
-  then rm $(TMPOUT)astest.out; echo $(2); \
-  else echo $(3); fi)
+define as-instr
+  $(shell \
+if printf $(1) | $(AS) $(null) 21 -W -o null; \
+  then echo $(2); \
+  else echo $(3); \
+fi)
+endef
 
 # cc-option
 # Usage: cflags-y += $(call cc-option, -march=winchip-c6, -march=i586)
-
-cc-option = $(shell if $(CC) $(CFLAGS) $(1) -S -o /dev/null -xc /dev/null \
-  /dev/null 21; then echo $(1); else echo $(2); fi ;)
+define cc-option
+  $(shell \
+if $(CC) $(CFLAGS) $(1) -S -o $(null) -xc null null 21; \
+  then echo $(1); \
+  else echo $(2); \
+fi)
+endef
 
 # cc-option-yn
 # Usage: flag := $(call cc-option-yn, -march=winchip-c6)
-cc-option-yn = $(shell if $(CC) $(CFLAGS) $(1) -S -o /dev/null -xc /dev/null \
- /dev/null 21; then echo y; else echo n; fi;)
+define cc-option-yn
+  $(shell \
+if $(CC) $(CFLAGS) $(1) -S -o $(null) -xc null null 21; \
+  then echo y; \
+  else echo n; \
+fi)
+endef
 
 # cc-option-align
@@ -103,8 +116,11 @@
 # ld-option
 # Usage: ldflags += $(call ld-option, -Wl$(comma)--hash-style=both)
-ld-option = $(shell if $(CC) $(1) -nostdlib -xc /dev/null \
--o $(TMPOUT)ldtest.out  /dev/null 21; \
- then rm $(TMPOUT)ldtest.out; echo $(1); \
- else echo $(2); fi)
+define ld-option
+  $(shell \
+if $(CC) $(1) -nostdlib -o $(null) -xc null null 21

[patch] spell 4 kbuild: improving option checking

2007-01-24 Thread Oleg Verych
Signed-off-by: Oleg Verych [EMAIL PROTECTED]

--- linux~2.6.20-rc5/scripts/Kbuild.include~2007-01-24 09:19:01.386426000 
+0100
+++ linux~2.6.20-rc5/scripts/Kbuild.include 2007-01-24 20:07:11.15282 
+0100
@@ -2,5 +2,5 @@
 # kbuild: Generic definitions
 
-# Convinient constants
+# Convenient constants
 comma   := ,
 squote  := '
@@ -171,5 +171,5 @@
 any-prereq = $(filter-out $(PHONY),$?) $(filter-out $(PHONY) $(wildcard $^),$^)
 
-# Execute command if command has changed or prerequisitei(s) are updated
+# Execute command if command has changed or prerequisite(s) are updated
 #
 if_changed = $(if $(strip $(any-prereq) $(arg-check)),   \
@@ -188,5 +188,5 @@
 
 # Usage: $(call if_changed_rule,foo)
-# will check if $(cmd_foo) changed, or any of the prequisites changed,
+# will check if $(cmd_foo) changed, or any of the prerequisites changed,
 # and if so will execute $(rule_foo)
 if_changed_rule = $(if $(strip $(any-prereq) $(arg-check) ), \
@@ -233,2 +233,4 @@
 echo-why = $(call escsq, $(strip $(why)))
 endif
+
+ LocalWords:  prequisites
-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[rft] (g)awk substitution (Re: [PATCH] sed s/gawk/awk/scripts/gen_init_ramfs.sh)

2007-01-24 Thread Oleg Verych
 On Tuesday 23 January 2007 7:49 pm, Andrew Morton wrote:
 If the kernel is being compiled on a non-Linux system (eg: legacy Unix)
 then it is, I guess, possible for `awk' and `gawk' to offer different
 features.  If the kernel's use of gawk uses GNU extensions then this patch
 might break things on such a system.
 
 I guess we'll find out...

OK, this is what (g) awk is needed for:

,-*- diff: shell script -*-
|local maj=$(LC_ALL=C ls -l ${location} | \
|   -   gawk
|'{sub(/,/, , $5); print $5}')
|+   awk '{sub(/,/, , $5); print
|$5}')
|local min=$(LC_ALL=C ls -l ${location} | \
|   -   gawk
|'{print $6}')
|+   awk '{print $6}')
|
|if [ -b ${location} ]; then
|   dev_type=b
|   @@ -134,7
|+134,7 @@
|;;
|   slink)
|   local
|target=$(LC_ALL=C ls -l ${location} | \
|-   gawk '{print $11}')
|+   awk '{print $11}')
`-*-

Let me propose you to test this as solution, that need no awk, only shell:
-*- sh -*-
#/bin/sh
# usage: $0 node symlink

nod=$1
sym=$2

pos_param() {
  set -- $@
  shift $1
  echo $1
}

location=${nod}
maj=`pos_param 5 $(LC_ALL=C ls -l ${location})`
maj=${maj%,}
min=`pos_param 6 $(LC_ALL=C ls -l ${location})`
echo maj min: $maj $min

location=${sym}
target=`pos_param 11 $(LC_ALL=C ls -l ${location})`
echo symlink target: ${target}

-*- Result of testcase -*-
[EMAIL PROTECTED]:/tmp$ ./awkless.sh /dev/null null
maj min: 1 3
symlink target: /dev/null
[EMAIL PROTECTED]:/tmp$
[EMAIL PROTECTED]:/tmp$
-*-

p.s. who is going to make alternative to GNU make ? ;D
---
-o--=O`C  info emacs : not found  /. .\ ( is there any reason to live? )
 #oo'L O  info make  : not found  o (R.I.P. Debian Operating System)
___=E M  man gcc: not found.-- (  TNX, RMS.   )
-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[patch, rft] scripts/gen_initramfs_list.sh: replace gawk with shell, whitespace cleanup

2007-01-24 Thread Oleg Verych
scripts/gen_initramfs_list.sh: replace gawk with shell, whitespace cleanup

Signed-off-by: Oleg Verych [EMAIL PROTECTED]
---
-o--=O`C
 #oo'L O
___=E M

--- linux~2.6.20-rc5/scripts/gen_initramfs_list.sh~ 2007-01-12 
19:54:26.0 +0100
+++ linux~2.6.20-rc5/scripts/gen_initramfs_list.sh  2007-01-24 
22:54:49.721441250 +0100
@@ -1,5 +1,6 @@
 #!/bin/bash
 # Copyright (C) Martin Schlemmer [EMAIL PROTECTED]
-# Copyright (c) 2006   Sam Ravnborg [EMAIL PROTECTED]
+# Copyright (C) 2006 Sam Ravnborg [EMAIL PROTECTED]
+# Copyright (C) 2007 Oleg Verych [EMAIL PROTECTED]
 #
 # Released under the terms of the GNU GPL
@@ -18,13 +19,13 @@
 $0 [-o file] [-u uid] [-g gid] {-d | cpio_source} ...
-o file  Create gzipped initramfs file named file using
-  gen_init_cpio and gzip
+  gen_init_cpio and gzip
-u uid   User ID to map to user ID 0 (root).
-  uid is only meaningful if cpio_source
-  is a directory.
+  uid is only meaningful if cpio_source
+  is a directory.
-g gid   Group ID to map to group ID 0 (root).
-  gid is only meaningful if cpio_source
-  is a directory.
+  gid is only meaningful if cpio_source
+  is a directory.
cpio_source  File list or directory for cpio archive.
-  If cpio_source is a .cpio file it will be used
+  If cpio_source is a .cpio file it will be used
   as direct input to initramfs.
-d Output the default cpio list.
@@ -95,4 +96,11 @@
 }
 
+# accessing fields, as in `awk'
+# $1 - field number; rest is argument string
+pos_param() {
+   shift $1
+   echo $1
+}
+
 # for each file print a line in following format
 # filetype name path to file octal mode uid gid
@@ -120,9 +128,7 @@
;;
nod)
-   local dev_type=
-   local maj=$(LC_ALL=C ls -l ${location} | \
-   gawk '{sub(/,/, , $5); print $5}')
-   local min=$(LC_ALL=C ls -l ${location} | \
-   gawk '{print $6}')
+   maj=`pos_param 5 $(LC_ALL=C ls -l ${location})`
+   min=`pos_param 6 $(LC_ALL=C ls -l ${location})`
+   maj=${maj%,}
 
if [ -b ${location} ]; then
@@ -134,6 +140,5 @@
;;
slink)
-   local target=$(LC_ALL=C ls -l ${location} | \
-   gawk '{print $11}')
+   target=`pos_param 11 $(LC_ALL=C ls -l ${location})`
str=${ftype} ${name} ${target} ${str}
;;
-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[patch, rft] scripts/makelst: replace gawk with shell, update

2007-01-24 Thread Oleg Verych
scripts/makelst: replace gawk with shell, update

Signed-off-by: Oleg Verych [EMAIL PROTECTED]
---
-o--=O`C
 #oo'L O
___=E M

--- linux~2.6.20-rc5/scripts/makelst~   2007-01-12 19:54:26.0 +0100
+++ linux~2.6.20-rc5/scripts/makelst2007-01-24 23:21:33.273657000 +0100
@@ -1,19 +1,22 @@
-#!/bin/bash
+#!/bin/sh
 # A script to dump mixed source code  assembly
 # with correct relocations from System.map
-# Requires the following lines in Rules.make.
-# Author(s): DJ Barrow ([EMAIL PROTECTED],[EMAIL PROTECTED]) 
-#William Stearns [EMAIL PROTECTED]
+# Requires the following lines in makefile:
 #%.lst: %.c
 #  $(CC) $(CFLAGS) $(EXTRA_CFLAGS) $(CFLAGS_$@) -g -c -o $*.o $
-#  $(TOPDIR)/scripts/makelst $*.o $(TOPDIR)/System.map $(OBJDUMP)
+#  $(srctree)/scripts/makelst $*.o $(srctree)/System.map $(OBJDUMP)
 #
-#Copyright (C) 2000 IBM Corporation
-#Author(s): DJ Barrow ([EMAIL PROTECTED],[EMAIL PROTECTED]) 
+# Copyright (C) 2000 IBM Corporation
+# Author(s): DJ Barrow ([EMAIL PROTECTED],[EMAIL PROTECTED])
+#William Stearns [EMAIL PROTECTED]
 #
 
+pos_param() {
+  shift $1 ; echo $1
+}
+
 t1=`$3 --syms $1 | grep .text | grep  F  | head -n 1`
 if [ -n $t1 ]; then
-  t2=`echo $t1 | gawk '{ print $6 }'`
+  t2=`pos_param 6 $t1`
   if [ ! -r $2 ]; then
 echo No System.map 2
@@ -21,6 +24,6 @@
   else
 t3=`grep $t2 $2`
-t4=`echo $t3 | gawk '{ print $1 }'`
-t5=`echo $t1 | gawk '{ print $1 }'`
+t4=`pos_param 1 $t3`
+t5=`pos_param 1 $t1`
 t6=`echo $t4 - $t5 | tr a-f A-F`
 t7=`( echo  ibase=16 ; echo $t6 ) | bc`

-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[newbie] Re: Is it possible to directly call do_path_lookup() in kernel?

2007-01-23 Thread Oleg Verych
On 2007-01-24, Xin Zhao wrote:
> Archived-At: 

Hallo.

> I just successfully called do_path_lookup() in my kernel module. I
> just removed the "fastcall" from the declaration of do_path_lookup(),
> then the problem disappeared. I don't quite understand "fastcall"
> though.

In linkage.h header near you.

> Can someone explain it?

Please use appropriate mailing list:

Kernelnewbies: Help each other learn about the Linux kernel.
Archive:   http://mail.nl.linux.org/kernelnewbies/
FAQ:   http://kernelnewbies.org/faq/

> Thanks,
> -x
>


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [KBUILD] I don't want initramfs in 2.6.19.1 but usr/ is still processed

2007-01-23 Thread Oleg Verych
On 2007-01-03, DervishD wrote:
>
> Hi all :)

Hallo!

> I've noticed that, even if I say NO to initramfs (and even ramdisk
> support), the make process wants to GEN usr/initramfs_data.cpio.gz by
> running the scripts/gen_initramfs_list.sh script.
>
> Why is that script run no matter the initramfs support? Looks like
> it only depends on the contents of CONFIG_INITRAMFS_SOURCE :?

I think reading Documentation/filesystems/ramfs-rootfs-initramfs.txt
will answer your question.

> Thanks in advance :)
>
> RaЗl NЗЯez de Arenas Coronado
>
> -- 
> Linux Registered User 88736 | http://www.dervishd.net
> It's my PC and I'll cry if I want to... RAmen!


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[patch] kbuild: create KBUILD_OUTPUT

2007-01-23 Thread Oleg Verych
kbuild: create KBUILD_OUTPUT

 When requesting build to another directory, try to create it first.

Cc: Sam Ravnborg <[EMAIL PROTECTED]>
Signed-off-by: Oleg Verych <[EMAIL PROTECTED]>
---

,-*- bash -*-
|[EMAIL PROTECTED]:~/kernel.org/_work/src/linux-2.6.20-rc5$
|[EMAIL PROTECTED]:~/kernel.org/_work/src/linux-2.6.20-rc5$ make O=/tmp/build
|cd: 1: can't cd to /tmp/build
|Makefile:116: *** output directory "/tmp/build" does not exist.  Stop.
|[EMAIL PROTECTED]:~/kernel.org/_work/src/linux-2.6.20-rc5$ patch -p1 
<../../va-patch/
|kbuild-create-output-dir.patch
|patching file Makefile
|[EMAIL PROTECTED]:~/kernel.org/_work/src/linux-2.6.20-rc5$ make O=/tmp/build
|HOSTCC scripts/basic/fixdep HOSTCC scripts/basic/docproc make[3]: ***
|[scripts/basic/docproc] Interrupt make[2]: *** [scripts_basic] Interrupt
|make: *** [_all] Interrupt
|
|[EMAIL PROTECTED]:~/kernel.org/_work/src/linux-2.6.20-rc5$
`-*-

--- linux-2.6.20-rc5/Makefile~orig  2007-01-12 19:54:26.0 +0100
+++ linux-2.6.20-rc5/Makefile   2007-01-24 00:59:55.926951750 +0100
@@ -113,5 +113,5 @@
 # check that the output directory actually exists
 saved-output := $(KBUILD_OUTPUT)
-KBUILD_OUTPUT := $(shell cd $(KBUILD_OUTPUT) && /bin/pwd)
+KBUILD_OUTPUT := $(shell d=$(KBUILD_OUTPUT) ; mkdir -p $$d && cd $$d && pwd)
 $(if $(KBUILD_OUTPUT),, \
  $(error output directory "$(saved-output)" does not exist))
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: identifying CONFIG variable typoes in the source tree

2007-01-23 Thread Oleg Verych
On 2007-01-23, Robert P. J. Day wrote:
[]
>   what it does is scan the entire tree for lines of the form
>
> ...if... CONFIG_whatever...
>
> collects all of those CONFIG variables and, one at a time, checks to
> see if that variable even exists in any Kconfig file in the tree so
> that it could possibly ever be set.  (i'm not guaranteeing that the
> script is perfect, but it does generate some interesting results.)
>
>   the first few lines of output:
>
> 53C700_BE_BUS
> 64_BIT
> 68328_SERIAL_UART2
> ...
>
[]
>   the script turns up 284 examples of this.

Next, this script must to learn how to search whom to send this info.
And if there's nobody, just to make list of known orphans ;).

> rday



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


+1 4 cz (Re: [Ksummit-2006-discuss] 2007 Linux Kernel Summit)

2007-01-23 Thread Oleg Verych
In gmane.linux.kernel, David Miller wrote:
> From: Alan Cox <[EMAIL PROTECTED]>
> Date: Mon, 22 Jan 2007 07:45:02 -0500
>
>> On Mon, Jan 22, 2007 at 12:07:11PM +0100, Christoph Hellwig wrote:
>> > > process.  This year, the Kernel Summit will be held in Cambridge,
>> > > England, at the DeVere University Arms Hotel, September 5-6 (with a
>> > > welcome reception on the 4th).  The decision to move the Kernel Summit
>> > > to England is a one-year experiment based on the very strong request of
>> > > last year's kernel summit attendees to try a location outside of Ottawa,
>> > > and especially from the roughly 1/3rd of the attendees that come from
>> > > the UK or Europe.  So the plan is for us to book the Ottawa Congress
>> > > Ceter space for July 2008 (which we will need to do by mid-year 2007),
>> 
>> Ditto..
>> 
>> Definitely disagree with that. I'd like to see the conference somewhere
   else different this time - perhaps *Czech Republic*, or somewhere else more
>> easterly and Linux active (or even Finland...)
>
> This is my position as well.
[]
> For the first time in many years I'm strongly considering actually
> going to the kernel summit, however if it goes back to Ottawa I
> definitely will stop going again.

It would be interesting. Thank you Alan, David!

;D

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


+1 4 cz (Re: [Ksummit-2006-discuss] 2007 Linux Kernel Summit)

2007-01-23 Thread Oleg Verych
In gmane.linux.kernel, David Miller wrote:
 From: Alan Cox [EMAIL PROTECTED]
 Date: Mon, 22 Jan 2007 07:45:02 -0500

 On Mon, Jan 22, 2007 at 12:07:11PM +0100, Christoph Hellwig wrote:
   process.  This year, the Kernel Summit will be held in Cambridge,
   England, at the DeVere University Arms Hotel, September 5-6 (with a
   welcome reception on the 4th).  The decision to move the Kernel Summit
   to England is a one-year experiment based on the very strong request of
   last year's kernel summit attendees to try a location outside of Ottawa,
   and especially from the roughly 1/3rd of the attendees that come from
   the UK or Europe.  So the plan is for us to book the Ottawa Congress
   Ceter space for July 2008 (which we will need to do by mid-year 2007),
 
 Ditto..
 
 Definitely disagree with that. I'd like to see the conference somewhere
   else different this time - perhaps *Czech Republic*, or somewhere else more
 easterly and Linux active (or even Finland...)

 This is my position as well.
[]
 For the first time in many years I'm strongly considering actually
 going to the kernel summit, however if it goes back to Ottawa I
 definitely will stop going again.

It would be interesting. Thank you Alan, David!

;D

-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: identifying CONFIG variable typoes in the source tree

2007-01-23 Thread Oleg Verych
On 2007-01-23, Robert P. J. Day wrote:
[]
   what it does is scan the entire tree for lines of the form

 ...if... CONFIG_whatever...

 collects all of those CONFIG variables and, one at a time, checks to
 see if that variable even exists in any Kconfig file in the tree so
 that it could possibly ever be set.  (i'm not guaranteeing that the
 script is perfect, but it does generate some interesting results.)

   the first few lines of output:

 53C700_BE_BUS
 64_BIT
 68328_SERIAL_UART2
 ...

[]
   the script turns up 284 examples of this.

Next, this script must to learn how to search whom to send this info.
And if there's nobody, just to make list of known orphans ;).

 rday



-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [KBUILD] I don't want initramfs in 2.6.19.1 but usr/ is still processed

2007-01-23 Thread Oleg Verych
On 2007-01-03, DervishD wrote:

 Hi all :)

Hallo!

 I've noticed that, even if I say NO to initramfs (and even ramdisk
 support), the make process wants to GEN usr/initramfs_data.cpio.gz by
 running the scripts/gen_initramfs_list.sh script.

 Why is that script run no matter the initramfs support? Looks like
 it only depends on the contents of CONFIG_INITRAMFS_SOURCE :?

I think reading Documentation/filesystems/ramfs-rootfs-initramfs.txt
will answer your question.

 Thanks in advance :)

 RaЗl NЗЯez de Arenas Coronado

 -- 
 Linux Registered User 88736 | http://www.dervishd.net
 It's my PC and I'll cry if I want to... RAmen!


-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[patch] kbuild: create KBUILD_OUTPUT

2007-01-23 Thread Oleg Verych
kbuild: create KBUILD_OUTPUT

 When requesting build to another directory, try to create it first.

Cc: Sam Ravnborg [EMAIL PROTECTED]
Signed-off-by: Oleg Verych [EMAIL PROTECTED]
---

,-*- bash -*-
|[EMAIL PROTECTED]:~/kernel.org/_work/src/linux-2.6.20-rc5$
|[EMAIL PROTECTED]:~/kernel.org/_work/src/linux-2.6.20-rc5$ make O=/tmp/build
|cd: 1: can't cd to /tmp/build
|Makefile:116: *** output directory /tmp/build does not exist.  Stop.
|[EMAIL PROTECTED]:~/kernel.org/_work/src/linux-2.6.20-rc5$ patch -p1 
../../va-patch/
|kbuild-create-output-dir.patch
|patching file Makefile
|[EMAIL PROTECTED]:~/kernel.org/_work/src/linux-2.6.20-rc5$ make O=/tmp/build
|HOSTCC scripts/basic/fixdep HOSTCC scripts/basic/docproc make[3]: ***
|[scripts/basic/docproc] Interrupt make[2]: *** [scripts_basic] Interrupt
|make: *** [_all] Interrupt
|
|[EMAIL PROTECTED]:~/kernel.org/_work/src/linux-2.6.20-rc5$
`-*-

--- linux-2.6.20-rc5/Makefile~orig  2007-01-12 19:54:26.0 +0100
+++ linux-2.6.20-rc5/Makefile   2007-01-24 00:59:55.926951750 +0100
@@ -113,5 +113,5 @@
 # check that the output directory actually exists
 saved-output := $(KBUILD_OUTPUT)
-KBUILD_OUTPUT := $(shell cd $(KBUILD_OUTPUT)  /bin/pwd)
+KBUILD_OUTPUT := $(shell d=$(KBUILD_OUTPUT) ; mkdir -p $$d  cd $$d  pwd)
 $(if $(KBUILD_OUTPUT),, \
  $(error output directory $(saved-output) does not exist))
-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[newbie] Re: Is it possible to directly call do_path_lookup() in kernel?

2007-01-23 Thread Oleg Verych
On 2007-01-24, Xin Zhao wrote:
 Archived-At: http://permalink.gmane.org/gmane.linux.kernel/485775

Hallo.

 I just successfully called do_path_lookup() in my kernel module. I
 just removed the fastcall from the declaration of do_path_lookup(),
 then the problem disappeared. I don't quite understand fastcall
 though.

In linkage.h header near you.

 Can someone explain it?

Please use appropriate mailing list:

Kernelnewbies: Help each other learn about the Linux kernel.
Archive:   http://mail.nl.linux.org/kernelnewbies/
FAQ:   http://kernelnewbies.org/faq/

 Thanks,
 -x



-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[fix, rfc] kbuild: O= with M= (Re: [PATCH -mm] replacement for broken kbuild-dont-put-temp-files-in-the-source-tree.patch)

2007-01-22 Thread Oleg Verych
On 2006-11-17, Oleg Verych wrote:
> On Tue, Oct 31, 2006 at 02:51:36PM +0100, olecom wrote:
> []
>> On Tue, Oct 31, 2006 at 02:14:16AM +0100, Horst Schirmeier wrote:
> []
>> > I'm not sure what you mean by $(objdir); I just got something to work
>> > which creates the /dev/null symlink in a (newly created if necessary)
>> > directory named
>> 
>> $(objtree) is a directory for all possible outputs of the build precess,
>> it's set up by `O=' or `KBUILD_OUTPUT', and this is *not* output for ready
>> external modules `$(M)'. Try to play with this, please.
>
> And for me, they are *not* working together:

It works with this:

Proposed-by: me

--- linux-2.6.20-rc5/scripts/Makefile.modpost.orig  2007-01-12 
19:54:26.0 +0100
+++ linux-2.6.20-rc5/scripts/Makefile.modpost   2007-01-23 08:23:51.583426500 
+0100
@@ -58,5 +58,5 @@
 #  Includes step 3,4
 quiet_cmd_modpost = MODPOST $(words $(filter-out vmlinux FORCE, $^)) modules
-  cmd_modpost = scripts/mod/modpost\
+  cmd_modpost = $(objtree)/scripts/mod/modpost \
 $(if $(CONFIG_MODVERSIONS),-m) \
$(if $(CONFIG_MODULE_SRCVERSION_ALL),-a,)  \
>> 
> 


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH] kbuild: Replace remaining "depends" with "depends on"

2007-01-22 Thread Oleg Verych
On 2006-12-13, Robert P. J. Day wrote:
>
>   Replace the very few remaining "depends" Kconfig directives with
> "depends on".
>
> Signed-off-by: Robert P. J. Day <[EMAIL PROTECTED]>
>
> ---

For this kind of fixes, please use
"kconfig" subsystem instead of
"kbuild" in subject. Thanks.



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [updated PATCH] remove 555 unneeded #includes of sched.h

2007-01-22 Thread Oleg Verych
On 2006-12-29, Tim Schmielau wrote:
[]
> OK, building 2.6.20-rc2-mm1 with all 59 configs from arch/arm/configs 
> with and w/o the patch indeed found one mysterious #include that may not 
> be removed. Thanks, Russell!
>
> Andrew, please use the attached patch instead of the previous one, it also 
> has a slightly better patch description.

Great job!

About patch. To make it smaller, i think, you better use less
"unified context" lines `diff -u1'.

Nice done! 


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[ot] Re: coding style and re-inventing the wheel way too many times

2007-01-22 Thread Oleg Verych
On 2006-12-21, Robert P. J. Day wrote:
[]
>   in any event, even *i* am not going to go near this kind of cleanup,
> but is there anything actually worth doing about it?  just curious.

Moscow wasn't built at once...

You may notice as some others are doing little by little steps:
- source cleanups;
- right dependancy;
- headers includes;
- warnings elimination;
- code reading-analyzing (brainwashing, as for me;) and a few line
fixes everywhere.

I think there are members here, who doing things, like that for at
least two years.

You are trying to focus (mostly) on style and sense -- ok. And maybe it's
like to be alone within a crowd. Anyways, as long as you fill, that you
can do that, and patches are accepded, changes are *documented* its ok,
also. Sometimes it's stupid, worthless or something else. If so, then
find more interesting things to do, unless you are going to proof
something to somebody ;E.

Here's, as i can see, almost no place for emotions, only technical stuff
and everything not far from it. See, there isn't any reply on you
message, except this one. I think, because of that.

--
-o--=O`C
 #oo'L O
<___=E M

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


dfsg isn't fsf (Re: GPL only modules [was Re: [GIT PATCH] more Driver core patches for 2.6.19])

2007-01-22 Thread Oleg Verych
On 2006-12-14, Alan wrote:
[]
> I doubt any distribution but the FSF "purified" Debian (the one that has
> no firmware so doesn't work) would do it.

DFSG "purified" Debian[1], please.

[1] 

--
-o--=O C  info emacs : not found  /. .\ ( is there any reason to live? )
 #oo'L O  info make  : not found  o ( yes! -- R.I.P. FSF+RMS, viva )
<___=E M  man gcc: not found`-- ( Debian Free Operating System )

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


dfsg isn't fsf (Re: GPL only modules [was Re: [GIT PATCH] more Driver core patches for 2.6.19])

2007-01-22 Thread Oleg Verych
On 2006-12-14, Alan wrote:
[]
 I doubt any distribution but the FSF purified Debian (the one that has
 no firmware so doesn't work) would do it.

DFSG purified Debian[1], please.

[1] http://www.debian.org/social_contract

--
-o--=O C  info emacs : not found  /. .\ ( is there any reason to live? )
 #oo'L O  info make  : not found  o ( yes! -- R.I.P. FSF+RMS, viva )
___=E M  man gcc: not found`-- ( Debian Free Operating System )

-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[ot] Re: coding style and re-inventing the wheel way too many times

2007-01-22 Thread Oleg Verych
On 2006-12-21, Robert P. J. Day wrote:
[]
   in any event, even *i* am not going to go near this kind of cleanup,
 but is there anything actually worth doing about it?  just curious.

Moscow wasn't built at once...

You may notice as some others are doing little by little steps:
- source cleanups;
- right dependancy;
- headers includes;
- warnings elimination;
- code reading-analyzing (brainwashing, as for me;) and a few line
fixes everywhere.

I think there are members here, who doing things, like that for at
least two years.

You are trying to focus (mostly) on style and sense -- ok. And maybe it's
like to be alone within a crowd. Anyways, as long as you fill, that you
can do that, and patches are accepded, changes are *documented* its ok,
also. Sometimes it's stupid, worthless or something else. If so, then
find more interesting things to do, unless you are going to proof
something to somebody ;E.

Here's, as i can see, almost no place for emotions, only technical stuff
and everything not far from it. See, there isn't any reply on you
message, except this one. I think, because of that.

--
-o--=O`C
 #oo'L O
___=E M

-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [updated PATCH] remove 555 unneeded #includes of sched.h

2007-01-22 Thread Oleg Verych
On 2006-12-29, Tim Schmielau wrote:
[]
 OK, building 2.6.20-rc2-mm1 with all 59 configs from arch/arm/configs 
 with and w/o the patch indeed found one mysterious #include that may not 
 be removed. Thanks, Russell!

 Andrew, please use the attached patch instead of the previous one, it also 
 has a slightly better patch description.

Great job!

About patch. To make it smaller, i think, you better use less
unified context lines `diff -u1'.

Nice done! 


-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH] kbuild: Replace remaining depends with depends on

2007-01-22 Thread Oleg Verych
On 2006-12-13, Robert P. J. Day wrote:

   Replace the very few remaining depends Kconfig directives with
 depends on.

 Signed-off-by: Robert P. J. Day [EMAIL PROTECTED]

 ---

For this kind of fixes, please use
kconfig subsystem instead of
kbuild in subject. Thanks.



-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


<    1   2   3   4   5   6   7   >