--- 2.6.14/include/video/impact.h	2011-07-25 00:06:58 +0200
+++ 2.6.14/include/video/impact.h	2018-08-21 00:01:31 +0200
@@ -194,10 +194,12 @@
 #define IMPACT_BLEND_ALPHA	0x0704c900
 
 #ifdef  __KERNEL__
-extern void impact_earlychar(unsigned char c);
-extern void impact_earlystring(char *s);
-extern void impact_earlyinit(void);
-extern void setup_impact_earlycons(void);
+extern void __init impact_earlychar(unsigned char c);
+extern void __init impact_earlystring(char *s);
+extern void __init impact_earlyinit(void);
+extern void __init setup_impact_earlycons(void);
+extern int  __init impact_earlyprintf(const char*, ...);
+extern int impact_earlyvprintf(const char*, va_list);
 #endif
 
 struct impact_cf_args


--- 2.6.14/drivers/video/impact.c	2011-11-01 20:16:43 +0100
+++ 2.6.14/drivers/video/impact.c	2018-09-20 22:02:20 +0200
@@ -101,11 +101,10 @@ struct impact_par {
 	struct {
 		/* DMA pool management, txtbl[0..num-1] passed to card */
-		unsigned int *txtbl;  /* txtbl[i] = pgidx(phys[i]) */
-		unsigned int txnum;   /* valid: txtbl[0..txnum-1] */
+		unsigned int *txtbl;  /* txtbl[i] = pgidx(dma_addr(virt[i])) */
+		unsigned int txnum;   /* valid: txtbl[0..txnum-1] --> card */
 		unsigned int txmax;   /* alloc: txtbl[0..txmax-1] */
-		unsigned long txphys; /* txphys = dma_addr(txtbl) */
+		unsigned long txphys; /* txphys = dma_addr(txtbl) --> card */
 		/* kernel DMA pools, the actual DMA-buffers */
 		void*         *virt;  /* virt[0..txnum-1]: dma-page-addresses */
-		unsigned long *phys;  /* phys[i] = dma_addr(virt[i]) */
 		unsigned int size;
 		unsigned long uaddr;  /* DMA-buffer's userland-address */
@@ -357,17 +356,14 @@ impact_resizekpool(struct fb_info *p, in
 			ClearPageReserved(dma_virt_to_page(PAR(p).pools[pool].virt[i]));
 			dma_free_coherent(NULL, PAGE_SIZE, PAR(p).pools[pool].virt[i],
-					PAR(p).pools[pool].phys[i]);
+					PAR(p).pools[pool].txtbl[i] << PAGE_SHIFT);
 		}
-		vfree(PAR(p).pools[pool].phys);
 		vfree(PAR(p).pools[pool].virt);
 	}
 	impact_alloctxtbl(p, pool, pages);
 	PAR(p).pools[pool].virt = vmalloc(pages*sizeof(unsigned long));
-	PAR(p).pools[pool].phys = vmalloc(pages*sizeof(unsigned long));
 	for (i = 0; i < PAR(p).pools[pool].txnum; i++) {
 		PAR(p).pools[pool].virt[i] =
 			dma_alloc_coherent(NULL, PAGE_SIZE, &dma_handle, GFP_KERNEL);
 		SetPageReserved(dma_virt_to_page(PAR(p).pools[pool].virt[i]));
-		PAR(p).pools[pool].phys[i] = dma_handle;
 		PAR(p).pools[pool].txtbl[i] = dma_handle >> PAGE_SHIFT;
 	}
@@ -816,6 +812,5 @@ impact_mmap(struct fb_info *p, struct fi
 			vma->vm_page_prot = pgprot_noncached(vma->vm_page_prot);
 		for (start = vma->vm_start, i = 0; i < n; i++) {
-			if (remap_pfn_range(vma, start,
-					PAR(p).pools[pool].phys[i] >> PAGE_SHIFT,
+			if (remap_pfn_range(vma, start, PAR(p).pools[pool].txtbl[i],
 					PAGE_SIZE, vma->vm_page_prot)) {
 				PAR(p).pools[pool].uaddr = 0;
@@ -894,5 +889,5 @@ static inline void impact_earlyrect(int
 }
 
-static void
+static void __init
 impact_paintchar(int x, int y, unsigned char *b, unsigned c, unsigned a)
 {
@@ -913,5 +908,5 @@ impact_paintchar(int x, int y, unsigned
 		*cfifo = IMPACT_CMD_CHAR(*b++ << 24);
 }
-static void impact_earlyhwinit(void)
+static void __init impact_earlyhwinit(void)
 {
 	impact_inithq(MMIO_FIXED);
@@ -956,5 +951,5 @@ early = {
 };
 
-void impact_earlychar(unsigned char c)
+void __init impact_earlychar(unsigned char c)
 {
 	if (early.posx != -1) {
@@ -985,5 +980,5 @@ out:
 	}
 }
-void impact_earlystring(char *s)
+void __init impact_earlystring(char *s)
 {
 	while (*s)
@@ -992,6 +987,7 @@ void impact_earlystring(char *s)
 static void impact_earlywrite(struct console *con, const char *s, unsigned n)
 {
-	while (n-- && *s)
-		impact_earlychar(*s++);
+	if (early.posx > -1) /* called after .init* sections are disbanded ? */
+		while (n-- && *s)
+			impact_earlychar(*s++);
 }
 void __init impact_earlyinit(void)
@@ -1017,4 +1013,30 @@ void __init setup_impact_earlycons(void)
 }
 
+static int __init early_vprintf(const char *fmt, va_list args)
+{                                                    
+	static char buf[256];
+	int n;
+	if (KERN_SOH_ASCII == *fmt) fmt++;
+	n = vsnprintf(buf, sizeof(buf), fmt, args);
+	impact_earlystring(buf);
+	return n;
+}
+
+int impact_earlyvprintf(const char *fmt, va_list args)
+{                                                    
+	/* called after .init* sections are disbanded ? */
+	return early.posx > -1 ? early_vprintf(fmt, args):-1;
+}
+
+int __init impact_earlyprintf(const char *fmt, ...)
+{                                                    
+	va_list args;
+	int n;
+	va_start(args, fmt);
+	n = early_vprintf(fmt, args);
+	va_end(args);
+	return n;
+}
+
 /* ------------------------------------------------------------------------- */
 

To be applied after welcomebg.1.diff

--- 2.6.14/drivers/video/impact.c	2011-11-01 20:16:43 +0100
+++ 2.6.14/drivers/video/impact.c	2018-09-20 22:02:20 +0200
@@ -1401,5 +1423,5 @@ static void expand_pixline(struct impact
 
 	for (i = 0; i < sizeof(virt)/sizeof(*virt); i++)
-		virt[i] = phys_to_virt(p->pools[0].phys[i]);
+		virt[i] = phys_to_virt(p->pools[0].txtbl[i] << PAGE_SHIFT);
 
 	for (i = bgbackup.idx[line]; i < bgbackup.idx[line+1]; i++) {
@@ -1434,5 +1456,5 @@ static void flush_pixline(struct impact_
 	int i;
 	for (i = 0; i < PAGES(PITCH(1280)); i++) {
-		void *v = phys_to_virt(p->pools[0].phys[i]);
+		void *v = phys_to_virt(p->pools[0].txtbl[i] << PAGE_SHIFT);
 		int k = PITCH(1280) - i * PAGE_SIZE;
 		if (k > PAGE_SIZE) k = PAGE_SIZE;


