Skip to content
Commit 79c5453d authored by Mauro Carvalho Chehab's avatar Mauro Carvalho Chehab
Browse files

media: atmel-isc: avoid returning a random value at isc_parse_dt()



As warned by smatch:
drivers/media/platform/atmel/atmel-isc.c:2097 isc_parse_dt() error: uninitialized symbol 'ret'.

The problem here is that of_graph_get_next_endpoint() can
potentially return NULL on its first pass, with would make
it return a random value, as ret is not initialized.

While here, use while(1) instead of for(; ;), as while is
the preferred syntax for such kind of loops.

Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@s-opensource.com>
parent 910b0797
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment