mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6.git
synced 2026-05-01 15:15:19 -04:00
arm64: rsi: Add automatic arm-cca-guest module loading
The TSM module provides guest identification and attestation when a guest runs in CCA realm mode. By creating a dummy platform device, let's ensure the module is automatically loaded. The udev daemon loads the TSM module after it receives a device addition event. Once that happens, it can be used earlier in the boot process to decrypt the rootfs. Signed-off-by: Jeremy Linton <jeremy.linton@arm.com> Reviewed-by: Gavin Shan <gshan@redhat.com> Reviewed-by: Steven Price <steven.price@arm.com> Link: https://lore.kernel.org/r/20241220181236.172060-2-jeremy.linton@arm.com Signed-off-by: Will Deacon <will@kernel.org>
This commit is contained in:
committed by
Will Deacon
parent
fac04efc5c
commit
a1edec2245
@@ -6,6 +6,7 @@
|
||||
#include <linux/arm-smccc.h>
|
||||
#include <linux/cc_platform.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/mod_devicetable.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/smp.h>
|
||||
#include <linux/tsm.h>
|
||||
@@ -219,6 +220,13 @@ static void __exit arm_cca_guest_exit(void)
|
||||
}
|
||||
module_exit(arm_cca_guest_exit);
|
||||
|
||||
/* modalias, so userspace can autoload this module when RSI is available */
|
||||
static const struct platform_device_id arm_cca_match[] __maybe_unused = {
|
||||
{ RSI_PDEV_NAME, 0},
|
||||
{ }
|
||||
};
|
||||
|
||||
MODULE_DEVICE_TABLE(platform, arm_cca_match);
|
||||
MODULE_AUTHOR("Sami Mujawar <sami.mujawar@arm.com>");
|
||||
MODULE_DESCRIPTION("Arm CCA Guest TSM Driver");
|
||||
MODULE_LICENSE("GPL");
|
||||
|
||||
Reference in New Issue
Block a user