]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commit
static_call: Fix static_call_update() sanity check
authorPeter Zijlstra <peterz@infradead.org>
Thu, 18 Mar 2021 10:31:51 +0000 (11:31 +0100)
committerSeth Forshee <seth.forshee@canonical.com>
Thu, 8 Apr 2021 20:42:18 +0000 (15:42 -0500)
commitd4ea1929923d567570667f63d115b38895c31204
treebf0fa00964116419bb1c670058ad81dc548eb7e8
parente847de68d249d7353db2bd314a7a49e4c7957ebb
static_call: Fix static_call_update() sanity check

BugLink: https://bugs.launchpad.net/bugs/1921712
commit 38c93587375053c5b9ef093f4a5ea754538cba32 upstream.

Sites that match init_section_contains() get marked as INIT. For
built-in code init_sections contains both __init and __exit text. OTOH
kernel_text_address() only explicitly includes __init text (and there
are no __exit text markers).

Match what jump_label already does and ignore the warning for INIT
sites. Also see the excellent changelog for commit: 8f35eaa5f2de
("jump_label: Don't warn on __exit jump entries")

Fixes: 9183c3f9ed710 ("static_call: Add inline static call infrastructure")
Reported-by: Sumit Garg <sumit.garg@linaro.org>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Acked-by: Jarkko Sakkinen <jarkko@kernel.org>
Tested-by: Sumit Garg <sumit.garg@linaro.org>
Link: https://lkml.kernel.org/r/20210318113610.739542434@infradead.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Andrea Righi <andrea.righi@canonical.com>
kernel/jump_label.c
kernel/static_call.c