]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commit
soc: mediatek: mtk-mutex: Replace max handles number with definition
authorAngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Wed, 22 Feb 2023 09:42:50 +0000 (10:42 +0100)
committerMatthias Brugger <matthias.bgg@gmail.com>
Sun, 2 Apr 2023 16:52:02 +0000 (18:52 +0200)
commitdc36768d05bc877b1227b09af1bb304a28284ce3
treec61004c9b58055dfbb687b4bdbefc6034d0820d1
parent00ee1db7016b73ecd3214d6dc2df4fa02beb694d
soc: mediatek: mtk-mutex: Replace max handles number with definition

Replace the magic number "10", defining the maximum number of supported
handles with a MTK_MUTEX_MAX_HANDLES definition.
While at it, also change the type for `id` from a signed integer to
a unsigned 8 bits integer to save some (small) memory footprint, as
this number is never higher than 10.

This cleanup brings no functional changes.

Signed-off-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Reviewed-by: Chen-Yu Tsai <wenst@chromium.org>
Link: https://lore.kernel.org/r/20230222094253.23678-7-angelogioacchino.delregno@collabora.com
Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com>
drivers/soc/mediatek/mtk-mutex.c