Skip to content

Commit 157bea5

Browse files
dcpleungnashif
authored andcommitted
i3c: set default return for i3c_device_adv_info_get()
Coverity flagged that the return variable ret may not be initialized when returning. So give it a default value. Fixes #90509 Signed-off-by: Daniel Leung <[email protected]>
1 parent 8970009 commit 157bea5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/i3c/i3c_common.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -772,7 +772,7 @@ int i3c_device_adv_info_get(struct i3c_device_desc *target)
772772
struct i3c_ccc_mwl mwl = {0};
773773
union i3c_ccc_getcaps caps = {0};
774774
union i3c_ccc_getmxds mxds = {0};
775-
int ret;
775+
int ret = -EIO;
776776

777777
/* GETMRL */
778778
if (i3c_ccc_do_getmrl(target, &mrl) != 0) {

0 commit comments

Comments
 (0)