Remove unnecessary path check in pcr_ibmtss.c and update the syntax in the other. Signed-off-by: Mimi Zohar <zohar@xxxxxxxxxxxxx> --- src/pcr_ibmtss.c | 12 +----------- src/pcr_tsspcrread.c | 4 ++-- 2 files changed, 3 insertions(+), 13 deletions(-) diff --git a/src/pcr_ibmtss.c b/src/pcr_ibmtss.c index b8700ddd5da8..6b38d280e80c 100644 --- a/src/pcr_ibmtss.c +++ b/src/pcr_ibmtss.c @@ -20,21 +20,11 @@ #undef MAX_DIGEST_SIZE /* imaevm uses a different value than the TSS */ #include <ibmtss/tss.h> -#define CMD "tsspcrread" - -static char path[PATH_MAX]; - int tpm2_pcr_supported(void) { if (imaevm_params.verbose > LOG_INFO) - log_info("Using %s to read PCRs.\n", CMD); - - if (get_cmd_path(CMD, path, sizeof(path))) { - log_debug("Couldn't find '%s' in $PATH\n", CMD); - return 0; - } + log_info("Using ibmtss to read PCRs.\n"); - log_debug("Found '%s' in $PATH\n", CMD); return 1; } diff --git a/src/pcr_tsspcrread.c b/src/pcr_tsspcrread.c index 95048f8a5469..39ff8f7fc14d 100644 --- a/src/pcr_tsspcrread.c +++ b/src/pcr_tsspcrread.c @@ -60,11 +60,11 @@ int tpm2_pcr_supported(void) log_info("Using %s to read PCRs.\n", CMD); if (get_cmd_path(CMD, path, sizeof(path))) { - log_debug("Couldn't find '%s' in $PATH\n", CMD); + log_info("Couldn't find '%s' in %s\n", CMD, path); return 0; } - log_debug("Found '%s' in $PATH\n", CMD); + log_debug("Found '%s' in %s\n", CMD, path); return 1; } -- 2.31.1