linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Leizhen (ThunderTown)" <thunder.leizhen@huawei.com>
To: Jiri Olsa <olsajiri@gmail.com>, Stephen Rothwell <sfr@canb.auug.org.au>
Cc: Luis Chamberlain <mcgrof@kernel.org>,
	David Miller <davem@davemloft.net>,
	Networking <netdev@vger.kernel.org>,
	Alexei Starovoitov <ast@kernel.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	"Linux Next Mailing List" <linux-next@vger.kernel.org>
Subject: Re: linux-next: build failure after merge of the modules tree
Date: Mon, 14 Nov 2022 17:08:43 +0800	[thread overview]
Message-ID: <4d2bd614-028e-ec8c-597c-56353a0a4ccf@huawei.com> (raw)
In-Reply-To: <Y3H12Xyt8ALo+HAU@krava>



On 2022/11/14 16:01, Jiri Olsa wrote:
> On Mon, Nov 14, 2022 at 11:13:50AM +1100, Stephen Rothwell wrote:
>> Hi all,
>>
>> After merging the modules tree, today's linux-next build (powerpc
>> ppc64_defconfig) failed like this:
>>
>> kernel/trace/ftrace.c: In function 'ftrace_lookup_symbols':
>> kernel/trace/ftrace.c:8316:52: error: passing argument 1 of 'module_kallsyms_on_each_symbol' from incompatible pointer type [-Werror=incompatible-pointer-types]
>>  8316 |         found_all = module_kallsyms_on_each_symbol(kallsyms_callback, &args);
>>       |                                                    ^~~~~~~~~~~~~~~~~
>>       |                                                    |
>>       |                                                    int (*)(void *, const char *, long unsigned int)
>> In file included from include/linux/device/driver.h:21,
>>                  from include/linux/device.h:32,
>>                  from include/linux/node.h:18,
>>                  from include/linux/cpu.h:17,
>>                  from include/linux/stop_machine.h:5,
>>                  from kernel/trace/ftrace.c:17:
>> include/linux/module.h:882:48: note: expected 'const char *' but argument is of type 'int (*)(void *, const char *, long unsigned int)'
>>   882 | int module_kallsyms_on_each_symbol(const char *modname,
>>       |                                    ~~~~~~~~~~~~^~~~~~~
>> kernel/trace/ftrace.c:8316:71: error: passing argument 2 of 'module_kallsyms_on_each_symbol' from incompatible pointer type [-Werror=incompatible-pointer-types]
>>  8316 |         found_all = module_kallsyms_on_each_symbol(kallsyms_callback, &args);
>>       |                                                                       ^~~~~
>>       |                                                                       |
>>       |                                                                       struct kallsyms_data *
>> include/linux/module.h:883:42: note: expected 'int (*)(void *, const char *, long unsigned int)' but argument is of type 'struct kallsyms_data *'
>>   883 |                                    int (*fn)(void *, const char *, unsigned long),
>>       |                                    ~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> kernel/trace/ftrace.c:8316:21: error: too few arguments to function 'module_kallsyms_on_each_symbol'
>>  8316 |         found_all = module_kallsyms_on_each_symbol(kallsyms_callback, &args);
>>       |                     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> include/linux/module.h:882:5: note: declared here
>>   882 | int module_kallsyms_on_each_symbol(const char *modname,
>>       |     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>>
>> Caused by commit
>>
>>   90de88426f3c ("livepatch: Improve the search performance of module_kallsyms_on_each_symbol()")
>>
>> from the modules tree interatcing with commit
>>
>>   3640bf8584f4 ("ftrace: Add support to resolve module symbols in ftrace_lookup_symbols")
>>
>> from the next-next tree.
>>
>> I have no idea how to easily fix this up, so I have used the modules
>> tree from next-20221111 for today in the hope someone will send me a fix.
> 
> hi,
> there's no quick fix.. I sent follow up email to the original
> change and cc-ed you

The fastest fix is drop my patch 7/9, 8/9, they depend on the interface change
of patch 6/9,but other patches don't rely on either of them.. And I can repost
them after v6.2-rc1.

Otherwise, you'll need to modify your patch, take the module reference before
invoking callback and put it after it is called, without passing modname.


> 
> thanks,
> jirka
> .
> 

-- 
Regards,
  Zhen Lei

  reply	other threads:[~2022-11-14  9:09 UTC|newest]

Thread overview: 43+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-14  0:13 linux-next: build failure after merge of the modules tree Stephen Rothwell
2022-11-14  8:01 ` Jiri Olsa
2022-11-14  9:08   ` Leizhen (ThunderTown) [this message]
  -- strict thread matches above, loose matches on Subject: below --
2024-02-02  1:03 Stephen Rothwell
2022-02-21 16:07 broonie
2022-02-23  0:32 ` Luis Chamberlain
2022-02-28  5:13   ` Stephen Rothwell
2022-02-28 18:16     ` Luis Chamberlain
2021-02-09 10:08 Stephen Rothwell
2021-02-09 15:16 ` Jessica Yu
2021-02-09 16:06   ` Christoph Hellwig
2021-02-09 21:50   ` Stephen Rothwell
2021-02-10  8:06     ` Jessica Yu
2021-02-10  8:37       ` Masahiro Yamada
2021-02-11  6:19         ` Masahiro Yamada
2021-02-10 12:21       ` Stephen Rothwell
2021-02-10 16:16         ` Jessica Yu
2019-06-25  4:27 Stephen Rothwell
2015-12-01 20:23 Mark Brown
2015-12-02  3:23 ` Rusty Russell
2015-11-27  1:26 Stephen Rothwell
2015-11-27  2:57 ` Rusty Russell
2015-06-25  6:54 Stephen Rothwell
2015-06-25  9:51 ` Dan Streetman
2015-06-24  1:37 Stephen Rothwell
2015-06-24 18:18 ` Dan Streetman
2015-06-24 22:57   ` Stephen Rothwell
2015-06-25  1:50     ` Stephen Rothwell
2014-12-18  2:05 Stephen Rothwell
2014-08-07  3:20 Stephen Rothwell
2014-08-07 11:37 ` Rusty Russell
2014-08-07 13:03   ` Stephen Rothwell
2014-08-07 13:07     ` Rusty Russell
2014-08-08  1:33       ` Stephen Rothwell
2014-07-28  3:58 Stephen Rothwell
2014-07-28 11:38 ` Rusty Russell
2014-03-25  3:02 Stephen Rothwell
2014-03-31  3:45 ` Rusty Russell
2012-11-26  4:10 Stephen Rothwell
2012-11-28 11:02 ` Stanislaw Gruszka
2012-12-03  0:29   ` Rusty Russell
2012-11-02  1:57 Stephen Rothwell
2012-11-02  3:16 ` Rusty Russell

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=4d2bd614-028e-ec8c-597c-56353a0a4ccf@huawei.com \
    --to=thunder.leizhen@huawei.com \
    --cc=ast@kernel.org \
    --cc=davem@davemloft.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-next@vger.kernel.org \
    --cc=mcgrof@kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=olsajiri@gmail.com \
    --cc=sfr@canb.auug.org.au \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).