* [PATCH] tee: optee: making OPTEE_SHM_NUM_PRIV_PAGES configurable via Kconfig
@ 2018-06-08 7:08 Sahil Malhotra
2018-06-20 9:12 ` Jens Wiklander
0 siblings, 1 reply; 2+ messages in thread
From: Sahil Malhotra @ 2018-06-08 7:08 UTC (permalink / raw)
To: linux-kernel; +Cc: Sahil Malhotra, Jens Wiklander
This change adds KCONFIG option to set number of pages out of
whole shared memory to be used for OP-TEE driver private data
structures.
Signed-off-by: Sahil Malhotra <sahil.malhotra@nxp.com>
---
drivers/tee/optee/Kconfig | 8 ++++++++
drivers/tee/optee/core.c | 2 +-
2 files changed, 9 insertions(+), 1 deletion(-)
diff --git a/drivers/tee/optee/Kconfig b/drivers/tee/optee/Kconfig
index 524c7a80fde4..f425c960a5a2 100644
--- a/drivers/tee/optee/Kconfig
+++ b/drivers/tee/optee/Kconfig
@@ -12,3 +12,11 @@ config OPTEE_BENCHMARK
help
This enables benchmarking feature in the OP-TEE Trusted
Execution Environment (TEE) driver.
+
+config OPTEE_SHM_NUM_PRIV_PAGES
+ int "Private Shared Memory Pages"
+ default 1
+ depends on OPTEE
+ help
+ This sets the number of private shared memory pages to be
+ used by OP-TEE TEE driver.
diff --git a/drivers/tee/optee/core.c b/drivers/tee/optee/core.c
index 4a2c420d4fe4..8d3be6b1bb96 100644
--- a/drivers/tee/optee/core.c
+++ b/drivers/tee/optee/core.c
@@ -33,7 +33,7 @@
#define DRIVER_NAME "optee"
-#define OPTEE_SHM_NUM_PRIV_PAGES 1
+#define OPTEE_SHM_NUM_PRIV_PAGES CONFIG_OPTEE_SHM_NUM_PRIV_PAGES
/**
* optee_from_msg_param() - convert from OPTEE_MSG parameters to
--
2.17.0
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] tee: optee: making OPTEE_SHM_NUM_PRIV_PAGES configurable via Kconfig
2018-06-08 7:08 [PATCH] tee: optee: making OPTEE_SHM_NUM_PRIV_PAGES configurable via Kconfig Sahil Malhotra
@ 2018-06-20 9:12 ` Jens Wiklander
0 siblings, 0 replies; 2+ messages in thread
From: Jens Wiklander @ 2018-06-20 9:12 UTC (permalink / raw)
To: Sahil Malhotra; +Cc: linux-kernel
On Fri, Jun 08, 2018 at 12:38:13PM +0530, Sahil Malhotra wrote:
> This change adds KCONFIG option to set number of pages out of
> whole shared memory to be used for OP-TEE driver private data
> structures.
>
> Signed-off-by: Sahil Malhotra <sahil.malhotra@nxp.com>
> ---
> drivers/tee/optee/Kconfig | 8 ++++++++
> drivers/tee/optee/core.c | 2 +-
> 2 files changed, 9 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/tee/optee/Kconfig b/drivers/tee/optee/Kconfig
> index 524c7a80fde4..f425c960a5a2 100644
> --- a/drivers/tee/optee/Kconfig
> +++ b/drivers/tee/optee/Kconfig
> @@ -12,3 +12,11 @@ config OPTEE_BENCHMARK
> help
> This enables benchmarking feature in the OP-TEE Trusted
> Execution Environment (TEE) driver.
> +
> +config OPTEE_SHM_NUM_PRIV_PAGES
> + int "Private Shared Memory Pages"
> + default 1
> + depends on OPTEE
> + help
> + This sets the number of private shared memory pages to be
> + used by OP-TEE TEE driver.
> diff --git a/drivers/tee/optee/core.c b/drivers/tee/optee/core.c
> index 4a2c420d4fe4..8d3be6b1bb96 100644
> --- a/drivers/tee/optee/core.c
> +++ b/drivers/tee/optee/core.c
> @@ -33,7 +33,7 @@
>
> #define DRIVER_NAME "optee"
>
> -#define OPTEE_SHM_NUM_PRIV_PAGES 1
> +#define OPTEE_SHM_NUM_PRIV_PAGES CONFIG_OPTEE_SHM_NUM_PRIV_PAGES
>
> /**
> * optee_from_msg_param() - convert from OPTEE_MSG parameters to
> --
> 2.17.0
>
Looks good to me, I'll pick it up.
Thanks,
Jens
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2018-06-20 9:12 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-06-08 7:08 [PATCH] tee: optee: making OPTEE_SHM_NUM_PRIV_PAGES configurable via Kconfig Sahil Malhotra
2018-06-20 9:12 ` Jens Wiklander
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®