* Bug: TPM returned invalid status @ 2021-01-25 9:00 Tj (Elloe Linux) 2021-01-27 17:58 ` Jarkko Sakkinen 0 siblings, 1 reply; 9+ messages in thread From: Tj (Elloe Linux) @ 2021-01-25 9:00 UTC (permalink / raw) To: linux-integrity Seeing this on Lenovo E495's that have: AMD Ryzen 7 3700U with Radeon Vega Mobile Gfx Linux version 5.11.0-rc4+ (tj@elloe000) (gcc (Ubuntu 9.3.0-17ubuntu1~20.04) 9.3.0, GNU ld (GNU Binutils for Ubuntu) 2.34) #12 SMP PREEMPT Sun Jan 24 11:28:01 GMT 2021 Command line: BOOT_IMAGE=/vmlinuz-5.11.0-rc4+ root=/dev/mapper/ELLOE000-rootfs ro acpi_osi=! "acpi_osi=Windows 2016" systemd.unified_cgroup_hierarchy=1 nosplash ... efi: EFI v2.70 by Lenovo efi: ACPI=0xbddfd000 ACPI 2.0=0xbddfd014 TPMFinalLog=0xbdc2d000 SMBIOS=0xba4d7000 SMBIOS 3.0=0xba4ca000 MEMATTR=0xb5611018 ESRT=0xb9075000 RNG=0xba5c2598 TPMEventLog=0xb13ae 018 ... DMI: LENOVO 20NECTO1WW/20NECTO1WW, BIOS R11ET32W (1.12 ) 12/23/2019 ... tpm_tis NTC0702:00: 2.0 TPM (device-id 0xFC, rev-id 1) ------------[ cut here ]------------ TPM returned invalid status WARNING: CPU: 3 PID: 1 at drivers/char/tpm/tpm_tis_core.c:249 tpm_tis_status+0x82/0x90 Modules linked in: CPU: 3 PID: 1 Comm: swapper/0 Not tainted 5.11.0-rc4+ #12 Hardware name: LENOVO 20NECTO1WW/20NECTO1WW, BIOS R11ET32W (1.12 ) 12/23/2019 RIP: 0010:tpm_tis_status+0x82/0x90 Code: 25 28 00 00 00 75 2b c9 c3 31 c0 80 3d af 14 1d 01 00 75 e4 48 c7 c7 dc 24 bf ad 88 45 ef c6 05 9c 14 1d 01 01 e8 65 83 3d 00 <0f> 0b 0f b6> RSP: 0018:ffffaa40400678d0 EFLAGS: 00010286 RAX: 0000000000000000 RBX: ffff8fb5c844f000 RCX: c0000000ffffdfff RDX: ffffaa40400676a8 RSI: 00000000ffffdfff RDI: 0000000000000247 RBP: ffffaa40400678e8 R08: 0000000000000000 R09: ffffaa40400676a0 R10: 0000000000000001 R11: 0000000000000001 R12: ffff8fb5c844f000 R13: ffff8fb5c84bcd98 R14: ffff8fb5c84c5000 R15: 0000000000000016 FS: 0000000000000000(0000) GS:ffff8fbc5e8c0000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000000000000000 CR3: 0000000569e10000 CR4: 00000000003506e0 Call Trace: tpm_tis_send_data+0x41/0x240 ? register_handler_proc+0xfa/0x120 tpm_tis_send_main+0x32/0xf0 tpm_tis_send+0x30/0xa0 tpm_transmit+0xe4/0x3e0 tpm_transmit_cmd+0x2a/0x90 tpm2_get_tpm_pt+0xe9/0x150 tpm_tis_probe_irq_single+0x16f/0x1e8 ? ioread8+0xf/0x40 tpm_tis_core_init.cold+0x2bf/0x455 tpm_tis_init.part.0+0xa0/0x140 tpm_tis_plat_probe+0xd4/0x100 platform_probe+0x45/0xa0 really_probe+0x1db/0x440 driver_probe_device+0xe9/0x160 device_driver_attach+0x5d/0x70 __driver_attach+0x8f/0x150 ? device_driver_attach+0x70/0x70 bus_for_each_dev+0x7e/0xc0 driver_attach+0x1e/0x20 bus_add_driver+0x152/0x1f0 driver_register+0x74/0xd0 ? tpm_init+0xf6/0xf6 __platform_driver_register+0x1e/0x20 init_tis+0x87/0xdd ? kobject_uevent+0xb/0x10 ? driver_register+0xac/0xd0 ? agp_intel_init+0x2f/0x2f ? __pci_register_driver+0x54/0x60 ? tpm_init+0xf6/0xf6 do_one_initcall+0x48/0x210 ? kgdboc_earlycon_late_init+0x25/0x25 ? do_one_initcall+0x6/0x210 kernel_init_freeable+0x1ef/0x24d ? rest_init+0xd0/0xd0 kernel_init+0xe/0x110 ret_from_fork+0x22/0x30 ---[ end trace 667721495775f7e0 ]--- battery: ACPI: Battery Slot [BAT0] (battery present) irq 7: nobody cared (try booting with the "irqpoll" option) CPU: 3 PID: 0 Comm: swapper/3 Tainted: G W 5.11.0-rc4+ #12 Hardware name: LENOVO 20NECTO1WW/20NECTO1WW, BIOS R11ET32W (1.12 ) 12/23/2019 Call Trace: <IRQ> dump_stack+0x74/0x92 __report_bad_irq+0x3a/0xaf note_interrupt.cold+0xb/0x60 handle_irq_event_percpu+0x73/0x80 handle_irq_event+0x39/0x60 handle_fasteoi_irq+0x9c/0x150 asm_call_irq_on_stack+0x12/0x20 </IRQ> common_interrupt+0xbb/0x140 asm_common_interrupt+0x1e/0x40 RIP: 0010:tick_nohz_idle_enter+0x47/0x50 Code: 54 6c 53 48 83 bb b0 00 00 00 00 75 20 80 4b 4c 01 e8 2d 13 ff ff 80 4b 4c 04 48 89 43 78 e8 c0 21 f9 ff fb 66 0f 1f 44 00 00 <5b> 5d c3 0f> RSP: 0018:ffffaa404017feb0 EFLAGS: 00000282 RAX: 000000006a4e43f7 RBX: ffff8fbc5e8df8c0 RCX: 000000006a4e428f RDX: 000000006a5cd015 RSI: 000000006a4e428f RDI: fffffffffff1727a RBP: ffffaa404017feb8 R08: 000000006a4e43f7 R09: ffff8fb5c025a840 R10: 000000000000036d R11: 0000000000000000 R12: 0000000000000091 R13: ffff8fb5c0924f00 R14: 0000000000000000 R15: 0000000000000000 do_idle+0x40/0x260 cpu_startup_entry+0x20/0x30 start_secondary+0x126/0x160 secondary_startup_64_no_verify+0xc2/0xcb handlers: [<00000000aa8f5d3e>] amd_gpio_irq_handler Disabling IRQ #7 tpm tpm0: tpm_try_transmit: send(): error -62 tpm tpm0: [Firmware Bug]: TPM interrupt not working, polling instead ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Bug: TPM returned invalid status 2021-01-25 9:00 Bug: TPM returned invalid status Tj (Elloe Linux) @ 2021-01-27 17:58 ` Jarkko Sakkinen 2021-01-27 18:00 ` Jarkko Sakkinen 0 siblings, 1 reply; 9+ messages in thread From: Jarkko Sakkinen @ 2021-01-27 17:58 UTC (permalink / raw) To: Tj (Elloe Linux), James.Bottomley; +Cc: linux-integrity, jsnitsel On Mon, Jan 25, 2021 at 09:00:54AM +0000, Tj (Elloe Linux) wrote: > Seeing this on Lenovo E495's that have: > > AMD Ryzen 7 3700U with Radeon Vega Mobile Gfx > > Linux version 5.11.0-rc4+ (tj@elloe000) (gcc (Ubuntu > 9.3.0-17ubuntu1~20.04) 9.3.0, GNU ld (GNU Binutils for Ubuntu) 2.34) #12 > SMP PREEMPT Sun Jan 24 11:28:01 GMT 2021 > Command line: BOOT_IMAGE=/vmlinuz-5.11.0-rc4+ > root=/dev/mapper/ELLOE000-rootfs ro acpi_osi=! "acpi_osi=Windows 2016" > systemd.unified_cgroup_hierarchy=1 nosplash > ... > efi: EFI v2.70 by Lenovo > > efi: ACPI=0xbddfd000 ACPI 2.0=0xbddfd014 TPMFinalLog=0xbdc2d000 > SMBIOS=0xba4d7000 SMBIOS 3.0=0xba4ca000 MEMATTR=0xb5611018 > ESRT=0xb9075000 RNG=0xba5c2598 TPMEventLog=0xb13ae > 018 > ... > DMI: LENOVO 20NECTO1WW/20NECTO1WW, BIOS R11ET32W (1.12 ) 12/23/2019 > ... > tpm_tis NTC0702:00: 2.0 TPM (device-id 0xFC, rev-id 1) > ------------[ cut here ]------------ > TPM returned invalid status > WARNING: CPU: 3 PID: 1 at drivers/char/tpm/tpm_tis_core.c:249 There's a patch set in cycle that should fix this: https://lore.kernel.org/linux-integrity/20201001180925.13808-1-James.Bottomley@HansenPartnership.com/ James, where are we at with this? /Jarkko ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Bug: TPM returned invalid status 2021-01-27 17:58 ` Jarkko Sakkinen @ 2021-01-27 18:00 ` Jarkko Sakkinen 2021-01-27 18:11 ` James Bottomley 0 siblings, 1 reply; 9+ messages in thread From: Jarkko Sakkinen @ 2021-01-27 18:00 UTC (permalink / raw) To: Tj (Elloe Linux), James.Bottomley; +Cc: linux-integrity, jsnitsel On Wed, Jan 27, 2021 at 07:58:08PM +0200, Jarkko Sakkinen wrote: > On Mon, Jan 25, 2021 at 09:00:54AM +0000, Tj (Elloe Linux) wrote: > > Seeing this on Lenovo E495's that have: > > > > AMD Ryzen 7 3700U with Radeon Vega Mobile Gfx > > > > Linux version 5.11.0-rc4+ (tj@elloe000) (gcc (Ubuntu > > 9.3.0-17ubuntu1~20.04) 9.3.0, GNU ld (GNU Binutils for Ubuntu) 2.34) #12 > > SMP PREEMPT Sun Jan 24 11:28:01 GMT 2021 > > Command line: BOOT_IMAGE=/vmlinuz-5.11.0-rc4+ > > root=/dev/mapper/ELLOE000-rootfs ro acpi_osi=! "acpi_osi=Windows 2016" > > systemd.unified_cgroup_hierarchy=1 nosplash > > ... > > efi: EFI v2.70 by Lenovo > > > > efi: ACPI=0xbddfd000 ACPI 2.0=0xbddfd014 TPMFinalLog=0xbdc2d000 > > SMBIOS=0xba4d7000 SMBIOS 3.0=0xba4ca000 MEMATTR=0xb5611018 > > ESRT=0xb9075000 RNG=0xba5c2598 TPMEventLog=0xb13ae > > 018 > > ... > > DMI: LENOVO 20NECTO1WW/20NECTO1WW, BIOS R11ET32W (1.12 ) 12/23/2019 > > ... > > tpm_tis NTC0702:00: 2.0 TPM (device-id 0xFC, rev-id 1) > > ------------[ cut here ]------------ > > TPM returned invalid status > > WARNING: CPU: 3 PID: 1 at drivers/char/tpm/tpm_tis_core.c:249 > > There's a patch set in cycle that should fix this: > > https://lore.kernel.org/linux-integrity/20201001180925.13808-1-James.Bottomley@HansenPartnership.com/ > > James, where are we at with this? I'm interested because I'm yet to send my pr and this is generating constantly bug reports. /Jarkko ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Bug: TPM returned invalid status 2021-01-27 18:00 ` Jarkko Sakkinen @ 2021-01-27 18:11 ` James Bottomley 2021-01-28 5:59 ` Jarkko Sakkinen 2021-03-30 2:04 ` Kees Cook 0 siblings, 2 replies; 9+ messages in thread From: James Bottomley @ 2021-01-27 18:11 UTC (permalink / raw) To: Jarkko Sakkinen, Tj (Elloe Linux); +Cc: linux-integrity, jsnitsel On Wed, 2021-01-27 at 20:00 +0200, Jarkko Sakkinen wrote: > On Wed, Jan 27, 2021 at 07:58:08PM +0200, Jarkko Sakkinen wrote: > > On Mon, Jan 25, 2021 at 09:00:54AM +0000, Tj (Elloe Linux) wrote: > > > Seeing this on Lenovo E495's that have: > > > > > > AMD Ryzen 7 3700U with Radeon Vega Mobile Gfx > > > > > > Linux version 5.11.0-rc4+ (tj@elloe000) (gcc (Ubuntu > > > 9.3.0-17ubuntu1~20.04) 9.3.0, GNU ld (GNU Binutils for Ubuntu) > > > 2.34) #12 SMP PREEMPT Sun Jan 24 11:28:01 GMT 2021 > > > Command line: BOOT_IMAGE=/vmlinuz-5.11.0-rc4+ > > > root=/dev/mapper/ELLOE000-rootfs ro acpi_osi=! "acpi_osi=Windows > > > 2016" systemd.unified_cgroup_hierarchy=1 nosplash > > > ... > > > efi: EFI v2.70 by Lenovo > > > > > > efi: ACPI=0xbddfd000 ACPI 2.0=0xbddfd014 TPMFinalLog=0xbdc2d000 > > > SMBIOS=0xba4d7000 SMBIOS 3.0=0xba4ca000 MEMATTR=0xb5611018 > > > ESRT=0xb9075000 RNG=0xba5c2598 TPMEventLog=0xb13ae > > > 018 > > > ... > > > DMI: LENOVO 20NECTO1WW/20NECTO1WW, BIOS R11ET32W (1.12 ) > > > 12/23/2019 > > > ... > > > tpm_tis NTC0702:00: 2.0 TPM (device-id 0xFC, rev-id 1) > > > ------------[ cut here ]------------ > > > TPM returned invalid status > > > WARNING: CPU: 3 PID: 1 at drivers/char/tpm/tpm_tis_core.c:249 > > > > There's a patch set in cycle that should fix this: > > > > https://lore.kernel.org/linux-integrity/20201001180925.13808-1-James.Bottomley@HansenPartnership.com/ > > > > James, where are we at with this? > > I'm interested because I'm yet to send my pr and this is generating > constantly bug reports. It's part of the enable interrupts series, which there's a lot of discussion over. However, that single patch can be broken out of the series if you like. The specific blocker was the screaming interrupt on the Lenovo that Jerry was looking at. He propose a quirk to fix its so perhaps we're now ready to move the entire series forward? James ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Bug: TPM returned invalid status 2021-01-27 18:11 ` James Bottomley @ 2021-01-28 5:59 ` Jarkko Sakkinen 2021-03-30 2:04 ` Kees Cook 1 sibling, 0 replies; 9+ messages in thread From: Jarkko Sakkinen @ 2021-01-28 5:59 UTC (permalink / raw) To: James Bottomley; +Cc: Tj (Elloe Linux), linux-integrity, jsnitsel On Wed, Jan 27, 2021 at 10:11:56AM -0800, James Bottomley wrote: > On Wed, 2021-01-27 at 20:00 +0200, Jarkko Sakkinen wrote: > > On Wed, Jan 27, 2021 at 07:58:08PM +0200, Jarkko Sakkinen wrote: > > > On Mon, Jan 25, 2021 at 09:00:54AM +0000, Tj (Elloe Linux) wrote: > > > > Seeing this on Lenovo E495's that have: > > > > > > > > AMD Ryzen 7 3700U with Radeon Vega Mobile Gfx > > > > > > > > Linux version 5.11.0-rc4+ (tj@elloe000) (gcc (Ubuntu > > > > 9.3.0-17ubuntu1~20.04) 9.3.0, GNU ld (GNU Binutils for Ubuntu) > > > > 2.34) #12 SMP PREEMPT Sun Jan 24 11:28:01 GMT 2021 > > > > Command line: BOOT_IMAGE=/vmlinuz-5.11.0-rc4+ > > > > root=/dev/mapper/ELLOE000-rootfs ro acpi_osi=! "acpi_osi=Windows > > > > 2016" systemd.unified_cgroup_hierarchy=1 nosplash > > > > ... > > > > efi: EFI v2.70 by Lenovo > > > > > > > > efi: ACPI=0xbddfd000 ACPI 2.0=0xbddfd014 TPMFinalLog=0xbdc2d000 > > > > SMBIOS=0xba4d7000 SMBIOS 3.0=0xba4ca000 MEMATTR=0xb5611018 > > > > ESRT=0xb9075000 RNG=0xba5c2598 TPMEventLog=0xb13ae > > > > 018 > > > > ... > > > > DMI: LENOVO 20NECTO1WW/20NECTO1WW, BIOS R11ET32W (1.12 ) > > > > 12/23/2019 > > > > ... > > > > tpm_tis NTC0702:00: 2.0 TPM (device-id 0xFC, rev-id 1) > > > > ------------[ cut here ]------------ > > > > TPM returned invalid status > > > > WARNING: CPU: 3 PID: 1 at drivers/char/tpm/tpm_tis_core.c:249 > > > > > > There's a patch set in cycle that should fix this: > > > > > > https://lore.kernel.org/linux-integrity/20201001180925.13808-1-James.Bottomley@HansenPartnership.com/ > > > > > > James, where are we at with this? > > > > I'm interested because I'm yet to send my pr and this is generating > > constantly bug reports. > > It's part of the enable interrupts series, which there's a lot of > discussion over. However, that single patch can be broken out of the > series if you like. The specific blocker was the screaming interrupt > on the Lenovo that Jerry was looking at. He propose a quirk to fix its > so perhaps we're now ready to move the entire series forward? Why only 1/5 and not 1/5 and 2/5? /Jarkko ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Bug: TPM returned invalid status 2021-01-27 18:11 ` James Bottomley 2021-01-28 5:59 ` Jarkko Sakkinen @ 2021-03-30 2:04 ` Kees Cook 2021-04-08 9:03 ` Tj (Elloe Linux) 1 sibling, 1 reply; 9+ messages in thread From: Kees Cook @ 2021-03-30 2:04 UTC (permalink / raw) To: James Bottomley Cc: Jarkko Sakkinen, Tj (Elloe Linux), linux-integrity, jsnitsel, Lino Sanfilippo On Wed, Jan 27, 2021 at 10:11:56AM -0800, James Bottomley wrote: > On Wed, 2021-01-27 at 20:00 +0200, Jarkko Sakkinen wrote: > > On Wed, Jan 27, 2021 at 07:58:08PM +0200, Jarkko Sakkinen wrote: > > > On Mon, Jan 25, 2021 at 09:00:54AM +0000, Tj (Elloe Linux) wrote: > > > > Seeing this on Lenovo E495's that have: > > > > > > > > AMD Ryzen 7 3700U with Radeon Vega Mobile Gfx > > > > > > > > Linux version 5.11.0-rc4+ (tj@elloe000) (gcc (Ubuntu > > > > 9.3.0-17ubuntu1~20.04) 9.3.0, GNU ld (GNU Binutils for Ubuntu) > > > > 2.34) #12 SMP PREEMPT Sun Jan 24 11:28:01 GMT 2021 > > > > Command line: BOOT_IMAGE=/vmlinuz-5.11.0-rc4+ > > > > root=/dev/mapper/ELLOE000-rootfs ro acpi_osi=! "acpi_osi=Windows > > > > 2016" systemd.unified_cgroup_hierarchy=1 nosplash > > > > ... > > > > efi: EFI v2.70 by Lenovo > > > > > > > > efi: ACPI=0xbddfd000 ACPI 2.0=0xbddfd014 TPMFinalLog=0xbdc2d000 > > > > SMBIOS=0xba4d7000 SMBIOS 3.0=0xba4ca000 MEMATTR=0xb5611018 > > > > ESRT=0xb9075000 RNG=0xba5c2598 TPMEventLog=0xb13ae > > > > 018 > > > > ... > > > > DMI: LENOVO 20NECTO1WW/20NECTO1WW, BIOS R11ET32W (1.12 ) > > > > 12/23/2019 > > > > ... > > > > tpm_tis NTC0702:00: 2.0 TPM (device-id 0xFC, rev-id 1) > > > > ------------[ cut here ]------------ > > > > TPM returned invalid status > > > > WARNING: CPU: 3 PID: 1 at drivers/char/tpm/tpm_tis_core.c:249 > > > > > > There's a patch set in cycle that should fix this: > > > > > > https://lore.kernel.org/linux-integrity/20201001180925.13808-1-James.Bottomley@HansenPartnership.com/ > > > > > > James, where are we at with this? > > > > I'm interested because I'm yet to send my pr and this is generating > > constantly bug reports. > > It's part of the enable interrupts series, which there's a lot of > discussion over. However, that single patch can be broken out of the > series if you like. The specific blocker was the screaming interrupt > on the Lenovo that Jerry was looking at. He propose a quirk to fix its > so perhaps we're now ready to move the entire series forward? Does this series solve the issue too? https://lore.kernel.org/linux-integrity/1613955394-13152-1-git-send-email-LinoSanfilippo@gmx.de/ (I haven't had a chance to test either series with my TPM, but I see the same "TPM returned invalid status" errors recently.) -- Kees Cook ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Bug: TPM returned invalid status 2021-03-30 2:04 ` Kees Cook @ 2021-04-08 9:03 ` Tj (Elloe Linux) 2021-04-09 9:55 ` Aw: " Lino Sanfilippo 0 siblings, 1 reply; 9+ messages in thread From: Tj (Elloe Linux) @ 2021-04-08 9:03 UTC (permalink / raw) To: Kees Cook, James Bottomley Cc: Jarkko Sakkinen, linux-integrity, jsnitsel, Lino Sanfilippo On 30/03/2021 03:04, Kees Cook wrote: > > Does this series solve the issue too? > > https://lore.kernel.org/linux-integrity/1613955394-13152-1-git-send-email-LinoSanfilippo@gmx.de/ > > (I haven't had a chance to test either series with my TPM, but I see the > same "TPM returned invalid status" errors recently.) > Unfortunately no. I tested it immediately but forgot to let you know. kernel: Linux version 5.12.0-rc5tpm-fix+ (tj@elloe000) (gcc (Ubuntu 9.3.0-17ubuntu1~20.04) 9.3.0, GNU ld (GNU Binutils for Ubuntu) 2.34) #29 SMP PREEMPT Tue Mar 30 09:05:15 BST 2021 ... kernel: tpm_tis NTC0702:00: 2.0 TPM (device-id 0xFC, rev-id 1) kernel: ------------[ cut here ]------------ kernel: TPM returned invalid status kernel: WARNING: CPU: 6 PID: 1 at drivers/char/tpm/tpm_tis_core.c:205 tpm_tis_status+0x82/0x90 kernel: Modules linked in: kernel: CPU: 6 PID: 1 Comm: swapper/0 Not tainted 5.12.0-rc5tpm-fix+ #29 kernel: Hardware name: LENOVO 20NECTO1WW/20NECTO1WW, BIOS R11ET32W (1.12 ) 12/23/2019 kernel: RIP: 0010:tpm_tis_status+0x82/0x90 kernel: Code: 25 28 00 00 00 75 2b c9 c3 31 c0 80 3d d2 3c 3a 01 00 75 e4 48 c7 c7 9c 7c 63 98 88 45 ef c6 05 bf 3c 3a 01 01 e8 39 58 42 00 <0f> 0b 0f b6 45 ef eb c6 e8 61 19 48 00 90 0f 1f 44 00 00 55 48 89 kernel: RSP: 0018:ffff995440067900 EFLAGS: 00010286 kernel: RAX: 0000000000000000 RBX: ffff8c84ca282000 RCX: c0000000ffffdfff kernel: RDX: ffff9954400676d0 RSI: 00000000ffffdfff RDI: ffffffff98e9f38c kernel: RBP: ffff995440067918 R08: 0000000000000000 R09: ffff9954400676c8 kernel: R10: 0000000000000001 R11: 0000000000000001 R12: ffff8c84ca282000 kernel: R13: ffff8c84c1418918 R14: ffff8c84c0fba000 R15: 0000000000000016 kernel: FS: 0000000000000000(0000) GS:ffff8c8b60b80000(0000) knlGS:0000000000000000 kernel: CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 kernel: CR2: 0000000000000000 CR3: 0000000559610000 CR4: 00000000003506e0 kernel: Call Trace: kernel: tpm_tis_send_data+0x41/0x240 kernel: tpm_tis_send+0x32/0xf0 kernel: tpm_transmit+0xe4/0x3e0 kernel: tpm_transmit_cmd+0x2a/0x90 kernel: tpm2_get_tpm_pt+0xe9/0x150 kernel: tpm_tis_probe_irq_single+0x18d/0x26d kernel: tpm_tis_core_init.cold+0x193/0x2bf kernel: tpm_tis_init.part.0+0xa0/0x140 kernel: tpm_tis_plat_probe+0xd4/0x100 kernel: platform_probe+0x45/0xa0 kernel: really_probe+0xfb/0x420 kernel: driver_probe_device+0xe9/0x160 kernel: device_driver_attach+0x5d/0x70 kernel: __driver_attach+0x8f/0x150 kernel: ? device_driver_attach+0x70/0x70 kernel: bus_for_each_dev+0x7e/0xc0 kernel: driver_attach+0x1e/0x20 kernel: bus_add_driver+0x152/0x1f0 kernel: driver_register+0x74/0xd0 kernel: ? tpm_init+0xf6/0xf6 kernel: __platform_driver_register+0x1e/0x20 kernel: init_tis+0x87/0xdd kernel: ? kobject_uevent+0xb/0x10 kernel: ? driver_register+0xac/0xd0 kernel: ? agp_intel_init+0x2f/0x2f kernel: ? __pci_register_driver+0x54/0x60 kernel: ? tpm_init+0xf6/0xf6 kernel: do_one_initcall+0x48/0x210 kernel: kernel_init_freeable+0x200/0x25e kernel: ? rest_init+0xd0/0xd0 kernel: kernel_init+0xe/0x110 kernel: ret_from_fork+0x22/0x30 kernel: ---[ end trace 45e4a376e6a7bd22 ]--- ^ permalink raw reply [flat|nested] 9+ messages in thread
* Aw: Re: Bug: TPM returned invalid status 2021-04-08 9:03 ` Tj (Elloe Linux) @ 2021-04-09 9:55 ` Lino Sanfilippo 2021-04-14 11:05 ` Jarkko Sakkinen 0 siblings, 1 reply; 9+ messages in thread From: Lino Sanfilippo @ 2021-04-09 9:55 UTC (permalink / raw) To: Tj (Elloe Linux) Cc: Kees Cook, James Bottomley, Jarkko Sakkinen, linux-integrity, jsnitsel Hi, > > On 30/03/2021 03:04, Kees Cook wrote: > > > > Does this series solve the issue too? > > > > https://lore.kernel.org/linux-integrity/1613955394-13152-1-git-send-email-LinoSanfilippo@gmx.de/ > > > > (I haven't had a chance to test either series with my TPM, but I see the > > same "TPM returned invalid status" errors recently.) > > > > Unfortunately no. I tested it immediately but forgot to let you know. > > > kernel: Linux version 5.12.0-rc5tpm-fix+ (tj@elloe000) (gcc (Ubuntu > 9.3.0-17ubuntu1~20.04) 9.3.0, GNU ld (GNU Binutils for Ubuntu) 2.34) #29 > SMP PREEMPT Tue Mar 30 09:05:15 BST 2021 > ... Well you tested the series with 5.12-rc5 while it was based on 5.11. Patch 2 in the series is supposed to fix the "invalid status" warning by making sure that the required locality has been requested before. To avoid such issues at all and to simplify the whole locality handling (and also to be prepared for interrupt handling which also requires locality management) that patch furthermore ensures that the locality is requested only once at driver startup and not released until driver shutdown. However between 5.11 and 5.12-rc5 there have been at least two patches that again introduced a locality request/release combo (d53a6adfb553 "tpm, tpm_tis: Decorate tpm_tis_gen_interrupt() with request_locality()" and a5665ec2affd "tpm, tpm_tis: Decorate tpm_get_timeouts() with request_locality()"). The latter results in the locality being released again before tpm_tis_status() is called and thus reintroduced the issue patch 2 fixed. I will prepare another series based on the latest kernel but at least for 5.11 the series should fix the issue (and also make interrupts working). Best regards, Lino ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Re: Bug: TPM returned invalid status 2021-04-09 9:55 ` Aw: " Lino Sanfilippo @ 2021-04-14 11:05 ` Jarkko Sakkinen 0 siblings, 0 replies; 9+ messages in thread From: Jarkko Sakkinen @ 2021-04-14 11:05 UTC (permalink / raw) To: Lino Sanfilippo Cc: Tj (Elloe Linux), Kees Cook, James Bottomley, linux-integrity, jsnitsel On Fri, Apr 09, 2021 at 11:55:05AM +0200, Lino Sanfilippo wrote: > > Hi, > > > > > On 30/03/2021 03:04, Kees Cook wrote: > > > > > > Does this series solve the issue too? > > > > > > https://lore.kernel.org/linux-integrity/1613955394-13152-1-git-send-email-LinoSanfilippo@gmx.de/ > > > > > > (I haven't had a chance to test either series with my TPM, but I see the > > > same "TPM returned invalid status" errors recently.) > > > > > > > Unfortunately no. I tested it immediately but forgot to let you know. > > > > > > kernel: Linux version 5.12.0-rc5tpm-fix+ (tj@elloe000) (gcc (Ubuntu > > 9.3.0-17ubuntu1~20.04) 9.3.0, GNU ld (GNU Binutils for Ubuntu) 2.34) #29 > > SMP PREEMPT Tue Mar 30 09:05:15 BST 2021 > > ... > > Well you tested the series with 5.12-rc5 while it was based on 5.11. Patch 2 > in the series is supposed to fix the "invalid status" warning by making sure > that the required locality has been requested before. > To avoid such issues at all and to simplify the whole locality handling (and > also to be prepared for interrupt handling which also requires locality management) > that patch furthermore ensures that the locality is requested only once at driver > startup and not released until driver shutdown. > > However between 5.11 and 5.12-rc5 there have been at least two patches that > again introduced a locality request/release combo (d53a6adfb553 "tpm, tpm_tis: > Decorate tpm_tis_gen_interrupt() with request_locality()" and a5665ec2affd > "tpm, tpm_tis: Decorate tpm_get_timeouts() with request_locality()"). > > The latter results in the locality being released again before tpm_tis_status() > is called and thus reintroduced the issue patch 2 fixed. > > I will prepare another series based on the latest kernel but at least for 5.11 > the series should fix the issue (and also make interrupts working). Thanks, I can review patches after coming from two week leave and include them to 5.13-rcX. Add stable cc in addition to the fixes tag. /Jarkko ^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2021-04-14 11:05 UTC | newest] Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2021-01-25 9:00 Bug: TPM returned invalid status Tj (Elloe Linux) 2021-01-27 17:58 ` Jarkko Sakkinen 2021-01-27 18:00 ` Jarkko Sakkinen 2021-01-27 18:11 ` James Bottomley 2021-01-28 5:59 ` Jarkko Sakkinen 2021-03-30 2:04 ` Kees Cook 2021-04-08 9:03 ` Tj (Elloe Linux) 2021-04-09 9:55 ` Aw: " Lino Sanfilippo 2021-04-14 11:05 ` Jarkko Sakkinen
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).