Skip to content

Commit

Permalink
[PATCH] nvidiafb: Fix absence of cursor in nvidiafb
Browse files Browse the repository at this point in the history
A recent change in nvidiafb caused nvidiafb_cursor to always return -ENXIO
instead of using the soft_cursor.  This will happen if the parameter "hwcur"
is not set, which happens to be the default.

Signed-off-by: Antonino Daplas <adaplas@pol.net>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
  • Loading branch information
Antonino A. Daplas authored and Linus Torvalds committed Sep 21, 2005
1 parent c90eef8 commit 7a48242
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
1 change: 1 addition & 0 deletions drivers/video/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -650,6 +650,7 @@ config FB_NVIDIA
select FB_CFB_FILLRECT
select FB_CFB_COPYAREA
select FB_CFB_IMAGEBLIT
select FB_SOFT_CURSOR
help
This driver supports graphics boards with the nVidia chips, TNT
and newer. For very old chipsets, such as the RIVA128, then use
Expand Down
5 changes: 4 additions & 1 deletion drivers/video/nvidia/nvidia.c
Original file line number Diff line number Diff line change
Expand Up @@ -893,7 +893,7 @@ static int nvidiafb_cursor(struct fb_info *info, struct fb_cursor *cursor)
int i, set = cursor->set;
u16 fg, bg;

if (!hwcur || cursor->image.width > MAX_CURS || cursor->image.height > MAX_CURS)
if (cursor->image.width > MAX_CURS || cursor->image.height > MAX_CURS)
return -ENXIO;

NVShowHideCursor(par, 0);
Expand Down Expand Up @@ -1356,6 +1356,9 @@ static int __devinit nvidia_set_fbinfo(struct fb_info *info)
info->pixmap.size = 8 * 1024;
info->pixmap.flags = FB_PIXMAP_SYSTEM;

if (!hwcur)
info->fbops->fb_cursor = soft_cursor;

info->var.accel_flags = (!noaccel);

switch (par->Architecture) {
Expand Down

0 comments on commit 7a48242

Please sign in to comment.