#define OVC_OGAMC1 0x38020
#define OVC_OGAMC0 0x38024
+#define OACOMD 0x30168
+#define OV_ENBL 0x1
+
/*
* Some BIOS scratch area registers. The 845 (and 830?) store the amount
* of video memory available to the BIOS in SWF1.
break;
case PVRSRV_PIXEL_FORMAT_ARGB8888:
default:
- uPlaneFormat = DISPPLANE_32BPP;
+ uPlaneFormat = DISPPLANE_32BPP_NO_ALPHA;
break;
}
struct drm_psb_private *dev_priv =
(struct drm_psb_private *) psDevInfo->psDrmDevice->dev_private;
u32 uDspCntr = 0;
+ u32 uOAEn;
if (!ospm_power_using_hw_begin(OSPM_DISPLAY_ISLAND, false))
return;
+ /* Overlay A command register */
+ uOAEn = PSB_RVDC32(OACOMD);
+
uDspCntr = PSB_RVDC32(DSPACNTR);
uDspCntr &= ~(0xf << 26);
- uDspCntr |= psDevInfo->uPlaneACntr;
+
+ if ((uOAEn & OV_ENBL) && (psDevInfo->uPlaneACntr == DISPPLANE_32BPP_NO_ALPHA))
+ uDspCntr |= DISPPLANE_32BPP;
+ else
+ uDspCntr |= psDevInfo->uPlaneACntr;
PSB_WVDC32(uDspCntr, DSPACNTR);
PSB_WVDC32(psDevInfo->uPlaneAStride, DSPASTRIDE);
PSB_WVDC32(psDevInfo->uPlaneAPos, DSPAPOS);
PSB_WVDC32(psDevInfo->uPlaneASize, DSPASIZE);
+
#ifdef CONFIG_MDFD_HDMI
/*TODO: fully support HDMI later*/
/*PSB_WVDC32(psDevInfo->uPlaneBCntr, DSPBCNTR);*/