aboutsummaryrefslogtreecommitdiffstats
path: root/sound/pci/rme9652
diff options
context:
space:
mode:
authorThomas Charbonnel <thomas@undata.org>2005-04-25 05:35:29 -0400
committerJaroslav Kysela <perex@suse.cz>2005-05-29 04:05:23 -0400
commit7679a03099992d8e6c878d459e22b639ed8c10fa (patch)
treec8f19bcd7c9297948936fd8efe3b82c08f63c601 /sound/pci/rme9652
parent67e1b51e293cec9bbe8c9ad81680bceec1e3b7f9 (diff)
[ALSA] hdsp - solved big endian problem
RME HDSP driver ppc firmware upload fix Signed-off-by: Thomas Charbonnel <thomas@undata.org> Signed-off-by: Jaroslav Kysela <perex@suse.cz>
Diffstat (limited to 'sound/pci/rme9652')
-rw-r--r--sound/pci/rme9652/hdsp.c14
1 files changed, 2 insertions, 12 deletions
diff --git a/sound/pci/rme9652/hdsp.c b/sound/pci/rme9652/hdsp.c
index 44ca7ddb68f6..b35ed5f0c042 100644
--- a/sound/pci/rme9652/hdsp.c
+++ b/sound/pci/rme9652/hdsp.c
@@ -4912,19 +4912,9 @@ static int __devinit hdsp_request_fw_loader(hdsp_t *hdsp)
4912 release_firmware(fw); 4912 release_firmware(fw);
4913 return -EINVAL; 4913 return -EINVAL;
4914 } 4914 }
4915#ifdef SNDRV_BIG_ENDIAN 4915
4916 {
4917 int i;
4918 u32 *src = (u32*)fw->data;
4919 for (i = 0; i < ARRAY_SIZE(hdsp->firmware_cache); i++, src++)
4920 hdsp->firmware_cache[i] = ((*src & 0x000000ff) << 16) |
4921 ((*src & 0x0000ff00) << 8) |
4922 ((*src & 0x00ff0000) >> 8) |
4923 ((*src & 0xff000000) >> 16);
4924 }
4925#else
4926 memcpy(hdsp->firmware_cache, fw->data, sizeof(hdsp->firmware_cache)); 4916 memcpy(hdsp->firmware_cache, fw->data, sizeof(hdsp->firmware_cache));
4927#endif 4917
4928 release_firmware(fw); 4918 release_firmware(fw);
4929 4919
4930 hdsp->state |= HDSP_FirmwareCached; 4920 hdsp->state |= HDSP_FirmwareCached;