[PATCH] 0002-sgi-o2-gbe-mte-init.diff

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Very simple test patch, broke nothing for me.

diff --git a/drivers/video/gbefb.c b/drivers/video/gbefb.c
index ed732a8..1d3b599 100644
--- a/drivers/video/gbefb.c
+++ b/drivers/video/gbefb.c
@@ -31,6 +31,7 @@
 #include <asm/tlbflush.h>
 
 #include <video/gbe.h>
+#include <video/crmfbreg.h>
 
 static struct sgi_gbe *gbe;
 
@@ -651,6 +652,7 @@ static void gbe_set_timing_info(struct gbe_timing_info *timing)
 static int gbefb_set_par(struct fb_info *info)
 {
 	int i;
+	unsigned int mte_current_mode; /* temporary  */
 	unsigned int val;
 	int wholeTilesX, partTilesX, maxPixelsPerTileX;
 	int height_pix;
@@ -695,6 +697,16 @@ static int gbefb_set_par(struct fb_info *info)
 	/* Initialize interrupts */
 	gbe->sgi_gbe_vt.vt_intr01 = 0xffffffff;
 	gbe->sgi_gbe_vt.vt_intr23 = 0xffffffff;
+	
+	/* Initialize MTE */
+	mte_current_mode = MTE_MODE_DST_ECC | 
+			    (MTE_TLB_A << MTE_DST_TLB_SHIFT) |
+			    (MTE_TLB_A << MTE_SRC_TLB_SHIFT) |
+			    (MTE_DEPTH_8 << MTE_DEPTH_SHIFT) |
+			    MTE_MODE_COPY; 
+	gbe->sgi_crm_mte.crm_mte_mode =  mte_current_mode;
+	gbe->sgi_crm_mte.crm_mte_dst_y_step = 1;
+	gbe->sgi_crm_mte.crm_mte_src_y_step = 1;
 
 	/* HACK:
 	   The GBE hardware uses a tiled memory to screen mapping. Tiles are



      



[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux