]> git.baikalelectronics.ru Git - kernel.git/commit
genksyms: fix gperf removal conversion
authorLinus Torvalds <torvalds@linux-foundation.org>
Fri, 8 Sep 2017 21:32:34 +0000 (14:32 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Fri, 8 Sep 2017 21:32:34 +0000 (14:32 -0700)
commita91916f201e1768c77b25d0c2a0018fb15c75f31
treea979c9d7dcc4d7f75f6417e437277b89424f3fc8
parent475e42726982cb76f17f220f6576e237500a4d1b
genksyms: fix gperf removal conversion

I had stupidly missed one special use of 'is_reserved_word()' when I
converted the code to avoid gperf.

I had changed that function to return the token ID directly rather than
a pointer to the token descriptor structure, but that meant that the
test for "is this a reserved word" changed from checking the return
value against NULL, to checking that it wasn't negative.

And while I had converted the main token parser over, I missed the
special case of the typeof phrase handling.  And since our dependency
chain for genksyms does not include the genksyms program itself
changing, my kernel rebuild didn't show the problem.

Fixes: 471f6d5a33c3 ("Remove gperf usage from toolchain")
Reported-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
scripts/genksyms/lex.l
scripts/genksyms/lex.lex.c_shipped