diff options
Diffstat (limited to 'drivers/tee/optee')
-rw-r--r-- | drivers/tee/optee/core.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/tee/optee/core.c b/drivers/tee/optee/core.c index ac59c77841a4..0842b6e6af82 100644 --- a/drivers/tee/optee/core.c +++ b/drivers/tee/optee/core.c @@ -703,8 +703,10 @@ static int __init optee_driver_init(void) return -ENODEV; np = of_find_matching_node(fw_np, optee_match); - if (!np || !of_device_is_available(np)) + if (!np || !of_device_is_available(np)) { + of_node_put(np); return -ENODEV; + } optee = optee_probe(np); of_node_put(np); |