Re: git: f1b9c1aafd84 - main - random: git'o in RANDOM_ENABLE_TPM

From: Renato Botelho <garga_at_FreeBSD.org>
Date: Mon, 17 Nov 2025 17:54:26 UTC
On 14/11/25 18:41, Gleb Smirnoff wrote:
> On Fri, Nov 14, 2025 at 06:03:15PM -0300, Renato Botelho wrote:
> R> After upgrading my laptop this morning I noticed it was freezing after
> R> suspend/resume.  I've bisected and ended up on this commit.
> R>
> R> I confirmed reverting d6f10a5d013f (only to prevent conflicts) followed by
> R> f1b9c1aafd84 and 3deb21f1afd5 have fixed the issue.
> R>
> R> My system is running today's CURRENT at 82d8a5029a80.
> 
> Looks like the commit you point at can't be a culprit.  Looking closer to your
> description "reverting d6f10a5d013f followed by f1b9c1aafd84 and 3deb21f1afd5"
> it seems that the only functional change is addition of device tpm and
> rdrand_rng and option RANDOM_ENABLE_TPM to the GENERIC.
> 
> Can you please try unmodified main sources at 82d8a5029a80, but modify GENERIC
> to remove these two lines:
> 
> +# random(4)
> +device         rdrand_rng              # Intel Bull Mountain RNG
> +device         tpm                     # Trusted Platform Module
> +options        RANDOM_ENABLE_TPM       # enable entropy from TPM 2.0
> 
> If that helps, can you please find which particular line makes the
> regression.
Hello Gleb!

I was far from keyboard during the weekend but I tested it today and 
RANDOM_ENABLE_TPM is the option that trigger the issue.

I've commented out RANDOM_ENABLE_{TPM,KBD,MOUSE} on unpatched src at 
82d8a5029a80 and suspend/resume worked as expected.  Uncommenting 
RANDOM_ENABLE_TPM made it to stop working again.
-- 
Renato Botelho