Huacai Chen 9e7dab7eda tpm: eventlog: Fix section mismatch for DEBUG_SECTION_MISMATCH
[ Upstream commit bed4593645366ad7362a3aa7bc0d100d8d8236a8 ]

If DEBUG_SECTION_MISMATCH enabled, __calc_tpm2_event_size() will not be
inlined, this cause section mismatch like this:

WARNING: modpost: vmlinux.o(.text.unlikely+0xe30c): Section mismatch in reference from the variable L0 to the function .init.text:early_ioremap()
The function L0() references
the function __init early_memremap().
This is often because L0 lacks a __init
annotation or the annotation of early_ioremap is wrong.

Fix it by using __always_inline instead of inline for the called-once
function __calc_tpm2_event_size().

Fixes: 44038bc514a2 ("tpm: Abstract crypto agile event size calculations")
Cc: stable@vger.kernel.org # v5.3
Reported-by: WANG Xuerui <git@xen0n.name>
Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
Signed-off-by: Jarkko Sakkinen <jarkko@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2022-08-17 14:24:28 +02:00
..
2021-07-21 19:54:21 -07:00
2021-08-31 16:43:06 -07:00
2021-09-20 12:43:34 +01:00
2021-09-01 15:25:28 -07:00
2021-08-29 14:47:42 +03:00
2022-08-17 14:23:11 +02:00
2021-08-31 09:41:22 -07:00
2021-08-16 10:50:32 -06:00
2021-08-26 16:52:03 -07:00
2021-12-14 10:57:11 +01:00
2022-07-07 17:53:26 +02:00
2021-11-25 09:48:41 +01:00
2021-07-20 09:20:49 -07:00
2021-09-07 21:17:28 +02:00
2021-08-26 15:32:28 -04:00
2021-07-27 11:00:36 +02:00
2021-09-06 07:20:56 -04:00
2021-07-26 15:09:44 +02:00
2021-07-27 20:11:45 +01:00
2021-07-27 20:11:44 +01:00
2021-09-03 09:58:13 -07:00
2021-08-05 11:46:42 +01:00
2021-09-03 10:44:35 -07:00
2022-04-13 20:59:03 +02:00
2021-07-27 17:05:06 +01:00
2021-07-27 09:29:15 +02:00
2022-08-17 14:24:08 +02:00
2022-07-23 12:53:57 +02:00
2021-11-18 19:15:51 +01:00
2022-07-12 16:35:08 +02:00
2021-06-29 10:53:53 -07:00
2021-07-01 11:06:05 -07:00
2022-06-09 10:23:32 +02:00
2021-09-07 12:27:27 -07:00
2021-09-17 13:52:17 +01:00
2021-07-06 10:37:46 -05:00
2021-09-07 19:13:42 -07:00
2022-07-02 16:41:17 +02:00
2021-08-18 22:08:24 +02:00
2021-09-02 21:38:56 +02:00
2021-10-07 16:51:57 +02:00
2021-08-17 17:50:51 +02:00
2022-07-12 16:35:08 +02:00
2021-08-31 16:43:06 -07:00
2021-08-06 13:41:48 -07:00
2021-08-19 09:02:55 +09:00
2021-11-21 13:44:12 +01:00
2021-07-01 11:06:03 -07:00
2021-09-09 13:25:49 -07:00
2021-07-27 12:17:21 +02:00
2022-07-29 17:25:32 +02:00
2021-07-27 12:12:08 +02:00
2021-09-08 15:32:35 -07:00
2021-08-11 06:44:24 -04:00