aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/tools/perf/scripts/python/export-to-sqlite.py
diff options
context:
space:
mode:
authorRichard Fitzgerald <rf@opensource.cirrus.com>2020-12-16 11:25:12 +0000
committerMark Brown <broonie@kernel.org>2020-12-28 12:24:43 +0000
commit7726e49837af634accaec317c8d246d1d90d8fc5 (patch)
tree45af6845d85f32b8af261141a83e6b8ba491a0fc /tools/perf/scripts/python/export-to-sqlite.py
parentcatpt: Switch to use list_entry_is_head() helper (diff)
downloadwireguard-linux-7726e49837af634accaec317c8d246d1d90d8fc5.tar.xz
wireguard-linux-7726e49837af634accaec317c8d246d1d90d8fc5.zip
ASoC: wm_adsp: Improve handling of raw byte streams
As the register map is 16-bit or 32-bit big-endian, the 24-bit DSP words appear padded and with the bytes swapped. When reading a raw stream of bytes, the pad bytes must be removed and the data bytes swapped back to their original order. The previous implementation of this assumed that the be32_to_cpu() in wm_adsp_read_data_block() would swap back to little-endian. But this is obviously only true on a little-endian CPU. It also made two walks through the data, once to endian-swap and again to strip the pad bytes. This patch re-works the code so that the endian-swap and unpad are done together in a single walk, and it is not dependent on the endianness of the CPU. The data_word_size argument to wm_adsp_remove_padding() has been dropped because currently this is always 3. Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com> Link: https://lore.kernel.org/r/20201216112512.26503-1-rf@opensource.cirrus.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python/export-to-sqlite.py')
0 files changed, 0 insertions, 0 deletions