tty/vt: consolemap: improve UNI_*() macros definitions
authorJiri Slaby <jslaby@suse.cz>
Tue, 14 Jun 2022 09:05:35 +0000 (11:05 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 27 Jun 2022 12:17:12 +0000 (14:17 +0200)
commit1c2f6294a3613b84fc20d6620da078dedbb2ac1e
treef07f5cdd18a232381033ab219873f555ebd6025d
parent8da443b1a4036b5863fd2ec7e0251164b704c726
tty/vt: consolemap: improve UNI_*() macros definitions

Use FIELD_GET() and GENMASK() helpers instead of direct shifts and ANDs.
This makes the code even more obvious. I didn't know about the helpers
at the time of writing the macros.

Suggested-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Link: https://lore.kernel.org/r/20220614090537.15557-6-jslaby@suse.cz
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/vt/consolemap.c