From: Dan Carpenter Date: Sun, 20 Nov 2011 20:57:49 +0000 (+0300) Subject: ALSA: cs5535 - Fix an endianness conversion X-Git-Tag: upstream/snapshot3+hdmi~8518^2~28 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=27533df80e93dc164e39d47281bbbd608f9014a6;p=platform%2Fadaptation%2Frenesas_rcar%2Frenesas_kernel.git ALSA: cs5535 - Fix an endianness conversion desc->size is supposed to be a le16 type. On a big endian system the current code will set ->size to zero. We fixed a similar bug on the next line but missed this one. Signed-off-by: Dan Carpenter Signed-off-by: Takashi Iwai --- diff --git a/sound/pci/cs5535audio/cs5535audio_pcm.c b/sound/pci/cs5535audio/cs5535audio_pcm.c index e083122..dbf94b1 100644 --- a/sound/pci/cs5535audio/cs5535audio_pcm.c +++ b/sound/pci/cs5535audio/cs5535audio_pcm.c @@ -148,7 +148,7 @@ static int cs5535audio_build_dma_packets(struct cs5535audio *cs5535au, struct cs5535audio_dma_desc *desc = &((struct cs5535audio_dma_desc *) dma->desc_buf.area)[i]; desc->addr = cpu_to_le32(addr); - desc->size = cpu_to_le32(period_bytes); + desc->size = cpu_to_le16(period_bytes); desc->ctlreserved = cpu_to_le16(PRD_EOP); desc_addr += sizeof(struct cs5535audio_dma_desc); addr += period_bytes;