diff options
| author | Kuninori Morimoto <[email protected]> | 2023-05-30 00:50:01 +0000 |
|---|---|---|
| committer | Mark Brown <[email protected]> | 2023-05-31 12:25:05 +0100 |
| commit | c3e9b6d6ef5a0a3e841c3aa29e7afc48a0b73806 (patch) | |
| tree | 880e8f7a36f14e36a61d41c8f4a3f0ac5f9adda5 /tools/perf/scripts/python/net_dropmonitor.py | |
| parent | a1c0221fa5baeae6c9dc30294c2c6d01f1f4379b (diff) | |
ASoC: soc-pcm.c: use temporary variable at soc_get_playback_capture()
soc_get_playback_capture() (A) returns number of substreams for
playback/capture (B).
(A) static int soc_get_playback_capture(...,
(B) int *playback, int *capture)
{
...
for_each_xxx(...) {
if (xxx)
return -EINVAL;
=> *playback = 1;
...
=> *capture = 1;
...
}
...
}
But, it is directly updating playback/capture which is the result of this
function even though it might be error. It should be updated in case of
succeed only. This patch updates it.
Signed-off-by: Kuninori Morimoto <[email protected]>
Reviewed-by: Amadeusz Sławiński <[email protected]>
Reviewed-by: Pierre-Louis Bossart <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Mark Brown <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/net_dropmonitor.py')
0 files changed, 0 insertions, 0 deletions