xref: /linux/drivers/firmware/qcom/Kconfig (revision 170aafe35cb98e0f3fbacb446ea86389fbce22ea)
1# SPDX-License-Identifier: GPL-2.0-only
2#
3# For a description of the syntax of this configuration file,
4# see Documentation/kbuild/kconfig-language.rst.
5#
6
7menu "Qualcomm firmware drivers"
8
9config QCOM_SCM
10	select QCOM_TZMEM
11	tristate
12
13config QCOM_TZMEM
14	tristate
15	select GENERIC_ALLOCATOR
16
17choice
18	prompt "TrustZone interface memory allocator mode"
19	depends on QCOM_TZMEM
20	default QCOM_TZMEM_MODE_GENERIC
21	help
22	  Selects the mode of the memory allocator providing memory buffers of
23	  suitable format for sharing with the TrustZone. If in doubt, select
24	  'Generic'.
25
26config QCOM_TZMEM_MODE_GENERIC
27	bool "Generic"
28	help
29	  Use the generic allocator mode. The memory is page-aligned, non-cachable
30	  and physically contiguous.
31
32config QCOM_TZMEM_MODE_SHMBRIDGE
33	bool "SHM Bridge"
34	help
35	  Use Qualcomm Shared Memory Bridge. The memory has the same alignment as
36	  in the 'Generic' allocator but is also explicitly marked as an SHM Bridge
37	  buffer.
38
39	  With this selected, all buffers passed to the TrustZone must be allocated
40	  using the TZMem allocator or else the TrustZone will refuse to use them.
41
42endchoice
43
44config QCOM_SCM_DOWNLOAD_MODE_DEFAULT
45	bool "Qualcomm download mode enabled by default"
46	depends on QCOM_SCM
47	help
48	  A device with "download mode" enabled will upon an unexpected
49	  warm-restart enter a special debug mode that allows the user to
50	  "download" memory content over USB for offline postmortem analysis.
51	  The feature can be enabled/disabled on the kernel command line.
52
53	  Say Y here to enable "download mode" by default.
54
55config QCOM_QSEECOM
56	bool "Qualcomm QSEECOM interface driver"
57	depends on QCOM_SCM=y
58	select AUXILIARY_BUS
59	help
60	  Various Qualcomm SoCs have a Secure Execution Environment (SEE) running
61	  in the Trust Zone. This module provides an interface to that via the
62	  QSEECOM mechanism, using SCM calls.
63
64	  The QSEECOM interface allows, among other things, access to applications
65	  running in the SEE. An example of such an application is 'uefisecapp',
66	  which is required to access UEFI variables on certain systems. If
67	  selected, the interface will also attempt to detect and register client
68	  devices for supported applications.
69
70	  Select Y here to enable the QSEECOM interface driver.
71
72config QCOM_QSEECOM_UEFISECAPP
73	bool "Qualcomm SEE UEFI Secure App client driver"
74	depends on QCOM_QSEECOM
75	depends on EFI
76	help
77	  Various Qualcomm SoCs do not allow direct access to EFI variables.
78	  Instead, these need to be accessed via the UEFI Secure Application
79	  (uefisecapp), residing in the Secure Execution Environment (SEE).
80
81	  This module provides a client driver for uefisecapp, installing efivar
82	  operations to allow the kernel accessing EFI variables, and via that also
83	  provide user-space with access to EFI variables via efivarfs.
84
85	  Select Y here to provide access to EFI variables on the aforementioned
86	  platforms.
87
88endmenu
89