diff options
author | Michel Dänzer <daenzer@vmware.com> | 2009-04-09 09:41:56 +0200 |
---|---|---|
committer | Michel Dänzer <daenzer@vmware.com> | 2009-04-09 09:41:56 +0200 |
commit | 6532aeddacdeda3aa534264741c8648e1c449e76 (patch) | |
tree | d80a54efe562986d3091a1b85927f3aedf7ac74c /src | |
parent | 0c19053975925fed637aaa41d440e0cab8f6b596 (diff) |
Clear the framebuffer before initializing modes.
Fixes garbage being visible shortly on server startup or when VT switching back
to X.
Diffstat (limited to 'src')
-rw-r--r-- | src/radeon_driver.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/radeon_driver.c b/src/radeon_driver.c index 8673f5e1..5a3a27ba 100644 --- a/src/radeon_driver.c +++ b/src/radeon_driver.c @@ -3764,6 +3764,10 @@ Bool RADEONScreenInit(int scrnIndex, ScreenPtr pScreen, } } + /* Clear the framebuffer */ + memset(info->FB + pScrn->fbOffset, 0, + pScrn->virtualY * pScrn->displayWidth * info->CurrentLayout.pixel_bytes); + /* set the modes with desired rotation, etc. */ if (!xf86SetDesiredModes (pScrn)) return FALSE; @@ -5660,6 +5664,10 @@ Bool RADEONEnterVT(int scrnIndex, int flags) pScrn->vtSema = TRUE; + /* Clear the framebuffer */ + memset(info->FB + pScrn->fbOffset, 0, + pScrn->virtualY * pScrn->displayWidth * info->CurrentLayout.pixel_bytes); + if (!xf86SetDesiredModes(pScrn)) return FALSE; |