Re: [systemd-devel] Issues supporting systems with and without TPM and firmware TPM (was Re: Handle device node timeout?)

2024-04-17 Thread Mikko Rapeli
Hi, On Tue, Apr 16, 2024 at 04:03:25PM +0200, Lennart Poettering wrote: > On Di, 16.04.24 15:02, Mikko Rapeli (mikko.rap...@linaro.org) wrote: > > > Hi, > > > > On Mon, Apr 15, 2024 at 05:41:00PM +0200, Lennart Poettering wrote: > > > Would be good to have that with systemd.log_target=debug, to

Re: [systemd-devel] Issues supporting systems with and without TPM and firmware TPM (was Re: Handle device node timeout?)

2024-04-16 Thread Mikko Rapeli
Hi, On Tue, Apr 16, 2024 at 04:03:25PM +0200, Lennart Poettering wrote: > On Di, 16.04.24 15:02, Mikko Rapeli (mikko.rap...@linaro.org) wrote: > > > Hi, > > > > On Mon, Apr 15, 2024 at 05:41:00PM +0200, Lennart Poettering wrote: > > > Would be good to have that with systemd.log_target=debug, to

Re: [systemd-devel] Issues supporting systems with and without TPM and firmware TPM (was Re: Handle device node timeout?)

2024-04-16 Thread Lennart Poettering
On Di, 16.04.24 15:02, Mikko Rapeli (mikko.rap...@linaro.org) wrote: > Hi, > > On Mon, Apr 15, 2024 at 05:41:00PM +0200, Lennart Poettering wrote: > > Would be good to have that with systemd.log_target=debug, to see if > > tpm2.target even gets enqueued. > > Here is the verbose log: > >

Re: [systemd-devel] Issues supporting systems with and without TPM and firmware TPM (was Re: Handle device node timeout?)

2024-04-16 Thread Mikko Rapeli
Hi, On Mon, Apr 15, 2024 at 05:41:00PM +0200, Lennart Poettering wrote: > Would be good to have that with systemd.log_target=debug, to see if > tpm2.target even gets enqueued. Here is the verbose log:

Re: [systemd-devel] Issues supporting systems with and without TPM and firmware TPM (was Re: Handle device node timeout?)

2024-04-16 Thread Mikko Rapeli
On Mon, Apr 15, 2024 at 05:45:49PM +0200, Lennart Poettering wrote: > On Mo, 15.04.24 17:41, Lennart Poettering (lenn...@poettering.net) wrote: > > > > or the services needed for systemd-repart config with Encrypt=tpm2 > > > > Ah, repart is interesting. We are missing the tpm2.target dependency >

Re: [systemd-devel] Issues supporting systems with and without TPM and firmware TPM (was Re: Handle device node timeout?)

2024-04-15 Thread Lennart Poettering
On Mo, 15.04.24 17:41, Lennart Poettering (lenn...@poettering.net) wrote: > > or the services needed for systemd-repart config with Encrypt=tpm2 > > Ah, repart is interesting. We are missing the tpm2.target dependency > there. That's a bug. Will fix. →

Re: [systemd-devel] Issues supporting systems with and without TPM and firmware TPM (was Re: Handle device node timeout?)

2024-04-15 Thread Lennart Poettering
On Mo, 15.04.24 17:23, Mikko Rapeli (mikko.rap...@linaro.org) wrote: > Hi, > > On Mon, Apr 15, 2024 at 04:02:46PM +0200, Lennart Poettering wrote: > > On Mo, 15.04.24 10:38, Mikko Rapeli (mikko.rap...@linaro.org) wrote: > > > > > Hi, > > > > > > On Fri, Apr 12, 2024 at 05:03:18PM +0300,

Re: [systemd-devel] Issues supporting systems with and without TPM and firmware TPM (was Re: Handle device node timeout?)

2024-04-15 Thread Mikko Rapeli
Hi, On Mon, Apr 15, 2024 at 04:02:46PM +0200, Lennart Poettering wrote: > On Mo, 15.04.24 10:38, Mikko Rapeli (mikko.rap...@linaro.org) wrote: > > > Hi, > > > > On Fri, Apr 12, 2024 at 05:03:18PM +0300, Aleksandar Kostadinov wrote: > > > Shouldn't the kernel automatically load the necessary

Re: [systemd-devel] Issues supporting systems with and without TPM and firmware TPM (was Re: Handle device node timeout?)

2024-04-15 Thread Lennart Poettering
On Mo, 15.04.24 10:38, Mikko Rapeli (mikko.rap...@linaro.org) wrote: > Hi, > > On Fri, Apr 12, 2024 at 05:03:18PM +0300, Aleksandar Kostadinov wrote: > > Shouldn't the kernel automatically load the necessary modues when > > devices are detected... given proper udev rules and module > >

Re: [systemd-devel] Issues supporting systems with and without TPM and firmware TPM (was Re: Handle device node timeout?)

2024-04-15 Thread Mikko Rapeli
Hi, On Fri, Apr 12, 2024 at 05:03:18PM +0300, Aleksandar Kostadinov wrote: > Shouldn't the kernel automatically load the necessary modues when > devices are detected... given proper udev rules and module > availability in the initrd filesystem? I guess it depends on how you > build your initrd

Re: [systemd-devel] Issues supporting systems with and without TPM and firmware TPM (was Re: Handle device node timeout?)

2024-04-12 Thread Aleksandar Kostadinov
Shouldn't the kernel automatically load the necessary modues when devices are detected... given proper udev rules and module availability in the initrd filesystem? I guess it depends on how you build your initrd system for including them. On Wed, Apr 10, 2024 at 10:24 AM Mikko Rapeli wrote: > >

Re: [systemd-devel] Issues supporting systems with and without TPM and firmware TPM (was Re: Handle device node timeout?)

2024-04-10 Thread Mikko Rapeli
On Tue, Apr 09, 2024 at 11:37:39AM +0300, Mikko Rapeli wrote: > Hi, > > On Mon, Feb 19, 2024 at 11:53:14AM +0100, Lennart Poettering wrote: > > For your usecase the new tpm2.target available in git main is what you > > really should focus on: all TPM using services should order themselves > >

Re: [systemd-devel] Issues supporting systems with and without TPM and firmware TPM (was Re: Handle device node timeout?)

2024-04-09 Thread Mikko Rapeli
Hi, On Mon, Feb 19, 2024 at 11:53:14AM +0100, Lennart Poettering wrote: > For your usecase the new tpm2.target available in git main is what you > really should focus on: all TPM using services should order themselves > after that. All stuff needed to make a TPM device appear should be > placed

Re: [systemd-devel] Issues supporting systems with and without TPM and firmware TPM (was Re: Handle device node timeout?)

2024-02-20 Thread Mikko Rapeli
Hi, On Tue, Feb 20, 2024 at 02:35:27PM +0100, Lennart Poettering wrote: > On Di, 20.02.24 10:24, Mikko Rapeli (mikko.rap...@linaro.org) wrote: > > > Thanks, I will check this. It sounds like optee needs a similar dependency > > generator. > > > > I wonder how many kernel subsystems/drivers which

Re: [systemd-devel] Issues supporting systems with and without TPM and firmware TPM (was Re: Handle device node timeout?)

2024-02-20 Thread Lennart Poettering
On Di, 20.02.24 10:24, Mikko Rapeli (mikko.rap...@linaro.org) wrote: > Thanks, I will check this. It sounds like optee needs a similar dependency > generator. > > I wonder how many kernel subsystems/drivers which need userspace daemons > would need systemd side dependency generators. Is it only

Re: [systemd-devel] Issues supporting systems with and without TPM and firmware TPM (was Re: Handle device node timeout?)

2024-02-20 Thread Mikko Rapeli
Hi, On Mon, Feb 19, 2024 at 01:54:02PM +0300, Andrei Borzenkov wrote: > On Mon, Feb 19, 2024 at 11:37 AM Mikko Rapeli wrote: > > > > Hi, > > > > On Fri, Feb 16, 2024 at 11:28:31AM +0200, Mikko Rapeli wrote: > > > Hi, > > > > > > Following up to my previous question which worked around with > > >

Re: [systemd-devel] Issues supporting systems with and without TPM and firmware TPM (was Re: Handle device node timeout?)

2024-02-20 Thread Mikko Rapeli
Hi, On Mon, Feb 19, 2024 at 11:53:14AM +0100, Lennart Poettering wrote: > On Mo, 19.02.24 10:36, Mikko Rapeli (mikko.rap...@linaro.org) wrote: > > > > After=dev-tpmrm0.device tee-supplicant@teepriv0.service > > > Wants=dev-tpmrm0.device tee-supplicant@teepriv0.service > > > > I think my problems

Re: [systemd-devel] Issues supporting systems with and without TPM and firmware TPM (was Re: Handle device node timeout?)

2024-02-20 Thread Mikko Rapeli
Hi, On Mon, Feb 19, 2024 at 11:47:52AM +0100, Lennart Poettering wrote: > On Fr, 16.02.24 11:28, Mikko Rapeli (mikko.rap...@linaro.org) wrote: > > > Support for fTPM devices is problematic. First, the kernel support must be > > modules > > but loading needs to be specially handled after

Re: [systemd-devel] Issues supporting systems with and without TPM and firmware TPM (was Re: Handle device node timeout?)

2024-02-19 Thread Andrei Borzenkov
On Mon, Feb 19, 2024 at 11:37 AM Mikko Rapeli wrote: > > Hi, > > On Fri, Feb 16, 2024 at 11:28:31AM +0200, Mikko Rapeli wrote: > > Hi, > > > > Following up to my previous question which worked around with > > Wants: and After: to dev-tpmrm0.device and tee-supplicant@teepriv0.service, > > which

Re: [systemd-devel] Issues supporting systems with and without TPM and firmware TPM (was Re: Handle device node timeout?)

2024-02-19 Thread Lennart Poettering
On Mo, 19.02.24 10:36, Mikko Rapeli (mikko.rap...@linaro.org) wrote: > > After=dev-tpmrm0.device tee-supplicant@teepriv0.service > > Wants=dev-tpmrm0.device tee-supplicant@teepriv0.service > > I think my problems come from: > > After=tee-supplicant@teepriv0.service >

Re: [systemd-devel] Issues supporting systems with and without TPM and firmware TPM (was Re: Handle device node timeout?)

2024-02-19 Thread Lennart Poettering
On Fr, 16.02.24 11:28, Mikko Rapeli (mikko.rap...@linaro.org) wrote: > Support for fTPM devices is problematic. First, the kernel support must be > modules > but loading needs to be specially handled after starting tee-supplicant. For > normal > boot udev handles optee detection and triggers

Re: [systemd-devel] Issues supporting systems with and without TPM and firmware TPM (was Re: Handle device node timeout?)

2024-02-19 Thread Mikko Rapeli
Hi, On Fri, Feb 16, 2024 at 11:28:31AM +0200, Mikko Rapeli wrote: > Hi, > > Following up to my previous question which worked around with > Wants: and After: to dev-tpmrm0.device and tee-supplicant@teepriv0.service, > which don't seem to work fully. > > In short, I want to support devices with

[systemd-devel] Issues supporting systems with and without TPM and firmware TPM (was Re: Handle device node timeout?)

2024-02-16 Thread Mikko Rapeli
Hi, Following up to my previous question which worked around with Wants: and After: to dev-tpmrm0.device and tee-supplicant@teepriv0.service, which don't seem to work fully. In short, I want to support devices with and without TPM. The TPM device can also be a firmware fTPM device which depends