]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
ASoC: fsl: fsl_qmc_audio: Remove unnecessary bool conversions
authorThorsten Blum <thorsten.blum@linux.dev>
Sun, 23 Feb 2025 20:27:41 +0000 (21:27 +0100)
committerMark Brown <broonie@kernel.org>
Mon, 24 Feb 2025 15:00:56 +0000 (15:00 +0000)
Remove unnecessary bool conversions and simplify the code.

Signed-off-by: Thorsten Blum <thorsten.blum@linux.dev>
Acked-by: Herve Codina <herve.codina@bootlin.com>
Link: https://patch.msgid.link/20250223202741.1916-2-thorsten.blum@linux.dev
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/fsl/fsl_qmc_audio.c

index e257b8adafe09543bf467c60e406397c2ae0767c..b2979290c9732477cdf187f55eb4e9804c91f13c 100644 (file)
@@ -892,7 +892,7 @@ static int qmc_audio_dai_parse(struct qmc_audio *qmc_audio, struct device_node *
                qmc_soc_dai_driver->playback.channels_max = count > 1 ? count : nb_tx_ts;
        }
        qmc_soc_dai_driver->playback.formats = qmc_audio_formats(nb_tx_ts,
-                                                                count > 1 ? true : false);
+                                                                count > 1);
 
        qmc_soc_dai_driver->capture.channels_min = 0;
        qmc_soc_dai_driver->capture.channels_max = 0;
@@ -901,7 +901,7 @@ static int qmc_audio_dai_parse(struct qmc_audio *qmc_audio, struct device_node *
                qmc_soc_dai_driver->capture.channels_max = count > 1 ? count : nb_rx_ts;
        }
        qmc_soc_dai_driver->capture.formats = qmc_audio_formats(nb_rx_ts,
-                                                               count > 1 ? true : false);
+                                                               count > 1);
 
        qmc_soc_dai_driver->playback.rates = snd_pcm_rate_to_rate_bit(tx_fs_rate);
        qmc_soc_dai_driver->playback.rate_min = tx_fs_rate;