mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Paul E. McKenney" <paulmck@kernel.org>
To: Hyeonggon Yoo <42.hyeyoo@gmail.com>
Cc: rcu@vger.kernel.org, Josh Triplett <josh@joshtriplett.org>,
	Steven Rostedt <rostedt@goodmis.org>,
	Mathieu Desnoyers <mathieu.desnoyers@efficios.com>,
	Joel Fernandes <joel@joelfernandes.org>,
	linux-kernel@vger.kernel.org
Subject: Re: RCU: undefined reference to irq_work_queue
Date: Thu, 17 Mar 2022 07:00:00 -0700	[thread overview]
Message-ID: <20220317140000.GO4285@paulmck-ThinkPad-P17-Gen-1> (raw)
In-Reply-To: <YjMcZexG/kJepYDi@ip-172-31-19-208.ap-northeast-1.compute.internal>

On Thu, Mar 17, 2022 at 11:32:53AM +0000, Hyeonggon Yoo wrote:
> Hello RCU folks,
> 
> I like to use minimal configuration for kernel development.
> when building with tinyconfig + CONFIG_PREEMPT=y on arm64:
> 
> ld: kernel/rcu/update.o: in function `call_rcu_tasks':
> update.c:(.text+0xb2c): undefined reference to `irq_work_queue'
> update.c:(.text+0xb2c): relocation truncated to fit: R_AARCH64_CALL26 against undefined symbol `irq_work_queue'
> make: *** [Makefile:1155: vmlinux] Error 1
> 
> It seems RCU calls irq_work_queue() without checking if CONFIG_IRQ_WORK is enabled.

Indeed it does!

And kernel/rcu/Kconfig shows why:

config TASKS_TRACE_RCU
	def_bool 0
	select IRQ_WORK
	help
	  This option enables a task-based RCU implementation that uses
	  explicit rcu_read_lock_trace() read-side markers, and allows
	  these readers to appear in the idle loop as well as on the CPU
	  hotplug code paths.  It can force IPIs on online CPUs, including
	  idle ones, so use with caution.

So the solution is to further minimize your configuration so as to
deselect TASKS_TRACE_RCU.  This means making sure that both BPF and
the various RCU torture tests are all deselected.

Or turn on IRQ_WORK, for example, if you need to use BPF.

							Thanx, Paul

  reply	other threads:[~2022-03-17 14:00 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-03-17 11:32 Hyeonggon Yoo
2022-03-17 14:00 ` Paul E. McKenney [this message]
2022-03-17 15:24   ` Hyeonggon Yoo
2022-03-17 16:20     ` Paul E. McKenney
2022-03-17 16:45       ` Hyeonggon Yoo
2022-03-17 17:36         ` Paul E. McKenney
2022-03-17 20:26           ` Randy Dunlap
2022-03-17 20:29             ` Paul E. McKenney
2022-03-17 20:31               ` Randy Dunlap
2022-03-17 20:41           ` Zhouyi Zhou
2022-03-17 20:53             ` Paul E. McKenney
2022-03-18 14:42               ` Hyeonggon Yoo
2022-03-17 15:22 ` Zhouyi Zhou
2022-03-17 15:54   ` Hyeonggon Yoo

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=20220317140000.GO4285@paulmck-ThinkPad-P17-Gen-1 \
    --to=paulmck@kernel.org \
    --cc=42.hyeyoo@gmail.com \
    --cc=joel@joelfernandes.org \
    --cc=josh@joshtriplett.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mathieu.desnoyers@efficios.com \
    --cc=rcu@vger.kernel.org \
    --cc=rostedt@goodmis.org \
    /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

all inboxes | Powered by JetHome®