device property: Don't check for NULL twice in the loops
authorAndy Shevchenko <andy.shevchenko@gmail.com>
Tue, 18 May 2021 06:48:43 +0000 (09:48 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 27 May 2021 13:48:12 +0000 (15:48 +0200)
commit7e7ba9b3d46d47e9f75cbf9d5392583a958a9807
tree392d27244aa24065ef014594d7ee1cf220d20367
parent0d71f80b1898311420b4d07183a1e693c9b20c9e
device property: Don't check for NULL twice in the loops

In fwnode_get_next_available_child_node() we check next_child for NULL
twice. All the same in fwnode_get_next_parent_dev() we may avoid checking
fwnode for NULL twice.

Signed-off-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Link: https://lore.kernel.org/r/20210518064843.3524015-1-andy.shevchenko@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/base/property.c