diff options
author | Frank Rowand <frank.rowand@sony.com> | 2018-10-04 20:40:21 -0700 |
---|---|---|
committer | Frank Rowand <frank.rowand@sony.com> | 2018-11-08 22:12:37 -0800 |
commit | eeb07c573ec307c53fe2f6ac6d8d11c261f64006 (patch) | |
tree | c6f825e39534e2b3e936cd358ad9316f324a6489 /tools/perf/scripts/python/exported-sql-viewer.py | |
parent | 160b1d4e4127f0ef5d9ac281b6fa6ef1fb78c45f (diff) |
of: unittest: initialize args before calling of_*parse_*()
Callers of of_irq_parse_one() blindly use the pointer args.np
without checking whether of_irq_parse_one() had an error and
thus did not set the value of args.np. Initialize args to
zero so that using the format "%pOF" to show the value of
args.np will show "(null)" when of_irq_parse_one() has an
error. This prevents the dereference of a random value.
Make the same fix for callers of of_parse_phandle_with_args()
and of_parse_phandle_with_args_map().
Reported-by: Guenter Roeck <linux@roeck-us.net>
Tested-by: Alan Tull <atull@kernel.org>
Signed-off-by: Frank Rowand <frank.rowand@sony.com>
Diffstat (limited to 'tools/perf/scripts/python/exported-sql-viewer.py')
0 files changed, 0 insertions, 0 deletions