binman: Allow state functions to fail to return data
authorSimon Glass <sjg@chromium.org>
Sat, 20 Jul 2019 18:23:42 +0000 (12:23 -0600)
committerSimon Glass <sjg@chromium.org>
Mon, 29 Jul 2019 15:38:05 +0000 (09:38 -0600)
commit6a3b5b54110980a42284beb05865436652113772
tree2491338717205929d13d20dba2453d13c9d7c28b
parentd5079330f588a1aeedc734197124543bbc4e2d3c
binman: Allow state functions to fail to return data

At present these state functions raise an exception if they cannot find
what is requested. But in some cases the information is optional (e.g. an
fdtmap in a coming patch) so it is better to return gracefully.

Update these two functions to return None when the data cannot be found.

Signed-off-by: Simon Glass <sjg@chromium.org>
tools/binman/state.py