summaryrefslogtreecommitdiff
path: root/drivers/video/fbdev/core/bitblit.c
diff options
context:
space:
mode:
authorJiri Slaby <jslaby@suse.cz>2020-06-15 09:48:57 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2020-06-24 17:08:33 +0200
commit4dfa3c54f908d7ec20b88671329d6a3205d37d36 (patch)
tree2d80027c99f770725712c6e433a067f47b46c5b1 /drivers/video/fbdev/core/bitblit.c
parentdc219db66ada76669b8ca23a1a9fbef703c9f6bd (diff)
vt: redefine world of cursor macros
The cursor code used to use magic constants, ANDs, ORs, and some macros. Redefine all this to make some sense. In particular: * Drop CUR_DEFAULT, which is CUR_UNDERLINE. CUR_DEFAULT was used only for cur_default variable initialization, so use CUR_UNDERLINE there to make obvious what's the default. * Drop CUR_HWMASK. Instead, define CUR_SIZE() which explains it more. And use it all over the places. * Define few more masks and bits which will be used in next patches instead of magic constants. * Define CUR_MAKE to build up cursor value. Signed-off-by: Jiri Slaby <jslaby@suse.cz> Cc: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com> Cc: dri-devel@lists.freedesktop.org Cc: linux-fbdev@vger.kernel.org Link: https://lore.kernel.org/r/20200615074910.19267-25-jslaby@suse.cz Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/video/fbdev/core/bitblit.c')
-rw-r--r--drivers/video/fbdev/core/bitblit.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/video/fbdev/core/bitblit.c b/drivers/video/fbdev/core/bitblit.c
index c750470a31ec..3b002b365a5a 100644
--- a/drivers/video/fbdev/core/bitblit.c
+++ b/drivers/video/fbdev/core/bitblit.c
@@ -325,7 +325,7 @@ static void bit_cursor(struct vc_data *vc, struct fb_info *info, int mode,
ops->p->cursor_shape = vc->vc_cursor_type;
cursor.set |= FB_CUR_SETSHAPE;
- switch (ops->p->cursor_shape & CUR_HWMASK) {
+ switch (CUR_SIZE(ops->p->cursor_shape)) {
case CUR_NONE:
cur_height = 0;
break;