From: Danylo Vodopianov <dvo-...@napatech.com> Add separate return value verification and logs for function.
Signed-off-by: Danylo Vodopianov <dvo-...@napatech.com> --- .../nthw/core/nt200a0x/reset/nthw_fpga_rst_nt200a0x.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/drivers/net/ntnic/nthw/core/nt200a0x/reset/nthw_fpga_rst_nt200a0x.c b/drivers/net/ntnic/nthw/core/nt200a0x/reset/nthw_fpga_rst_nt200a0x.c index 3528792845..cc6f7d13b5 100644 --- a/drivers/net/ntnic/nthw/core/nt200a0x/reset/nthw_fpga_rst_nt200a0x.c +++ b/drivers/net/ntnic/nthw/core/nt200a0x/reset/nthw_fpga_rst_nt200a0x.c @@ -528,7 +528,16 @@ static int nthw_fpga_rst_nt200a0x_init(struct fpga_info_s *p_fpga_info, nthw_rac_rab_setup(p_fpga_info->mp_nthw_rac); res = nthw_fpga_iic_scan(p_fpga, 0, 0); + if (res == -1) { + NT_LOG(ERR, NTHW, "Failed to init iic instance %d - %d for NT200 (%d)", 0, 0, res); + return -1; + } + res = nthw_fpga_iic_scan(p_fpga, 2, 3); + if (res == -1) { + NT_LOG(ERR, NTHW, "Failed to init iic instance %d - %d for NT200 (%d)", 2, 3, res); + return -1; + } /* * Detect clock synth model -- 2.47.1