public inbox for linux-security-module@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 00/17] tee: Use bus callbacks instead of driver callbacks
@ 2025-12-15 14:16 Uwe Kleine-König
  2025-12-15 14:16 ` [PATCH v2 14/17] KEYS: trusted: Migrate to use tee specific driver registration function Uwe Kleine-König
                   ` (3 more replies)
  0 siblings, 4 replies; 15+ messages in thread
From: Uwe Kleine-König @ 2025-12-15 14:16 UTC (permalink / raw)
  To: Jens Wiklander, Jonathan Corbet, Sumit Garg, Olivia Mackall,
	Herbert Xu, Clément Léger, Alexandre Belloni,
	Ard Biesheuvel, Maxime Coquelin, Alexandre Torgue, Sumit Garg,
	Ilias Apalodimas, Jan Kiszka, Uwe Kleine-König, Sudeep Holla,
	Christophe JAILLET, Rafał Miłecki, Michael Chan,
	Pavan Chebbi, James Bottomley, Jarkko Sakkinen, Mimi Zohar,
	David Howells, Paul Moore, James Morris, Serge E. Hallyn,
	Peter Huewe
  Cc: op-tee, linux-kernel, linux-doc, linux-crypto, linux-rtc,
	linux-efi, linux-stm32, linux-arm-kernel, Cristian Marussi,
	arm-scmi, linux-mips, netdev, linux-integrity, keyrings,
	linux-security-module, Jason Gunthorpe

Hello,

the objective of this series is to make tee driver stop using callbacks
in struct device_driver. These were superseded by bus methods in 2006
(commit 594c8281f905 ("[PATCH] Add bus_type probe, remove, shutdown
methods.")) but nobody cared to convert all subsystems accordingly.

Here the tee drivers are converted. The first commit is somewhat
unrelated, but simplifies the conversion (and the drivers). It
introduces driver registration helpers that care about setting the bus
and owner. (The latter is missing in all drivers, so by using these
helpers the drivers become more correct.)

v1 of this series is available at
https://lore.kernel.org/all/cover.1765472125.git.u.kleine-koenig@baylibre.com

Changes since v1:

 - rebase to v6.19-rc1 (no conflicts)
 - add tags received so far
 - fix whitespace issues pointed out by Sumit Garg
 - fix shutdown callback to shutdown and not remove

As already noted in v1's cover letter, this series should go in during a
single merge window as there are runtime warnings when the series is
only applied partially. Sumit Garg suggested to apply the whole series
via Jens Wiklander's tree.
If this is done the dependencies in this series are honored, in case the
plan changes: Patches #4 - #17 depend on the first two.

Note this series is only build tested.

Uwe Kleine-König (17):
  tee: Add some helpers to reduce boilerplate for tee client drivers
  tee: Add probe, remove and shutdown bus callbacks to tee_client_driver
  tee: Adapt documentation to cover recent additions
  hwrng: optee - Make use of module_tee_client_driver()
  hwrng: optee - Make use of tee bus methods
  rtc: optee: Migrate to use tee specific driver registration function
  rtc: optee: Make use of tee bus methods
  efi: stmm: Make use of module_tee_client_driver()
  efi: stmm: Make use of tee bus methods
  firmware: arm_scmi: optee: Make use of module_tee_client_driver()
  firmware: arm_scmi: Make use of tee bus methods
  firmware: tee_bnxt: Make use of module_tee_client_driver()
  firmware: tee_bnxt: Make use of tee bus methods
  KEYS: trusted: Migrate to use tee specific driver registration
    function
  KEYS: trusted: Make use of tee bus methods
  tpm/tpm_ftpm_tee: Make use of tee specific driver registration
  tpm/tpm_ftpm_tee: Make use of tee bus methods

 Documentation/driver-api/tee.rst             | 18 +----
 drivers/char/hw_random/optee-rng.c           | 26 ++----
 drivers/char/tpm/tpm_ftpm_tee.c              | 31 +++++---
 drivers/firmware/arm_scmi/transports/optee.c | 32 +++-----
 drivers/firmware/broadcom/tee_bnxt_fw.c      | 30 ++-----
 drivers/firmware/efi/stmm/tee_stmm_efi.c     | 25 ++----
 drivers/rtc/rtc-optee.c                      | 27 ++-----
 drivers/tee/tee_core.c                       | 84 ++++++++++++++++++++
 include/linux/tee_drv.h                      | 12 +++
 security/keys/trusted-keys/trusted_tee.c     | 17 ++--
 10 files changed, 164 insertions(+), 138 deletions(-)

base-commit: 8f0b4cce4481fb22653697cced8d0d04027cb1e8
-- 
2.47.3


^ permalink raw reply	[flat|nested] 15+ messages in thread

* [PATCH v2 14/17] KEYS: trusted: Migrate to use tee specific driver registration function
  2025-12-15 14:16 [PATCH v2 00/17] tee: Use bus callbacks instead of driver callbacks Uwe Kleine-König
@ 2025-12-15 14:16 ` Uwe Kleine-König
  2025-12-15 22:01   ` Jarkko Sakkinen
  2025-12-15 14:16 ` [PATCH v2 15/17] KEYS: trusted: Make use of tee bus methods Uwe Kleine-König
                   ` (2 subsequent siblings)
  3 siblings, 1 reply; 15+ messages in thread
From: Uwe Kleine-König @ 2025-12-15 14:16 UTC (permalink / raw)
  To: Jens Wiklander, Sumit Garg, James Bottomley, Jarkko Sakkinen,
	Mimi Zohar, David Howells, Paul Moore, James Morris,
	Serge E. Hallyn
  Cc: linux-integrity, keyrings, linux-security-module, op-tee,
	linux-kernel, Sumit Garg

The tee subsystem recently got a set of dedicated functions to register
(and unregister) a tee driver. Make use of them. These care for setting the
driver's bus (so the explicit assignment can be dropped) and the driver
owner (which is an improvement this driver benefits from).

Reviewed-by: Sumit Garg <sumit.garg@oss.qualcomm.com>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@baylibre.com>
---
 security/keys/trusted-keys/trusted_tee.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/security/keys/trusted-keys/trusted_tee.c b/security/keys/trusted-keys/trusted_tee.c
index aa3d477de6db..3cea9a377955 100644
--- a/security/keys/trusted-keys/trusted_tee.c
+++ b/security/keys/trusted-keys/trusted_tee.c
@@ -264,7 +264,6 @@ static struct tee_client_driver trusted_key_driver = {
 	.id_table	= trusted_key_id_table,
 	.driver		= {
 		.name		= DRIVER_NAME,
-		.bus		= &tee_bus_type,
 		.probe		= trusted_key_probe,
 		.remove		= trusted_key_remove,
 	},
@@ -272,12 +271,12 @@ static struct tee_client_driver trusted_key_driver = {
 
 static int trusted_tee_init(void)
 {
-	return driver_register(&trusted_key_driver.driver);
+	return tee_client_driver_register(&trusted_key_driver);
 }
 
 static void trusted_tee_exit(void)
 {
-	driver_unregister(&trusted_key_driver.driver);
+	tee_client_driver_unregister(&trusted_key_driver);
 }
 
 struct trusted_key_ops trusted_key_tee_ops = {
-- 
2.47.3


^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [PATCH v2 15/17] KEYS: trusted: Make use of tee bus methods
  2025-12-15 14:16 [PATCH v2 00/17] tee: Use bus callbacks instead of driver callbacks Uwe Kleine-König
  2025-12-15 14:16 ` [PATCH v2 14/17] KEYS: trusted: Migrate to use tee specific driver registration function Uwe Kleine-König
@ 2025-12-15 14:16 ` Uwe Kleine-König
  2025-12-15 22:04   ` Jarkko Sakkinen
  2025-12-18  7:21 ` [PATCH v2 00/17] tee: Use bus callbacks instead of driver callbacks Jens Wiklander
  2026-01-06  9:39 ` Jon Hunter
  3 siblings, 1 reply; 15+ messages in thread
From: Uwe Kleine-König @ 2025-12-15 14:16 UTC (permalink / raw)
  To: Jens Wiklander, Sumit Garg, James Bottomley, Jarkko Sakkinen,
	Mimi Zohar, David Howells, Paul Moore, James Morris,
	Serge E. Hallyn
  Cc: linux-integrity, keyrings, linux-security-module, op-tee,
	linux-kernel, Sumit Garg

The tee bus got dedicated callbacks for probe and remove.
Make use of these. This fixes a runtime warning about the driver needing
to be converted to the bus methods.

Reviewed-by: Sumit Garg <sumit.garg@oss.qualcomm.com>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@baylibre.com>
---
 security/keys/trusted-keys/trusted_tee.c | 12 +++++-------
 1 file changed, 5 insertions(+), 7 deletions(-)

diff --git a/security/keys/trusted-keys/trusted_tee.c b/security/keys/trusted-keys/trusted_tee.c
index 3cea9a377955..6e465c8bef5e 100644
--- a/security/keys/trusted-keys/trusted_tee.c
+++ b/security/keys/trusted-keys/trusted_tee.c
@@ -202,9 +202,9 @@ static int optee_ctx_match(struct tee_ioctl_version_data *ver, const void *data)
 		return 0;
 }
 
-static int trusted_key_probe(struct device *dev)
+static int trusted_key_probe(struct tee_client_device *rng_device)
 {
-	struct tee_client_device *rng_device = to_tee_client_device(dev);
+	struct device *dev = &rng_device->dev;
 	int ret;
 	struct tee_ioctl_open_session_arg sess_arg;
 
@@ -244,13 +244,11 @@ static int trusted_key_probe(struct device *dev)
 	return ret;
 }
 
-static int trusted_key_remove(struct device *dev)
+static void trusted_key_remove(struct tee_client_device *dev)
 {
 	unregister_key_type(&key_type_trusted);
 	tee_client_close_session(pvt_data.ctx, pvt_data.session_id);
 	tee_client_close_context(pvt_data.ctx);
-
-	return 0;
 }
 
 static const struct tee_client_device_id trusted_key_id_table[] = {
@@ -261,11 +259,11 @@ static const struct tee_client_device_id trusted_key_id_table[] = {
 MODULE_DEVICE_TABLE(tee, trusted_key_id_table);
 
 static struct tee_client_driver trusted_key_driver = {
+	.probe		= trusted_key_probe,
+	.remove		= trusted_key_remove,
 	.id_table	= trusted_key_id_table,
 	.driver		= {
 		.name		= DRIVER_NAME,
-		.probe		= trusted_key_probe,
-		.remove		= trusted_key_remove,
 	},
 };
 
-- 
2.47.3


^ permalink raw reply related	[flat|nested] 15+ messages in thread

* Re: [PATCH v2 14/17] KEYS: trusted: Migrate to use tee specific driver registration function
  2025-12-15 14:16 ` [PATCH v2 14/17] KEYS: trusted: Migrate to use tee specific driver registration function Uwe Kleine-König
@ 2025-12-15 22:01   ` Jarkko Sakkinen
  0 siblings, 0 replies; 15+ messages in thread
From: Jarkko Sakkinen @ 2025-12-15 22:01 UTC (permalink / raw)
  To: Uwe Kleine-König
  Cc: Jens Wiklander, Sumit Garg, James Bottomley, Mimi Zohar,
	David Howells, Paul Moore, James Morris, Serge E. Hallyn,
	linux-integrity, keyrings, linux-security-module, op-tee,
	linux-kernel, Sumit Garg

On Mon, Dec 15, 2025 at 03:16:44PM +0100, Uwe Kleine-König wrote:
> The tee subsystem recently got a set of dedicated functions to register
> (and unregister) a tee driver. Make use of them. These care for setting the
> driver's bus (so the explicit assignment can be dropped) and the driver
> owner (which is an improvement this driver benefits from).
> 
> Reviewed-by: Sumit Garg <sumit.garg@oss.qualcomm.com>
> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@baylibre.com>
> ---
>  security/keys/trusted-keys/trusted_tee.c | 5 ++---
>  1 file changed, 2 insertions(+), 3 deletions(-)
> 
> diff --git a/security/keys/trusted-keys/trusted_tee.c b/security/keys/trusted-keys/trusted_tee.c
> index aa3d477de6db..3cea9a377955 100644
> --- a/security/keys/trusted-keys/trusted_tee.c
> +++ b/security/keys/trusted-keys/trusted_tee.c
> @@ -264,7 +264,6 @@ static struct tee_client_driver trusted_key_driver = {
>  	.id_table	= trusted_key_id_table,
>  	.driver		= {
>  		.name		= DRIVER_NAME,
> -		.bus		= &tee_bus_type,
>  		.probe		= trusted_key_probe,
>  		.remove		= trusted_key_remove,
>  	},
> @@ -272,12 +271,12 @@ static struct tee_client_driver trusted_key_driver = {
>  
>  static int trusted_tee_init(void)
>  {
> -	return driver_register(&trusted_key_driver.driver);
> +	return tee_client_driver_register(&trusted_key_driver);
>  }
>  
>  static void trusted_tee_exit(void)
>  {
> -	driver_unregister(&trusted_key_driver.driver);
> +	tee_client_driver_unregister(&trusted_key_driver);
>  }
>  
>  struct trusted_key_ops trusted_key_tee_ops = {
> -- 
> 2.47.3
> 

Reviewed-by: Jarkko Sakkinen <jarkko@kernel.org>

BR, Jarkko

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [PATCH v2 15/17] KEYS: trusted: Make use of tee bus methods
  2025-12-15 14:16 ` [PATCH v2 15/17] KEYS: trusted: Make use of tee bus methods Uwe Kleine-König
@ 2025-12-15 22:04   ` Jarkko Sakkinen
  0 siblings, 0 replies; 15+ messages in thread
From: Jarkko Sakkinen @ 2025-12-15 22:04 UTC (permalink / raw)
  To: Uwe Kleine-König
  Cc: Jens Wiklander, Sumit Garg, James Bottomley, Mimi Zohar,
	David Howells, Paul Moore, James Morris, Serge E. Hallyn,
	linux-integrity, keyrings, linux-security-module, op-tee,
	linux-kernel, Sumit Garg

On Mon, Dec 15, 2025 at 03:16:45PM +0100, Uwe Kleine-König wrote:
> The tee bus got dedicated callbacks for probe and remove.
> Make use of these. This fixes a runtime warning about the driver needing
> to be converted to the bus methods.
> 
> Reviewed-by: Sumit Garg <sumit.garg@oss.qualcomm.com>
> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@baylibre.com>
> ---
>  security/keys/trusted-keys/trusted_tee.c | 12 +++++-------
>  1 file changed, 5 insertions(+), 7 deletions(-)
> 
> diff --git a/security/keys/trusted-keys/trusted_tee.c b/security/keys/trusted-keys/trusted_tee.c
> index 3cea9a377955..6e465c8bef5e 100644
> --- a/security/keys/trusted-keys/trusted_tee.c
> +++ b/security/keys/trusted-keys/trusted_tee.c
> @@ -202,9 +202,9 @@ static int optee_ctx_match(struct tee_ioctl_version_data *ver, const void *data)
>  		return 0;
>  }
>  
> -static int trusted_key_probe(struct device *dev)
> +static int trusted_key_probe(struct tee_client_device *rng_device)
>  {
> -	struct tee_client_device *rng_device = to_tee_client_device(dev);
> +	struct device *dev = &rng_device->dev;
>  	int ret;
>  	struct tee_ioctl_open_session_arg sess_arg;

I'm sorry but cannot help saying but these not being in reverse tree
order hurts my eyes ;-)

I.e., I'd personally move declaration of sess_arg right after rng_device
despite being additional change to the scope of the patch.

That said, Sumit has the ultimate veto right here, and this not any kind
of fault in this patch so I will obviously ack the patch;

Reviewed-by: Jarkko Sakkinen <jarkko@kernel.org>


>  
> @@ -244,13 +244,11 @@ static int trusted_key_probe(struct device *dev)
>  	return ret;
>  }
>  
> -static int trusted_key_remove(struct device *dev)
> +static void trusted_key_remove(struct tee_client_device *dev)
>  {
>  	unregister_key_type(&key_type_trusted);
>  	tee_client_close_session(pvt_data.ctx, pvt_data.session_id);
>  	tee_client_close_context(pvt_data.ctx);
> -
> -	return 0;
>  }
>  
>  static const struct tee_client_device_id trusted_key_id_table[] = {
> @@ -261,11 +259,11 @@ static const struct tee_client_device_id trusted_key_id_table[] = {
>  MODULE_DEVICE_TABLE(tee, trusted_key_id_table);
>  
>  static struct tee_client_driver trusted_key_driver = {
> +	.probe		= trusted_key_probe,
> +	.remove		= trusted_key_remove,
>  	.id_table	= trusted_key_id_table,
>  	.driver		= {
>  		.name		= DRIVER_NAME,
> -		.probe		= trusted_key_probe,
> -		.remove		= trusted_key_remove,
>  	},
>  };
>  
> -- 
> 2.47.3
> 

BR, Jarkko

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [PATCH v2 00/17] tee: Use bus callbacks instead of driver callbacks
  2025-12-15 14:16 [PATCH v2 00/17] tee: Use bus callbacks instead of driver callbacks Uwe Kleine-König
  2025-12-15 14:16 ` [PATCH v2 14/17] KEYS: trusted: Migrate to use tee specific driver registration function Uwe Kleine-König
  2025-12-15 14:16 ` [PATCH v2 15/17] KEYS: trusted: Make use of tee bus methods Uwe Kleine-König
@ 2025-12-18  7:21 ` Jens Wiklander
  2025-12-18 13:53   ` Alexandre Belloni
  2026-01-06  9:39 ` Jon Hunter
  3 siblings, 1 reply; 15+ messages in thread
From: Jens Wiklander @ 2025-12-18  7:21 UTC (permalink / raw)
  To: Uwe Kleine-König
  Cc: Jonathan Corbet, Sumit Garg, Olivia Mackall, Herbert Xu,
	Clément Léger, Alexandre Belloni, Ard Biesheuvel,
	Maxime Coquelin, Alexandre Torgue, Sumit Garg, Ilias Apalodimas,
	Jan Kiszka, Sudeep Holla, Christophe JAILLET,
	Rafał Miłecki, Michael Chan, Pavan Chebbi,
	James Bottomley, Jarkko Sakkinen, Mimi Zohar, David Howells,
	Paul Moore, James Morris, Serge E. Hallyn, Peter Huewe, op-tee,
	linux-kernel, linux-doc, linux-crypto, linux-rtc, linux-efi,
	linux-stm32, linux-arm-kernel, Cristian Marussi, arm-scmi,
	linux-mips, netdev, linux-integrity, keyrings,
	linux-security-module, Jason Gunthorpe

Hi,

On Mon, Dec 15, 2025 at 3:17 PM Uwe Kleine-König
<u.kleine-koenig@baylibre.com> wrote:
>
> Hello,
>
> the objective of this series is to make tee driver stop using callbacks
> in struct device_driver. These were superseded by bus methods in 2006
> (commit 594c8281f905 ("[PATCH] Add bus_type probe, remove, shutdown
> methods.")) but nobody cared to convert all subsystems accordingly.
>
> Here the tee drivers are converted. The first commit is somewhat
> unrelated, but simplifies the conversion (and the drivers). It
> introduces driver registration helpers that care about setting the bus
> and owner. (The latter is missing in all drivers, so by using these
> helpers the drivers become more correct.)
>
> v1 of this series is available at
> https://lore.kernel.org/all/cover.1765472125.git.u.kleine-koenig@baylibre.com
>
> Changes since v1:
>
>  - rebase to v6.19-rc1 (no conflicts)
>  - add tags received so far
>  - fix whitespace issues pointed out by Sumit Garg
>  - fix shutdown callback to shutdown and not remove
>
> As already noted in v1's cover letter, this series should go in during a
> single merge window as there are runtime warnings when the series is
> only applied partially. Sumit Garg suggested to apply the whole series
> via Jens Wiklander's tree.
> If this is done the dependencies in this series are honored, in case the
> plan changes: Patches #4 - #17 depend on the first two.
>
> Note this series is only build tested.
>
> Uwe Kleine-König (17):
>   tee: Add some helpers to reduce boilerplate for tee client drivers
>   tee: Add probe, remove and shutdown bus callbacks to tee_client_driver
>   tee: Adapt documentation to cover recent additions
>   hwrng: optee - Make use of module_tee_client_driver()
>   hwrng: optee - Make use of tee bus methods
>   rtc: optee: Migrate to use tee specific driver registration function
>   rtc: optee: Make use of tee bus methods
>   efi: stmm: Make use of module_tee_client_driver()
>   efi: stmm: Make use of tee bus methods
>   firmware: arm_scmi: optee: Make use of module_tee_client_driver()
>   firmware: arm_scmi: Make use of tee bus methods
>   firmware: tee_bnxt: Make use of module_tee_client_driver()
>   firmware: tee_bnxt: Make use of tee bus methods
>   KEYS: trusted: Migrate to use tee specific driver registration
>     function
>   KEYS: trusted: Make use of tee bus methods
>   tpm/tpm_ftpm_tee: Make use of tee specific driver registration
>   tpm/tpm_ftpm_tee: Make use of tee bus methods
>
>  Documentation/driver-api/tee.rst             | 18 +----
>  drivers/char/hw_random/optee-rng.c           | 26 ++----
>  drivers/char/tpm/tpm_ftpm_tee.c              | 31 +++++---
>  drivers/firmware/arm_scmi/transports/optee.c | 32 +++-----
>  drivers/firmware/broadcom/tee_bnxt_fw.c      | 30 ++-----
>  drivers/firmware/efi/stmm/tee_stmm_efi.c     | 25 ++----
>  drivers/rtc/rtc-optee.c                      | 27 ++-----
>  drivers/tee/tee_core.c                       | 84 ++++++++++++++++++++
>  include/linux/tee_drv.h                      | 12 +++
>  security/keys/trusted-keys/trusted_tee.c     | 17 ++--
>  10 files changed, 164 insertions(+), 138 deletions(-)
>
> base-commit: 8f0b4cce4481fb22653697cced8d0d04027cb1e8
> --
> 2.47.3
>

Thank you for the nice cleanup, Uwe.

I've applied patch 1-3 to the branch tee_bus_callback_for_6.20 in my
tree at https://git.kernel.org/pub/scm/linux/kernel/git/jenswi/linux-tee.git/

The branch is based on v6.19-rc1, and I'll try to keep it stable for
others to depend on, if needed. Let's see if we can agree on taking
the remaining patches via that branch.

Cheers,
Jens

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [PATCH v2 00/17] tee: Use bus callbacks instead of driver callbacks
  2025-12-18  7:21 ` [PATCH v2 00/17] tee: Use bus callbacks instead of driver callbacks Jens Wiklander
@ 2025-12-18 13:53   ` Alexandre Belloni
  2025-12-18 16:29     ` Jens Wiklander
  0 siblings, 1 reply; 15+ messages in thread
From: Alexandre Belloni @ 2025-12-18 13:53 UTC (permalink / raw)
  To: Jens Wiklander
  Cc: Uwe Kleine-König, Jonathan Corbet, Sumit Garg,
	Olivia Mackall, Herbert Xu, Clément Léger,
	Ard Biesheuvel, Maxime Coquelin, Alexandre Torgue, Sumit Garg,
	Ilias Apalodimas, Jan Kiszka, Sudeep Holla, Christophe JAILLET,
	Rafał Miłecki, Michael Chan, Pavan Chebbi,
	James Bottomley, Jarkko Sakkinen, Mimi Zohar, David Howells,
	Paul Moore, James Morris, Serge E. Hallyn, Peter Huewe, op-tee,
	linux-kernel, linux-doc, linux-crypto, linux-rtc, linux-efi,
	linux-stm32, linux-arm-kernel, Cristian Marussi, arm-scmi,
	linux-mips, netdev, linux-integrity, keyrings,
	linux-security-module, Jason Gunthorpe

On 18/12/2025 08:21:27+0100, Jens Wiklander wrote:
> Hi,
> 
> On Mon, Dec 15, 2025 at 3:17 PM Uwe Kleine-König
> <u.kleine-koenig@baylibre.com> wrote:
> >
> > Hello,
> >
> > the objective of this series is to make tee driver stop using callbacks
> > in struct device_driver. These were superseded by bus methods in 2006
> > (commit 594c8281f905 ("[PATCH] Add bus_type probe, remove, shutdown
> > methods.")) but nobody cared to convert all subsystems accordingly.
> >
> > Here the tee drivers are converted. The first commit is somewhat
> > unrelated, but simplifies the conversion (and the drivers). It
> > introduces driver registration helpers that care about setting the bus
> > and owner. (The latter is missing in all drivers, so by using these
> > helpers the drivers become more correct.)
> >
> > v1 of this series is available at
> > https://lore.kernel.org/all/cover.1765472125.git.u.kleine-koenig@baylibre.com
> >
> > Changes since v1:
> >
> >  - rebase to v6.19-rc1 (no conflicts)
> >  - add tags received so far
> >  - fix whitespace issues pointed out by Sumit Garg
> >  - fix shutdown callback to shutdown and not remove
> >
> > As already noted in v1's cover letter, this series should go in during a
> > single merge window as there are runtime warnings when the series is
> > only applied partially. Sumit Garg suggested to apply the whole series
> > via Jens Wiklander's tree.
> > If this is done the dependencies in this series are honored, in case the
> > plan changes: Patches #4 - #17 depend on the first two.
> >
> > Note this series is only build tested.
> >
> > Uwe Kleine-König (17):
> >   tee: Add some helpers to reduce boilerplate for tee client drivers
> >   tee: Add probe, remove and shutdown bus callbacks to tee_client_driver
> >   tee: Adapt documentation to cover recent additions
> >   hwrng: optee - Make use of module_tee_client_driver()
> >   hwrng: optee - Make use of tee bus methods
> >   rtc: optee: Migrate to use tee specific driver registration function
> >   rtc: optee: Make use of tee bus methods
> >   efi: stmm: Make use of module_tee_client_driver()
> >   efi: stmm: Make use of tee bus methods
> >   firmware: arm_scmi: optee: Make use of module_tee_client_driver()
> >   firmware: arm_scmi: Make use of tee bus methods
> >   firmware: tee_bnxt: Make use of module_tee_client_driver()
> >   firmware: tee_bnxt: Make use of tee bus methods
> >   KEYS: trusted: Migrate to use tee specific driver registration
> >     function
> >   KEYS: trusted: Make use of tee bus methods
> >   tpm/tpm_ftpm_tee: Make use of tee specific driver registration
> >   tpm/tpm_ftpm_tee: Make use of tee bus methods
> >
> >  Documentation/driver-api/tee.rst             | 18 +----
> >  drivers/char/hw_random/optee-rng.c           | 26 ++----
> >  drivers/char/tpm/tpm_ftpm_tee.c              | 31 +++++---
> >  drivers/firmware/arm_scmi/transports/optee.c | 32 +++-----
> >  drivers/firmware/broadcom/tee_bnxt_fw.c      | 30 ++-----
> >  drivers/firmware/efi/stmm/tee_stmm_efi.c     | 25 ++----
> >  drivers/rtc/rtc-optee.c                      | 27 ++-----
> >  drivers/tee/tee_core.c                       | 84 ++++++++++++++++++++
> >  include/linux/tee_drv.h                      | 12 +++
> >  security/keys/trusted-keys/trusted_tee.c     | 17 ++--
> >  10 files changed, 164 insertions(+), 138 deletions(-)
> >
> > base-commit: 8f0b4cce4481fb22653697cced8d0d04027cb1e8
> > --
> > 2.47.3
> >
> 
> Thank you for the nice cleanup, Uwe.
> 
> I've applied patch 1-3 to the branch tee_bus_callback_for_6.20 in my
> tree at https://git.kernel.org/pub/scm/linux/kernel/git/jenswi/linux-tee.git/
> 
> The branch is based on v6.19-rc1, and I'll try to keep it stable for
> others to depend on, if needed. Let's see if we can agree on taking
> the remaining patches via that branch.

6 and 7 can go through your branch.

-- 
Alexandre Belloni, co-owner and COO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [PATCH v2 00/17] tee: Use bus callbacks instead of driver callbacks
  2025-12-18 13:53   ` Alexandre Belloni
@ 2025-12-18 16:29     ` Jens Wiklander
  2026-01-05  9:16       ` Jens Wiklander
  0 siblings, 1 reply; 15+ messages in thread
From: Jens Wiklander @ 2025-12-18 16:29 UTC (permalink / raw)
  To: Alexandre Belloni
  Cc: Uwe Kleine-König, Jonathan Corbet, Sumit Garg,
	Olivia Mackall, Herbert Xu, Clément Léger,
	Ard Biesheuvel, Maxime Coquelin, Alexandre Torgue, Sumit Garg,
	Ilias Apalodimas, Jan Kiszka, Sudeep Holla, Christophe JAILLET,
	Rafał Miłecki, Michael Chan, Pavan Chebbi,
	James Bottomley, Jarkko Sakkinen, Mimi Zohar, David Howells,
	Paul Moore, James Morris, Serge E. Hallyn, Peter Huewe, op-tee,
	linux-kernel, linux-doc, linux-crypto, linux-rtc, linux-efi,
	linux-stm32, linux-arm-kernel, Cristian Marussi, arm-scmi,
	linux-mips, netdev, linux-integrity, keyrings,
	linux-security-module, Jason Gunthorpe

On Thu, Dec 18, 2025 at 2:53 PM Alexandre Belloni
<alexandre.belloni@bootlin.com> wrote:
>
> On 18/12/2025 08:21:27+0100, Jens Wiklander wrote:
> > Hi,
> >
> > On Mon, Dec 15, 2025 at 3:17 PM Uwe Kleine-König
> > <u.kleine-koenig@baylibre.com> wrote:
> > >
> > > Hello,
> > >
> > > the objective of this series is to make tee driver stop using callbacks
> > > in struct device_driver. These were superseded by bus methods in 2006
> > > (commit 594c8281f905 ("[PATCH] Add bus_type probe, remove, shutdown
> > > methods.")) but nobody cared to convert all subsystems accordingly.
> > >
> > > Here the tee drivers are converted. The first commit is somewhat
> > > unrelated, but simplifies the conversion (and the drivers). It
> > > introduces driver registration helpers that care about setting the bus
> > > and owner. (The latter is missing in all drivers, so by using these
> > > helpers the drivers become more correct.)
> > >
> > > v1 of this series is available at
> > > https://lore.kernel.org/all/cover.1765472125.git.u.kleine-koenig@baylibre.com
> > >
> > > Changes since v1:
> > >
> > >  - rebase to v6.19-rc1 (no conflicts)
> > >  - add tags received so far
> > >  - fix whitespace issues pointed out by Sumit Garg
> > >  - fix shutdown callback to shutdown and not remove
> > >
> > > As already noted in v1's cover letter, this series should go in during a
> > > single merge window as there are runtime warnings when the series is
> > > only applied partially. Sumit Garg suggested to apply the whole series
> > > via Jens Wiklander's tree.
> > > If this is done the dependencies in this series are honored, in case the
> > > plan changes: Patches #4 - #17 depend on the first two.
> > >
> > > Note this series is only build tested.
> > >
> > > Uwe Kleine-König (17):
> > >   tee: Add some helpers to reduce boilerplate for tee client drivers
> > >   tee: Add probe, remove and shutdown bus callbacks to tee_client_driver
> > >   tee: Adapt documentation to cover recent additions
> > >   hwrng: optee - Make use of module_tee_client_driver()
> > >   hwrng: optee - Make use of tee bus methods
> > >   rtc: optee: Migrate to use tee specific driver registration function
> > >   rtc: optee: Make use of tee bus methods
> > >   efi: stmm: Make use of module_tee_client_driver()
> > >   efi: stmm: Make use of tee bus methods
> > >   firmware: arm_scmi: optee: Make use of module_tee_client_driver()
> > >   firmware: arm_scmi: Make use of tee bus methods
> > >   firmware: tee_bnxt: Make use of module_tee_client_driver()
> > >   firmware: tee_bnxt: Make use of tee bus methods
> > >   KEYS: trusted: Migrate to use tee specific driver registration
> > >     function
> > >   KEYS: trusted: Make use of tee bus methods
> > >   tpm/tpm_ftpm_tee: Make use of tee specific driver registration
> > >   tpm/tpm_ftpm_tee: Make use of tee bus methods
> > >
> > >  Documentation/driver-api/tee.rst             | 18 +----
> > >  drivers/char/hw_random/optee-rng.c           | 26 ++----
> > >  drivers/char/tpm/tpm_ftpm_tee.c              | 31 +++++---
> > >  drivers/firmware/arm_scmi/transports/optee.c | 32 +++-----
> > >  drivers/firmware/broadcom/tee_bnxt_fw.c      | 30 ++-----
> > >  drivers/firmware/efi/stmm/tee_stmm_efi.c     | 25 ++----
> > >  drivers/rtc/rtc-optee.c                      | 27 ++-----
> > >  drivers/tee/tee_core.c                       | 84 ++++++++++++++++++++
> > >  include/linux/tee_drv.h                      | 12 +++
> > >  security/keys/trusted-keys/trusted_tee.c     | 17 ++--
> > >  10 files changed, 164 insertions(+), 138 deletions(-)
> > >
> > > base-commit: 8f0b4cce4481fb22653697cced8d0d04027cb1e8
> > > --
> > > 2.47.3
> > >
> >
> > Thank you for the nice cleanup, Uwe.
> >
> > I've applied patch 1-3 to the branch tee_bus_callback_for_6.20 in my
> > tree at https://git.kernel.org/pub/scm/linux/kernel/git/jenswi/linux-tee.git/
> >
> > The branch is based on v6.19-rc1, and I'll try to keep it stable for
> > others to depend on, if needed. Let's see if we can agree on taking
> > the remaining patches via that branch.
>
> 6 and 7 can go through your branch.

Good, I've added them to my branch now.

Thanks,
Jens

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [PATCH v2 00/17] tee: Use bus callbacks instead of driver callbacks
  2025-12-18 16:29     ` Jens Wiklander
@ 2026-01-05  9:16       ` Jens Wiklander
  2026-01-06  5:04         ` Herbert Xu
                           ` (2 more replies)
  0 siblings, 3 replies; 15+ messages in thread
From: Jens Wiklander @ 2026-01-05  9:16 UTC (permalink / raw)
  To: Alexandre Belloni
  Cc: Uwe Kleine-König, Jonathan Corbet, Sumit Garg,
	Olivia Mackall, Herbert Xu, Clément Léger,
	Ard Biesheuvel, Maxime Coquelin, Alexandre Torgue, Sumit Garg,
	Ilias Apalodimas, Jan Kiszka, Sudeep Holla, Christophe JAILLET,
	Rafał Miłecki, Michael Chan, Pavan Chebbi,
	James Bottomley, Jarkko Sakkinen, Mimi Zohar, David Howells,
	Paul Moore, James Morris, Serge E. Hallyn, Peter Huewe, op-tee,
	linux-kernel, linux-doc, linux-crypto, linux-rtc, linux-efi,
	linux-stm32, linux-arm-kernel, Cristian Marussi, arm-scmi,
	linux-mips, netdev, linux-integrity, keyrings,
	linux-security-module, Jason Gunthorpe

Hi,

On Thu, Dec 18, 2025 at 5:29 PM Jens Wiklander
<jens.wiklander@linaro.org> wrote:
>
> On Thu, Dec 18, 2025 at 2:53 PM Alexandre Belloni
> <alexandre.belloni@bootlin.com> wrote:
> >
> > On 18/12/2025 08:21:27+0100, Jens Wiklander wrote:
> > > Hi,
> > >
> > > On Mon, Dec 15, 2025 at 3:17 PM Uwe Kleine-König
> > > <u.kleine-koenig@baylibre.com> wrote:
> > > >
> > > > Hello,
> > > >
> > > > the objective of this series is to make tee driver stop using callbacks
> > > > in struct device_driver. These were superseded by bus methods in 2006
> > > > (commit 594c8281f905 ("[PATCH] Add bus_type probe, remove, shutdown
> > > > methods.")) but nobody cared to convert all subsystems accordingly.
> > > >
> > > > Here the tee drivers are converted. The first commit is somewhat
> > > > unrelated, but simplifies the conversion (and the drivers). It
> > > > introduces driver registration helpers that care about setting the bus
> > > > and owner. (The latter is missing in all drivers, so by using these
> > > > helpers the drivers become more correct.)
> > > >
> > > > v1 of this series is available at
> > > > https://lore.kernel.org/all/cover.1765472125.git.u.kleine-koenig@baylibre.com
> > > >
> > > > Changes since v1:
> > > >
> > > >  - rebase to v6.19-rc1 (no conflicts)
> > > >  - add tags received so far
> > > >  - fix whitespace issues pointed out by Sumit Garg
> > > >  - fix shutdown callback to shutdown and not remove
> > > >
> > > > As already noted in v1's cover letter, this series should go in during a
> > > > single merge window as there are runtime warnings when the series is
> > > > only applied partially. Sumit Garg suggested to apply the whole series
> > > > via Jens Wiklander's tree.
> > > > If this is done the dependencies in this series are honored, in case the
> > > > plan changes: Patches #4 - #17 depend on the first two.
> > > >
> > > > Note this series is only build tested.
> > > >
> > > > Uwe Kleine-König (17):
> > > >   tee: Add some helpers to reduce boilerplate for tee client drivers
> > > >   tee: Add probe, remove and shutdown bus callbacks to tee_client_driver
> > > >   tee: Adapt documentation to cover recent additions
> > > >   hwrng: optee - Make use of module_tee_client_driver()
> > > >   hwrng: optee - Make use of tee bus methods
> > > >   rtc: optee: Migrate to use tee specific driver registration function
> > > >   rtc: optee: Make use of tee bus methods
> > > >   efi: stmm: Make use of module_tee_client_driver()
> > > >   efi: stmm: Make use of tee bus methods
> > > >   firmware: arm_scmi: optee: Make use of module_tee_client_driver()
> > > >   firmware: arm_scmi: Make use of tee bus methods
> > > >   firmware: tee_bnxt: Make use of module_tee_client_driver()
> > > >   firmware: tee_bnxt: Make use of tee bus methods
> > > >   KEYS: trusted: Migrate to use tee specific driver registration
> > > >     function
> > > >   KEYS: trusted: Make use of tee bus methods
> > > >   tpm/tpm_ftpm_tee: Make use of tee specific driver registration
> > > >   tpm/tpm_ftpm_tee: Make use of tee bus methods
> > > >
> > > >  Documentation/driver-api/tee.rst             | 18 +----
> > > >  drivers/char/hw_random/optee-rng.c           | 26 ++----
> > > >  drivers/char/tpm/tpm_ftpm_tee.c              | 31 +++++---
> > > >  drivers/firmware/arm_scmi/transports/optee.c | 32 +++-----
> > > >  drivers/firmware/broadcom/tee_bnxt_fw.c      | 30 ++-----
> > > >  drivers/firmware/efi/stmm/tee_stmm_efi.c     | 25 ++----
> > > >  drivers/rtc/rtc-optee.c                      | 27 ++-----
> > > >  drivers/tee/tee_core.c                       | 84 ++++++++++++++++++++
> > > >  include/linux/tee_drv.h                      | 12 +++
> > > >  security/keys/trusted-keys/trusted_tee.c     | 17 ++--
> > > >  10 files changed, 164 insertions(+), 138 deletions(-)
> > > >
> > > > base-commit: 8f0b4cce4481fb22653697cced8d0d04027cb1e8
> > > > --
> > > > 2.47.3
> > > >
> > >
> > > Thank you for the nice cleanup, Uwe.
> > >
> > > I've applied patch 1-3 to the branch tee_bus_callback_for_6.20 in my
> > > tree at https://git.kernel.org/pub/scm/linux/kernel/git/jenswi/linux-tee.git/
> > >
> > > The branch is based on v6.19-rc1, and I'll try to keep it stable for
> > > others to depend on, if needed. Let's see if we can agree on taking
> > > the remaining patches via that branch.
> >
> > 6 and 7 can go through your branch.
>
> Good, I've added them to my branch now.

This entire patch set should go in during a single merge window. I
will not send any pull request until I'm sure all patches will be
merged.

So far (if I'm not mistaken), only the patches I've already added to
next have appeared next. I can take the rest of the patches, too, but
I need OK for the following:

Jarkko, you seem happy with the following patches
- KEYS: trusted: Migrate to use tee specific driver registration function
- KEYS: trusted: Make use of tee bus methods
- tpm/tpm_ftpm_tee: Make use of tee specific driver registration
- tpm/tpm_ftpm_tee: Make use of tee bus methods
OK if I take them via my tree, or would you rather take them yourself?

Herbert, you seem happy with the following patches
- hwrng: optee - Make use of module_tee_client_driver()
- hwrng: optee - Make use of tee bus methods
OK if I take them via my tree, or would you rather take them yourself?

Sudeep, you seem happy with the following patches
- firmware: arm_scmi: optee: Make use of module_tee_client_driver()
- firmware: arm_scmi: Make use of tee bus methods
OK if I take them via my tree, or would you rather take them yourself?

Michael, Pavan, are you OK with the following patches
- firmware: tee_bnxt: Make use of module_tee_client_driver()
- firmware: tee_bnxt: Make use of tee bus methods
OK if I take them via my tree, or would you rather take them yourself?

Thanks,
Jens

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [PATCH v2 00/17] tee: Use bus callbacks instead of driver callbacks
  2026-01-05  9:16       ` Jens Wiklander
@ 2026-01-06  5:04         ` Herbert Xu
  2026-01-06 13:40         ` Sudeep Holla
  2026-01-08 12:38         ` Jarkko Sakkinen
  2 siblings, 0 replies; 15+ messages in thread
From: Herbert Xu @ 2026-01-06  5:04 UTC (permalink / raw)
  To: Jens Wiklander
  Cc: Alexandre Belloni, Uwe Kleine-König, Jonathan Corbet,
	Sumit Garg, Olivia Mackall, Clément Léger,
	Ard Biesheuvel, Maxime Coquelin, Alexandre Torgue, Sumit Garg,
	Ilias Apalodimas, Jan Kiszka, Sudeep Holla, Christophe JAILLET,
	Rafał Miłecki, Michael Chan, Pavan Chebbi,
	James Bottomley, Jarkko Sakkinen, Mimi Zohar, David Howells,
	Paul Moore, James Morris, Serge E. Hallyn, Peter Huewe, op-tee,
	linux-kernel, linux-doc, linux-crypto, linux-rtc, linux-efi,
	linux-stm32, linux-arm-kernel, Cristian Marussi, arm-scmi,
	linux-mips, netdev, linux-integrity, keyrings,
	linux-security-module, Jason Gunthorpe

On Mon, Jan 05, 2026 at 10:16:09AM +0100, Jens Wiklander wrote:
>
> Herbert, you seem happy with the following patches
> - hwrng: optee - Make use of module_tee_client_driver()
> - hwrng: optee - Make use of tee bus methods
> OK if I take them via my tree, or would you rather take them yourself?

Feel free to take them through your tree.

Thanks,
-- 
Email: Herbert Xu <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [PATCH v2 00/17] tee: Use bus callbacks instead of driver callbacks
  2025-12-15 14:16 [PATCH v2 00/17] tee: Use bus callbacks instead of driver callbacks Uwe Kleine-König
                   ` (2 preceding siblings ...)
  2025-12-18  7:21 ` [PATCH v2 00/17] tee: Use bus callbacks instead of driver callbacks Jens Wiklander
@ 2026-01-06  9:39 ` Jon Hunter
  2026-01-07  9:36   ` Jens Wiklander
  3 siblings, 1 reply; 15+ messages in thread
From: Jon Hunter @ 2026-01-06  9:39 UTC (permalink / raw)
  To: Uwe Kleine-König, Jens Wiklander, Jonathan Corbet,
	Sumit Garg, Olivia Mackall, Herbert Xu, Clément Léger,
	Alexandre Belloni, Ard Biesheuvel, Maxime Coquelin,
	Alexandre Torgue, Sumit Garg, Ilias Apalodimas, Jan Kiszka,
	Sudeep Holla, Christophe JAILLET, Rafał Miłecki,
	Michael Chan, Pavan Chebbi, James Bottomley, Jarkko Sakkinen,
	Mimi Zohar, David Howells, Paul Moore, James Morris,
	Serge E. Hallyn, Peter Huewe
  Cc: op-tee, linux-kernel, linux-doc, linux-crypto, linux-rtc,
	linux-efi, linux-stm32, linux-arm-kernel, Cristian Marussi,
	arm-scmi, linux-mips, netdev, linux-integrity, keyrings,
	linux-security-module, Jason Gunthorpe,
	linux-tegra@vger.kernel.org

Hi Uwe,

On 15/12/2025 14:16, Uwe Kleine-König wrote:
> Hello,
> 
> the objective of this series is to make tee driver stop using callbacks
> in struct device_driver. These were superseded by bus methods in 2006
> (commit 594c8281f905 ("[PATCH] Add bus_type probe, remove, shutdown
> methods.")) but nobody cared to convert all subsystems accordingly.
> 
> Here the tee drivers are converted. The first commit is somewhat
> unrelated, but simplifies the conversion (and the drivers). It
> introduces driver registration helpers that care about setting the bus
> and owner. (The latter is missing in all drivers, so by using these
> helpers the drivers become more correct.)
> 
> v1 of this series is available at
> https://lore.kernel.org/all/cover.1765472125.git.u.kleine-koenig@baylibre.com
> 
> Changes since v1:
> 
>   - rebase to v6.19-rc1 (no conflicts)
>   - add tags received so far
>   - fix whitespace issues pointed out by Sumit Garg
>   - fix shutdown callback to shutdown and not remove
> 
> As already noted in v1's cover letter, this series should go in during a
> single merge window as there are runtime warnings when the series is
> only applied partially. Sumit Garg suggested to apply the whole series
> via Jens Wiklander's tree.
> If this is done the dependencies in this series are honored, in case the
> plan changes: Patches #4 - #17 depend on the first two.
> 
> Note this series is only build tested.
> 
> Uwe Kleine-König (17):
>    tee: Add some helpers to reduce boilerplate for tee client drivers
>    tee: Add probe, remove and shutdown bus callbacks to tee_client_driver
>    tee: Adapt documentation to cover recent additions
>    hwrng: optee - Make use of module_tee_client_driver()
>    hwrng: optee - Make use of tee bus methods
>    rtc: optee: Migrate to use tee specific driver registration function
>    rtc: optee: Make use of tee bus methods
>    efi: stmm: Make use of module_tee_client_driver()
>    efi: stmm: Make use of tee bus methods
>    firmware: arm_scmi: optee: Make use of module_tee_client_driver()
>    firmware: arm_scmi: Make use of tee bus methods
>    firmware: tee_bnxt: Make use of module_tee_client_driver()
>    firmware: tee_bnxt: Make use of tee bus methods
>    KEYS: trusted: Migrate to use tee specific driver registration
>      function
>    KEYS: trusted: Make use of tee bus methods
>    tpm/tpm_ftpm_tee: Make use of tee specific driver registration
>    tpm/tpm_ftpm_tee: Make use of tee bus methods


On the next-20260105 I am seeing the following warnings ...

  WARNING KERN Driver 'optee-rng' needs updating - please use bus_type methods
  WARNING KERN Driver 'scmi-optee' needs updating - please use bus_type methods
  WARNING KERN Driver 'tee_bnxt_fw' needs updating - please use bus_type methods

I bisected the first warning and this point to the following
commit ...

# first bad commit: [a707eda330b932bcf698be9460e54e2f389e24b7] tee: Add some helpers to reduce boilerplate for tee client drivers

I have not bisected the others, but guess they are related
to this series. Do you observe the same?

Thanks
Jon

-- 
nvpublic


^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [PATCH v2 00/17] tee: Use bus callbacks instead of driver callbacks
  2026-01-05  9:16       ` Jens Wiklander
  2026-01-06  5:04         ` Herbert Xu
@ 2026-01-06 13:40         ` Sudeep Holla
  2026-01-07  9:38           ` Jens Wiklander
  2026-01-08 12:38         ` Jarkko Sakkinen
  2 siblings, 1 reply; 15+ messages in thread
From: Sudeep Holla @ 2026-01-06 13:40 UTC (permalink / raw)
  To: Jens Wiklander
  Cc: Alexandre Belloni, Sudeep Holla, Uwe Kleine-König,
	Jonathan Corbet, Sumit Garg, Olivia Mackall, Herbert Xu,
	Clément Léger, Ard Biesheuvel, Maxime Coquelin,
	Alexandre Torgue, Sumit Garg, Ilias Apalodimas, Jan Kiszka,
	Christophe JAILLET, Rafał Miłecki, Michael Chan,
	Pavan Chebbi, James Bottomley, Jarkko Sakkinen, Mimi Zohar,
	David Howells, Paul Moore, James Morris, Serge E. Hallyn,
	Peter Huewe, op-tee, linux-kernel, linux-doc, linux-crypto,
	linux-rtc, linux-efi, linux-stm32, linux-arm-kernel,
	Cristian Marussi, arm-scmi, linux-mips, netdev, linux-integrity,
	keyrings, linux-security-module, Jason Gunthorpe

On Mon, Jan 05, 2026 at 10:16:09AM +0100, Jens Wiklander wrote:
> Hi,
> 
> On Thu, Dec 18, 2025 at 5:29 PM Jens Wiklander
> <jens.wiklander@linaro.org> wrote:
> >
> > On Thu, Dec 18, 2025 at 2:53 PM Alexandre Belloni
> > <alexandre.belloni@bootlin.com> wrote:
> > >
> > > On 18/12/2025 08:21:27+0100, Jens Wiklander wrote:
> > > > Hi,
> > > >
> > > > On Mon, Dec 15, 2025 at 3:17 PM Uwe Kleine-König
> > > > <u.kleine-koenig@baylibre.com> wrote:
> > > > >
> > > > > Hello,
> > > > >
> > > > > the objective of this series is to make tee driver stop using callbacks
> > > > > in struct device_driver. These were superseded by bus methods in 2006
> > > > > (commit 594c8281f905 ("[PATCH] Add bus_type probe, remove, shutdown
> > > > > methods.")) but nobody cared to convert all subsystems accordingly.
> > > > >
> > > > > Here the tee drivers are converted. The first commit is somewhat
> > > > > unrelated, but simplifies the conversion (and the drivers). It
> > > > > introduces driver registration helpers that care about setting the bus
> > > > > and owner. (The latter is missing in all drivers, so by using these
> > > > > helpers the drivers become more correct.)
> > > > >
> > > > > v1 of this series is available at
> > > > > https://lore.kernel.org/all/cover.1765472125.git.u.kleine-koenig@baylibre.com
> > > > >
> > > > > Changes since v1:
> > > > >
> > > > >  - rebase to v6.19-rc1 (no conflicts)
> > > > >  - add tags received so far
> > > > >  - fix whitespace issues pointed out by Sumit Garg
> > > > >  - fix shutdown callback to shutdown and not remove
> > > > >
> > > > > As already noted in v1's cover letter, this series should go in during a
> > > > > single merge window as there are runtime warnings when the series is
> > > > > only applied partially. Sumit Garg suggested to apply the whole series
> > > > > via Jens Wiklander's tree.
> > > > > If this is done the dependencies in this series are honored, in case the
> > > > > plan changes: Patches #4 - #17 depend on the first two.
> > > > >
> > > > > Note this series is only build tested.
> > > > >
> > > > > Uwe Kleine-König (17):
> > > > >   tee: Add some helpers to reduce boilerplate for tee client drivers
> > > > >   tee: Add probe, remove and shutdown bus callbacks to tee_client_driver
> > > > >   tee: Adapt documentation to cover recent additions
> > > > >   hwrng: optee - Make use of module_tee_client_driver()
> > > > >   hwrng: optee - Make use of tee bus methods
> > > > >   rtc: optee: Migrate to use tee specific driver registration function
> > > > >   rtc: optee: Make use of tee bus methods
> > > > >   efi: stmm: Make use of module_tee_client_driver()
> > > > >   efi: stmm: Make use of tee bus methods
> > > > >   firmware: arm_scmi: optee: Make use of module_tee_client_driver()
> > > > >   firmware: arm_scmi: Make use of tee bus methods
> > > > >   firmware: tee_bnxt: Make use of module_tee_client_driver()
> > > > >   firmware: tee_bnxt: Make use of tee bus methods
> > > > >   KEYS: trusted: Migrate to use tee specific driver registration
> > > > >     function
> > > > >   KEYS: trusted: Make use of tee bus methods
> > > > >   tpm/tpm_ftpm_tee: Make use of tee specific driver registration
> > > > >   tpm/tpm_ftpm_tee: Make use of tee bus methods
> > > > >
> > > > >  Documentation/driver-api/tee.rst             | 18 +----
> > > > >  drivers/char/hw_random/optee-rng.c           | 26 ++----
> > > > >  drivers/char/tpm/tpm_ftpm_tee.c              | 31 +++++---
> > > > >  drivers/firmware/arm_scmi/transports/optee.c | 32 +++-----
> > > > >  drivers/firmware/broadcom/tee_bnxt_fw.c      | 30 ++-----
> > > > >  drivers/firmware/efi/stmm/tee_stmm_efi.c     | 25 ++----
> > > > >  drivers/rtc/rtc-optee.c                      | 27 ++-----
> > > > >  drivers/tee/tee_core.c                       | 84 ++++++++++++++++++++
> > > > >  include/linux/tee_drv.h                      | 12 +++
> > > > >  security/keys/trusted-keys/trusted_tee.c     | 17 ++--
> > > > >  10 files changed, 164 insertions(+), 138 deletions(-)
> > > > >
> > > > > base-commit: 8f0b4cce4481fb22653697cced8d0d04027cb1e8
> > > > > --
> > > > > 2.47.3
> > > > >
> > > >
> > > > Thank you for the nice cleanup, Uwe.
> > > >
> > > > I've applied patch 1-3 to the branch tee_bus_callback_for_6.20 in my
> > > > tree at https://git.kernel.org/pub/scm/linux/kernel/git/jenswi/linux-tee.git/
> > > >
> > > > The branch is based on v6.19-rc1, and I'll try to keep it stable for
> > > > others to depend on, if needed. Let's see if we can agree on taking
> > > > the remaining patches via that branch.
> > >
> > > 6 and 7 can go through your branch.
> >
> > Good, I've added them to my branch now.
> 
> This entire patch set should go in during a single merge window. I
> will not send any pull request until I'm sure all patches will be
> merged.
> 
> So far (if I'm not mistaken), only the patches I've already added to
> next have appeared next. I can take the rest of the patches, too, but
> I need OK for the following:
> 

[...]

> 
> Sudeep, you seem happy with the following patches
> - firmware: arm_scmi: optee: Make use of module_tee_client_driver()
> - firmware: arm_scmi: Make use of tee bus methods
> OK if I take them via my tree, or would you rather take them yourself?
>

I am happy if you want to take all of them in one go. I think I have
already acked it. Please shout if you need anything else from me, happy to
help in anyway to make it easier to handle this change set.

-- 
Regards,
Sudeep

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [PATCH v2 00/17] tee: Use bus callbacks instead of driver callbacks
  2026-01-06  9:39 ` Jon Hunter
@ 2026-01-07  9:36   ` Jens Wiklander
  0 siblings, 0 replies; 15+ messages in thread
From: Jens Wiklander @ 2026-01-07  9:36 UTC (permalink / raw)
  To: Jon Hunter
  Cc: Uwe Kleine-König, Jonathan Corbet, Sumit Garg,
	Olivia Mackall, Herbert Xu, Clément Léger,
	Alexandre Belloni, Ard Biesheuvel, Maxime Coquelin,
	Alexandre Torgue, Sumit Garg, Ilias Apalodimas, Jan Kiszka,
	Sudeep Holla, Christophe JAILLET, Rafał Miłecki,
	Michael Chan, Pavan Chebbi, James Bottomley, Jarkko Sakkinen,
	Mimi Zohar, David Howells, Paul Moore, James Morris,
	Serge E. Hallyn, Peter Huewe, op-tee, linux-kernel, linux-doc,
	linux-crypto, linux-rtc, linux-efi, linux-stm32, linux-arm-kernel,
	Cristian Marussi, arm-scmi, linux-mips, netdev, linux-integrity,
	keyrings, linux-security-module, Jason Gunthorpe,
	linux-tegra@vger.kernel.org

Hi Jon,

On Tue, Jan 6, 2026 at 10:40 AM Jon Hunter <jonathanh@nvidia.com> wrote:
>
> Hi Uwe,
>
> On 15/12/2025 14:16, Uwe Kleine-König wrote:
> > Hello,
> >
> > the objective of this series is to make tee driver stop using callbacks
> > in struct device_driver. These were superseded by bus methods in 2006
> > (commit 594c8281f905 ("[PATCH] Add bus_type probe, remove, shutdown
> > methods.")) but nobody cared to convert all subsystems accordingly.
> >
> > Here the tee drivers are converted. The first commit is somewhat
> > unrelated, but simplifies the conversion (and the drivers). It
> > introduces driver registration helpers that care about setting the bus
> > and owner. (The latter is missing in all drivers, so by using these
> > helpers the drivers become more correct.)
> >
> > v1 of this series is available at
> > https://lore.kernel.org/all/cover.1765472125.git.u.kleine-koenig@baylibre.com
> >
> > Changes since v1:
> >
> >   - rebase to v6.19-rc1 (no conflicts)
> >   - add tags received so far
> >   - fix whitespace issues pointed out by Sumit Garg
> >   - fix shutdown callback to shutdown and not remove
> >
> > As already noted in v1's cover letter, this series should go in during a
> > single merge window as there are runtime warnings when the series is
> > only applied partially. Sumit Garg suggested to apply the whole series
> > via Jens Wiklander's tree.
> > If this is done the dependencies in this series are honored, in case the
> > plan changes: Patches #4 - #17 depend on the first two.
> >
> > Note this series is only build tested.
> >
> > Uwe Kleine-König (17):
> >    tee: Add some helpers to reduce boilerplate for tee client drivers
> >    tee: Add probe, remove and shutdown bus callbacks to tee_client_driver
> >    tee: Adapt documentation to cover recent additions
> >    hwrng: optee - Make use of module_tee_client_driver()
> >    hwrng: optee - Make use of tee bus methods
> >    rtc: optee: Migrate to use tee specific driver registration function
> >    rtc: optee: Make use of tee bus methods
> >    efi: stmm: Make use of module_tee_client_driver()
> >    efi: stmm: Make use of tee bus methods
> >    firmware: arm_scmi: optee: Make use of module_tee_client_driver()
> >    firmware: arm_scmi: Make use of tee bus methods
> >    firmware: tee_bnxt: Make use of module_tee_client_driver()
> >    firmware: tee_bnxt: Make use of tee bus methods
> >    KEYS: trusted: Migrate to use tee specific driver registration
> >      function
> >    KEYS: trusted: Make use of tee bus methods
> >    tpm/tpm_ftpm_tee: Make use of tee specific driver registration
> >    tpm/tpm_ftpm_tee: Make use of tee bus methods
>
>
> On the next-20260105 I am seeing the following warnings ...
>
>   WARNING KERN Driver 'optee-rng' needs updating - please use bus_type methods
>   WARNING KERN Driver 'scmi-optee' needs updating - please use bus_type methods
>   WARNING KERN Driver 'tee_bnxt_fw' needs updating - please use bus_type methods
>
> I bisected the first warning and this point to the following
> commit ...
>
> # first bad commit: [a707eda330b932bcf698be9460e54e2f389e24b7] tee: Add some helpers to reduce boilerplate for tee client drivers
>
> I have not bisected the others, but guess they are related
> to this series. Do you observe the same?

Yes, I see the same.

I'm sorry, I didn't realize that someone might bisect this when I took
only a few of the patches into next. I've applied all the patches in
this series now.

Thanks,
Jens

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [PATCH v2 00/17] tee: Use bus callbacks instead of driver callbacks
  2026-01-06 13:40         ` Sudeep Holla
@ 2026-01-07  9:38           ` Jens Wiklander
  0 siblings, 0 replies; 15+ messages in thread
From: Jens Wiklander @ 2026-01-07  9:38 UTC (permalink / raw)
  To: Sudeep Holla
  Cc: Alexandre Belloni, Uwe Kleine-König, Jonathan Corbet,
	Sumit Garg, Olivia Mackall, Herbert Xu, Clément Léger,
	Ard Biesheuvel, Maxime Coquelin, Alexandre Torgue, Sumit Garg,
	Ilias Apalodimas, Jan Kiszka, Christophe JAILLET,
	Rafał Miłecki, Michael Chan, Pavan Chebbi,
	James Bottomley, Jarkko Sakkinen, Mimi Zohar, David Howells,
	Paul Moore, James Morris, Serge E. Hallyn, Peter Huewe, op-tee,
	linux-kernel, linux-doc, linux-crypto, linux-rtc, linux-efi,
	linux-stm32, linux-arm-kernel, Cristian Marussi, arm-scmi,
	linux-mips, netdev, linux-integrity, keyrings,
	linux-security-module, Jason Gunthorpe

On Tue, Jan 6, 2026 at 2:40 PM Sudeep Holla <sudeep.holla@arm.com> wrote:
>
> On Mon, Jan 05, 2026 at 10:16:09AM +0100, Jens Wiklander wrote:
> > Hi,
> >
> > On Thu, Dec 18, 2025 at 5:29 PM Jens Wiklander
> > <jens.wiklander@linaro.org> wrote:
> > >
> > > On Thu, Dec 18, 2025 at 2:53 PM Alexandre Belloni
> > > <alexandre.belloni@bootlin.com> wrote:
> > > >
> > > > On 18/12/2025 08:21:27+0100, Jens Wiklander wrote:
> > > > > Hi,
> > > > >
> > > > > On Mon, Dec 15, 2025 at 3:17 PM Uwe Kleine-König
> > > > > <u.kleine-koenig@baylibre.com> wrote:
> > > > > >
> > > > > > Hello,
> > > > > >
> > > > > > the objective of this series is to make tee driver stop using callbacks
> > > > > > in struct device_driver. These were superseded by bus methods in 2006
> > > > > > (commit 594c8281f905 ("[PATCH] Add bus_type probe, remove, shutdown
> > > > > > methods.")) but nobody cared to convert all subsystems accordingly.
> > > > > >
> > > > > > Here the tee drivers are converted. The first commit is somewhat
> > > > > > unrelated, but simplifies the conversion (and the drivers). It
> > > > > > introduces driver registration helpers that care about setting the bus
> > > > > > and owner. (The latter is missing in all drivers, so by using these
> > > > > > helpers the drivers become more correct.)
> > > > > >
> > > > > > v1 of this series is available at
> > > > > > https://lore.kernel.org/all/cover.1765472125.git.u.kleine-koenig@baylibre.com
> > > > > >
> > > > > > Changes since v1:
> > > > > >
> > > > > >  - rebase to v6.19-rc1 (no conflicts)
> > > > > >  - add tags received so far
> > > > > >  - fix whitespace issues pointed out by Sumit Garg
> > > > > >  - fix shutdown callback to shutdown and not remove
> > > > > >
> > > > > > As already noted in v1's cover letter, this series should go in during a
> > > > > > single merge window as there are runtime warnings when the series is
> > > > > > only applied partially. Sumit Garg suggested to apply the whole series
> > > > > > via Jens Wiklander's tree.
> > > > > > If this is done the dependencies in this series are honored, in case the
> > > > > > plan changes: Patches #4 - #17 depend on the first two.
> > > > > >
> > > > > > Note this series is only build tested.
> > > > > >
> > > > > > Uwe Kleine-König (17):
> > > > > >   tee: Add some helpers to reduce boilerplate for tee client drivers
> > > > > >   tee: Add probe, remove and shutdown bus callbacks to tee_client_driver
> > > > > >   tee: Adapt documentation to cover recent additions
> > > > > >   hwrng: optee - Make use of module_tee_client_driver()
> > > > > >   hwrng: optee - Make use of tee bus methods
> > > > > >   rtc: optee: Migrate to use tee specific driver registration function
> > > > > >   rtc: optee: Make use of tee bus methods
> > > > > >   efi: stmm: Make use of module_tee_client_driver()
> > > > > >   efi: stmm: Make use of tee bus methods
> > > > > >   firmware: arm_scmi: optee: Make use of module_tee_client_driver()
> > > > > >   firmware: arm_scmi: Make use of tee bus methods
> > > > > >   firmware: tee_bnxt: Make use of module_tee_client_driver()
> > > > > >   firmware: tee_bnxt: Make use of tee bus methods
> > > > > >   KEYS: trusted: Migrate to use tee specific driver registration
> > > > > >     function
> > > > > >   KEYS: trusted: Make use of tee bus methods
> > > > > >   tpm/tpm_ftpm_tee: Make use of tee specific driver registration
> > > > > >   tpm/tpm_ftpm_tee: Make use of tee bus methods
> > > > > >
> > > > > >  Documentation/driver-api/tee.rst             | 18 +----
> > > > > >  drivers/char/hw_random/optee-rng.c           | 26 ++----
> > > > > >  drivers/char/tpm/tpm_ftpm_tee.c              | 31 +++++---
> > > > > >  drivers/firmware/arm_scmi/transports/optee.c | 32 +++-----
> > > > > >  drivers/firmware/broadcom/tee_bnxt_fw.c      | 30 ++-----
> > > > > >  drivers/firmware/efi/stmm/tee_stmm_efi.c     | 25 ++----
> > > > > >  drivers/rtc/rtc-optee.c                      | 27 ++-----
> > > > > >  drivers/tee/tee_core.c                       | 84 ++++++++++++++++++++
> > > > > >  include/linux/tee_drv.h                      | 12 +++
> > > > > >  security/keys/trusted-keys/trusted_tee.c     | 17 ++--
> > > > > >  10 files changed, 164 insertions(+), 138 deletions(-)
> > > > > >
> > > > > > base-commit: 8f0b4cce4481fb22653697cced8d0d04027cb1e8
> > > > > > --
> > > > > > 2.47.3
> > > > > >
> > > > >
> > > > > Thank you for the nice cleanup, Uwe.
> > > > >
> > > > > I've applied patch 1-3 to the branch tee_bus_callback_for_6.20 in my
> > > > > tree at https://git.kernel.org/pub/scm/linux/kernel/git/jenswi/linux-tee.git/
> > > > >
> > > > > The branch is based on v6.19-rc1, and I'll try to keep it stable for
> > > > > others to depend on, if needed. Let's see if we can agree on taking
> > > > > the remaining patches via that branch.
> > > >
> > > > 6 and 7 can go through your branch.
> > >
> > > Good, I've added them to my branch now.
> >
> > This entire patch set should go in during a single merge window. I
> > will not send any pull request until I'm sure all patches will be
> > merged.
> >
> > So far (if I'm not mistaken), only the patches I've already added to
> > next have appeared next. I can take the rest of the patches, too, but
> > I need OK for the following:
> >
>
> [...]
>
> >
> > Sudeep, you seem happy with the following patches
> > - firmware: arm_scmi: optee: Make use of module_tee_client_driver()
> > - firmware: arm_scmi: Make use of tee bus methods
> > OK if I take them via my tree, or would you rather take them yourself?
> >
>
> I am happy if you want to take all of them in one go. I think I have
> already acked it. Please shout if you need anything else from me, happy to
> help in anyway to make it easier to handle this change set.

Thanks, I've applied all the patches in the series now, since it
otherwise causes warnings during boot.

/Jens

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [PATCH v2 00/17] tee: Use bus callbacks instead of driver callbacks
  2026-01-05  9:16       ` Jens Wiklander
  2026-01-06  5:04         ` Herbert Xu
  2026-01-06 13:40         ` Sudeep Holla
@ 2026-01-08 12:38         ` Jarkko Sakkinen
  2 siblings, 0 replies; 15+ messages in thread
From: Jarkko Sakkinen @ 2026-01-08 12:38 UTC (permalink / raw)
  To: Jens Wiklander
  Cc: Alexandre Belloni, Uwe Kleine-König, Jonathan Corbet,
	Sumit Garg, Olivia Mackall, Herbert Xu, Clément Léger,
	Ard Biesheuvel, Maxime Coquelin, Alexandre Torgue, Sumit Garg,
	Ilias Apalodimas, Jan Kiszka, Sudeep Holla, Christophe JAILLET,
	Rafał Miłecki, Michael Chan, Pavan Chebbi,
	James Bottomley, Mimi Zohar, David Howells, Paul Moore,
	James Morris, Serge E. Hallyn, Peter Huewe, op-tee, linux-kernel,
	linux-doc, linux-crypto, linux-rtc, linux-efi, linux-stm32,
	linux-arm-kernel, Cristian Marussi, arm-scmi, linux-mips, netdev,
	linux-integrity, keyrings, linux-security-module, Jason Gunthorpe

On Mon, Jan 05, 2026 at 10:16:09AM +0100, Jens Wiklander wrote:
> Hi,
> 
> On Thu, Dec 18, 2025 at 5:29 PM Jens Wiklander
> <jens.wiklander@linaro.org> wrote:
> >
> > On Thu, Dec 18, 2025 at 2:53 PM Alexandre Belloni
> > <alexandre.belloni@bootlin.com> wrote:
> > >
> > > On 18/12/2025 08:21:27+0100, Jens Wiklander wrote:
> > > > Hi,
> > > >
> > > > On Mon, Dec 15, 2025 at 3:17 PM Uwe Kleine-König
> > > > <u.kleine-koenig@baylibre.com> wrote:
> > > > >
> > > > > Hello,
> > > > >
> > > > > the objective of this series is to make tee driver stop using callbacks
> > > > > in struct device_driver. These were superseded by bus methods in 2006
> > > > > (commit 594c8281f905 ("[PATCH] Add bus_type probe, remove, shutdown
> > > > > methods.")) but nobody cared to convert all subsystems accordingly.
> > > > >
> > > > > Here the tee drivers are converted. The first commit is somewhat
> > > > > unrelated, but simplifies the conversion (and the drivers). It
> > > > > introduces driver registration helpers that care about setting the bus
> > > > > and owner. (The latter is missing in all drivers, so by using these
> > > > > helpers the drivers become more correct.)
> > > > >
> > > > > v1 of this series is available at
> > > > > https://lore.kernel.org/all/cover.1765472125.git.u.kleine-koenig@baylibre.com
> > > > >
> > > > > Changes since v1:
> > > > >
> > > > >  - rebase to v6.19-rc1 (no conflicts)
> > > > >  - add tags received so far
> > > > >  - fix whitespace issues pointed out by Sumit Garg
> > > > >  - fix shutdown callback to shutdown and not remove
> > > > >
> > > > > As already noted in v1's cover letter, this series should go in during a
> > > > > single merge window as there are runtime warnings when the series is
> > > > > only applied partially. Sumit Garg suggested to apply the whole series
> > > > > via Jens Wiklander's tree.
> > > > > If this is done the dependencies in this series are honored, in case the
> > > > > plan changes: Patches #4 - #17 depend on the first two.
> > > > >
> > > > > Note this series is only build tested.
> > > > >
> > > > > Uwe Kleine-König (17):
> > > > >   tee: Add some helpers to reduce boilerplate for tee client drivers
> > > > >   tee: Add probe, remove and shutdown bus callbacks to tee_client_driver
> > > > >   tee: Adapt documentation to cover recent additions
> > > > >   hwrng: optee - Make use of module_tee_client_driver()
> > > > >   hwrng: optee - Make use of tee bus methods
> > > > >   rtc: optee: Migrate to use tee specific driver registration function
> > > > >   rtc: optee: Make use of tee bus methods
> > > > >   efi: stmm: Make use of module_tee_client_driver()
> > > > >   efi: stmm: Make use of tee bus methods
> > > > >   firmware: arm_scmi: optee: Make use of module_tee_client_driver()
> > > > >   firmware: arm_scmi: Make use of tee bus methods
> > > > >   firmware: tee_bnxt: Make use of module_tee_client_driver()
> > > > >   firmware: tee_bnxt: Make use of tee bus methods
> > > > >   KEYS: trusted: Migrate to use tee specific driver registration
> > > > >     function
> > > > >   KEYS: trusted: Make use of tee bus methods
> > > > >   tpm/tpm_ftpm_tee: Make use of tee specific driver registration
> > > > >   tpm/tpm_ftpm_tee: Make use of tee bus methods
> > > > >
> > > > >  Documentation/driver-api/tee.rst             | 18 +----
> > > > >  drivers/char/hw_random/optee-rng.c           | 26 ++----
> > > > >  drivers/char/tpm/tpm_ftpm_tee.c              | 31 +++++---
> > > > >  drivers/firmware/arm_scmi/transports/optee.c | 32 +++-----
> > > > >  drivers/firmware/broadcom/tee_bnxt_fw.c      | 30 ++-----
> > > > >  drivers/firmware/efi/stmm/tee_stmm_efi.c     | 25 ++----
> > > > >  drivers/rtc/rtc-optee.c                      | 27 ++-----
> > > > >  drivers/tee/tee_core.c                       | 84 ++++++++++++++++++++
> > > > >  include/linux/tee_drv.h                      | 12 +++
> > > > >  security/keys/trusted-keys/trusted_tee.c     | 17 ++--
> > > > >  10 files changed, 164 insertions(+), 138 deletions(-)
> > > > >
> > > > > base-commit: 8f0b4cce4481fb22653697cced8d0d04027cb1e8
> > > > > --
> > > > > 2.47.3
> > > > >
> > > >
> > > > Thank you for the nice cleanup, Uwe.
> > > >
> > > > I've applied patch 1-3 to the branch tee_bus_callback_for_6.20 in my
> > > > tree at https://git.kernel.org/pub/scm/linux/kernel/git/jenswi/linux-tee.git/
> > > >
> > > > The branch is based on v6.19-rc1, and I'll try to keep it stable for
> > > > others to depend on, if needed. Let's see if we can agree on taking
> > > > the remaining patches via that branch.
> > >
> > > 6 and 7 can go through your branch.
> >
> > Good, I've added them to my branch now.
> 
> This entire patch set should go in during a single merge window. I
> will not send any pull request until I'm sure all patches will be
> merged.
> 
> So far (if I'm not mistaken), only the patches I've already added to
> next have appeared next. I can take the rest of the patches, too, but
> I need OK for the following:
> 
> Jarkko, you seem happy with the following patches
> - KEYS: trusted: Migrate to use tee specific driver registration function
> - KEYS: trusted: Make use of tee bus methods
> - tpm/tpm_ftpm_tee: Make use of tee specific driver registration
> - tpm/tpm_ftpm_tee: Make use of tee bus methods
> OK if I take them via my tree, or would you rather take them yourself?

I don't mind.

> 
> Herbert, you seem happy with the following patches
> - hwrng: optee - Make use of module_tee_client_driver()
> - hwrng: optee - Make use of tee bus methods
> OK if I take them via my tree, or would you rather take them yourself?
> 
> Sudeep, you seem happy with the following patches
> - firmware: arm_scmi: optee: Make use of module_tee_client_driver()
> - firmware: arm_scmi: Make use of tee bus methods
> OK if I take them via my tree, or would you rather take them yourself?
> 
> Michael, Pavan, are you OK with the following patches
> - firmware: tee_bnxt: Make use of module_tee_client_driver()
> - firmware: tee_bnxt: Make use of tee bus methods
> OK if I take them via my tree, or would you rather take them yourself?
> 
> Thanks,
> Jens

BR, Jarkko

^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2026-01-08 12:38 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-12-15 14:16 [PATCH v2 00/17] tee: Use bus callbacks instead of driver callbacks Uwe Kleine-König
2025-12-15 14:16 ` [PATCH v2 14/17] KEYS: trusted: Migrate to use tee specific driver registration function Uwe Kleine-König
2025-12-15 22:01   ` Jarkko Sakkinen
2025-12-15 14:16 ` [PATCH v2 15/17] KEYS: trusted: Make use of tee bus methods Uwe Kleine-König
2025-12-15 22:04   ` Jarkko Sakkinen
2025-12-18  7:21 ` [PATCH v2 00/17] tee: Use bus callbacks instead of driver callbacks Jens Wiklander
2025-12-18 13:53   ` Alexandre Belloni
2025-12-18 16:29     ` Jens Wiklander
2026-01-05  9:16       ` Jens Wiklander
2026-01-06  5:04         ` Herbert Xu
2026-01-06 13:40         ` Sudeep Holla
2026-01-07  9:38           ` Jens Wiklander
2026-01-08 12:38         ` Jarkko Sakkinen
2026-01-06  9:39 ` Jon Hunter
2026-01-07  9:36   ` Jens Wiklander

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox