Skip to contentSkip to conversation

2.5.44 - neofb-0.4

PATCH In review Denis Oliver Kropp 2 participants 2 messages Oct 30, 2002 – Oct 31, 2002

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 2.5.44 - neofb-0.4

Changes:

- Toshiba Libretto support
- allow modes larger than LCD size if LCD is disabled
- keep BIOS settings if internal/external display haven't been enabled explicitly

(all changes by Thomas J. Moore <[email protected]>)

Signature · 8 lines
  Denis Oliver Kropp

.------------------------------------------.
| DirectFB - Hardware accelerated graphics |
| http://www.directfb.org/                 |
"------------------------------------------"

                            Convergence GmbH
drivers/char/toshiba.c +1 -1
diff -Naur linux-2.4.20-rc1/drivers/char/toshiba.c linux-2.4.20-rc1-neofb-0.4/drivers/char/toshiba.c
@@ -217,7 +217,7 @@
 /*
  * Put the laptop into System Management Mode
  */
-static int tosh_smm(SMMRegisters *regs)
+int tosh_smm(SMMRegisters *regs)
 {
 	int eax;
 
drivers/video/neofb.c +77 -18

198 lines not on this page · raw message

drivers/video/neofb.h +1 -0
diff -Naur linux-2.4.20-rc1/drivers/video/neofb.h linux-2.4.20-rc1-neofb-0.4/drivers/video/neofb.h
@@ -154,6 +154,7 @@
   int lcd_stretch;
   int internal_display;
   int external_display;
+  int libretto;
 
   struct {
     u16 red, green, blue, transp;
#1 lore raw

Em Wed, Oct 30, 2002 at 05:56:21PM +0100, Denis Oliver Kropp escreveu:

drivers/video/neofb.c line 96

Quoted 9 lines

diff -Naur linux-2.4.20-rc1/drivers/video/neofb.c linux-2.4.20-rc1-neofb-0.4/drivers/video/neofb.c

drivers/video/neofb.c +1 -0
 static int disabled   = 0;
 static int internal   = 0;
 static int external   = 0;
+static int libretto   = 0;
 static int nostretch  = 0;
 static int nopciburst = 0;

Could you just leave those globas uninitialized? That way it goes to the .bss that will get zeroed anyway and the image will be slightly smaller.

Quoted 7 lines
drivers/video/neofb.c +7 -0
+static struct fb_var_screeninfo __devinitdata neofb_var800x480x8 = {
+	accel_flags:	FB_ACCELF_TEXT,
+	xres:		800,
+	yres:		480,
+	xres_virtual:   800,
+	yres_virtual:   30000,
+	bits_per_pixel: 8,

drivers/video/neofb.c line 1839

Quoted 10 lines
drivers/video/neofb.c +10 -0
+	pixclock:	25000,
+	left_margin:	88,
+	right_margin:	40,
+	upper_margin:	23,
+	lower_margin:	1,
+	hsync_len:	128,
+	vsync_len:	4,
+	sync:		FB_SYNC_HOR_HIGH_ACT | FB_SYNC_VERT_HIGH_ACT,
+	vmode:		FB_VMODE_NONINTERLACED
+};

Please use ANSI C designated elements style, also supported by gcc and that was the reason for massive conversion all over the kernel, it should look like this:

static struct fb_var_screeninfo __devinitdata neofb_var800x480x8 = {
	.accel_flags	= FB_ACCELF_TEXT,
	.xres		= 800,
	.yres		= 480,

<snip>

drivers/video/neofb.c line 1843

Quoted 3 lines

static struct fb_var_screeninfo __devinitdata neofb_var1024x768x8 = {

drivers/video/neofb.c +0 -0
 	accel_flags:	FB_ACCELF_TEXT,
 	xres:		1024,

ditto