]> git.itanic.dy.fi Git - linux-stable/commit
tpm, tpm_tis: correct tpm_tis_flags enumeration values
authorLino Sanfilippo <l.sanfilippo@kunbus.com>
Tue, 30 May 2023 16:41:16 +0000 (18:41 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 9 Jun 2023 08:48:18 +0000 (10:48 +0200)
commitb3b340ae1697cd594fdfcdbdd81094b098e2d98b
tree03dc9a1f366dd498eec124631f22ca4f9b719b0e
parentd24943e27c1683e41f11586d703bff4d02c309a2
tpm, tpm_tis: correct tpm_tis_flags enumeration values

commit 4ecd704a4c51fd95973fcc3a60444e0e24eb9439 upstream.

With commit 858e8b792d06 ("tpm, tpm_tis: Avoid cache incoherency in test
for interrupts") bit accessor functions are used to access flags in
tpm_tis_data->flags.

However these functions expect bit numbers, while the flags are defined
as bit masks in enum tpm_tis_flag.

Fix this inconsistency by using numbers instead of masks also for the
flags in the enum.

Reported-by: Pavel Machek <pavel@denx.de>
Fixes: 858e8b792d06 ("tpm, tpm_tis: Avoid cache incoherency in test for interrupts")
Signed-off-by: Lino Sanfilippo <l.sanfilippo@kunbus.com>
Cc: stable@vger.kernel.org
Reviewed-by: Pavel Machek <pavel@denx.de>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/char/tpm/tpm_tis_core.h