dm: core: remove unnecessary return condition in driver lookup
authorMasahiro Yamada <yamada.m@jp.panasonic.com>
Mon, 17 Nov 2014 08:19:40 +0000 (17:19 +0900)
committerSimon Glass <sjg@chromium.org>
Sat, 22 Nov 2014 09:16:49 +0000 (10:16 +0100)
commitf724e0bba2967397545bd48992bba66452d6759d
tree61e4988acf9cc21b89cb87f441ed31a00093a614
parent84a71537333e05b920a5679b4b18d61fc925fefa
dm: core: remove unnecessary return condition in driver lookup

The variable "drv" never becomes NULL because ll_entry_start()
always returns a valid pointer even if there are no entries.

The case "n_ents == 0" is covered by the following "for" loop.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Acked-by: Simon Glass <sjg@chromium.org>
drivers/core/lists.c