mirror of
https://github.com/X11Libre/xserver.git
synced 2026-10-17 00:32:57 +00:00
Add a memory_base variable and use it.
This commit is contained in:
parent
f5916edb17
commit
f4bcd36a38
8 changed files with 11 additions and 12 deletions
|
|
@ -74,8 +74,8 @@ mgaScreenInit (KdScreenInfo *screen)
|
|||
screen->dumb = TRUE;
|
||||
|
||||
fprintf (stderr, "vesa mapping is %d\n", mgas->vesa.mapping);
|
||||
#endif
|
||||
mgas->screen = mgas->vesa.fb;
|
||||
#endif
|
||||
screen->memory_base = mgas->vesa.fb;
|
||||
|
||||
memory = mgas->vesa.fb_size;
|
||||
screen_size = screen->fb[0].byteStride * screen->height;
|
||||
|
|
|
|||
|
|
@ -96,7 +96,6 @@ typedef struct _mgaCardInfo {
|
|||
|
||||
typedef struct _mgaScreenInfo {
|
||||
VesaScreenPrivRec vesa;
|
||||
CARD8 *screen;
|
||||
|
||||
int pitch;
|
||||
int pw;
|
||||
|
|
|
|||
|
|
@ -102,7 +102,7 @@ mgaPrepareSolid (PixmapPtr pPixmap, int alu, Pixel pm, Pixel fg)
|
|||
cmd = MGA_OPCOD_TRAP | MGA_DWGCTL_SOLID | MGA_DWGCTL_ARZERO | MGA_DWGCTL_SGNZERO |
|
||||
MGA_DWGCTL_SHIFTZERO | mgaRop[alu];
|
||||
|
||||
dst_org = (int)pPixmap->devPrivate.ptr - (int)mgas->screen;
|
||||
dst_org = (int)pPixmap->devPrivate.ptr - (int)pScreenPriv->screen->memory_base;
|
||||
|
||||
mgaSetup (pPixmap->drawable.pScreen, 5);
|
||||
|
||||
|
|
@ -152,8 +152,8 @@ mgaPrepareCopy (PixmapPtr pSrcPixmap, PixmapPtr pDstPixmap,
|
|||
|
||||
mgaSetup (pSrcPixmap->drawable.pScreen, 7);
|
||||
|
||||
MGA_OUT32 (mmio, MGA_REG_SRCORG, ((int)pSrcPixmap->devPrivate.ptr - (int)mgas->screen));
|
||||
MGA_OUT32 (mmio, MGA_REG_DSTORG, ((int)pDstPixmap->devPrivate.ptr - (int)mgas->screen));
|
||||
MGA_OUT32 (mmio, MGA_REG_SRCORG, ((int)pSrcPixmap->devPrivate.ptr - (int)pScreenPriv->screen->memory_base));
|
||||
MGA_OUT32 (mmio, MGA_REG_DSTORG, ((int)pDstPixmap->devPrivate.ptr - (int)pScreenPriv->screen->memory_base));
|
||||
MGA_OUT32 (mmio, MGA_REG_PITCH, pDstPixmap->devKind / (pDstPixmap->drawable.bitsPerPixel >> 3));
|
||||
src_pitch = pSrcPixmap->devKind / (pSrcPixmap->drawable.bitsPerPixel >> 3);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue