Date: Sun, 6 May 2012 17:46:10 GMT From: Robert Watson <rwatson@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 210745 for review Message-ID: <201205061746.q46HkAwB043753@skunkworks.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://p4web.freebsd.org/@@210745?ac=10 Change 210745 by rwatson@rwatson_svr_ctsrd_mipsbuild on 2012/05/06 17:46:02 Fix several nits in the initialisation and writing of the blend register by the MTL driver. Affected files ... .. //depot/projects/ctsrd/beribsd/src/sys/dev/terasic/mtl/terasic_mtl.c#4 edit .. //depot/projects/ctsrd/beribsd/src/sys/dev/terasic/mtl/terasic_mtl_reg.c#5 edit Differences ... ==== //depot/projects/ctsrd/beribsd/src/sys/dev/terasic/mtl/terasic_mtl.c#4 (text+ko) ==== @@ -82,12 +82,13 @@ * last. */ error = terasic_mtl_syscons_attach(sc); - if (error == 0) - return (0); + if (error) + goto error; terasic_mtl_blend_default_set(sc, TERASIC_MTL_COLOR_BLACK); terasic_mtl_blend_pixel_set(sc, TERASIC_MTL_ALPHA_TRANSPARENT); terasic_mtl_blend_textfg_set(sc, TERASIC_MTL_ALPHA_OPAQUE); terasic_mtl_blend_textbg_set(sc, TERASIC_MTL_ALPHA_OPAQUE); + return (0); error: terasic_mtl_text_detach(sc); terasic_mtl_pixel_detach(sc); ==== //depot/projects/ctsrd/beribsd/src/sys/dev/terasic/mtl/terasic_mtl_reg.c#5 (text+ko) ==== @@ -161,6 +161,7 @@ terasic_mtl_reg_blend_get(sc, &v); v &= ~TERASIC_MTL_BLEND_DEFAULT_MASK; v |= colour << TERASIC_MTL_BLEND_DEFAULT_SHIFT; + terasic_mtl_reg_blend_set(sc, v); TERASIC_MTL_UNLOCK(sc); } @@ -173,6 +174,7 @@ terasic_mtl_reg_blend_get(sc, &v); v &= ~TERASIC_MTL_BLEND_PIXEL_MASK; v |= alpha << TERASIC_MTL_BLEND_PIXEL_SHIFT; + terasic_mtl_reg_blend_set(sc, v); TERASIC_MTL_UNLOCK(sc); } @@ -185,6 +187,7 @@ terasic_mtl_reg_blend_get(sc, &v); v &= ~TERASIC_MTL_BLEND_TEXTFG_MASK; v |= alpha << TERASIC_MTL_BLEND_TEXTFG_SHIFT; + terasic_mtl_reg_blend_set(sc, v); TERASIC_MTL_UNLOCK(sc); } @@ -197,6 +200,7 @@ terasic_mtl_reg_blend_get(sc, &v); v &= ~TERASIC_MTL_BLEND_TEXTBG_MASK; v |= alpha << TERASIC_MTL_BLEND_TEXTBG_SHIFT; + terasic_mtl_reg_blend_set(sc, v); TERASIC_MTL_UNLOCK(sc); }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201205061746.q46HkAwB043753>