# --- T2-COPYRIGHT-BEGIN --- # t2/package/*/xf86-video-rendition/01-fb-base-and-ucode-cursor-overlap.patch # Copyright (C) 2026 The T2 SDE Project # SPDX-License-Identifier: GPL-2.0 or patched project license # --- T2-COPYRIGHT-END --- --- a/src/accelX.c 2026-07-12 13:16:43.158866381 +0200 +++ b/src/accelX.c 2026-07-12 13:20:59.588609408 +0200 @@ -344,7 +344,7 @@ pRendition->board.mode.virtualheight)); verite_out32(iob, P2(pRendition->board.mode.bitsperpixel, pRendition->board.mode.pixelformat)); - verite_out32(iob, MC_SIZE); + verite_out32(iob, pRendition->board.fbOffset); verite_out32(iob, (pRendition->board.mode.virtualwidth)* (pRendition->board.mode.bitsperpixel>>3)); @@ -519,7 +519,7 @@ pRendition->board.mode.virtualheight)); verite_out32(iob, P2(pRendition->board.mode.bitsperpixel, pRendition->board.mode.pixelformat)); - verite_out32(iob, MC_SIZE); + verite_out32(iob, pRendition->board.fbOffset); verite_out32(iob, pRendition->board.mode.virtualwidth * (pRendition->board.mode.bitsperpixel>>3)); --- a/src/rendition.c 2026-07-12 13:16:43.158906584 +0200 +++ b/src/rendition.c 2026-07-12 13:20:47.720435391 +0200 @@ -852,25 +852,14 @@ if (!pScreenInfo->chipset) pScreenInfo->chipset = (char *)renditionChipsets[0].name; - if(!xf86ReturnOptValBool(pRendition->Options, OPTION_SW_CURSOR,0)){ - if(!pRendition->board.rotate) - /* Do preemtive things for HW cursor */ - RenditionHWCursorPreInit(pScreenInfo); - else{ - xf86DrvMsg(pScreenInfo->scrnIndex, X_WARNING, - "Hardware cursor not supported on rotated screen\n"); - xf86DrvMsg(pScreenInfo->scrnIndex, X_INFO, - "Software cursor activated\n"); - } - } - else - xf86DrvMsg(pScreenInfo->scrnIndex, X_CONFIG, - "Software cursor selected\n"); - /* Unmapping delayed until after micrcode loading */ /****************************************/ /* Reserve memory and load the microcode */ /****************************************/ + /* The microcode occupies a fixed region [0, MC_SIZE) at the start of + * video memory, so it has to claim its share of fbOffset before any + * other consumer (notably the HW cursor) carves memory out below the + * framebuffer. */ #if USE_ACCEL if (!xf86ReturnOptValBool(pRendition->Options, OPTION_NOACCEL,0) && !pRendition->board.shadowfb) { @@ -892,6 +881,21 @@ ("Skipping acceleration\n")); #endif + if(!xf86ReturnOptValBool(pRendition->Options, OPTION_SW_CURSOR,0)){ + if(!pRendition->board.rotate) + /* Do preemtive things for HW cursor */ + RenditionHWCursorPreInit(pScreenInfo); + else{ + xf86DrvMsg(pScreenInfo->scrnIndex, X_WARNING, + "Hardware cursor not supported on rotated screen\n"); + xf86DrvMsg(pScreenInfo->scrnIndex, X_INFO, + "Software cursor activated\n"); + } + } + else + xf86DrvMsg(pScreenInfo->scrnIndex, X_CONFIG, + "Software cursor selected\n"); + #ifdef DEBUG ErrorF("PreInit OK...!!!!\n"); sleep(2);