* [PATCH v2 0/5] optee: Add support for enumerating RPMB-dependent services
@ 2026-08-23 19:47 Jan Kiszka
2026-08-23 19:47 ` [PATCH v2 1/5] tee: optee: Factor out service enumeration and binding functions Jan Kiszka
` (5 more replies)
0 siblings, 6 replies; 24+ messages in thread
From: Jan Kiszka @ 2026-08-23 19:47 UTC (permalink / raw)
To: U-Boot Mailing List
Cc: Jens Wiklander, Ilias Apalodimas, Sai Sree Kartheek Adivi,
Alexander Heinisch, Tanmay Kathpalia
This allows to find firmware TPM again with recent OP-TEE versions,
possibly also other services. The StMM service was not affected because
it is directly invoked by efi_variable_tee when needed, and that is late
enough so that all dependencies are available by then.
See patches for further details.
Changes in v2:
- fix build breakages with disabled CONFIGs
- structure code differently between optee core and rpmb
- debug() -> dev_dbg()
Jan
Jan Kiszka (5):
tee: optee: Factor out service enumeration and binding functions
tee: optee: Add support for enumerating services that only need RPMB
tee: optee: Do not warn about TEE_ERROR_STORAGE_NOT_AVAILABLE
mmc: Call back to optee after a successful mmc_init
mmc: Make "MMC Device not found" a debug output
drivers/mmc/mmc-uclass.c | 2 +-
drivers/mmc/mmc.c | 4 +++
drivers/mmc/mmc_legacy.c | 2 +-
drivers/tee/optee/core.c | 58 +++++++++++++++----------------
drivers/tee/optee/optee_private.h | 24 +++++++++++++
drivers/tee/optee/rpmb.c | 19 ++++++++++
include/tee/optee.h | 6 ++++
7 files changed, 83 insertions(+), 32 deletions(-)
--
2.47.3
^ permalink raw reply [flat|nested] 24+ messages in thread
* [PATCH v2 1/5] tee: optee: Factor out service enumeration and binding functions
2026-08-23 19:47 [PATCH v2 0/5] optee: Add support for enumerating RPMB-dependent services Jan Kiszka
@ 2026-08-23 19:47 ` Jan Kiszka
2026-09-08 7:08 ` Ilias Apalodimas
2026-08-23 19:47 ` [PATCH v2 2/5] tee: optee: Add support for enumerating services that only need RPMB Jan Kiszka
` (4 subsequent siblings)
5 siblings, 1 reply; 24+ messages in thread
From: Jan Kiszka @ 2026-08-23 19:47 UTC (permalink / raw)
To: U-Boot Mailing List
Cc: Jens Wiklander, Ilias Apalodimas, Sai Sree Kartheek Adivi,
Alexander Heinisch, Tanmay Kathpalia
From: Jan Kiszka <jan.kiszka@siemens.com>
This already avoids code duplication between the different enumeration
commands. It will furthermore allow to implement a third one for
services with RPMB needs.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
---
drivers/tee/optee/core.c | 33 +++++++++++++++++--------------
drivers/tee/optee/optee_private.h | 3 +++
2 files changed, 21 insertions(+), 15 deletions(-)
diff --git a/drivers/tee/optee/core.c b/drivers/tee/optee/core.c
index 4d67c948ec1..2871760a7b7 100644
--- a/drivers/tee/optee/core.c
+++ b/drivers/tee/optee/core.c
@@ -156,7 +156,7 @@ static int enum_services(struct udevice *dev, struct tee_shm **shm, size_t *coun
return ret;
}
-static int open_enum_session(struct udevice *dev, u32 *tee_sess)
+int optee_open_enum_session(struct udevice *dev, u32 *tee_sess)
{
const struct tee_optee_ta_uuid pta_uuid = PTA_DEVICE_ENUM;
struct tee_open_session_arg arg = { };
@@ -176,31 +176,34 @@ static int open_enum_session(struct udevice *dev, u32 *tee_sess)
return 0;
}
-static int bind_service_drivers(struct udevice *dev)
+int optee_bind_services(struct udevice *dev, u32 tee_sess,
+ unsigned int pta_cmd)
{
struct tee_shm *service_list = NULL;
size_t service_count;
- u32 tee_sess;
- int ret, ret2;
-
- ret = open_enum_session(dev, &tee_sess);
- if (ret)
- return ret;
+ int ret;
ret = enum_services(dev, &service_list, &service_count, tee_sess,
- PTA_CMD_GET_DEVICES);
+ pta_cmd);
if (!ret && service_count)
ret = bind_service_list(dev, service_list, service_count);
tee_shm_free(service_list);
- service_list = NULL;
- ret2 = enum_services(dev, &service_list, &service_count, tee_sess,
- PTA_CMD_GET_DEVICES_SUPP);
- if (!ret2 && service_count)
- ret2 = bind_service_list(dev, service_list, service_count);
+ return ret;
+}
+
+static int bind_service_drivers(struct udevice *dev)
+{
+ u32 tee_sess;
+ int ret, ret2;
- tee_shm_free(service_list);
+ ret = optee_open_enum_session(dev, &tee_sess);
+ if (ret)
+ return ret;
+
+ ret = optee_bind_services(dev, tee_sess, PTA_CMD_GET_DEVICES);
+ ret2 = optee_bind_services(dev, tee_sess, PTA_CMD_GET_DEVICES_SUPP);
tee_close_session(dev, tee_sess);
diff --git a/drivers/tee/optee/optee_private.h b/drivers/tee/optee/optee_private.h
index 1f07a27ee4b..25b6b3c3218 100644
--- a/drivers/tee/optee/optee_private.h
+++ b/drivers/tee/optee/optee_private.h
@@ -27,6 +27,9 @@ struct optee_msg_arg;
void optee_suppl_cmd(struct udevice *dev, struct tee_shm *shm_arg,
void **page_list);
+int optee_open_enum_session(struct udevice *dev, u32 *tee_sess);
+int optee_bind_services(struct udevice *dev, u32 tee_sess,
+ unsigned int pta_cmd);
#ifdef CONFIG_SUPPORT_EMMC_RPMB
/**
--
2.47.3
^ permalink raw reply related [flat|nested] 24+ messages in thread
* [PATCH v2 2/5] tee: optee: Add support for enumerating services that only need RPMB
2026-08-23 19:47 [PATCH v2 0/5] optee: Add support for enumerating RPMB-dependent services Jan Kiszka
2026-08-23 19:47 ` [PATCH v2 1/5] tee: optee: Factor out service enumeration and binding functions Jan Kiszka
@ 2026-08-23 19:47 ` Jan Kiszka
2026-09-08 7:25 ` Ilias Apalodimas
2026-08-23 19:47 ` [PATCH v2 3/5] tee: optee: Do not warn about TEE_ERROR_STORAGE_NOT_AVAILABLE Jan Kiszka
` (3 subsequent siblings)
5 siblings, 1 reply; 24+ messages in thread
From: Jan Kiszka @ 2026-08-23 19:47 UTC (permalink / raw)
To: U-Boot Mailing List
Cc: Jens Wiklander, Ilias Apalodimas, Sai Sree Kartheek Adivi,
Alexander Heinisch, Tanmay Kathpalia
From: Jan Kiszka <jan.kiszka@siemens.com>
Up to OP-TEE 4.4.0, all services that needed a supplicant where returned
by PTA_CMD_GET_DEVICES_SUPP. Since then, services that only need a
supplicant for the purpose of accessing the RPMB are only enumerated by
the new, separate PTA_CMD_GET_DEVICES_RPMB. U-Boot so far lacks support
for that, thus no longer finds such services, e.g. fTPM.
Perform the separate enumeration during probe but, as that may fail if
the MMC is not probed yet, also provide a callback to trigger a retry
when another MMC device becomes available.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
---
drivers/tee/optee/core.c | 22 +++++++---------------
drivers/tee/optee/optee_private.h | 21 +++++++++++++++++++++
drivers/tee/optee/rpmb.c | 19 +++++++++++++++++++
include/tee/optee.h | 6 ++++++
4 files changed, 53 insertions(+), 15 deletions(-)
diff --git a/drivers/tee/optee/core.c b/drivers/tee/optee/core.c
index 2871760a7b7..ed8f2b6ec74 100644
--- a/drivers/tee/optee/core.c
+++ b/drivers/tee/optee/core.c
@@ -27,19 +27,6 @@
*/
#define PTA_DEVICE_ENUM { 0x7011a688, 0xddde, 0x4053, \
{ 0xa5, 0xa9, 0x7b, 0x3c, 0x4d, 0xdf, 0x13, 0xb8 } }
-/*
- * PTA_CMD_GET_DEVICES - List services without supplicant dependencies
- *
- * [out] memref[0]: List of the UUIDs of service enumerated by OP-TEE
- */
-#define PTA_CMD_GET_DEVICES 0x0
-
-/*
- * PTA_CMD_GET_DEVICES_SUPP - List services depending on tee supplicant
- *
- * [out] memref[0]: List of the UUIDs of service enumerated by OP-TEE
- */
-#define PTA_CMD_GET_DEVICES_SUPP 0x1
typedef void (optee_invoke_fn)(unsigned long, unsigned long, unsigned long,
unsigned long, unsigned long, unsigned long,
@@ -195,8 +182,8 @@ int optee_bind_services(struct udevice *dev, u32 tee_sess,
static int bind_service_drivers(struct udevice *dev)
{
+ int ret, ret2, ret3 = 0;
u32 tee_sess;
- int ret, ret2;
ret = optee_open_enum_session(dev, &tee_sess);
if (ret)
@@ -204,13 +191,18 @@ static int bind_service_drivers(struct udevice *dev)
ret = optee_bind_services(dev, tee_sess, PTA_CMD_GET_DEVICES);
ret2 = optee_bind_services(dev, tee_sess, PTA_CMD_GET_DEVICES_SUPP);
+ if (CONFIG_IS_ENABLED(SUPPORT_EMMC_RPMB))
+ ret3 = optee_bind_services(dev, tee_sess,
+ PTA_CMD_GET_DEVICES_RPMB);
tee_close_session(dev, tee_sess);
if (ret)
return ret;
+ if (ret2)
+ return ret2;
- return ret2;
+ return ret3;
}
/**
diff --git a/drivers/tee/optee/optee_private.h b/drivers/tee/optee/optee_private.h
index 25b6b3c3218..daff3e04493 100644
--- a/drivers/tee/optee/optee_private.h
+++ b/drivers/tee/optee/optee_private.h
@@ -9,6 +9,27 @@
#include <tee.h>
#include <log.h>
+/*
+ * PTA_CMD_GET_DEVICES - List services without supplicant dependencies
+ *
+ * [out] memref[0]: List of the UUIDs of service enumerated by OP-TEE
+ */
+#define PTA_CMD_GET_DEVICES 0x0
+
+/*
+ * PTA_CMD_GET_DEVICES_SUPP - List services depending on tee supplicant
+ *
+ * [out] memref[0]: List of the UUIDs of service enumerated by OP-TEE
+ */
+#define PTA_CMD_GET_DEVICES_SUPP 0x1
+
+/*
+ * PTA_CMD_GET_DEVICES_RPMB - List services only depending on RPMB support
+ *
+ * [out] memref[0]: List of the UUIDs of service enumerated by OP-TEE
+ */
+#define PTA_CMD_GET_DEVICES_RPMB 0x2
+
/**
* struct optee_private - OP-TEE driver private data
* @rpmb_mmc: mmc device for the RPMB partition
diff --git a/drivers/tee/optee/rpmb.c b/drivers/tee/optee/rpmb.c
index bacced6af6c..f7312d7171c 100644
--- a/drivers/tee/optee/rpmb.c
+++ b/drivers/tee/optee/rpmb.c
@@ -191,3 +191,22 @@ void optee_suppl_rpmb_release(struct udevice *dev)
{
release_mmc(dev_get_priv(dev));
}
+
+void optee_rpmb_available(void)
+{
+ struct udevice *dev;
+ struct uclass *uc;
+ u32 tee_sess;
+
+ uclass_id_foreach_dev(UCLASS_TEE, dev, uc) {
+ if (strcmp(dev->driver->name, "optee") != 0)
+ continue;
+
+ if (optee_open_enum_session(dev, &tee_sess) != 0)
+ continue;
+
+ optee_bind_services(dev, tee_sess, PTA_CMD_GET_DEVICES_RPMB);
+
+ tee_close_session(dev, tee_sess);
+ }
+}
diff --git a/include/tee/optee.h b/include/tee/optee.h
index d1194493780..755533b2c0b 100644
--- a/include/tee/optee.h
+++ b/include/tee/optee.h
@@ -74,4 +74,10 @@ static inline bool is_optee_smc_api(void)
}
#endif
+#if defined(CONFIG_OPTEE) && defined(CONFIG_SUPPORT_EMMC_RPMB)
+void optee_rpmb_available(void);
+#else
+static inline void optee_rpmb_available(void) {}
+#endif
+
#endif /* _OPTEE_H */
--
2.47.3
^ permalink raw reply related [flat|nested] 24+ messages in thread
* [PATCH v2 3/5] tee: optee: Do not warn about TEE_ERROR_STORAGE_NOT_AVAILABLE
2026-08-23 19:47 [PATCH v2 0/5] optee: Add support for enumerating RPMB-dependent services Jan Kiszka
2026-08-23 19:47 ` [PATCH v2 1/5] tee: optee: Factor out service enumeration and binding functions Jan Kiszka
2026-08-23 19:47 ` [PATCH v2 2/5] tee: optee: Add support for enumerating services that only need RPMB Jan Kiszka
@ 2026-08-23 19:47 ` Jan Kiszka
2026-09-08 7:15 ` Ilias Apalodimas
2026-08-23 19:47 ` [PATCH v2 4/5] mmc: Call back to optee after a successful mmc_init Jan Kiszka
` (2 subsequent siblings)
5 siblings, 1 reply; 24+ messages in thread
From: Jan Kiszka @ 2026-08-23 19:47 UTC (permalink / raw)
To: U-Boot Mailing List
Cc: Jens Wiklander, Ilias Apalodimas, Sai Sree Kartheek Adivi,
Alexander Heinisch, Tanmay Kathpalia
From: Jan Kiszka <jan.kiszka@siemens.com>
This is a transitional error that is resolved once an RPMB becomes
available. Keep it as debug output only.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
---
drivers/tee/optee/core.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/drivers/tee/optee/core.c b/drivers/tee/optee/core.c
index ed8f2b6ec74..d3b5811afb8 100644
--- a/drivers/tee/optee/core.c
+++ b/drivers/tee/optee/core.c
@@ -106,7 +106,10 @@ static int __enum_services(struct udevice *dev, struct tee_shm *shm, size_t *shm
ret = tee_invoke_func(dev, &arg, 1, ¶m);
if (ret || (arg.ret && arg.ret != TEE_ERROR_SHORT_BUFFER)) {
- dev_err(dev, "Enumeration command 0x%x failed: 0x%x\n", pta_cmd, arg.ret);
+ if (arg.ret != TEE_ERROR_STORAGE_NOT_AVAILABLE)
+ dev_err(dev, "Enumeration command 0x%x failed: 0x%x\n", pta_cmd, arg.ret);
+ else
+ dev_dbg(dev, "Enumeration command 0x%x failed due to unavailable storage\n", pta_cmd);
return -EINVAL;
}
--
2.47.3
^ permalink raw reply related [flat|nested] 24+ messages in thread
* [PATCH v2 4/5] mmc: Call back to optee after a successful mmc_init
2026-08-23 19:47 [PATCH v2 0/5] optee: Add support for enumerating RPMB-dependent services Jan Kiszka
` (2 preceding siblings ...)
2026-08-23 19:47 ` [PATCH v2 3/5] tee: optee: Do not warn about TEE_ERROR_STORAGE_NOT_AVAILABLE Jan Kiszka
@ 2026-08-23 19:47 ` Jan Kiszka
2026-08-26 8:44 ` Peng Fan
2026-08-23 19:47 ` [PATCH v2 5/5] mmc: Make "MMC Device not found" a debug output Jan Kiszka
2026-09-08 9:36 ` [PATCH v2 0/5] optee: Add support for enumerating RPMB-dependent services Ilias Apalodimas
5 siblings, 1 reply; 24+ messages in thread
From: Jan Kiszka @ 2026-08-23 19:47 UTC (permalink / raw)
To: U-Boot Mailing List
Cc: Jens Wiklander, Ilias Apalodimas, Sai Sree Kartheek Adivi,
Alexander Heinisch, Tanmay Kathpalia, Peng Fan, Jaehoon Chung
From: Jan Kiszka <jan.kiszka@siemens.com>
This is needed to that OP-TEE can re-enumerate services which need RPMB
access that may have become available now.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
---
CC: Peng Fan <peng.fan@nxp.com>
CC: Jaehoon Chung <jh80.chung@samsung.com>
---
drivers/mmc/mmc.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/drivers/mmc/mmc.c b/drivers/mmc/mmc.c
index 670e92ee12b..2463e50cd3c 100644
--- a/drivers/mmc/mmc.c
+++ b/drivers/mmc/mmc.c
@@ -27,6 +27,7 @@
#include <linux/list.h>
#include <linux/printk.h>
#include <div64.h>
+#include <tee/optee.h>
#include "mmc_private.h"
#define DEFAULT_CMD6_TIMEOUT_MS 500
@@ -3168,6 +3169,9 @@ int mmc_init(struct mmc *mmc)
mmc->cfg->name);
}
+ if (CONFIG_IS_ENABLED(OPTEE) && mmc->capacity_rpmb > 0)
+ optee_rpmb_available();
+
return err;
}
--
2.47.3
^ permalink raw reply related [flat|nested] 24+ messages in thread
* [PATCH v2 5/5] mmc: Make "MMC Device not found" a debug output
2026-08-23 19:47 [PATCH v2 0/5] optee: Add support for enumerating RPMB-dependent services Jan Kiszka
` (3 preceding siblings ...)
2026-08-23 19:47 ` [PATCH v2 4/5] mmc: Call back to optee after a successful mmc_init Jan Kiszka
@ 2026-08-23 19:47 ` Jan Kiszka
2026-08-26 8:44 ` Peng Fan
2026-09-08 7:12 ` Ilias Apalodimas
2026-09-08 9:36 ` [PATCH v2 0/5] optee: Add support for enumerating RPMB-dependent services Ilias Apalodimas
5 siblings, 2 replies; 24+ messages in thread
From: Jan Kiszka @ 2026-08-23 19:47 UTC (permalink / raw)
To: U-Boot Mailing List
Cc: Jens Wiklander, Ilias Apalodimas, Sai Sree Kartheek Adivi,
Alexander Heinisch, Tanmay Kathpalia, Peng Fan, Jaehoon Chung
From: Jan Kiszka <jan.kiszka@siemens.com>
Callers of find_mmc_device are generally processing and informing about
errors already, e.g.
=> mmc dev 2
MMC Device 2 not found
no mmc device at slot 2
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
---
CC: Peng Fan <peng.fan@nxp.com>
CC: Jaehoon Chung <jh80.chung@samsung.com>
---
drivers/mmc/mmc-uclass.c | 2 +-
drivers/mmc/mmc_legacy.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/mmc/mmc-uclass.c b/drivers/mmc/mmc-uclass.c
index 698530088fe..ec16899f92e 100644
--- a/drivers/mmc/mmc-uclass.c
+++ b/drivers/mmc/mmc-uclass.c
@@ -319,7 +319,7 @@ struct mmc *find_mmc_device(int dev_num)
if (ret) {
#if !defined(CONFIG_XPL_BUILD) || defined(CONFIG_SPL_LIBCOMMON_SUPPORT)
- printf("MMC Device %d not found\n", dev_num);
+ dev_dbg(dev, "MMC Device %d not found\n", dev_num);
#endif
return NULL;
}
diff --git a/drivers/mmc/mmc_legacy.c b/drivers/mmc/mmc_legacy.c
index 8f8ba34be71..573521842f6 100644
--- a/drivers/mmc/mmc_legacy.c
+++ b/drivers/mmc/mmc_legacy.c
@@ -45,7 +45,7 @@ struct mmc *find_mmc_device(int dev_num)
}
#if !defined(CONFIG_XPL_BUILD) || defined(CONFIG_SPL_LIBCOMMON_SUPPORT)
- printf("MMC Device %d not found\n", dev_num);
+ dev_dbg(dev, "MMC Device %d not found\n", dev_num);
#endif
return NULL;
--
2.47.3
^ permalink raw reply related [flat|nested] 24+ messages in thread
* Re: [PATCH v2 4/5] mmc: Call back to optee after a successful mmc_init
2026-08-23 19:47 ` [PATCH v2 4/5] mmc: Call back to optee after a successful mmc_init Jan Kiszka
@ 2026-08-26 8:44 ` Peng Fan
2026-08-26 10:10 ` Kathpalia, Tanmay
0 siblings, 1 reply; 24+ messages in thread
From: Peng Fan @ 2026-08-26 8:44 UTC (permalink / raw)
To: Jan Kiszka
Cc: U-Boot Mailing List, Jens Wiklander, Ilias Apalodimas,
Sai Sree Kartheek Adivi, Alexander Heinisch, Tanmay Kathpalia,
Peng Fan, Jaehoon Chung
On Sun, Aug 23, 2026 at 09:47:25PM +0200, Jan Kiszka wrote:
>From: Jan Kiszka <jan.kiszka@siemens.com>
>
>This is needed to that OP-TEE can re-enumerate services which need RPMB
>access that may have become available now.
>
>Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 5/5] mmc: Make "MMC Device not found" a debug output
2026-08-23 19:47 ` [PATCH v2 5/5] mmc: Make "MMC Device not found" a debug output Jan Kiszka
@ 2026-08-26 8:44 ` Peng Fan
2026-08-26 10:10 ` Kathpalia, Tanmay
2026-09-08 7:12 ` Ilias Apalodimas
1 sibling, 1 reply; 24+ messages in thread
From: Peng Fan @ 2026-08-26 8:44 UTC (permalink / raw)
To: Jan Kiszka
Cc: U-Boot Mailing List, Jens Wiklander, Ilias Apalodimas,
Sai Sree Kartheek Adivi, Alexander Heinisch, Tanmay Kathpalia,
Peng Fan, Jaehoon Chung
On Sun, Aug 23, 2026 at 09:47:26PM +0200, Jan Kiszka wrote:
>From: Jan Kiszka <jan.kiszka@siemens.com>
>
>Callers of find_mmc_device are generally processing and informing about
>errors already, e.g.
>
>=> mmc dev 2
>MMC Device 2 not found
>no mmc device at slot 2
>
>Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 4/5] mmc: Call back to optee after a successful mmc_init
2026-08-26 8:44 ` Peng Fan
@ 2026-08-26 10:10 ` Kathpalia, Tanmay
0 siblings, 0 replies; 24+ messages in thread
From: Kathpalia, Tanmay @ 2026-08-26 10:10 UTC (permalink / raw)
To: Peng Fan, Jan Kiszka
Cc: U-Boot Mailing List, Jens Wiklander, Ilias Apalodimas,
Sai Sree Kartheek Adivi, Alexander Heinisch, Peng Fan,
Jaehoon Chung
[-- Attachment #1: Type: text/plain, Size: 1071 bytes --]
Reviewed-by: Tanmay Kathpalia <tanmay.kathpalia@altera.com<mailto:tanmay.kathpalia@altera.com>>
Altera Confidential
________________________________
From: Peng Fan <peng.fan@oss.nxp.com>
Sent: Wednesday, August 26, 2026 2:17:09 pm
To: Jan Kiszka <jan.kiszka@siemens.com>
Cc: U-Boot Mailing List <u-boot@lists.u-boot-project.org>; Jens Wiklander <jens.wiklander@oss.qualcomm.com>; Ilias Apalodimas <ilias.apalodimas@linaro.org>; Sai Sree Kartheek Adivi <s-adivi@ti.com>; Alexander Heinisch <alexander.heinisch@siemens.com>; Kathpalia, Tanmay <tanmay.kathpalia@altera.com>; Peng Fan <peng.fan@nxp.com>; Jaehoon Chung <jh80.chung@samsung.com>
Subject: Re: [PATCH v2 4/5] mmc: Call back to optee after a successful mmc_init
On Sun, Aug 23, 2026 at 09:47:25PM +0200, Jan Kiszka wrote:
>From: Jan Kiszka <jan.kiszka@siemens.com>
>
>This is needed to that OP-TEE can re-enumerate services which need RPMB
>access that may have become available now.
>
>Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
[-- Attachment #2: Type: text/html, Size: 3202 bytes --]
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 5/5] mmc: Make "MMC Device not found" a debug output
2026-08-26 8:44 ` Peng Fan
@ 2026-08-26 10:10 ` Kathpalia, Tanmay
0 siblings, 0 replies; 24+ messages in thread
From: Kathpalia, Tanmay @ 2026-08-26 10:10 UTC (permalink / raw)
To: Peng Fan, Jan Kiszka
Cc: U-Boot Mailing List, Jens Wiklander, Ilias Apalodimas,
Sai Sree Kartheek Adivi, Alexander Heinisch, Peng Fan,
Jaehoon Chung
[-- Attachment #1: Type: text/plain, Size: 1114 bytes --]
Reviewed-by: Tanmay Kathpalia <tanmay.kathpalia@altera.com<mailto:tanmay.kathpalia@altera.com>>
Altera Confidential
________________________________
From: Peng Fan <peng.fan@oss.nxp.com>
Sent: Wednesday, August 26, 2026 2:17:24 pm
To: Jan Kiszka <jan.kiszka@siemens.com>
Cc: U-Boot Mailing List <u-boot@lists.u-boot-project.org>; Jens Wiklander <jens.wiklander@oss.qualcomm.com>; Ilias Apalodimas <ilias.apalodimas@linaro.org>; Sai Sree Kartheek Adivi <s-adivi@ti.com>; Alexander Heinisch <alexander.heinisch@siemens.com>; Kathpalia, Tanmay <tanmay.kathpalia@altera.com>; Peng Fan <peng.fan@nxp.com>; Jaehoon Chung <jh80.chung@samsung.com>
Subject: Re: [PATCH v2 5/5] mmc: Make "MMC Device not found" a debug output
On Sun, Aug 23, 2026 at 09:47:26PM +0200, Jan Kiszka wrote:
>From: Jan Kiszka <jan.kiszka@siemens.com>
>
>Callers of find_mmc_device are generally processing and informing about
>errors already, e.g.
>
>=> mmc dev 2
>MMC Device 2 not found
>no mmc device at slot 2
>
>Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
[-- Attachment #2: Type: text/html, Size: 2923 bytes --]
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 1/5] tee: optee: Factor out service enumeration and binding functions
2026-08-23 19:47 ` [PATCH v2 1/5] tee: optee: Factor out service enumeration and binding functions Jan Kiszka
@ 2026-09-08 7:08 ` Ilias Apalodimas
2026-09-08 9:47 ` Jan Kiszka
0 siblings, 1 reply; 24+ messages in thread
From: Ilias Apalodimas @ 2026-09-08 7:08 UTC (permalink / raw)
To: Jan Kiszka, U-Boot Mailing List
Cc: Jens Wiklander, Sai Sree Kartheek Adivi, Alexander Heinisch,
Tanmay Kathpalia
Hi Jan
On Sun Aug 23, 2026 at 10:47 PM EEST, Jan Kiszka wrote:
> From: Jan Kiszka <jan.kiszka@siemens.com>
>
> This already avoids code duplication between the different enumeration
> commands. It will furthermore allow to implement a third one for
> services with RPMB needs.
>
> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
> ---
> drivers/tee/optee/core.c | 33 +++++++++++++++++--------------
> drivers/tee/optee/optee_private.h | 3 +++
> 2 files changed, 21 insertions(+), 15 deletions(-)
>
> diff --git a/drivers/tee/optee/core.c b/drivers/tee/optee/core.c
> index 4d67c948ec1..2871760a7b7 100644
> --- a/drivers/tee/optee/core.c
> +++ b/drivers/tee/optee/core.c
> @@ -156,7 +156,7 @@ static int enum_services(struct udevice *dev, struct tee_shm **shm, size_t *coun
> return ret;
> }
>
> -static int open_enum_session(struct udevice *dev, u32 *tee_sess)
> +int optee_open_enum_session(struct udevice *dev, u32 *tee_sess)
> {
> const struct tee_optee_ta_uuid pta_uuid = PTA_DEVICE_ENUM;
> struct tee_open_session_arg arg = { };
> @@ -176,31 +176,34 @@ static int open_enum_session(struct udevice *dev, u32 *tee_sess)
> return 0;
> }
>
> -static int bind_service_drivers(struct udevice *dev)
> +int optee_bind_services(struct udevice *dev, u32 tee_sess,
> + unsigned int pta_cmd)
> {
> struct tee_shm *service_list = NULL;
> size_t service_count;
> - u32 tee_sess;
> - int ret, ret2;
> -
> - ret = open_enum_session(dev, &tee_sess);
> - if (ret)
> - return ret;
> + int ret;
>
> ret = enum_services(dev, &service_list, &service_count, tee_sess,
> - PTA_CMD_GET_DEVICES);
> + pta_cmd);
> if (!ret && service_count)
> ret = bind_service_list(dev, service_list, service_count);
>
> tee_shm_free(service_list);
> - service_list = NULL;
>
> - ret2 = enum_services(dev, &service_list, &service_count, tee_sess,
> - PTA_CMD_GET_DEVICES_SUPP);
> - if (!ret2 && service_count)
> - ret2 = bind_service_list(dev, service_list, service_count);
> + return ret;
> +}
> +
> +static int bind_service_drivers(struct udevice *dev)
> +{
> + u32 tee_sess;
> + int ret, ret2;
>
> - tee_shm_free(service_list);
> + ret = optee_open_enum_session(dev, &tee_sess);
> + if (ret)
> + return ret;
> +
> + ret = optee_bind_services(dev, tee_sess, PTA_CMD_GET_DEVICES);
Any reason we aren't exiting immediately here?
> + ret2 = optee_bind_services(dev, tee_sess, PTA_CMD_GET_DEVICES_SUPP);
>
> tee_close_session(dev, tee_sess);
>
> diff --git a/drivers/tee/optee/optee_private.h b/drivers/tee/optee/optee_private.h
> index 1f07a27ee4b..25b6b3c3218 100644
> --- a/drivers/tee/optee/optee_private.h
> +++ b/drivers/tee/optee/optee_private.h
> @@ -27,6 +27,9 @@ struct optee_msg_arg;
>
> void optee_suppl_cmd(struct udevice *dev, struct tee_shm *shm_arg,
> void **page_list);
> +int optee_open_enum_session(struct udevice *dev, u32 *tee_sess);
> +int optee_bind_services(struct udevice *dev, u32 tee_sess,
> + unsigned int pta_cmd);
>
> #ifdef CONFIG_SUPPORT_EMMC_RPMB
> /**
Cheers
/Ilias
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 5/5] mmc: Make "MMC Device not found" a debug output
2026-08-23 19:47 ` [PATCH v2 5/5] mmc: Make "MMC Device not found" a debug output Jan Kiszka
2026-08-26 8:44 ` Peng Fan
@ 2026-09-08 7:12 ` Ilias Apalodimas
2026-09-08 7:43 ` Kathpalia, Tanmay
1 sibling, 1 reply; 24+ messages in thread
From: Ilias Apalodimas @ 2026-09-08 7:12 UTC (permalink / raw)
To: Jan Kiszka, U-Boot Mailing List
Cc: Jens Wiklander, Sai Sree Kartheek Adivi, Alexander Heinisch,
Tanmay Kathpalia, Peng Fan, Jaehoon Chung
On Sun Aug 23, 2026 at 10:47 PM EEST, Jan Kiszka wrote:
> From: Jan Kiszka <jan.kiszka@siemens.com>
[...]
> diff --git a/drivers/mmc/mmc-uclass.c b/drivers/mmc/mmc-uclass.c
> index 698530088fe..ec16899f92e 100644
> --- a/drivers/mmc/mmc-uclass.c
> +++ b/drivers/mmc/mmc-uclass.c
> @@ -319,7 +319,7 @@ struct mmc *find_mmc_device(int dev_num)
>
> if (ret) {
> #if !defined(CONFIG_XPL_BUILD) || defined(CONFIG_SPL_LIBCOMMON_SUPPORT)
> - printf("MMC Device %d not found\n", dev_num);
> + dev_dbg(dev, "MMC Device %d not found\n", dev_num);
'dev' might be unitiazed here on failures
> #endif
> return NULL;
> }
> diff --git a/drivers/mmc/mmc_legacy.c b/drivers/mmc/mmc_legacy.c
> index 8f8ba34be71..573521842f6 100644
> --- a/drivers/mmc/mmc_legacy.c
> +++ b/drivers/mmc/mmc_legacy.c
> @@ -45,7 +45,7 @@ struct mmc *find_mmc_device(int dev_num)
> }
>
> #if !defined(CONFIG_XPL_BUILD) || defined(CONFIG_SPL_LIBCOMMON_SUPPORT)
> - printf("MMC Device %d not found\n", dev_num);
> + dev_dbg(dev, "MMC Device %d not found\n", dev_num);
> #endif
>
> return NULL;
Cheers
/Ilias
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 3/5] tee: optee: Do not warn about TEE_ERROR_STORAGE_NOT_AVAILABLE
2026-08-23 19:47 ` [PATCH v2 3/5] tee: optee: Do not warn about TEE_ERROR_STORAGE_NOT_AVAILABLE Jan Kiszka
@ 2026-09-08 7:15 ` Ilias Apalodimas
2026-09-08 11:01 ` Jan Kiszka
0 siblings, 1 reply; 24+ messages in thread
From: Ilias Apalodimas @ 2026-09-08 7:15 UTC (permalink / raw)
To: Jan Kiszka, U-Boot Mailing List
Cc: Jens Wiklander, Sai Sree Kartheek Adivi, Alexander Heinisch,
Tanmay Kathpalia
Hi Jan
On Sun Aug 23, 2026 at 10:47 PM EEST, Jan Kiszka wrote:
> From: Jan Kiszka <jan.kiszka@siemens.com>
>
> This is a transitional error that is resolved once an RPMB becomes
> available. Keep it as debug output only.
>
> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
> ---
> drivers/tee/optee/core.c | 5 ++++-
> 1 file changed, 4 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/tee/optee/core.c b/drivers/tee/optee/core.c
> index ed8f2b6ec74..d3b5811afb8 100644
> --- a/drivers/tee/optee/core.c
> +++ b/drivers/tee/optee/core.c
> @@ -106,7 +106,10 @@ static int __enum_services(struct udevice *dev, struct tee_shm *shm, size_t *shm
>
> ret = tee_invoke_func(dev, &arg, 1, ¶m);
> if (ret || (arg.ret && arg.ret != TEE_ERROR_SHORT_BUFFER)) {
> - dev_err(dev, "Enumeration command 0x%x failed: 0x%x\n", pta_cmd, arg.ret);
> + if (arg.ret != TEE_ERROR_STORAGE_NOT_AVAILABLE)
> + dev_err(dev, "Enumeration command 0x%x failed: 0x%x\n", pta_cmd, arg.ret);
> + else
> + dev_dbg(dev, "Enumeration command 0x%x failed due to unavailable storage\n", pta_cmd);
I don't mind changing this and I like the different error messages. Isn't the dgb message useful for
users though? Or it is something that's not expected to happen in production systems so we can hide
it?
Cheers
/Ilias
> return -EINVAL;
> }
>
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 2/5] tee: optee: Add support for enumerating services that only need RPMB
2026-08-23 19:47 ` [PATCH v2 2/5] tee: optee: Add support for enumerating services that only need RPMB Jan Kiszka
@ 2026-09-08 7:25 ` Ilias Apalodimas
2026-09-08 10:55 ` Jan Kiszka
0 siblings, 1 reply; 24+ messages in thread
From: Ilias Apalodimas @ 2026-09-08 7:25 UTC (permalink / raw)
To: Jan Kiszka, U-Boot Mailing List
Cc: Jens Wiklander, Sai Sree Kartheek Adivi, Alexander Heinisch,
Tanmay Kathpalia
[...]
On Sun Aug 23, 2026 at 10:47 PM EEST, Jan Kiszka wrote:
> +
> /**
> * struct optee_private - OP-TEE driver private data
> * @rpmb_mmc: mmc device for the RPMB partition
> diff --git a/drivers/tee/optee/rpmb.c b/drivers/tee/optee/rpmb.c
> index bacced6af6c..f7312d7171c 100644
> --- a/drivers/tee/optee/rpmb.c
> +++ b/drivers/tee/optee/rpmb.c
> @@ -191,3 +191,22 @@ void optee_suppl_rpmb_release(struct udevice *dev)
> {
> release_mmc(dev_get_priv(dev));
> }
> +
> +void optee_rpmb_available(void)
> +{
> + struct udevice *dev;
> + struct uclass *uc;
> + u32 tee_sess;
> +
> + uclass_id_foreach_dev(UCLASS_TEE, dev, uc) {
> + if (strcmp(dev->driver->name, "optee") != 0)
> + continue;
> +
> + if (optee_open_enum_session(dev, &tee_sess) != 0)
> + continue;
> +
> + optee_bind_services(dev, tee_sess, PTA_CMD_GET_DEVICES_RPMB);
Will this work if devices are bound but not probed? IOW do we need a device_active() check?
> +
> + tee_close_session(dev, tee_sess);
> + }
> +}
> diff --git a/include/tee/optee.h b/include/tee/optee.h
> index d1194493780..755533b2c0b 100644
> --- a/include/tee/optee.h
> +++ b/include/tee/optee.h
> @@ -74,4 +74,10 @@ static inline bool is_optee_smc_api(void)
> }
> #endif
>
> +#if defined(CONFIG_OPTEE) && defined(CONFIG_SUPPORT_EMMC_RPMB)
> +void optee_rpmb_available(void);
> +#else
> +static inline void optee_rpmb_available(void) {}
> +#endif
> +
> #endif /* _OPTEE_H */
Thanks
/Ilias
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 5/5] mmc: Make "MMC Device not found" a debug output
2026-09-08 7:12 ` Ilias Apalodimas
@ 2026-09-08 7:43 ` Kathpalia, Tanmay
0 siblings, 0 replies; 24+ messages in thread
From: Kathpalia, Tanmay @ 2026-09-08 7:43 UTC (permalink / raw)
To: Ilias Apalodimas, Jan Kiszka, U-Boot Mailing List
Cc: Jens Wiklander, Sai Sree Kartheek Adivi, Alexander Heinisch,
Peng Fan, Jaehoon Chung
On 9/8/2026 12:42 PM, Ilias Apalodimas wrote:
> On Sun Aug 23, 2026 at 10:47 PM EEST, Jan Kiszka wrote:
>> From: Jan Kiszka <jan.kiszka@siemens.com>
> [...]
>
>> diff --git a/drivers/mmc/mmc-uclass.c b/drivers/mmc/mmc-uclass.c
>> index 698530088fe..ec16899f92e 100644
>> --- a/drivers/mmc/mmc-uclass.c
>> +++ b/drivers/mmc/mmc-uclass.c
>> @@ -319,7 +319,7 @@ struct mmc *find_mmc_device(int dev_num)
>>
>> if (ret) {
>> #if !defined(CONFIG_XPL_BUILD) || defined(CONFIG_SPL_LIBCOMMON_SUPPORT)
>> - printf("MMC Device %d not found\n", dev_num);
>> + dev_dbg(dev, "MMC Device %d not found\n", dev_num);
> 'dev' might be unitiazed here on failures
Yes, good catch. On the failure path of blk_find_device(), 'dev'
is not guaranteed to be valid, so using it with dev_dbg() is wrong.
I think debug() is the right replacement rather than leaving printf(),
e.g.:
debug("MMC Device %d not found\n", dev_num);
>
>> #endif
>> return NULL;
>> }
>> diff --git a/drivers/mmc/mmc_legacy.c b/drivers/mmc/mmc_legacy.c
>> index 8f8ba34be71..573521842f6 100644
>> --- a/drivers/mmc/mmc_legacy.c
>> +++ b/drivers/mmc/mmc_legacy.c
>> @@ -45,7 +45,7 @@ struct mmc *find_mmc_device(int dev_num)
>> }
>>
>> #if !defined(CONFIG_XPL_BUILD) || defined(CONFIG_SPL_LIBCOMMON_SUPPORT)
>> - printf("MMC Device %d not found\n", dev_num);
>> + dev_dbg(dev, "MMC Device %d not found\n", dev_num);
>> #endif
Same for the legacy path, which has no 'dev' at all.
Thanks Ilias, you are right. Dropping my Reviewed-by until a fixed
version.
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 0/5] optee: Add support for enumerating RPMB-dependent services
2026-08-23 19:47 [PATCH v2 0/5] optee: Add support for enumerating RPMB-dependent services Jan Kiszka
` (4 preceding siblings ...)
2026-08-23 19:47 ` [PATCH v2 5/5] mmc: Make "MMC Device not found" a debug output Jan Kiszka
@ 2026-09-08 9:36 ` Ilias Apalodimas
2026-09-08 9:43 ` Jan Kiszka
5 siblings, 1 reply; 24+ messages in thread
From: Ilias Apalodimas @ 2026-09-08 9:36 UTC (permalink / raw)
To: Jan Kiszka
Cc: U-Boot Mailing List, Jens Wiklander, Sai Sree Kartheek Adivi,
Alexander Heinisch, Tanmay Kathpalia
[-- Attachment #1: Type: text/plain, Size: 1548 bytes --]
Hi Jan
The CI [0] complains on this. My guess is it's due to the dev_dbg changes,
but I haven't found time to look into it.
[0]
https://git.u-boot-project.org/u-boot/custodians/u-boot-tpm/-/pipelines/1208
Cheers
/Ilias
On Sun, 23 Aug 2026 at 22:47, Jan Kiszka <jan.kiszka@siemens.com> wrote:
> This allows to find firmware TPM again with recent OP-TEE versions,
> possibly also other services. The StMM service was not affected because
> it is directly invoked by efi_variable_tee when needed, and that is late
> enough so that all dependencies are available by then.
>
> See patches for further details.
>
> Changes in v2:
> - fix build breakages with disabled CONFIGs
> - structure code differently between optee core and rpmb
> - debug() -> dev_dbg()
>
> Jan
>
> Jan Kiszka (5):
> tee: optee: Factor out service enumeration and binding functions
> tee: optee: Add support for enumerating services that only need RPMB
> tee: optee: Do not warn about TEE_ERROR_STORAGE_NOT_AVAILABLE
> mmc: Call back to optee after a successful mmc_init
> mmc: Make "MMC Device not found" a debug output
>
> drivers/mmc/mmc-uclass.c | 2 +-
> drivers/mmc/mmc.c | 4 +++
> drivers/mmc/mmc_legacy.c | 2 +-
> drivers/tee/optee/core.c | 58 +++++++++++++++----------------
> drivers/tee/optee/optee_private.h | 24 +++++++++++++
> drivers/tee/optee/rpmb.c | 19 ++++++++++
> include/tee/optee.h | 6 ++++
> 7 files changed, 83 insertions(+), 32 deletions(-)
>
> --
> 2.47.3
>
>
[-- Attachment #2: Type: text/html, Size: 2693 bytes --]
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 0/5] optee: Add support for enumerating RPMB-dependent services
2026-09-08 9:36 ` [PATCH v2 0/5] optee: Add support for enumerating RPMB-dependent services Ilias Apalodimas
@ 2026-09-08 9:43 ` Jan Kiszka
0 siblings, 0 replies; 24+ messages in thread
From: Jan Kiszka @ 2026-09-08 9:43 UTC (permalink / raw)
To: Ilias Apalodimas
Cc: U-Boot Mailing List, Jens Wiklander, Sai Sree Kartheek Adivi,
Alexander Heinisch, Tanmay Kathpalia
On 08.09.26 11:36, Ilias Apalodimas wrote:
> Hi Jan
>
> The CI [0] complains on this. My guess is it's due to the dev_dbg
> changes, but I haven't found time to look into it.
>
> [0] https://git.u-boot-project.org/u-boot/custodians/u-boot-tpm/-/
> pipelines/1208 <https://git.u-boot-project.org/u-boot/custodians/u-boot-
> tpm/-/pipelines/1208>
>
Yes, looks like (log is cut off, though). Let me sort this our first.
Jan
> Cheers
> /Ilias
>
> On Sun, 23 Aug 2026 at 22:47, Jan Kiszka <jan.kiszka@siemens.com
> <mailto:jan.kiszka@siemens.com>> wrote:
>
> This allows to find firmware TPM again with recent OP-TEE versions,
> possibly also other services. The StMM service was not affected because
> it is directly invoked by efi_variable_tee when needed, and that is late
> enough so that all dependencies are available by then.
>
> See patches for further details.
>
> Changes in v2:
> - fix build breakages with disabled CONFIGs
> - structure code differently between optee core and rpmb
> - debug() -> dev_dbg()
>
> Jan
>
> Jan Kiszka (5):
> tee: optee: Factor out service enumeration and binding functions
> tee: optee: Add support for enumerating services that only need RPMB
> tee: optee: Do not warn about TEE_ERROR_STORAGE_NOT_AVAILABLE
> mmc: Call back to optee after a successful mmc_init
> mmc: Make "MMC Device not found" a debug output
>
> drivers/mmc/mmc-uclass.c | 2 +-
> drivers/mmc/mmc.c | 4 +++
> drivers/mmc/mmc_legacy.c | 2 +-
> drivers/tee/optee/core.c | 58 +++++++++++++++----------------
> drivers/tee/optee/optee_private.h | 24 +++++++++++++
> drivers/tee/optee/rpmb.c | 19 ++++++++++
> include/tee/optee.h | 6 ++++
> 7 files changed, 83 insertions(+), 32 deletions(-)
>
> --
> 2.47.3
>
--
Siemens AG, Foundational Technologies
Linux Expert Center
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 1/5] tee: optee: Factor out service enumeration and binding functions
2026-09-08 7:08 ` Ilias Apalodimas
@ 2026-09-08 9:47 ` Jan Kiszka
2026-09-08 9:53 ` Jan Kiszka
0 siblings, 1 reply; 24+ messages in thread
From: Jan Kiszka @ 2026-09-08 9:47 UTC (permalink / raw)
To: Ilias Apalodimas, U-Boot Mailing List
Cc: Jens Wiklander, Sai Sree Kartheek Adivi, Alexander Heinisch,
Tanmay Kathpalia
On 08.09.26 09:08, Ilias Apalodimas wrote:
> Hi Jan
>
>
> On Sun Aug 23, 2026 at 10:47 PM EEST, Jan Kiszka wrote:
>> From: Jan Kiszka <jan.kiszka@siemens.com>
>>
>> This already avoids code duplication between the different enumeration
>> commands. It will furthermore allow to implement a third one for
>> services with RPMB needs.
>>
>> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
>> ---
>> drivers/tee/optee/core.c | 33 +++++++++++++++++--------------
>> drivers/tee/optee/optee_private.h | 3 +++
>> 2 files changed, 21 insertions(+), 15 deletions(-)
>>
>> diff --git a/drivers/tee/optee/core.c b/drivers/tee/optee/core.c
>> index 4d67c948ec1..2871760a7b7 100644
>> --- a/drivers/tee/optee/core.c
>> +++ b/drivers/tee/optee/core.c
>> @@ -156,7 +156,7 @@ static int enum_services(struct udevice *dev, struct tee_shm **shm, size_t *coun
>> return ret;
>> }
>>
>> -static int open_enum_session(struct udevice *dev, u32 *tee_sess)
>> +int optee_open_enum_session(struct udevice *dev, u32 *tee_sess)
>> {
>> const struct tee_optee_ta_uuid pta_uuid = PTA_DEVICE_ENUM;
>> struct tee_open_session_arg arg = { };
>> @@ -176,31 +176,34 @@ static int open_enum_session(struct udevice *dev, u32 *tee_sess)
>> return 0;
>> }
>>
>> -static int bind_service_drivers(struct udevice *dev)
>> +int optee_bind_services(struct udevice *dev, u32 tee_sess,
>> + unsigned int pta_cmd)
>> {
>> struct tee_shm *service_list = NULL;
>> size_t service_count;
>> - u32 tee_sess;
>> - int ret, ret2;
>> -
>> - ret = open_enum_session(dev, &tee_sess);
>> - if (ret)
>> - return ret;
>> + int ret;
>>
>> ret = enum_services(dev, &service_list, &service_count, tee_sess,
>> - PTA_CMD_GET_DEVICES);
>> + pta_cmd);
>> if (!ret && service_count)
>> ret = bind_service_list(dev, service_list, service_count);
>>
>> tee_shm_free(service_list);
>> - service_list = NULL;
>>
>> - ret2 = enum_services(dev, &service_list, &service_count, tee_sess,
>> - PTA_CMD_GET_DEVICES_SUPP);
>> - if (!ret2 && service_count)
>> - ret2 = bind_service_list(dev, service_list, service_count);
>> + return ret;
>> +}
>> +
>> +static int bind_service_drivers(struct udevice *dev)
>> +{
>> + u32 tee_sess;
>> + int ret, ret2;
>>
>> - tee_shm_free(service_list);
>> + ret = optee_open_enum_session(dev, &tee_sess);
>> + if (ret)
>> + return ret;
>> +
>> + ret = optee_bind_services(dev, tee_sess, PTA_CMD_GET_DEVICES);
>
> Any reason we aren't exiting immediately here?
>
Just maintained the pre-existing behavior. But I could do this as well:
ret = optee_bind_services(dev, tee_sess, PTA_CMD_GET_DEVICES);
if (ret == 0)
ret = optee_bind_services(dev, tee_sess,
PTA_CMD_GET_DEVICES_SUPP);
Simpler, in fact...
Jan
>> + ret2 = optee_bind_services(dev, tee_sess, PTA_CMD_GET_DEVICES_SUPP);
>>
>> tee_close_session(dev, tee_sess);
>>
>> diff --git a/drivers/tee/optee/optee_private.h b/drivers/tee/optee/optee_private.h
>> index 1f07a27ee4b..25b6b3c3218 100644
>> --- a/drivers/tee/optee/optee_private.h
>> +++ b/drivers/tee/optee/optee_private.h
>> @@ -27,6 +27,9 @@ struct optee_msg_arg;
>>
>> void optee_suppl_cmd(struct udevice *dev, struct tee_shm *shm_arg,
>> void **page_list);
>> +int optee_open_enum_session(struct udevice *dev, u32 *tee_sess);
>> +int optee_bind_services(struct udevice *dev, u32 tee_sess,
>> + unsigned int pta_cmd);
>>
>> #ifdef CONFIG_SUPPORT_EMMC_RPMB
>> /**
>
> Cheers
> /Ilias
--
Siemens AG, Foundational Technologies
Linux Expert Center
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 1/5] tee: optee: Factor out service enumeration and binding functions
2026-09-08 9:47 ` Jan Kiszka
@ 2026-09-08 9:53 ` Jan Kiszka
2026-09-08 10:34 ` Ilias Apalodimas
0 siblings, 1 reply; 24+ messages in thread
From: Jan Kiszka @ 2026-09-08 9:53 UTC (permalink / raw)
To: Ilias Apalodimas, U-Boot Mailing List
Cc: Jens Wiklander, Sai Sree Kartheek Adivi, Alexander Heinisch,
Tanmay Kathpalia
On 08.09.26 11:47, Jan Kiszka wrote:
> On 08.09.26 09:08, Ilias Apalodimas wrote:
>> Hi Jan
>>
>>
>> On Sun Aug 23, 2026 at 10:47 PM EEST, Jan Kiszka wrote:
>>> From: Jan Kiszka <jan.kiszka@siemens.com>
>>>
>>> This already avoids code duplication between the different enumeration
>>> commands. It will furthermore allow to implement a third one for
>>> services with RPMB needs.
>>>
>>> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
>>> ---
>>> drivers/tee/optee/core.c | 33 +++++++++++++++++--------------
>>> drivers/tee/optee/optee_private.h | 3 +++
>>> 2 files changed, 21 insertions(+), 15 deletions(-)
>>>
>>> diff --git a/drivers/tee/optee/core.c b/drivers/tee/optee/core.c
>>> index 4d67c948ec1..2871760a7b7 100644
>>> --- a/drivers/tee/optee/core.c
>>> +++ b/drivers/tee/optee/core.c
>>> @@ -156,7 +156,7 @@ static int enum_services(struct udevice *dev, struct tee_shm **shm, size_t *coun
>>> return ret;
>>> }
>>>
>>> -static int open_enum_session(struct udevice *dev, u32 *tee_sess)
>>> +int optee_open_enum_session(struct udevice *dev, u32 *tee_sess)
>>> {
>>> const struct tee_optee_ta_uuid pta_uuid = PTA_DEVICE_ENUM;
>>> struct tee_open_session_arg arg = { };
>>> @@ -176,31 +176,34 @@ static int open_enum_session(struct udevice *dev, u32 *tee_sess)
>>> return 0;
>>> }
>>>
>>> -static int bind_service_drivers(struct udevice *dev)
>>> +int optee_bind_services(struct udevice *dev, u32 tee_sess,
>>> + unsigned int pta_cmd)
>>> {
>>> struct tee_shm *service_list = NULL;
>>> size_t service_count;
>>> - u32 tee_sess;
>>> - int ret, ret2;
>>> -
>>> - ret = open_enum_session(dev, &tee_sess);
>>> - if (ret)
>>> - return ret;
>>> + int ret;
>>>
>>> ret = enum_services(dev, &service_list, &service_count, tee_sess,
>>> - PTA_CMD_GET_DEVICES);
>>> + pta_cmd);
>>> if (!ret && service_count)
>>> ret = bind_service_list(dev, service_list, service_count);
>>>
>>> tee_shm_free(service_list);
>>> - service_list = NULL;
>>>
>>> - ret2 = enum_services(dev, &service_list, &service_count, tee_sess,
>>> - PTA_CMD_GET_DEVICES_SUPP);
>>> - if (!ret2 && service_count)
>>> - ret2 = bind_service_list(dev, service_list, service_count);
>>> + return ret;
>>> +}
>>> +
>>> +static int bind_service_drivers(struct udevice *dev)
>>> +{
>>> + u32 tee_sess;
>>> + int ret, ret2;
>>>
>>> - tee_shm_free(service_list);
>>> + ret = optee_open_enum_session(dev, &tee_sess);
>>> + if (ret)
>>> + return ret;
>>> +
>>> + ret = optee_bind_services(dev, tee_sess, PTA_CMD_GET_DEVICES);
>>
>> Any reason we aren't exiting immediately here?
>>
>
> Just maintained the pre-existing behavior. But I could do this as well:
>
> ret = optee_bind_services(dev, tee_sess, PTA_CMD_GET_DEVICES);
> if (ret == 0)
> ret = optee_bind_services(dev, tee_sess,
> PTA_CMD_GET_DEVICES_SUPP);
>
> Simpler, in fact...
>
... but logically different: We only warn if any binding attempt fails,
now we would not even attempt the other.
Key question is whether such an error scenario is possible at all, thus
only PTA_CMD_GET_DEVICES fails but not PTA_CMD_GET_DEVICES_SUPP.
Jan
--
Siemens AG, Foundational Technologies
Linux Expert Center
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 1/5] tee: optee: Factor out service enumeration and binding functions
2026-09-08 9:53 ` Jan Kiszka
@ 2026-09-08 10:34 ` Ilias Apalodimas
0 siblings, 0 replies; 24+ messages in thread
From: Ilias Apalodimas @ 2026-09-08 10:34 UTC (permalink / raw)
To: Jan Kiszka
Cc: U-Boot Mailing List, Jens Wiklander, Sai Sree Kartheek Adivi,
Alexander Heinisch, Tanmay Kathpalia
On Tue, 8 Sept 2026 at 12:53, Jan Kiszka <jan.kiszka@siemens.com> wrote:
>
> On 08.09.26 11:47, Jan Kiszka wrote:
> > On 08.09.26 09:08, Ilias Apalodimas wrote:
> >> Hi Jan
> >>
> >>
> >> On Sun Aug 23, 2026 at 10:47 PM EEST, Jan Kiszka wrote:
> >>> From: Jan Kiszka <jan.kiszka@siemens.com>
> >>>
> >>> This already avoids code duplication between the different enumeration
> >>> commands. It will furthermore allow to implement a third one for
> >>> services with RPMB needs.
> >>>
> >>> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
> >>> ---
> >>> drivers/tee/optee/core.c | 33 +++++++++++++++++--------------
> >>> drivers/tee/optee/optee_private.h | 3 +++
> >>> 2 files changed, 21 insertions(+), 15 deletions(-)
> >>>
> >>> diff --git a/drivers/tee/optee/core.c b/drivers/tee/optee/core.c
> >>> index 4d67c948ec1..2871760a7b7 100644
> >>> --- a/drivers/tee/optee/core.c
> >>> +++ b/drivers/tee/optee/core.c
> >>> @@ -156,7 +156,7 @@ static int enum_services(struct udevice *dev, struct tee_shm **shm, size_t *coun
> >>> return ret;
> >>> }
> >>>
> >>> -static int open_enum_session(struct udevice *dev, u32 *tee_sess)
> >>> +int optee_open_enum_session(struct udevice *dev, u32 *tee_sess)
> >>> {
> >>> const struct tee_optee_ta_uuid pta_uuid = PTA_DEVICE_ENUM;
> >>> struct tee_open_session_arg arg = { };
> >>> @@ -176,31 +176,34 @@ static int open_enum_session(struct udevice *dev, u32 *tee_sess)
> >>> return 0;
> >>> }
> >>>
> >>> -static int bind_service_drivers(struct udevice *dev)
> >>> +int optee_bind_services(struct udevice *dev, u32 tee_sess,
> >>> + unsigned int pta_cmd)
> >>> {
> >>> struct tee_shm *service_list = NULL;
> >>> size_t service_count;
> >>> - u32 tee_sess;
> >>> - int ret, ret2;
> >>> -
> >>> - ret = open_enum_session(dev, &tee_sess);
> >>> - if (ret)
> >>> - return ret;
> >>> + int ret;
> >>>
> >>> ret = enum_services(dev, &service_list, &service_count, tee_sess,
> >>> - PTA_CMD_GET_DEVICES);
> >>> + pta_cmd);
> >>> if (!ret && service_count)
> >>> ret = bind_service_list(dev, service_list, service_count);
> >>>
> >>> tee_shm_free(service_list);
> >>> - service_list = NULL;
> >>>
> >>> - ret2 = enum_services(dev, &service_list, &service_count, tee_sess,
> >>> - PTA_CMD_GET_DEVICES_SUPP);
> >>> - if (!ret2 && service_count)
> >>> - ret2 = bind_service_list(dev, service_list, service_count);
> >>> + return ret;
> >>> +}
> >>> +
> >>> +static int bind_service_drivers(struct udevice *dev)
> >>> +{
> >>> + u32 tee_sess;
> >>> + int ret, ret2;
> >>>
> >>> - tee_shm_free(service_list);
> >>> + ret = optee_open_enum_session(dev, &tee_sess);
> >>> + if (ret)
> >>> + return ret;
> >>> +
> >>> + ret = optee_bind_services(dev, tee_sess, PTA_CMD_GET_DEVICES);
> >>
> >> Any reason we aren't exiting immediately here?
> >>
> >
> > Just maintained the pre-existing behavior. But I could do this as well:
> >
> > ret = optee_bind_services(dev, tee_sess, PTA_CMD_GET_DEVICES);
> > if (ret == 0)
> > ret = optee_bind_services(dev, tee_sess,
> > PTA_CMD_GET_DEVICES_SUPP);
> >
> > Simpler, in fact...
> >
>
> ... but logically different: We only warn if any binding attempt fails,
> now we would not even attempt the other.
>
> Key question is whether such an error scenario is possible at all, thus
> only PTA_CMD_GET_DEVICES fails but not PTA_CMD_GET_DEVICES_SUPP.
This can happen in the kernel (e.g the emulated RPMB that the
supplicant presents), but I don't think it happens in u-boot. However,
this is a valid reason not to exit immediately, so I am fine leaving
it as is
Cheers
/Ilias
>
> Jan
>
> --
> Siemens AG, Foundational Technologies
> Linux Expert Center
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 2/5] tee: optee: Add support for enumerating services that only need RPMB
2026-09-08 7:25 ` Ilias Apalodimas
@ 2026-09-08 10:55 ` Jan Kiszka
2026-09-08 11:55 ` Ilias Apalodimas
0 siblings, 1 reply; 24+ messages in thread
From: Jan Kiszka @ 2026-09-08 10:55 UTC (permalink / raw)
To: Ilias Apalodimas, U-Boot Mailing List
Cc: Jens Wiklander, Sai Sree Kartheek Adivi, Alexander Heinisch,
Tanmay Kathpalia
On 08.09.26 09:25, Ilias Apalodimas wrote:
> [...]
>
> On Sun Aug 23, 2026 at 10:47 PM EEST, Jan Kiszka wrote:
>> +
>> /**
>> * struct optee_private - OP-TEE driver private data
>> * @rpmb_mmc: mmc device for the RPMB partition
>> diff --git a/drivers/tee/optee/rpmb.c b/drivers/tee/optee/rpmb.c
>> index bacced6af6c..f7312d7171c 100644
>> --- a/drivers/tee/optee/rpmb.c
>> +++ b/drivers/tee/optee/rpmb.c
>> @@ -191,3 +191,22 @@ void optee_suppl_rpmb_release(struct udevice *dev)
>> {
>> release_mmc(dev_get_priv(dev));
>> }
>> +
>> +void optee_rpmb_available(void)
>> +{
>> + struct udevice *dev;
>> + struct uclass *uc;
>> + u32 tee_sess;
>> +
>> + uclass_id_foreach_dev(UCLASS_TEE, dev, uc) {
>> + if (strcmp(dev->driver->name, "optee") != 0)
>> + continue;
>> +
>> + if (optee_open_enum_session(dev, &tee_sess) != 0)
>> + continue;
>> +
>> + optee_bind_services(dev, tee_sess, PTA_CMD_GET_DEVICES_RPMB);
>
> Will this work if devices are bound but not probed? IOW do we need a device_active() check?
>
You mean the theoretical case that MMC is probed before optee? Unlikely
right now but still valid. Let me add that.
Jan
>> +
>> + tee_close_session(dev, tee_sess);
>> + }
>> +}
>> diff --git a/include/tee/optee.h b/include/tee/optee.h
>> index d1194493780..755533b2c0b 100644
>> --- a/include/tee/optee.h
>> +++ b/include/tee/optee.h
>> @@ -74,4 +74,10 @@ static inline bool is_optee_smc_api(void)
>> }
>> #endif
>>
>> +#if defined(CONFIG_OPTEE) && defined(CONFIG_SUPPORT_EMMC_RPMB)
>> +void optee_rpmb_available(void);
>> +#else
>> +static inline void optee_rpmb_available(void) {}
>> +#endif
>> +
>> #endif /* _OPTEE_H */
>
> Thanks
> /Ilias
--
Siemens AG, Foundational Technologies
Linux Expert Center
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 3/5] tee: optee: Do not warn about TEE_ERROR_STORAGE_NOT_AVAILABLE
2026-09-08 7:15 ` Ilias Apalodimas
@ 2026-09-08 11:01 ` Jan Kiszka
2026-09-08 11:54 ` Ilias Apalodimas
0 siblings, 1 reply; 24+ messages in thread
From: Jan Kiszka @ 2026-09-08 11:01 UTC (permalink / raw)
To: Ilias Apalodimas, U-Boot Mailing List
Cc: Jens Wiklander, Sai Sree Kartheek Adivi, Alexander Heinisch,
Tanmay Kathpalia
On 08.09.26 09:15, Ilias Apalodimas wrote:
> Hi Jan
>
> On Sun Aug 23, 2026 at 10:47 PM EEST, Jan Kiszka wrote:
>> From: Jan Kiszka <jan.kiszka@siemens.com>
>>
>> This is a transitional error that is resolved once an RPMB becomes
>> available. Keep it as debug output only.
>>
>> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
>> ---
>> drivers/tee/optee/core.c | 5 ++++-
>> 1 file changed, 4 insertions(+), 1 deletion(-)
>>
>> diff --git a/drivers/tee/optee/core.c b/drivers/tee/optee/core.c
>> index ed8f2b6ec74..d3b5811afb8 100644
>> --- a/drivers/tee/optee/core.c
>> +++ b/drivers/tee/optee/core.c
>> @@ -106,7 +106,10 @@ static int __enum_services(struct udevice *dev, struct tee_shm *shm, size_t *shm
>>
>> ret = tee_invoke_func(dev, &arg, 1, ¶m);
>> if (ret || (arg.ret && arg.ret != TEE_ERROR_SHORT_BUFFER)) {
>> - dev_err(dev, "Enumeration command 0x%x failed: 0x%x\n", pta_cmd, arg.ret);
>> + if (arg.ret != TEE_ERROR_STORAGE_NOT_AVAILABLE)
>> + dev_err(dev, "Enumeration command 0x%x failed: 0x%x\n", pta_cmd, arg.ret);
>> + else
>> + dev_dbg(dev, "Enumeration command 0x%x failed due to unavailable storage\n", pta_cmd);
>
> I don't mind changing this and I like the different error messages. Isn't the dgb message useful for
> users though? Or it is something that's not expected to happen in production systems so we can hide
> it?
First of all, it's now something that will always happen due to probing
of services that need RPMB when there is none yet. And, as explained
above, it will be resolved later on. If you user misconfigured the
firmware, though, there will be no resolution - but that is a debugging
case.
Jan
--
Siemens AG, Foundational Technologies
Linux Expert Center
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 3/5] tee: optee: Do not warn about TEE_ERROR_STORAGE_NOT_AVAILABLE
2026-09-08 11:01 ` Jan Kiszka
@ 2026-09-08 11:54 ` Ilias Apalodimas
0 siblings, 0 replies; 24+ messages in thread
From: Ilias Apalodimas @ 2026-09-08 11:54 UTC (permalink / raw)
To: Jan Kiszka
Cc: U-Boot Mailing List, Jens Wiklander, Sai Sree Kartheek Adivi,
Alexander Heinisch, Tanmay Kathpalia
On Tue, 8 Sept 2026 at 14:01, Jan Kiszka <jan.kiszka@siemens.com> wrote:
>
> On 08.09.26 09:15, Ilias Apalodimas wrote:
> > Hi Jan
> >
> > On Sun Aug 23, 2026 at 10:47 PM EEST, Jan Kiszka wrote:
> >> From: Jan Kiszka <jan.kiszka@siemens.com>
> >>
> >> This is a transitional error that is resolved once an RPMB becomes
> >> available. Keep it as debug output only.
> >>
> >> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
> >> ---
> >> drivers/tee/optee/core.c | 5 ++++-
> >> 1 file changed, 4 insertions(+), 1 deletion(-)
> >>
> >> diff --git a/drivers/tee/optee/core.c b/drivers/tee/optee/core.c
> >> index ed8f2b6ec74..d3b5811afb8 100644
> >> --- a/drivers/tee/optee/core.c
> >> +++ b/drivers/tee/optee/core.c
> >> @@ -106,7 +106,10 @@ static int __enum_services(struct udevice *dev, struct tee_shm *shm, size_t *shm
> >>
> >> ret = tee_invoke_func(dev, &arg, 1, ¶m);
> >> if (ret || (arg.ret && arg.ret != TEE_ERROR_SHORT_BUFFER)) {
> >> - dev_err(dev, "Enumeration command 0x%x failed: 0x%x\n", pta_cmd, arg.ret);
> >> + if (arg.ret != TEE_ERROR_STORAGE_NOT_AVAILABLE)
> >> + dev_err(dev, "Enumeration command 0x%x failed: 0x%x\n", pta_cmd, arg.ret);
> >> + else
> >> + dev_dbg(dev, "Enumeration command 0x%x failed due to unavailable storage\n", pta_cmd);
> >
> > I don't mind changing this and I like the different error messages. Isn't the dgb message useful for
> > users though? Or it is something that's not expected to happen in production systems so we can hide
> > it?
>
> First of all, it's now something that will always happen due to probing
> of services that need RPMB when there is none yet. And, as explained
> above, it will be resolved later on. If you user misconfigured the
> firmware, though, there will be no resolution - but that is a debugging
> case.
Fair enough
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
>
> Jan
>
> --
> Siemens AG, Foundational Technologies
> Linux Expert Center
^ permalink raw reply [flat|nested] 24+ messages in thread
* Re: [PATCH v2 2/5] tee: optee: Add support for enumerating services that only need RPMB
2026-09-08 10:55 ` Jan Kiszka
@ 2026-09-08 11:55 ` Ilias Apalodimas
0 siblings, 0 replies; 24+ messages in thread
From: Ilias Apalodimas @ 2026-09-08 11:55 UTC (permalink / raw)
To: Jan Kiszka
Cc: U-Boot Mailing List, Jens Wiklander, Sai Sree Kartheek Adivi,
Alexander Heinisch, Tanmay Kathpalia
On Tue, 8 Sept 2026 at 13:56, Jan Kiszka <jan.kiszka@siemens.com> wrote:
>
> On 08.09.26 09:25, Ilias Apalodimas wrote:
> > [...]
> >
> > On Sun Aug 23, 2026 at 10:47 PM EEST, Jan Kiszka wrote:
> >> +
> >> /**
> >> * struct optee_private - OP-TEE driver private data
> >> * @rpmb_mmc: mmc device for the RPMB partition
> >> diff --git a/drivers/tee/optee/rpmb.c b/drivers/tee/optee/rpmb.c
> >> index bacced6af6c..f7312d7171c 100644
> >> --- a/drivers/tee/optee/rpmb.c
> >> +++ b/drivers/tee/optee/rpmb.c
> >> @@ -191,3 +191,22 @@ void optee_suppl_rpmb_release(struct udevice *dev)
> >> {
> >> release_mmc(dev_get_priv(dev));
> >> }
> >> +
> >> +void optee_rpmb_available(void)
> >> +{
> >> + struct udevice *dev;
> >> + struct uclass *uc;
> >> + u32 tee_sess;
> >> +
> >> + uclass_id_foreach_dev(UCLASS_TEE, dev, uc) {
> >> + if (strcmp(dev->driver->name, "optee") != 0)
> >> + continue;
> >> +
> >> + if (optee_open_enum_session(dev, &tee_sess) != 0)
> >> + continue;
> >> +
> >> + optee_bind_services(dev, tee_sess, PTA_CMD_GET_DEVICES_RPMB);
> >
> > Will this work if devices are bound but not probed? IOW do we need a device_active() check?
> >
>
> You mean the theoretical case that MMC is probed before optee? Unlikely
> right now but still valid. Let me add that.
Yea, I am not sure if anyone can trigger this with preboot commands
etc, but I think it's better to have it.
Cheers
/Ilias
>
> Jan
>
> >> +
> >> + tee_close_session(dev, tee_sess);
> >> + }
> >> +}
> >> diff --git a/include/tee/optee.h b/include/tee/optee.h
> >> index d1194493780..755533b2c0b 100644
> >> --- a/include/tee/optee.h
> >> +++ b/include/tee/optee.h
> >> @@ -74,4 +74,10 @@ static inline bool is_optee_smc_api(void)
> >> }
> >> #endif
> >>
> >> +#if defined(CONFIG_OPTEE) && defined(CONFIG_SUPPORT_EMMC_RPMB)
> >> +void optee_rpmb_available(void);
> >> +#else
> >> +static inline void optee_rpmb_available(void) {}
> >> +#endif
> >> +
> >> #endif /* _OPTEE_H */
> >
> > Thanks
> > /Ilias
>
> --
> Siemens AG, Foundational Technologies
> Linux Expert Center
^ permalink raw reply [flat|nested] 24+ messages in thread
end of thread, other threads:[~2026-09-08 11:56 UTC | newest]
Thread overview: 24+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-08-23 19:47 [PATCH v2 0/5] optee: Add support for enumerating RPMB-dependent services Jan Kiszka
2026-08-23 19:47 ` [PATCH v2 1/5] tee: optee: Factor out service enumeration and binding functions Jan Kiszka
2026-09-08 7:08 ` Ilias Apalodimas
2026-09-08 9:47 ` Jan Kiszka
2026-09-08 9:53 ` Jan Kiszka
2026-09-08 10:34 ` Ilias Apalodimas
2026-08-23 19:47 ` [PATCH v2 2/5] tee: optee: Add support for enumerating services that only need RPMB Jan Kiszka
2026-09-08 7:25 ` Ilias Apalodimas
2026-09-08 10:55 ` Jan Kiszka
2026-09-08 11:55 ` Ilias Apalodimas
2026-08-23 19:47 ` [PATCH v2 3/5] tee: optee: Do not warn about TEE_ERROR_STORAGE_NOT_AVAILABLE Jan Kiszka
2026-09-08 7:15 ` Ilias Apalodimas
2026-09-08 11:01 ` Jan Kiszka
2026-09-08 11:54 ` Ilias Apalodimas
2026-08-23 19:47 ` [PATCH v2 4/5] mmc: Call back to optee after a successful mmc_init Jan Kiszka
2026-08-26 8:44 ` Peng Fan
2026-08-26 10:10 ` Kathpalia, Tanmay
2026-08-23 19:47 ` [PATCH v2 5/5] mmc: Make "MMC Device not found" a debug output Jan Kiszka
2026-08-26 8:44 ` Peng Fan
2026-08-26 10:10 ` Kathpalia, Tanmay
2026-09-08 7:12 ` Ilias Apalodimas
2026-09-08 7:43 ` Kathpalia, Tanmay
2026-09-08 9:36 ` [PATCH v2 0/5] optee: Add support for enumerating RPMB-dependent services Ilias Apalodimas
2026-09-08 9:43 ` Jan Kiszka
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.