mirror of
https://github.com/torvalds/linux.git
synced 2026-05-23 22:52:19 +02:00
media: c8sectpfe: Refactor load_c8sectpfe_fw
release_firmware() in the same function that it was requested. It is more clear and makes smatch happy. drivers/media/platform/st/sti/c8sectpfe/c8sectpfe-core.c:1146 load_c8sectpfe_fw() warn: 'fw' from request_firmware() not released on lines: 1125,1132. Signed-off-by: Ricardo Ribalda <ribalda@chromium.org> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
This commit is contained in:
parent
179559ed31
commit
cf8da3293b
|
|
@ -1096,7 +1096,6 @@ static int load_slim_core_fw(const struct firmware *fw, struct c8sectpfei *fei)
|
|||
}
|
||||
}
|
||||
|
||||
release_firmware(fw);
|
||||
return err;
|
||||
}
|
||||
|
||||
|
|
@ -1120,6 +1119,7 @@ static int load_c8sectpfe_fw(struct c8sectpfei *fei)
|
|||
}
|
||||
|
||||
err = load_slim_core_fw(fw, fei);
|
||||
release_firmware(fw);
|
||||
if (err) {
|
||||
dev_err(fei->dev, "load_slim_core_fw failed err=(%d)\n", err);
|
||||
return err;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user