You can import this changeset into BK by piping this whole message to: '| bk receive [path to repository]' or apply the patch as usual. =================================================================== ChangeSet@1.959, 2002-12-27 15:35:44-08:00, rth@are.twiddle.net [TGAFB] Minor bug fixes to obtain a working TGA console with the new FB API. tgafb.c | 31 +++++++++---------------------- 1 files changed, 9 insertions, 22 deletions diff -Nru a/drivers/video/tgafb.c b/drivers/video/tgafb.c --- a/drivers/video/tgafb.c Fri Dec 27 15:43:57 2002 +++ b/drivers/video/tgafb.c Fri Dec 27 15:43:57 2002 @@ -1,32 +1,16 @@ /* * linux/drivers/video/tgafb.c -- DEC 21030 TGA frame buffer device * - * Copyright (C) 1999,2000 Martin Lucina, Tom Zerucha - * - * $Id: tgafb.c,v 1.12.2.3 2000/04/04 06:44:56 mato Exp $ - * - * This driver is partly based on the original TGA framebuffer device, which - * was partly based on the original TGA console driver, which are - * - * Copyright (C) 1997 Geert Uytterhoeven * Copyright (C) 1995 Jay Estabrook + * Copyright (C) 1997 Geert Uytterhoeven + * Copyright (C) 1999,2000 Martin Lucina, Tom Zerucha + * Copyright (C) 2002 Richard Henderson * * This file is subject to the terms and conditions of the GNU General Public * License. See the file COPYING in the main directory of this archive for * more details. */ -/* KNOWN PROBLEMS/TO DO ===================================================== * - * - * - How to set a single color register on 24-plane cards? - * - * - Hardware cursor/other text acceleration methods - * - * - Some redraws can stall kernel for several seconds - * [This should now be solved by the fast memmove() patch in 2.3.6] - * - * KNOWN PROBLEMS/TO DO ==================================================== */ - #include #include #include @@ -76,6 +60,7 @@ .fb_fillrect = cfb_fillrect, .fb_copyarea = cfb_copyarea, .fb_imageblit = cfb_imageblit, + .fb_cursor = soft_cursor, }; @@ -446,8 +431,10 @@ TGA_WRITE_REG(par, red|(BT485_DATA_PAL<<8),TGA_RAMDAC_REG); TGA_WRITE_REG(par, green|(BT485_DATA_PAL<<8),TGA_RAMDAC_REG); TGA_WRITE_REG(par, blue|(BT485_DATA_PAL<<8),TGA_RAMDAC_REG); + } else if (regno < 16) { + u32 value = (red << 16) | (green << 8) | blue; + ((u32 *)info->pseudo_palette)[regno] = value; } - /* How to set a single color register on 24-plane cards?? */ return 0; } @@ -594,6 +581,7 @@ return -ENOMEM; } memset(all, 0, sizeof(*all)); + pci_set_drvdata(pdev, all); /* Request the mem regions. */ bar0_start = pci_resource_start(pdev, 0); @@ -620,12 +608,11 @@ all->par.tga_type = tga_type; pci_read_config_byte(pdev, PCI_REVISION_ID, &all->par.tga_chip_rev); - pci_set_drvdata(pdev, &all->info); - /* Setup framebuffer. */ all->info.node = NODEV; all->info.flags = FBINFO_FLAG_DEFAULT; all->info.fbops = &tgafb_ops; + all->info.screen_base = (char *) all->par.tga_fb_base; all->info.currcon = -1; all->info.par = &all->par; all->info.pseudo_palette = all->pseudo_palette; =================================================================== This BitKeeper patch contains the following changesets: 1.959 ## Wrapped with gzip_uu ## begin 664 bkpatch3904 M'XL(`+[E##X``[55[V\:1Q#]?/M7C)0OD)IC=^\7AX,5&R<.2J):;ORE4826 MO8$[^;@][2U0J]?_O7.X=1**'"5M`2'MS-NY-^\]Q#.X;="./>MR]@S>F,:- M/671=[LBRTKT*W14OS&&ZL/W[\YO&)M,8)JK:H6_H(/)A#ECMZK,FI?*Y:6I?&=5U:S1*5^; M=?L(;27GDMZ12`(>Q:V(>9BT6F1"J%!@QF4XBD-&M%X>$#^8(:1,9$#?81M( MF2;L$H2?1BEP.11R*!,0T3B(QF$XX*,QYW!D)/PD8,#9!?RWY*=,P\O M+S[!^Z(R%A:;%2R+W["A)X%9.%54H&!G[%U1K8"@H$W5F!+IYJYP)':.4.$. M7E_`^?7,9V\AD`$/V/5GT=G@.U^,<<79V3>6S6S1>3_<%AF:+A?+A:^_6#SD M(FZ)2I"V<:B%7N@HC8-%&H?1,8F?F/?@8!#)E(YQD.PS=13^[7S]"]9'L_8D MZU@&412F;11RSO>Y$\EA[&3Z5.Q2&$CYO^3N/,M@N9CKC6TH=[DQ=SY5N]]H MW>`F,_-:E>@<`B6P0:=-:9&R2=A`#A9UW:&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