On Fri, Apr 4, 2025 at 2:56 PM Masahiro Yamada <[email protected]> wrote:
>
> On Fri, Apr 4, 2025 at 7:25 PM Uros Bizjak <[email protected]> wrote:
> >
> > Current version of genksyms doesn't know anything about __typeof_unqual__()
> > operator.  Avoid the usage of __typeof_unqual__() with genksyms to prevent
> > errors when symbols are versioned.
> >
> > There were no problems with gendwarfksyms.
> >
> > Signed-off-by: Uros Bizjak <[email protected]>
> > Fixes: ac053946f5c40 ("compiler.h: introduce TYPEOF_UNQUAL() macro")
> > Reported-by: Paul Menzel <[email protected]>
> > Closes: 
> > https://lore.kernel.org/lkml/[email protected]/
> > Cc: Sami Tolvanen <[email protected]>
> > Cc: Andrew Morton <[email protected]>
> > ---
>
>
> Why don't you add it to the genksyms keyword table?

It doesn't work, even if I patch it with an even more elaborate patch
(attached).

I guess some more surgery will be needed, but for now a fallback works
as expected.

Uros.
diff --git a/scripts/genksyms/keywords.c b/scripts/genksyms/keywords.c
index b85e0979a00c..8d0167df47ea 100644
--- a/scripts/genksyms/keywords.c
+++ b/scripts/genksyms/keywords.c
@@ -17,6 +17,8 @@ static struct resword {
        { "__signed__", SIGNED_KEYW },
        { "__typeof", TYPEOF_KEYW },
        { "__typeof__", TYPEOF_KEYW },
+       { "__typeof_unqual", TYPEOF_KEYW },
+       { "__typeof_unqual__", TYPEOF_KEYW },
        { "__volatile", VOLATILE_KEYW },
        { "__volatile__", VOLATILE_KEYW },
        { "__builtin_va_list", VA_LIST_KEYW },
@@ -57,6 +59,7 @@ static struct resword {
        { "struct", STRUCT_KEYW },
        { "typedef", TYPEDEF_KEYW },
        { "typeof", TYPEOF_KEYW },
+       { "typeof_unqual", TYPEOF_KEYW },
        { "union", UNION_KEYW },
        { "unsigned", UNSIGNED_KEYW },
        { "void", VOID_KEYW },

Reply via email to