Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ASoC: cs35l45: Corrects cs35l45_get_clk_freq_id function data type

Changes cs35l45_get_clk_freq_id() function data type from unsigned int
to int. This function is returns a positive index value if successful
or a negative error code if unsuccessful.

Functionally there should be no difference as long as the unsigned int
return is interpreted as an int, however it should be corrected for
readability.

Signed-off-by: Ricardo Rivera-Matos <rriveram@opensource.cirrus.com>
Link: https://patch.msgid.link/20240919151654.197337-1-rriveram@opensource.cirrus.com
Signed-off-by: Mark Brown <broonie@kernel.org>

authored by

Ricardo Rivera-Matos and committed by
Mark Brown
01e709ae 85109780

+2 -2
+1 -1
sound/soc/codecs/cs35l45-tables.c
··· 315 315 { 0x3B, 24576000 }, 316 316 }; 317 317 318 - unsigned int cs35l45_get_clk_freq_id(unsigned int freq) 318 + int cs35l45_get_clk_freq_id(unsigned int freq) 319 319 { 320 320 int i; 321 321
+1 -1
sound/soc/codecs/cs35l45.h
··· 507 507 extern const struct regmap_config cs35l45_i2c_regmap; 508 508 extern const struct regmap_config cs35l45_spi_regmap; 509 509 int cs35l45_apply_patch(struct cs35l45_private *cs35l45); 510 - unsigned int cs35l45_get_clk_freq_id(unsigned int freq); 510 + int cs35l45_get_clk_freq_id(unsigned int freq); 511 511 int cs35l45_probe(struct cs35l45_private *cs35l45); 512 512 void cs35l45_remove(struct cs35l45_private *cs35l45); 513 513