summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
Diffstat (limited to 'drivers')
-rw-r--r--drivers/char/tpm/tpm_of.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/char/tpm/tpm_of.c b/drivers/char/tpm/tpm_of.c
index 643cc8ccb35b..36df9df4c472 100644
--- a/drivers/char/tpm/tpm_of.c
+++ b/drivers/char/tpm/tpm_of.c
@@ -31,7 +31,7 @@ int tpm_read_log_of(struct tpm_chip *chip)
log = &chip->log;
if (chip->dev.parent->of_node)
np = chip->dev.parent->of_node;
- if (!np)
+ else
return -ENODEV;
sizep = of_get_property(np, "linux,sml-size", NULL);