Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-09-10 Thread Linus Torvalds
On Sun, Sep 10, 2017 at 6:58 AM, Masahiro Yamada wrote: > > "is_reserved_word()" sounds like a boolean function > that returns 1 or 0. > Maybe, the choice of the function name was not nice. Yeah, not great name. That's the old name, though - I didn't change that

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-09-10 Thread Linus Torvalds
On Sun, Sep 10, 2017 at 6:58 AM, Masahiro Yamada wrote: > > "is_reserved_word()" sounds like a boolean function > that returns 1 or 0. > Maybe, the choice of the function name was not nice. Yeah, not great name. That's the old name, though - I didn't change that part, I just changed how it used

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-09-10 Thread Masahiro Yamada
Hi Sam, 2017-09-09 15:39 GMT+09:00 Sam Ravnborg : > On Fri, Sep 08, 2017 at 02:38:23PM -0700, Linus Torvalds wrote: >> On Fri, Sep 8, 2017 at 11:39 AM, Linus Torvalds >> wrote: >> > >> > Strange. Does anybody see what the pattern to the failure

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-09-10 Thread Masahiro Yamada
Hi Sam, 2017-09-09 15:39 GMT+09:00 Sam Ravnborg : > On Fri, Sep 08, 2017 at 02:38:23PM -0700, Linus Torvalds wrote: >> On Fri, Sep 8, 2017 at 11:39 AM, Linus Torvalds >> wrote: >> > >> > Strange. Does anybody see what the pattern to the failure is? >> >> Found it. Stupid special case for

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-09-10 Thread Masahiro Yamada
Hi Linus, 2017-09-09 6:38 GMT+09:00 Linus Torvalds : > On Fri, Sep 8, 2017 at 11:39 AM, Linus Torvalds > wrote: >> >> Strange. Does anybody see what the pattern to the failure is? > > Found it. Stupid special case for 'typeof()' that

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-09-10 Thread Masahiro Yamada
Hi Linus, 2017-09-09 6:38 GMT+09:00 Linus Torvalds : > On Fri, Sep 8, 2017 at 11:39 AM, Linus Torvalds > wrote: >> >> Strange. Does anybody see what the pattern to the failure is? > > Found it. Stupid special case for 'typeof()' that used > is_reserved_word() in ways I hadn't realized. > > Fix

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-09-09 Thread Sam Ravnborg
On Fri, Sep 08, 2017 at 02:38:23PM -0700, Linus Torvalds wrote: > On Fri, Sep 8, 2017 at 11:39 AM, Linus Torvalds > wrote: > > > > Strange. Does anybody see what the pattern to the failure is? > > Found it. Stupid special case for 'typeof()' that used >

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-09-09 Thread Sam Ravnborg
On Fri, Sep 08, 2017 at 02:38:23PM -0700, Linus Torvalds wrote: > On Fri, Sep 8, 2017 at 11:39 AM, Linus Torvalds > wrote: > > > > Strange. Does anybody see what the pattern to the failure is? > > Found it. Stupid special case for 'typeof()' that used > is_reserved_word() in ways I hadn't

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-09-08 Thread Linus Torvalds
On Fri, Sep 8, 2017 at 11:39 AM, Linus Torvalds wrote: > > Strange. Does anybody see what the pattern to the failure is? Found it. Stupid special case for 'typeof()' that used is_reserved_word() in ways I hadn't realized. Fix committed. Linus

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-09-08 Thread Linus Torvalds
On Fri, Sep 8, 2017 at 11:39 AM, Linus Torvalds wrote: > > Strange. Does anybody see what the pattern to the failure is? Found it. Stupid special case for 'typeof()' that used is_reserved_word() in ways I hadn't realized. Fix committed. Linus

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-09-08 Thread Linus Torvalds
On Fri, Sep 8, 2017 at 11:01 AM, Linus Torvalds wrote: > > It doesn't seem to happen for every exported symbol, though. Odd. Fascinating. Picking one file at random that shows this, I did net/ceph/mon_client.c. The version file that gets generated for that looks

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-09-08 Thread Linus Torvalds
On Fri, Sep 8, 2017 at 11:01 AM, Linus Torvalds wrote: > > It doesn't seem to happen for every exported symbol, though. Odd. Fascinating. Picking one file at random that shows this, I did net/ceph/mon_client.c. The version file that gets generated for that looks like this:

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-09-08 Thread Linus Torvalds
On Fri, Sep 8, 2017 at 10:22 AM, Linus Torvalds wrote: > > Of course, I only did a "make allmodconfig" to test the MODVERSIONS > case, I didn't actually install the modules. Is that error perhaps > only detected at install time? Oh, I take that back. I just got a

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-09-08 Thread Linus Torvalds
On Fri, Sep 8, 2017 at 10:22 AM, Linus Torvalds wrote: > > Of course, I only did a "make allmodconfig" to test the MODVERSIONS > case, I didn't actually install the modules. Is that error perhaps > only detected at install time? Oh, I take that back. I just got a ton of warnings with my

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-09-08 Thread Linus Torvalds
On Thu, Sep 7, 2017 at 11:18 PM, Masahiro Yamada wrote: > > If CONFIG_MODVERSIONS is enabled, > I notice lots of error messages. > WARNING: EXPORT symbol "finish_open" [vmlinux] version generation > failed, symbol will not be versioned > > So, I think something was

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-09-08 Thread Linus Torvalds
On Thu, Sep 7, 2017 at 11:18 PM, Masahiro Yamada wrote: > > If CONFIG_MODVERSIONS is enabled, > I notice lots of error messages. > WARNING: EXPORT symbol "finish_open" [vmlinux] version generation > failed, symbol will not be versioned > > So, I think something was broken in scripts/genksyms/. >

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-09-08 Thread Masahiro Yamada
Hi Linus, Very sorry that I had not responded quickly. When I was digging into tool version dependency, as you pointed out, gperf is a problem (but seemed one time breakage for gperf 3.1) flex seemed very stable for a long time. bison seemed a bit problem if old version is used. But, I did

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-09-08 Thread Masahiro Yamada
Hi Linus, Very sorry that I had not responded quickly. When I was digging into tool version dependency, as you pointed out, gperf is a problem (but seemed one time breakage for gperf 3.1) flex seemed very stable for a long time. bison seemed a bit problem if old version is used. But, I did

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-08-19 Thread Linus Torvalds
On Sat, Aug 19, 2017 at 10:14 AM, Linus Torvalds wrote: > > Anybody want to look at just getting rid of the gperf use? I took a stab at it. It wasn't too bad, although I think this needs a *lot* of testing, and I think it needs checking of Makefile dependencies

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-08-19 Thread Linus Torvalds
On Sat, Aug 19, 2017 at 10:14 AM, Linus Torvalds wrote: > > Anybody want to look at just getting rid of the gperf use? I took a stab at it. It wasn't too bad, although I think this needs a *lot* of testing, and I think it needs checking of Makefile dependencies etc. NOTE NOTE NOTE! This may be

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-08-19 Thread Linus Torvalds
On Sat, Aug 19, 2017 at 10:03 AM, Linus Torvalds wrote: > > So one of the advantages of the pre-shipped files is that we can avoid > that kind of crazy version issues with the tools. Side note: the traditional way to handle this is autoconf etc. Since I think

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-08-19 Thread Linus Torvalds
On Sat, Aug 19, 2017 at 10:03 AM, Linus Torvalds wrote: > > So one of the advantages of the pre-shipped files is that we can avoid > that kind of crazy version issues with the tools. Side note: the traditional way to handle this is autoconf etc. Since I think autoconf is evil crap, I refuse to

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-08-19 Thread Linus Torvalds
On Sat, Aug 19, 2017 at 1:49 AM, Masahiro Yamada wrote: > > Here is one question. Is it acceptable to use those rules all the time? > That is, generate those C files by flex, bison, gperf during the > kernel building. Yeah, I think we probably should do that.

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-08-19 Thread Linus Torvalds
On Sat, Aug 19, 2017 at 1:49 AM, Masahiro Yamada wrote: > > Here is one question. Is it acceptable to use those rules all the time? > That is, generate those C files by flex, bison, gperf during the > kernel building. Yeah, I think we probably should do that. However, when I just tested, I

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-08-19 Thread Cao jin
Hi, I am stuck in a similar problem recent days by chance. I am just curious about the purpose of introduction of these *_shipped file, are they just for user's convenience when user doesn't install the those tools? -- Sincerely, Cao jin On 08/19/2017 04:49 PM, Masahiro Yamada wrote: > In

Re: [RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-08-19 Thread Cao jin
Hi, I am stuck in a similar problem recent days by chance. I am just curious about the purpose of introduction of these *_shipped file, are they just for user's convenience when user doesn't install the those tools? -- Sincerely, Cao jin On 08/19/2017 04:49 PM, Masahiro Yamada wrote: > In

[RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-08-19 Thread Masahiro Yamada
In Linux build system convention, we do not run tools such as flex, bison, gperf during the kernel building. Instead, manage generated C files in the repository with _shipped suffixes. They are simply shipped (copied) removing the _shipped suffixes during the kernel building. Commit 7373f4f83c71

[RFC PATCH 0/3] kbuild: generate intermediate C files instead of copying _shipped files

2017-08-19 Thread Masahiro Yamada
In Linux build system convention, we do not run tools such as flex, bison, gperf during the kernel building. Instead, manage generated C files in the repository with _shipped suffixes. They are simply shipped (copied) removing the _shipped suffixes during the kernel building. Commit 7373f4f83c71