Skip to content

Commit 56af322

Browse files
Tomas WinklerJarkko Sakkinen
authored andcommitted
tpm/tpm_tis: remove unused itpm variable
Fixes the warning: drivers/char/tpm/tpm_tis_core.c:443:7: warning: variable ‘itpm’ set but not used [-Wunused-but-set-variable] bool itpm; ^~~~ Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Acked-by: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com> Signed-off-by: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
1 parent f39a9e9 commit 56af322

File tree

1 file changed

+0
-5
lines changed

1 file changed

+0
-5
lines changed

drivers/char/tpm/tpm_tis_core.c

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -440,7 +440,6 @@ static int probe_itpm(struct tpm_chip *chip)
440440
0x00, 0x00, 0x00, 0xf1
441441
};
442442
size_t len = sizeof(cmd_getticks);
443-
bool itpm;
444443
u16 vendor;
445444

446445
rc = tpm_tis_read16(priv, TPM_DID_VID(0), &vendor);
@@ -451,17 +450,13 @@ static int probe_itpm(struct tpm_chip *chip)
451450
if (vendor != TPM_VID_INTEL)
452451
return 0;
453452

454-
itpm = false;
455-
456453
rc = tpm_tis_send_data(chip, cmd_getticks, len);
457454
if (rc == 0)
458455
goto out;
459456

460457
tpm_tis_ready(chip);
461458
release_locality(chip, priv->locality, 0);
462459

463-
itpm = true;
464-
465460
rc = tpm_tis_send_data(chip, cmd_getticks, len);
466461
if (rc == 0) {
467462
dev_info(&chip->dev, "Detected an iTPM.\n");

0 commit comments

Comments
 (0)