]> Gentwo Git Trees - linux/.git/commit
ASoC: use int type to store negative error codes
authorMark Brown <broonie@kernel.org>
Thu, 28 Aug 2025 19:45:00 +0000 (21:45 +0200)
committerMark Brown <broonie@kernel.org>
Thu, 28 Aug 2025 19:45:00 +0000 (21:45 +0200)
commit44e51457861edd47bea0f43fab4ed952fdd901f1
treeda24b1671a741d32ffc40acb5b10ce2cced78e95
parentf43095de82b04a11f7239fdf9e724d907ea3dc3b
parent11f5c5f9e43e9020bae452232983fe98e7abfce0
ASoC: use int type to store negative error codes

Merge series from Qianfeng Rong <rongqianfeng@vivo.com>:

The 'ret' variable usually is used to store returns from some functions,
which return either zero on success or negative error codes on failure.

Storing the negative error codes in unsigned type, doesn't cause an issue
at runtime but it's ugly as pants.  Additionally, assigning negative error
codes to unsigned type may trigger a GCC warning when the -Wsign-conversion
flag is enabled.

Change "ret" from u32/unsigned int to int type.  No effect on runtime.