提交 7679a030 编写于 作者: T Thomas Charbonnel 提交者: Jaroslav Kysela

[ALSA] hdsp - solved big endian problem

RME HDSP driver
ppc firmware upload fix
Signed-off-by: NThomas Charbonnel <thomas@undata.org>
Signed-off-by: NJaroslav Kysela <perex@suse.cz>
上级 67e1b51e
......@@ -4912,19 +4912,9 @@ static int __devinit hdsp_request_fw_loader(hdsp_t *hdsp)
release_firmware(fw);
return -EINVAL;
}
#ifdef SNDRV_BIG_ENDIAN
{
int i;
u32 *src = (u32*)fw->data;
for (i = 0; i < ARRAY_SIZE(hdsp->firmware_cache); i++, src++)
hdsp->firmware_cache[i] = ((*src & 0x000000ff) << 16) |
((*src & 0x0000ff00) << 8) |
((*src & 0x00ff0000) >> 8) |
((*src & 0xff000000) >> 16);
}
#else
memcpy(hdsp->firmware_cache, fw->data, sizeof(hdsp->firmware_cache));
#endif
release_firmware(fw);
hdsp->state |= HDSP_FirmwareCached;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册