From: Rusty Russell <rusty@rustcorp.com.au>
To: Masahiro Yamada <yamada.masahiro@socionext.com>,
linux-kbuild@vger.kernel.org
Cc: Arnd Bergmann <arnd@arndb.de>,
Michal Marek <michal.lkml@markovi.net>,
linux-kernel@vger.kernel.org, Jessica Yu <jeyu@kernel.org>
Subject: Re: [PATCH] modpost: remove leftover symbol prefix handling for module device table
Date: Sat, 29 Sep 2018 16:30:22 +0930 [thread overview]
Message-ID: <87bm8giy9l.fsf@rustcorp.com.au> (raw)
In-Reply-To: <1538115715-10078-1-git-send-email-yamada.masahiro@socionext.com>
Please send this to the module maintainer (CC'd).
Masahiro Yamada <yamada.masahiro@socionext.com> writes:
> Blackfin and metag were the only architectures that prefix symbols with
> an underscore. They were removed by commit 4ba66a976072 ("arch: remove
> blackfin port"), commit bb6fb6dfcc17 ("metag: Remove arch/metag/"),
> respectively.
>
> It is no longer necessary to handle <prefix> part of module device
> table symbols.
>
> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
> ---
>
> scripts/mod/file2alias.c | 7 +++----
> 1 file changed, 3 insertions(+), 4 deletions(-)
>
> diff --git a/scripts/mod/file2alias.c b/scripts/mod/file2alias.c
> index 7be4369..ba4ebc4 100644
> --- a/scripts/mod/file2alias.c
> +++ b/scripts/mod/file2alias.c
> @@ -1415,11 +1415,10 @@ void handle_moddevtable(struct module *mod, struct elf_info *info,
> if (ELF_ST_TYPE(sym->st_info) != STT_OBJECT)
> return;
>
> - /* All our symbols are of form <prefix>__mod_<name>__<identifier>_device_table. */
> - name = strstr(symname, "__mod_");
> - if (!name)
> + /* All our symbols are of form __mod_<name>__<identifier>_device_table. */
> + if (strncmp(symname, "__mod_", strlen("__mod_")))
> return;
> - name += strlen("__mod_");
> + name = symname + strlen("__mod_");
> namelen = strlen(name);
> if (namelen < strlen("_device_table"))
> return;
> --
> 2.7.4
WARNING: multiple messages have this Message-ID (diff)
From: Rusty Russell <rusty@rustcorp.com.au>
To: Masahiro Yamada <yamada.masahiro@socionext.com>,
linux-kbuild@vger.kernel.org
Cc: Arnd Bergmann <arnd@arndb.de>,
Masahiro Yamada <yamada.masahiro@socionext.com>,
Michal Marek <michal.lkml@markovi.net>,
linux-kernel@vger.kernel.org, Jessica Yu <jeyu@kernel.org>
Subject: Re: [PATCH] modpost: remove leftover symbol prefix handling for module device table
Date: Sat, 29 Sep 2018 16:30:22 +0930 [thread overview]
Message-ID: <87bm8giy9l.fsf@rustcorp.com.au> (raw)
In-Reply-To: <1538115715-10078-1-git-send-email-yamada.masahiro@socionext.com>
Please send this to the module maintainer (CC'd).
Masahiro Yamada <yamada.masahiro@socionext.com> writes:
> Blackfin and metag were the only architectures that prefix symbols with
> an underscore. They were removed by commit 4ba66a976072 ("arch: remove
> blackfin port"), commit bb6fb6dfcc17 ("metag: Remove arch/metag/"),
> respectively.
>
> It is no longer necessary to handle <prefix> part of module device
> table symbols.
>
> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
> ---
>
> scripts/mod/file2alias.c | 7 +++----
> 1 file changed, 3 insertions(+), 4 deletions(-)
>
> diff --git a/scripts/mod/file2alias.c b/scripts/mod/file2alias.c
> index 7be4369..ba4ebc4 100644
> --- a/scripts/mod/file2alias.c
> +++ b/scripts/mod/file2alias.c
> @@ -1415,11 +1415,10 @@ void handle_moddevtable(struct module *mod, struct elf_info *info,
> if (ELF_ST_TYPE(sym->st_info) != STT_OBJECT)
> return;
>
> - /* All our symbols are of form <prefix>__mod_<name>__<identifier>_device_table. */
> - name = strstr(symname, "__mod_");
> - if (!name)
> + /* All our symbols are of form __mod_<name>__<identifier>_device_table. */
> + if (strncmp(symname, "__mod_", strlen("__mod_")))
> return;
> - name += strlen("__mod_");
> + name = symname + strlen("__mod_");
> namelen = strlen(name);
> if (namelen < strlen("_device_table"))
> return;
> --
> 2.7.4
next prev parent reply other threads:[~2018-09-29 13:27 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-09-28 6:21 [PATCH] modpost: remove leftover symbol prefix handling for module device table Masahiro Yamada
2018-09-29 7:00 ` Rusty Russell [this message]
2018-09-29 7:00 ` Rusty Russell
2018-09-29 16:44 ` Masahiro Yamada
2018-10-09 15:00 ` Masahiro Yamada
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87bm8giy9l.fsf@rustcorp.com.au \
--to=rusty@rustcorp.com.au \
--cc=arnd@arndb.de \
--cc=jeyu@kernel.org \
--cc=linux-kbuild@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=michal.lkml@markovi.net \
--cc=yamada.masahiro@socionext.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.