From: "Paul E. McKenney" <paulmck@kernel.org>
To: kernel test robot <lkp@intel.com>
Cc: kbuild-all@lists.01.org, linux-kernel@vger.kernel.org
Subject: Re: [rcu:dev.2020.06.02a 85/90] kernel/smp.c:122: undefined reference to `__udivdi3'
Date: Fri, 5 Jun 2020 15:11:32 -0700 [thread overview]
Message-ID: <20200605221132.GD4455@paulmck-ThinkPad-P72> (raw)
In-Reply-To: <202006060528.SmyaIPRq%lkp@intel.com>
On Sat, Jun 06, 2020 at 05:38:31AM +0800, kernel test robot wrote:
> tree: https://git.kernel.org/pub/scm/linux/kernel/git/paulmck/linux-rcu.git dev.2020.06.02a
> head: 5216948905dd07a84cef8a7dc72c2ec076802efd
> commit: 92ebbb71443dced2019cd24b737ce60b03a29e10 [85/90] EXP kernel/smp: Provide CSD lock timeout diagnostics
> config: i386-randconfig-c001-20200605 (attached as .config)
> compiler: gcc-9 (Debian 9.3.0-13) 9.3.0
>
> If you fix the issue, kindly add following tag as appropriate
> Reported-by: kernel test robot <lkp@intel.com>
>
> All errors (new ones prefixed by >>, old ones prefixed by <<):
>
> ld: kernel/smp.o: in function `csd_lock_wait':
> >> kernel/smp.c:122: undefined reference to `__udivdi3'
> >> ld: kernel/smp.c:128: undefined reference to `__udivdi3'
> >> ld: kernel/smp.c:136: undefined reference to `__umoddi3'
> ld: kernel/smp.c:136: undefined reference to `__udivdi3'
> >> ld: kernel/smp.c:122: undefined reference to `__udivdi3'
> >> ld: kernel/smp.c:128: undefined reference to `__udivdi3'
> >> ld: kernel/smp.c:136: undefined reference to `__umoddi3'
> ld: kernel/smp.c:136: undefined reference to `__udivdi3'
> >> ld: kernel/smp.c:122: undefined reference to `__udivdi3'
> >> ld: kernel/smp.c:128: undefined reference to `__udivdi3'
> >> ld: kernel/smp.c:136: undefined reference to `__umoddi3'
> ld: kernel/smp.c:136: undefined reference to `__udivdi3'
> >> ld: kernel/smp.c:122: undefined reference to `__udivdi3'
> >> ld: kernel/smp.c:128: undefined reference to `__udivdi3'
> >> ld: kernel/smp.c:136: undefined reference to `__umoddi3'
> ld: kernel/smp.c:136: undefined reference to `__udivdi3'
Good catch, thank you, fixup patch applied.
Thanx, Paul
> vim +122 kernel/smp.c
>
> 107
> 108 /*
> 109 * csd_lock/csd_unlock used to serialize access to per-cpu csd resources
> 110 *
> 111 * For non-synchronous ipi calls the csd can still be in use by the
> 112 * previous function call. For multi-cpu calls its even more interesting
> 113 * as we'll have to ensure no other cpu is observing our csd.
> 114 */
> 115 static __always_inline void csd_lock_wait(call_single_data_t *csd)
> 116 {
> 117 int bug_id = 0;
> 118 int cpu;
> 119 call_single_data_t *cpu_cur_csd;
> 120 u64 ts0, ts1, ts2, ts_delta;
> 121
> > 122 ts1 = ts0 = sched_clock() / 1000 / 1000;
> 123 for (;;) {
> 124 unsigned long flags = READ_ONCE(csd->flags);
> 125
> 126 if (!(flags & CSD_FLAG_LOCK))
> 127 break;
> > 128 ts2 = sched_clock() / 1000 / 1000;
> 129 ts_delta = ts2 - ts1;
> 130 if (unlikely(ts_delta > CSD_LOCK_TIMEOUT)) {
> 131 bug_id = atomic_inc_return(&csd_bug_count);
> 132 cpu = csd->cpu;
> 133 smp_mb(); // No stale cur_csd values!
> 134 cpu_cur_csd = per_cpu(cur_csd, cpu);
> 135 smp_mb(); // No refetching cur_csd values!
> > 136 printk("csd: Detected non-responsive CSD lock (#%d) on CPU#%d, waiting %Ld.%03Ld secs for CPU#%02d %pf(%ps), currently %s.\n",
> 137 bug_id, raw_smp_processor_id(),
> 138 ts_delta/1000ULL, ts_delta % 1000ULL, cpu,
> 139 csd->func, csd->info,
> 140 !cpu_cur_csd ? "unresponsive"
> 141 : csd == cpu_cur_csd
> 142 ? "handling this request"
> 143 : "handling prior request");
> 144 if (!trigger_single_cpu_backtrace(cpu))
> 145 dump_cpu_task(cpu);
> 146 if (!cpu_cur_csd) {
> 147 printk("csd: Re-sending CSD lock (#%d) IPI from CPU#%02d to CPU#%02d\n", bug_id, raw_smp_processor_id(), cpu);
> 148 arch_send_call_function_single_ipi(cpu);
> 149 }
> 150 dump_stack();
> 151 ts1 = ts2;
> 152 }
> 153 cpu_relax();
> 154 }
> 155 smp_acquire__after_ctrl_dep();
> 156 if (unlikely(bug_id))
> 157 printk("csd: CSD lock (#%d) got unstuck on CPU#%02d, CPU#%02d released the lock after all. Phew!\n", bug_id, raw_smp_processor_id(), cpu);
> 158 }
> 159
>
> ---
> 0-DAY CI Kernel Test Service, Intel Corporation
> https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
prev parent reply other threads:[~2020-06-05 22:11 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-06-05 21:38 [rcu:dev.2020.06.02a 85/90] kernel/smp.c:122: undefined reference to `__udivdi3' kernel test robot
2020-06-05 22:11 ` Paul E. McKenney [this message]
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=20200605221132.GD4455@paulmck-ThinkPad-P72 \
--to=paulmck@kernel.org \
--cc=kbuild-all@lists.01.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lkp@intel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox