[rcu:rcu/dev 14/15] kernel/time/tick-sched.c:820: undefined reference to `__divdi3'

From: kbuild test robot
Date: Wed Aug 16 2017 - 01:20:39 EST


tree: https://git.kernel.org/pub/scm/linux/kernel/git/paulmck/linux-rcu.git rcu/dev
head: 551164572a4a41968abd020ec24499085cc2adf7
commit: 33103e7b1f89ef432dfe3337d2a6932cdf5c1312 [14/15] EXP: Trace tick return from tick_nohz_stop_sched_tick
config: mips-nlm_xlr_defconfig (attached as .config)
compiler: mips-linux-gnu-gcc (Debian 6.1.1-9) 6.1.1 20160705
reproduce:
wget https://raw.githubusercontent.com/01org/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
git checkout 33103e7b1f89ef432dfe3337d2a6932cdf5c1312
# save the attached .config to linux build tree
make.cross ARCH=mips

All errors (new ones prefixed by >>):

kernel/time/tick-sched.o: In function `tick_nohz_stop_sched_tick':
>> kernel/time/tick-sched.c:820: undefined reference to `__divdi3'

vim +820 kernel/time/tick-sched.c

758
759 /* Calculate the next expiry time */
760 if (delta < (KTIME_MAX - basemono))
761 expires = basemono + delta;
762 else
763 expires = KTIME_MAX;
764
765 expires = min_t(u64, expires, next_tick);
766 tick = expires;
767
768 /* Skip reprogram of event if its not changed */
769 if (ts->tick_stopped && (expires == ts->next_tick)) {
770 /* Sanity check: make sure clockevent is actually programmed */
771 if (tick == KTIME_MAX || ts->next_tick == hrtimer_get_expires(&ts->sched_timer))
772 goto out;
773
774 WARN_ON_ONCE(1);
775 printk_once("basemono: %llu ts->next_tick: %llu dev->next_event: %llu timer->active: %d timer->expires: %llu\n",
776 basemono, ts->next_tick, dev->next_event,
777 hrtimer_active(&ts->sched_timer), hrtimer_get_expires(&ts->sched_timer));
778 }
779
780 /*
781 * nohz_stop_sched_tick can be called several times before
782 * the nohz_restart_sched_tick is called. This happens when
783 * interrupts arrive which do not cause a reschedule. In the
784 * first call we save the current tick time, so we can restart
785 * the scheduler tick in nohz_restart_sched_tick.
786 */
787 if (!ts->tick_stopped) {
788 calc_load_nohz_start();
789 cpu_load_update_nohz_start();
790
791 ts->last_tick = hrtimer_get_expires(&ts->sched_timer);
792 ts->tick_stopped = 1;
793 trace_tick_stop(1, TICK_DEP_MASK_NONE);
794 }
795
796 ts->next_tick = tick;
797
798 /*
799 * If the expiration time == KTIME_MAX, then we simply stop
800 * the tick timer.
801 */
802 if (unlikely(expires == KTIME_MAX)) {
803 if (ts->nohz_mode == NOHZ_MODE_HIGHRES)
804 hrtimer_cancel(&ts->sched_timer);
805 goto out;
806 }
807
808 hrtimer_set_expires(&ts->sched_timer, tick);
809
810 if (ts->nohz_mode == NOHZ_MODE_HIGHRES)
811 hrtimer_start_expires(&ts->sched_timer, HRTIMER_MODE_ABS_PINNED);
812 else
813 tick_program_event(tick, 1);
814 out:
815 /*
816 * Update the estimated sleep length until the next timer
817 * (not only the tick).
818 */
819 ts->sleep_length = ktime_sub(dev->next_event, now);
> 820 trace_printk("tick_nohz_stop_sched_tick: %lld\n", (tick - ktime_get()) / 1000);
821 return tick;
822 }
823

---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation

Attachment: .config.gz
Description: application/gzip