Skip to contentSkip to conversation

ASoC: fsl_sai: Don't use ~FSL_SAI_CR2_SYNC

PATCH New Mark Brown 1 participant 1 message Aug 4, 2014

Subsystems (3)
lore
Share & tools
lore

Mark Brown

author maintainer
#0 lore raw

PATCH 1/1 ASoC: fsl_sai: Don't use ~FSL_SAI_CR2_SYNC

From: Mark Brown <[email protected]>

On 64 bit systems ~FSL_SAI_CR2_SYNC generates a constant that won't fit in an unsigned int, causing GCC to warn. Since we're already only updating one bit due to the masking in update bits just write the value explicitly as zero.

---
 sound/soc/fsl/fsl_sai.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
sound/soc/fsl/fsl_sai.c +1 -2
index faa0497..9f10575 100644
@@ -333,8 +333,7 @@ static int fsl_sai_trigger(struct snd_pcm_substream *substream, int cmd,
 	 * The transmitter bit clock and frame sync are to be
 	 * used by both the transmitter and receiver.
 	 */
-	regmap_update_bits(sai->regmap, FSL_SAI_TCR2, FSL_SAI_CR2_SYNC,
-			   ~FSL_SAI_CR2_SYNC);
+	regmap_update_bits(sai->regmap, FSL_SAI_TCR2, FSL_SAI_CR2_SYNC, 0);
 	regmap_update_bits(sai->regmap, FSL_SAI_RCR2, FSL_SAI_CR2_SYNC,
 			   FSL_SAI_CR2_SYNC);
 
Signature · 1 line
2.0.0