Commit c7acff98 authored by Ben Skeggs's avatar Ben Skeggs

drm/nouveau/fbcon/nv50-: use NVIDIA's headers for imageblit()

Signed-off-by: default avatarBen Skeggs <bskeggs@redhat.com>
Reviewed-by: default avatarLyude Paul <lyude@redhat.com>
parent 5755b1ea
...@@ -123,14 +123,16 @@ nv50_fbcon_imageblit(struct fb_info *info, const struct fb_image *image) ...@@ -123,14 +123,16 @@ nv50_fbcon_imageblit(struct fb_info *info, const struct fb_image *image)
if (ret) if (ret)
return ret; return ret;
PUSH_NVSQ(push, NV502D, 0x0814, bg, PUSH_MTHD(push, NV502D, SET_PIXELS_FROM_CPU_COLOR0, bg,
0x0818, fg); SET_PIXELS_FROM_CPU_COLOR1, fg);
PUSH_NVSQ(push, NV502D, 0x0838, image->width,
0x083c, image->height); PUSH_MTHD(push, NV502D, SET_PIXELS_FROM_CPU_SRC_WIDTH, image->width,
PUSH_NVSQ(push, NV502D, 0x0850, 0, SET_PIXELS_FROM_CPU_SRC_HEIGHT, image->height);
0x0854, image->dx,
0x0858, 0, PUSH_MTHD(push, NV502D, SET_PIXELS_FROM_CPU_DST_X0_FRAC, 0,
0x085c, image->dy); SET_PIXELS_FROM_CPU_DST_X0_INT, image->dx,
SET_PIXELS_FROM_CPU_DST_Y0_FRAC, 0,
SET_PIXELS_FROM_CPU_DST_Y0_INT, image->dy);
dwords = ALIGN(ALIGN(image->width, 8) * image->height, 32) >> 5; dwords = ALIGN(ALIGN(image->width, 8) * image->height, 32) >> 5;
while (dwords) { while (dwords) {
...@@ -142,7 +144,7 @@ nv50_fbcon_imageblit(struct fb_info *info, const struct fb_image *image) ...@@ -142,7 +144,7 @@ nv50_fbcon_imageblit(struct fb_info *info, const struct fb_image *image)
dwords -= count; dwords -= count;
PUSH_NVNI(push, NV502D, 0x0860, data, count); PUSH_NINC(push, NV502D, PIXELS_FROM_CPU_DATA, data, count);
data += count; data += count;
} }
......
...@@ -123,14 +123,16 @@ nvc0_fbcon_imageblit(struct fb_info *info, const struct fb_image *image) ...@@ -123,14 +123,16 @@ nvc0_fbcon_imageblit(struct fb_info *info, const struct fb_image *image)
if (ret) if (ret)
return ret; return ret;
PUSH_NVSQ(push, NV902D, 0x0814, bg, PUSH_MTHD(push, NV902D, SET_PIXELS_FROM_CPU_COLOR0, bg,
0x0818, fg); SET_PIXELS_FROM_CPU_COLOR1, fg);
PUSH_NVSQ(push, NV902D, 0x0838, image->width,
0x083c, image->height); PUSH_MTHD(push, NV902D, SET_PIXELS_FROM_CPU_SRC_WIDTH, image->width,
PUSH_NVSQ(push, NV902D, 0x0850, 0, SET_PIXELS_FROM_CPU_SRC_HEIGHT, image->height);
0x0854, image->dx,
0x0858, 0, PUSH_MTHD(push, NV902D, SET_PIXELS_FROM_CPU_DST_X0_FRAC, 0,
0x085c, image->dy); SET_PIXELS_FROM_CPU_DST_X0_INT, image->dx,
SET_PIXELS_FROM_CPU_DST_Y0_FRAC, 0,
SET_PIXELS_FROM_CPU_DST_Y0_INT, image->dy);
dwords = ALIGN(ALIGN(image->width, 8) * image->height, 32) >> 5; dwords = ALIGN(ALIGN(image->width, 8) * image->height, 32) >> 5;
while (dwords) { while (dwords) {
...@@ -142,7 +144,7 @@ nvc0_fbcon_imageblit(struct fb_info *info, const struct fb_image *image) ...@@ -142,7 +144,7 @@ nvc0_fbcon_imageblit(struct fb_info *info, const struct fb_image *image)
dwords -= count; dwords -= count;
PUSH_NVNI(push, NV902D, 0x0860, data, count); PUSH_NINC(push, NV902D, PIXELS_FROM_CPU_DATA, data, count);
data += count; data += count;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment