Re: [PATCH] Use 16bpp when running in virt and on XenSource gfx
On Wed, Apr 27, 2016 at 11:59:43AM -0400, Adam Jackson wrote: > On Tue, 2016-04-26 at 13:57 +0200, Stefan Dirsch wrote: > > From: Frederic Crozat> > > > Due to graphics corruption default to 16bpp in virt instead of 24 (Fedora). > > Do the same on XenSource gfx, which suffers from the same issue. > > remote: I: patch #83711 updated using rev > 82db44fe8a726a4a1192b1b93992b642d0ec17b3. > remote: I: 1 patch(es) updated to state Accepted. > To ssh://git.freedesktop.org/git/xorg/driver/xf86-video-cirrus >23da607..82db44f master -> master Nice. Thanks for pushing! Stefan Public Key available -- Stefan Dirsch (Res. & Dev.) SUSE LINUX GmbH Tel: 0911-740 53 0Maxfeldstraße 5 FAX: 0911-740 53 479 D-90409 Nürnberg http://www.suse.deGermany --- SUSE Linux GmbH, GF: Felix Imendörffer, Jane Smithard, Graham Norton, HRB 21284 (AG Nürnberg) --- ___ xorg-devel@lists.x.org: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: https://lists.x.org/mailman/listinfo/xorg-devel
Re: [PATCH] Use 16bpp when running in virt and on XenSource gfx
On Tue, 2016-04-26 at 13:57 +0200, Stefan Dirsch wrote: > From: Frederic Crozat> > Due to graphics corruption default to 16bpp in virt instead of 24 (Fedora). > Do the same on XenSource gfx, which suffers from the same issue. remote: I: patch #83711 updated using rev 82db44fe8a726a4a1192b1b93992b642d0ec17b3. remote: I: 1 patch(es) updated to state Accepted. To ssh://git.freedesktop.org/git/xorg/driver/xf86-video-cirrus 23da607..82db44f master -> master - ajax ___ xorg-devel@lists.x.org: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: https://lists.x.org/mailman/listinfo/xorg-devel
Re: [PATCH] Use 16bpp when running in virt and on XenSource gfx
> From: Stefan Dirsch> Date: Tue, 26 Apr 2016 11:45:38 +0200 > > From: Frederic Crozat > > Due to graphics corruption default to 16bpp in virt instead of 24 (Fedora). > Do the same on XenSource gfx, which suffers from the same issue. I think using magic numbers like that is unhelpful, especially without comments. > --- > src/alp_driver.c | 11 ++- > 1 file changed, 10 insertions(+), 1 deletion(-) > > diff --git a/src/alp_driver.c b/src/alp_driver.c > index da31321..6abb476 100644 > --- a/src/alp_driver.c > +++ b/src/alp_driver.c > @@ -466,6 +466,7 @@ AlpPreInit(ScrnInfoPtr pScrn, int flags) > vgaHWPtr hwp; > MessageType from, from1; > int i; > + int defaultdepth; > int depth_flags; > ClockRangePtr clockRanges; > char *s; > @@ -551,11 +552,19 @@ AlpPreInit(ScrnInfoPtr pScrn, int flags) > depth_flags |= Support32bppFb | > SupportConvert32to24 | > PreferConvert32to24; > + > + /* use 16bpp in virt */ > + if (((pCir->PciInfo->subvendor_id & 0x) == 0x1af4) || > + ((pCir->PciInfo->subvendor_id & 0x) == 0x5853)) > + defaultdepth = 16; > + else > + defaultdepth = 24; > + > /* >* The first thing we should figure out is the depth, bpp, etc. >* We support both 24bpp and 32bpp layouts, so indicate that. >*/ > - if (!xf86SetDepthBpp(pScrn, 0, 0, 24, depth_flags)) { > + if (!xf86SetDepthBpp(pScrn, 0, 0, defaultdepth, depth_flags)) { > return FALSE; > } else { > /* Check that the returned depth is one we support */ > -- > 2.6.2 > > ___ > xorg-devel@lists.x.org: X.Org development > Archives: http://lists.x.org/archives/xorg-devel > Info: https://lists.x.org/mailman/listinfo/xorg-devel > > ___ xorg-devel@lists.x.org: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: https://lists.x.org/mailman/listinfo/xorg-devel
[PATCH] Use 16bpp when running in virt and on XenSource gfx
From: Frederic CrozatDue to graphics corruption default to 16bpp in virt instead of 24 (Fedora). Do the same on XenSource gfx, which suffers from the same issue. --- src/alp_driver.c | 11 ++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/alp_driver.c b/src/alp_driver.c index da31321..6abb476 100644 --- a/src/alp_driver.c +++ b/src/alp_driver.c @@ -466,6 +466,7 @@ AlpPreInit(ScrnInfoPtr pScrn, int flags) vgaHWPtr hwp; MessageType from, from1; int i; + int defaultdepth; int depth_flags; ClockRangePtr clockRanges; char *s; @@ -551,11 +552,19 @@ AlpPreInit(ScrnInfoPtr pScrn, int flags) depth_flags |= Support32bppFb | SupportConvert32to24 | PreferConvert32to24; + + /* use 16bpp in virt */ + if (((pCir->PciInfo->subvendor_id & 0x) == 0x1af4) || + ((pCir->PciInfo->subvendor_id & 0x) == 0x5853)) + defaultdepth = 16; + else + defaultdepth = 24; + /* * The first thing we should figure out is the depth, bpp, etc. * We support both 24bpp and 32bpp layouts, so indicate that. */ - if (!xf86SetDepthBpp(pScrn, 0, 0, 24, depth_flags)) { + if (!xf86SetDepthBpp(pScrn, 0, 0, defaultdepth, depth_flags)) { return FALSE; } else { /* Check that the returned depth is one we support */ -- 2.6.2 ___ xorg-devel@lists.x.org: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: https://lists.x.org/mailman/listinfo/xorg-devel