Commit b7108486 authored by Greg Kroah-Hartman's avatar Greg Kroah-Hartman

Merge tag 'soundwire-5.2-rc4' of...

Merge tag 'soundwire-5.2-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/vkoul/soundwire into char-misc-linus

Vinod writes:

soundwire fixes for v5.2-rc4

Srinivas Kandagatla fixed by bunch of issues, two in core for locking
and out of bound access and one in intel driver copy-paste

* tag 'soundwire-5.2-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/vkoul/soundwire:
  soundwire: intel: set dai min and max channels correctly
  soundwire: stream: fix bad unlock balance
  soundwire: stream: fix out of boundary access on port properties
parents d1fdb6d8 39194128
...@@ -715,8 +715,8 @@ static int intel_create_dai(struct sdw_cdns *cdns, ...@@ -715,8 +715,8 @@ static int intel_create_dai(struct sdw_cdns *cdns,
return -ENOMEM; return -ENOMEM;
} }
dais[i].playback.channels_min = 1; dais[i].capture.channels_min = 1;
dais[i].playback.channels_max = max_ch; dais[i].capture.channels_max = max_ch;
dais[i].capture.rates = SNDRV_PCM_RATE_48000; dais[i].capture.rates = SNDRV_PCM_RATE_48000;
dais[i].capture.formats = SNDRV_PCM_FMTBIT_S16_LE; dais[i].capture.formats = SNDRV_PCM_FMTBIT_S16_LE;
} }
......
...@@ -814,7 +814,8 @@ static int do_bank_switch(struct sdw_stream_runtime *stream) ...@@ -814,7 +814,8 @@ static int do_bank_switch(struct sdw_stream_runtime *stream)
goto error; goto error;
} }
mutex_unlock(&bus->msg_lock); if (bus->multi_link)
mutex_unlock(&bus->msg_lock);
} }
return ret; return ret;
...@@ -1406,9 +1407,7 @@ struct sdw_dpn_prop *sdw_get_slave_dpn_prop(struct sdw_slave *slave, ...@@ -1406,9 +1407,7 @@ struct sdw_dpn_prop *sdw_get_slave_dpn_prop(struct sdw_slave *slave,
} }
for (i = 0; i < num_ports; i++) { for (i = 0; i < num_ports; i++) {
dpn_prop = &dpn_prop[i]; if (dpn_prop[i].num == port_num)
if (dpn_prop->num == port_num)
return &dpn_prop[i]; return &dpn_prop[i];
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment