diff options
Diffstat (limited to 'drivers/video')
-rw-r--r-- | drivers/video/aty/atyfb_base.c | 2 | ||||
-rw-r--r-- | drivers/video/aty/radeon_i2c.c | 8 | ||||
-rw-r--r-- | drivers/video/backlight/corgi_bl.c | 4 | ||||
-rw-r--r-- | drivers/video/backlight/hp680_bl.c | 2 | ||||
-rw-r--r-- | drivers/video/fb_ddc.c | 6 | ||||
-rw-r--r-- | drivers/video/hitfb.c | 1 | ||||
-rw-r--r-- | drivers/video/intelfb/intelfbhw.c | 6 | ||||
-rw-r--r-- | drivers/video/nvidia/nv_hw.c | 12 | ||||
-rw-r--r-- | drivers/video/nvidia/nv_setup.c | 20 | ||||
-rw-r--r-- | drivers/video/nvidia/nv_type.h | 1 | ||||
-rw-r--r-- | drivers/video/nvidia/nvidia.c | 24 | ||||
-rw-r--r-- | drivers/video/offb.c | 36 | ||||
-rw-r--r-- | drivers/video/pnx4008/pnxrgbfb.c | 5 | ||||
-rw-r--r-- | drivers/video/pnx4008/sdum.c | 2 |
14 files changed, 85 insertions, 44 deletions
diff --git a/drivers/video/aty/atyfb_base.c b/drivers/video/aty/atyfb_base.c index b77b30923928..e815b354c09d 100644 --- a/drivers/video/aty/atyfb_base.c +++ b/drivers/video/aty/atyfb_base.c | |||
@@ -406,7 +406,7 @@ static struct { | |||
406 | { PCI_CHIP_MACH64LB, "3D RAGE LT PRO (Mach64 LB, AGP)", 236, 75, 100, 135, ATI_CHIP_264LTPRO }, | 406 | { PCI_CHIP_MACH64LB, "3D RAGE LT PRO (Mach64 LB, AGP)", 236, 75, 100, 135, ATI_CHIP_264LTPRO }, |
407 | { PCI_CHIP_MACH64LD, "3D RAGE LT PRO (Mach64 LD, AGP)", 230, 100, 100, 135, ATI_CHIP_264LTPRO }, | 407 | { PCI_CHIP_MACH64LD, "3D RAGE LT PRO (Mach64 LD, AGP)", 230, 100, 100, 135, ATI_CHIP_264LTPRO }, |
408 | { PCI_CHIP_MACH64LI, "3D RAGE LT PRO (Mach64 LI, PCI)", 230, 100, 100, 135, ATI_CHIP_264LTPRO | M64F_G3_PB_1_1 | M64F_G3_PB_1024x768 }, | 408 | { PCI_CHIP_MACH64LI, "3D RAGE LT PRO (Mach64 LI, PCI)", 230, 100, 100, 135, ATI_CHIP_264LTPRO | M64F_G3_PB_1_1 | M64F_G3_PB_1024x768 }, |
409 | { PCI_CHIP_MACH64LP, "3D RAGE LT PRO (Mach64 LP, PCI)", 230, 100, 100, 135, ATI_CHIP_264LTPRO }, | 409 | { PCI_CHIP_MACH64LP, "3D RAGE LT PRO (Mach64 LP, PCI)", 230, 100, 100, 135, ATI_CHIP_264LTPRO | M64F_G3_PB_1024x768 }, |
410 | { PCI_CHIP_MACH64LQ, "3D RAGE LT PRO (Mach64 LQ, PCI)", 230, 100, 100, 135, ATI_CHIP_264LTPRO }, | 410 | { PCI_CHIP_MACH64LQ, "3D RAGE LT PRO (Mach64 LQ, PCI)", 230, 100, 100, 135, ATI_CHIP_264LTPRO }, |
411 | 411 | ||
412 | { PCI_CHIP_MACH64GM, "3D RAGE XL (Mach64 GM, AGP 2x)", 230, 83, 63, 135, ATI_CHIP_264XL }, | 412 | { PCI_CHIP_MACH64GM, "3D RAGE XL (Mach64 GM, AGP 2x)", 230, 83, 63, 135, ATI_CHIP_264XL }, |
diff --git a/drivers/video/aty/radeon_i2c.c b/drivers/video/aty/radeon_i2c.c index 676754520099..869725a13c21 100644 --- a/drivers/video/aty/radeon_i2c.c +++ b/drivers/video/aty/radeon_i2c.c | |||
@@ -139,7 +139,13 @@ void radeon_delete_i2c_busses(struct radeonfb_info *rinfo) | |||
139 | int radeon_probe_i2c_connector(struct radeonfb_info *rinfo, int conn, | 139 | int radeon_probe_i2c_connector(struct radeonfb_info *rinfo, int conn, |
140 | u8 **out_edid) | 140 | u8 **out_edid) |
141 | { | 141 | { |
142 | u8 *edid = fb_ddc_read(&rinfo->i2c[conn-1].adapter); | 142 | u32 reg = rinfo->i2c[conn-1].ddc_reg; |
143 | u8 *edid; | ||
144 | |||
145 | OUTREG(reg, INREG(reg) & | ||
146 | ~(VGA_DDC_DATA_OUTPUT | VGA_DDC_CLK_OUTPUT)); | ||
147 | |||
148 | edid = fb_ddc_read(&rinfo->i2c[conn-1].adapter); | ||
143 | 149 | ||
144 | if (out_edid) | 150 | if (out_edid) |
145 | *out_edid = edid; | 151 | *out_edid = edid; |
diff --git a/drivers/video/backlight/corgi_bl.c b/drivers/video/backlight/corgi_bl.c index 2ebbfd95145f..d07ecb53c68b 100644 --- a/drivers/video/backlight/corgi_bl.c +++ b/drivers/video/backlight/corgi_bl.c | |||
@@ -111,7 +111,7 @@ static struct backlight_properties corgibl_data = { | |||
111 | .update_status = corgibl_set_intensity, | 111 | .update_status = corgibl_set_intensity, |
112 | }; | 112 | }; |
113 | 113 | ||
114 | static int __init corgibl_probe(struct platform_device *pdev) | 114 | static int corgibl_probe(struct platform_device *pdev) |
115 | { | 115 | { |
116 | struct corgibl_machinfo *machinfo = pdev->dev.platform_data; | 116 | struct corgibl_machinfo *machinfo = pdev->dev.platform_data; |
117 | 117 | ||
@@ -166,4 +166,4 @@ module_exit(corgibl_exit); | |||
166 | 166 | ||
167 | MODULE_AUTHOR("Richard Purdie <rpurdie@rpsys.net>"); | 167 | MODULE_AUTHOR("Richard Purdie <rpurdie@rpsys.net>"); |
168 | MODULE_DESCRIPTION("Corgi Backlight Driver"); | 168 | MODULE_DESCRIPTION("Corgi Backlight Driver"); |
169 | MODULE_LICENSE("GPLv2"); | 169 | MODULE_LICENSE("GPL"); |
diff --git a/drivers/video/backlight/hp680_bl.c b/drivers/video/backlight/hp680_bl.c index fe1488374f62..e3993213d10e 100644 --- a/drivers/video/backlight/hp680_bl.c +++ b/drivers/video/backlight/hp680_bl.c | |||
@@ -19,7 +19,7 @@ | |||
19 | #include <linux/backlight.h> | 19 | #include <linux/backlight.h> |
20 | 20 | ||
21 | #include <asm/cpu/dac.h> | 21 | #include <asm/cpu/dac.h> |
22 | #include <asm/hp6xx/hp6xx.h> | 22 | #include <asm/hp6xx.h> |
23 | #include <asm/hd64461.h> | 23 | #include <asm/hd64461.h> |
24 | 24 | ||
25 | #define HP680_MAX_INTENSITY 255 | 25 | #define HP680_MAX_INTENSITY 255 |
diff --git a/drivers/video/fb_ddc.c b/drivers/video/fb_ddc.c index 3aa6ebf68f17..f836137a0eda 100644 --- a/drivers/video/fb_ddc.c +++ b/drivers/video/fb_ddc.c | |||
@@ -20,26 +20,26 @@ | |||
20 | static unsigned char *fb_do_probe_ddc_edid(struct i2c_adapter *adapter) | 20 | static unsigned char *fb_do_probe_ddc_edid(struct i2c_adapter *adapter) |
21 | { | 21 | { |
22 | unsigned char start = 0x0; | 22 | unsigned char start = 0x0; |
23 | unsigned char *buf = kmalloc(EDID_LENGTH, GFP_KERNEL); | ||
23 | struct i2c_msg msgs[] = { | 24 | struct i2c_msg msgs[] = { |
24 | { | 25 | { |
25 | .addr = DDC_ADDR, | 26 | .addr = DDC_ADDR, |
27 | .flags = 0, | ||
26 | .len = 1, | 28 | .len = 1, |
27 | .buf = &start, | 29 | .buf = &start, |
28 | }, { | 30 | }, { |
29 | .addr = DDC_ADDR, | 31 | .addr = DDC_ADDR, |
30 | .flags = I2C_M_RD, | 32 | .flags = I2C_M_RD, |
31 | .len = EDID_LENGTH, | 33 | .len = EDID_LENGTH, |
34 | .buf = buf, | ||
32 | } | 35 | } |
33 | }; | 36 | }; |
34 | unsigned char *buf; | ||
35 | 37 | ||
36 | buf = kmalloc(EDID_LENGTH, GFP_KERNEL); | ||
37 | if (!buf) { | 38 | if (!buf) { |
38 | dev_warn(&adapter->dev, "unable to allocate memory for EDID " | 39 | dev_warn(&adapter->dev, "unable to allocate memory for EDID " |
39 | "block.\n"); | 40 | "block.\n"); |
40 | return NULL; | 41 | return NULL; |
41 | } | 42 | } |
42 | msgs[1].buf = buf; | ||
43 | 43 | ||
44 | if (i2c_transfer(adapter, msgs, 2) == 2) | 44 | if (i2c_transfer(adapter, msgs, 2) == 2) |
45 | return buf; | 45 | return buf; |
diff --git a/drivers/video/hitfb.c b/drivers/video/hitfb.c index 3afb472763c0..3dc49424dc75 100644 --- a/drivers/video/hitfb.c +++ b/drivers/video/hitfb.c | |||
@@ -29,7 +29,6 @@ | |||
29 | #include <asm/io.h> | 29 | #include <asm/io.h> |
30 | #include <asm/hd64461.h> | 30 | #include <asm/hd64461.h> |
31 | #include <asm/cpu/dac.h> | 31 | #include <asm/cpu/dac.h> |
32 | #include <asm/hp6xx/hp6xx.h> | ||
33 | 32 | ||
34 | #define WIDTH 640 | 33 | #define WIDTH 640 |
35 | 34 | ||
diff --git a/drivers/video/intelfb/intelfbhw.c b/drivers/video/intelfb/intelfbhw.c index eeeeff9a09eb..a95836839e1e 100644 --- a/drivers/video/intelfb/intelfbhw.c +++ b/drivers/video/intelfb/intelfbhw.c | |||
@@ -161,7 +161,7 @@ intelfbhw_get_memory(struct pci_dev *pdev, int *aperture_size, | |||
161 | return 1; | 161 | return 1; |
162 | 162 | ||
163 | /* Find the bridge device. It is always 0:0.0 */ | 163 | /* Find the bridge device. It is always 0:0.0 */ |
164 | if (!(bridge_dev = pci_find_slot(0, PCI_DEVFN(0, 0)))) { | 164 | if (!(bridge_dev = pci_get_bus_and_slot(0, PCI_DEVFN(0, 0)))) { |
165 | ERR_MSG("cannot find bridge device\n"); | 165 | ERR_MSG("cannot find bridge device\n"); |
166 | return 1; | 166 | return 1; |
167 | } | 167 | } |
@@ -169,6 +169,8 @@ intelfbhw_get_memory(struct pci_dev *pdev, int *aperture_size, | |||
169 | /* Get the fb aperture size and "stolen" memory amount. */ | 169 | /* Get the fb aperture size and "stolen" memory amount. */ |
170 | tmp = 0; | 170 | tmp = 0; |
171 | pci_read_config_word(bridge_dev, INTEL_GMCH_CTRL, &tmp); | 171 | pci_read_config_word(bridge_dev, INTEL_GMCH_CTRL, &tmp); |
172 | pci_dev_put(bridge_dev); | ||
173 | |||
172 | switch (pdev->device) { | 174 | switch (pdev->device) { |
173 | case PCI_DEVICE_ID_INTEL_915G: | 175 | case PCI_DEVICE_ID_INTEL_915G: |
174 | case PCI_DEVICE_ID_INTEL_915GM: | 176 | case PCI_DEVICE_ID_INTEL_915GM: |
@@ -662,7 +664,7 @@ intelfbhw_print_hw_state(struct intelfb_info *dinfo, struct intelfb_hwstate *hw) | |||
662 | int index = dinfo->pll_index; | 664 | int index = dinfo->pll_index; |
663 | DBG_MSG("intelfbhw_print_hw_state\n"); | 665 | DBG_MSG("intelfbhw_print_hw_state\n"); |
664 | 666 | ||
665 | if (!hw || !dinfo) | 667 | if (!hw) |
666 | return; | 668 | return; |
667 | /* Read in as much of the HW state as possible. */ | 669 | /* Read in as much of the HW state as possible. */ |
668 | printk("hw state dump start\n"); | 670 | printk("hw state dump start\n"); |
diff --git a/drivers/video/nvidia/nv_hw.c b/drivers/video/nvidia/nv_hw.c index 9ed640d35728..ea426115c6f9 100644 --- a/drivers/video/nvidia/nv_hw.c +++ b/drivers/video/nvidia/nv_hw.c | |||
@@ -145,12 +145,18 @@ static void nvGetClocks(struct nvidia_par *par, unsigned int *MClk, | |||
145 | 145 | ||
146 | if (par->Architecture >= NV_ARCH_40) { | 146 | if (par->Architecture >= NV_ARCH_40) { |
147 | pll = NV_RD32(par->PMC, 0x4020); | 147 | pll = NV_RD32(par->PMC, 0x4020); |
148 | P = (pll >> 16) & 0x03; | 148 | P = (pll >> 16) & 0x07; |
149 | pll = NV_RD32(par->PMC, 0x4024); | 149 | pll = NV_RD32(par->PMC, 0x4024); |
150 | M = pll & 0xFF; | 150 | M = pll & 0xFF; |
151 | N = (pll >> 8) & 0xFF; | 151 | N = (pll >> 8) & 0xFF; |
152 | MB = (pll >> 16) & 0xFF; | 152 | if (((par->Chipset & 0xfff0) == 0x0290) || |
153 | NB = (pll >> 24) & 0xFF; | 153 | ((par->Chipset & 0xfff0) == 0x0390)) { |
154 | MB = 1; | ||
155 | NB = 1; | ||
156 | } else { | ||
157 | MB = (pll >> 16) & 0xFF; | ||
158 | NB = (pll >> 24) & 0xFF; | ||
159 | } | ||
154 | *MClk = ((N * NB * par->CrystalFreqKHz) / (M * MB)) >> P; | 160 | *MClk = ((N * NB * par->CrystalFreqKHz) / (M * MB)) >> P; |
155 | 161 | ||
156 | pll = NV_RD32(par->PMC, 0x4000); | 162 | pll = NV_RD32(par->PMC, 0x4000); |
diff --git a/drivers/video/nvidia/nv_setup.c b/drivers/video/nvidia/nv_setup.c index a18a9aebf05f..eab3e282a4de 100644 --- a/drivers/video/nvidia/nv_setup.c +++ b/drivers/video/nvidia/nv_setup.c | |||
@@ -262,7 +262,7 @@ static void nv10GetConfig(struct nvidia_par *par) | |||
262 | #endif | 262 | #endif |
263 | 263 | ||
264 | dev = pci_find_slot(0, 1); | 264 | dev = pci_find_slot(0, 1); |
265 | if ((par->Chipset && 0xffff) == 0x01a0) { | 265 | if ((par->Chipset & 0xffff) == 0x01a0) { |
266 | int amt = 0; | 266 | int amt = 0; |
267 | 267 | ||
268 | pci_read_config_dword(dev, 0x7c, &amt); | 268 | pci_read_config_dword(dev, 0x7c, &amt); |
@@ -359,6 +359,7 @@ int NVCommonSetup(struct fb_info *info) | |||
359 | case 0x0186: | 359 | case 0x0186: |
360 | case 0x0187: | 360 | case 0x0187: |
361 | case 0x018D: | 361 | case 0x018D: |
362 | case 0x0228: | ||
362 | case 0x0286: | 363 | case 0x0286: |
363 | case 0x028C: | 364 | case 0x028C: |
364 | case 0x0316: | 365 | case 0x0316: |
@@ -382,6 +383,10 @@ int NVCommonSetup(struct fb_info *info) | |||
382 | case 0x034C: | 383 | case 0x034C: |
383 | case 0x0160: | 384 | case 0x0160: |
384 | case 0x0166: | 385 | case 0x0166: |
386 | case 0x0169: | ||
387 | case 0x016B: | ||
388 | case 0x016C: | ||
389 | case 0x016D: | ||
385 | case 0x00C8: | 390 | case 0x00C8: |
386 | case 0x00CC: | 391 | case 0x00CC: |
387 | case 0x0144: | 392 | case 0x0144: |
@@ -639,12 +644,23 @@ int NVCommonSetup(struct fb_info *info) | |||
639 | par->fpHeight = NV_RD32(par->PRAMDAC, 0x0800) + 1; | 644 | par->fpHeight = NV_RD32(par->PRAMDAC, 0x0800) + 1; |
640 | par->fpSyncs = NV_RD32(par->PRAMDAC, 0x0848) & 0x30000033; | 645 | par->fpSyncs = NV_RD32(par->PRAMDAC, 0x0848) & 0x30000033; |
641 | 646 | ||
642 | printk("Panel size is %i x %i\n", par->fpWidth, par->fpHeight); | 647 | printk("nvidiafb: Panel size is %i x %i\n", par->fpWidth, par->fpHeight); |
643 | } | 648 | } |
644 | 649 | ||
645 | if (monA) | 650 | if (monA) |
646 | info->monspecs = *monA; | 651 | info->monspecs = *monA; |
647 | 652 | ||
653 | if (!par->FlatPanel || !par->twoHeads) | ||
654 | par->FPDither = 0; | ||
655 | |||
656 | par->LVDS = 0; | ||
657 | if (par->FlatPanel && par->twoHeads) { | ||
658 | NV_WR32(par->PRAMDAC0, 0x08B0, 0x00010004); | ||
659 | if (par->PRAMDAC0[0x08b4] & 1) | ||
660 | par->LVDS = 1; | ||
661 | printk("nvidiafb: Panel is %s\n", par->LVDS ? "LVDS" : "TMDS"); | ||
662 | } | ||
663 | |||
648 | kfree(edidA); | 664 | kfree(edidA); |
649 | kfree(edidB); | 665 | kfree(edidB); |
650 | done: | 666 | done: |
diff --git a/drivers/video/nvidia/nv_type.h b/drivers/video/nvidia/nv_type.h index acdc26693402..86e65dea60d3 100644 --- a/drivers/video/nvidia/nv_type.h +++ b/drivers/video/nvidia/nv_type.h | |||
@@ -129,6 +129,7 @@ struct nvidia_par { | |||
129 | int fpHeight; | 129 | int fpHeight; |
130 | int PanelTweak; | 130 | int PanelTweak; |
131 | int paneltweak; | 131 | int paneltweak; |
132 | int LVDS; | ||
132 | int pm_state; | 133 | int pm_state; |
133 | u32 crtcSync_read; | 134 | u32 crtcSync_read; |
134 | u32 fpSyncs; | 135 | u32 fpSyncs; |
diff --git a/drivers/video/nvidia/nvidia.c b/drivers/video/nvidia/nvidia.c index eb24107bcc81..538e947610e1 100644 --- a/drivers/video/nvidia/nvidia.c +++ b/drivers/video/nvidia/nvidia.c | |||
@@ -1160,20 +1160,20 @@ static u32 __devinit nvidia_get_arch(struct fb_info *info) | |||
1160 | case 0x0340: /* GeForceFX 5700 */ | 1160 | case 0x0340: /* GeForceFX 5700 */ |
1161 | arch = NV_ARCH_30; | 1161 | arch = NV_ARCH_30; |
1162 | break; | 1162 | break; |
1163 | case 0x0040: | 1163 | case 0x0040: /* GeForce 6800 */ |
1164 | case 0x00C0: | 1164 | case 0x00C0: /* GeForce 6800 */ |
1165 | case 0x0120: | 1165 | case 0x0120: /* GeForce 6800 */ |
1166 | case 0x0130: | 1166 | case 0x0130: |
1167 | case 0x0140: | 1167 | case 0x0140: /* GeForce 6600 */ |
1168 | case 0x0160: | 1168 | case 0x0160: /* GeForce 6200 */ |
1169 | case 0x01D0: | 1169 | case 0x01D0: /* GeForce 7200, 7300, 7400 */ |
1170 | case 0x0090: | 1170 | case 0x0090: /* GeForce 7800 */ |
1171 | case 0x0210: | 1171 | case 0x0210: /* GeForce 6800 */ |
1172 | case 0x0220: | 1172 | case 0x0220: /* GeForce 6200 */ |
1173 | case 0x0230: | 1173 | case 0x0230: |
1174 | case 0x0240: | 1174 | case 0x0240: /* GeForce 6100 */ |
1175 | case 0x0290: | 1175 | case 0x0290: /* GeForce 7900 */ |
1176 | case 0x0390: | 1176 | case 0x0390: /* GeForce 7600 */ |
1177 | arch = NV_ARCH_40; | 1177 | arch = NV_ARCH_40; |
1178 | break; | 1178 | break; |
1179 | case 0x0020: /* TNT, TNT2 */ | 1179 | case 0x0020: /* TNT, TNT2 */ |
diff --git a/drivers/video/offb.c b/drivers/video/offb.c index bad0e98fb3b6..9a40bbecf76b 100644 --- a/drivers/video/offb.c +++ b/drivers/video/offb.c | |||
@@ -157,7 +157,7 @@ static int offb_setcolreg(u_int regno, u_int red, u_int green, u_int blue, | |||
157 | out_le32(par->cmap_adr + 0xb4, (red << 16 | green << 8 | blue)); | 157 | out_le32(par->cmap_adr + 0xb4, (red << 16 | green << 8 | blue)); |
158 | break; | 158 | break; |
159 | case cmap_gxt2000: | 159 | case cmap_gxt2000: |
160 | out_le32((unsigned __iomem *) par->cmap_adr + regno, | 160 | out_le32(((unsigned __iomem *) par->cmap_adr) + regno, |
161 | (red << 16 | green << 8 | blue)); | 161 | (red << 16 | green << 8 | blue)); |
162 | break; | 162 | break; |
163 | } | 163 | } |
@@ -213,7 +213,7 @@ static int offb_blank(int blank, struct fb_info *info) | |||
213 | out_le32(par->cmap_adr + 0xb4, 0); | 213 | out_le32(par->cmap_adr + 0xb4, 0); |
214 | break; | 214 | break; |
215 | case cmap_gxt2000: | 215 | case cmap_gxt2000: |
216 | out_le32((unsigned __iomem *) par->cmap_adr + i, | 216 | out_le32(((unsigned __iomem *) par->cmap_adr) + i, |
217 | 0); | 217 | 0); |
218 | break; | 218 | break; |
219 | } | 219 | } |
@@ -226,13 +226,23 @@ static int offb_blank(int blank, struct fb_info *info) | |||
226 | static void __iomem *offb_map_reg(struct device_node *np, int index, | 226 | static void __iomem *offb_map_reg(struct device_node *np, int index, |
227 | unsigned long offset, unsigned long size) | 227 | unsigned long offset, unsigned long size) |
228 | { | 228 | { |
229 | struct resource r; | 229 | const u32 *addrp; |
230 | 230 | u64 asize, taddr; | |
231 | if (of_address_to_resource(np, index, &r)) | 231 | unsigned int flags; |
232 | return 0; | 232 | |
233 | if ((r.start + offset + size) > r.end) | 233 | addrp = of_get_pci_address(np, index, &asize, &flags); |
234 | return 0; | 234 | if (addrp == NULL) |
235 | return ioremap(r.start + offset, size); | 235 | addrp = of_get_address(np, index, &asize, &flags); |
236 | if (addrp == NULL) | ||
237 | return NULL; | ||
238 | if ((flags & (IORESOURCE_IO | IORESOURCE_MEM)) == 0) | ||
239 | return NULL; | ||
240 | if ((offset + size) > asize) | ||
241 | return NULL; | ||
242 | taddr = of_translate_address(np, addrp); | ||
243 | if (taddr == OF_BAD_ADDR) | ||
244 | return NULL; | ||
245 | return ioremap(taddr + offset, size); | ||
236 | } | 246 | } |
237 | 247 | ||
238 | static void __init offb_init_fb(const char *name, const char *full_name, | 248 | static void __init offb_init_fb(const char *name, const char *full_name, |
@@ -289,7 +299,6 @@ static void __init offb_init_fb(const char *name, const char *full_name, | |||
289 | 299 | ||
290 | par->cmap_type = cmap_unknown; | 300 | par->cmap_type = cmap_unknown; |
291 | if (depth == 8) { | 301 | if (depth == 8) { |
292 | /* Palette hacks disabled for now */ | ||
293 | if (dp && !strncmp(name, "ATY,Rage128", 11)) { | 302 | if (dp && !strncmp(name, "ATY,Rage128", 11)) { |
294 | par->cmap_adr = offb_map_reg(dp, 2, 0, 0x1fff); | 303 | par->cmap_adr = offb_map_reg(dp, 2, 0, 0x1fff); |
295 | if (par->cmap_adr) | 304 | if (par->cmap_adr) |
@@ -313,7 +322,8 @@ static void __init offb_init_fb(const char *name, const char *full_name, | |||
313 | ioremap(base + 0x7ff000, 0x1000) + 0xcc0; | 322 | ioremap(base + 0x7ff000, 0x1000) + 0xcc0; |
314 | par->cmap_data = par->cmap_adr + 1; | 323 | par->cmap_data = par->cmap_adr + 1; |
315 | par->cmap_type = cmap_m64; | 324 | par->cmap_type = cmap_m64; |
316 | } else if (dp && device_is_compatible(dp, "pci1014,b7")) { | 325 | } else if (dp && (device_is_compatible(dp, "pci1014,b7") || |
326 | device_is_compatible(dp, "pci1014,21c"))) { | ||
317 | par->cmap_adr = offb_map_reg(dp, 0, 0x6000, 0x1000); | 327 | par->cmap_adr = offb_map_reg(dp, 0, 0x6000, 0x1000); |
318 | if (par->cmap_adr) | 328 | if (par->cmap_adr) |
319 | par->cmap_type = cmap_gxt2000; | 329 | par->cmap_type = cmap_gxt2000; |
@@ -433,7 +443,7 @@ static void __init offb_init_nodriver(struct device_node *dp, int no_real_node) | |||
433 | pp = get_property(dp, "linux,bootx-linebytes", &len); | 443 | pp = get_property(dp, "linux,bootx-linebytes", &len); |
434 | if (pp == NULL) | 444 | if (pp == NULL) |
435 | pp = get_property(dp, "linebytes", &len); | 445 | pp = get_property(dp, "linebytes", &len); |
436 | if (pp && len == sizeof(u32)) | 446 | if (pp && len == sizeof(u32) && (*pp != 0xffffffffu)) |
437 | pitch = *pp; | 447 | pitch = *pp; |
438 | else | 448 | else |
439 | pitch = width * ((depth + 7) / 8); | 449 | pitch = width * ((depth + 7) / 8); |
@@ -496,7 +506,7 @@ static void __init offb_init_nodriver(struct device_node *dp, int no_real_node) | |||
496 | offb_init_fb(no_real_node ? "bootx" : dp->name, | 506 | offb_init_fb(no_real_node ? "bootx" : dp->name, |
497 | no_real_node ? "display" : dp->full_name, | 507 | no_real_node ? "display" : dp->full_name, |
498 | width, height, depth, pitch, address, | 508 | width, height, depth, pitch, address, |
499 | no_real_node ? dp : NULL); | 509 | no_real_node ? NULL : dp); |
500 | } | 510 | } |
501 | } | 511 | } |
502 | 512 | ||
diff --git a/drivers/video/pnx4008/pnxrgbfb.c b/drivers/video/pnx4008/pnxrgbfb.c index 7d9453c91a42..f29e66e2d774 100644 --- a/drivers/video/pnx4008/pnxrgbfb.c +++ b/drivers/video/pnx4008/pnxrgbfb.c | |||
@@ -154,7 +154,8 @@ static int __devinit rgbfb_probe(struct platform_device *pdev) | |||
154 | goto err1; | 154 | goto err1; |
155 | } | 155 | } |
156 | 156 | ||
157 | if (!fb_get_options("pnxrgbfb", &option) && !strcmp(option, "nocursor")) | 157 | if (!fb_get_options("pnxrgbfb", &option) && option && |
158 | !strcmp(option, "nocursor")) | ||
158 | rgbfb_ops.fb_cursor = no_cursor; | 159 | rgbfb_ops.fb_cursor = no_cursor; |
159 | 160 | ||
160 | info->node = -1; | 161 | info->node = -1; |
@@ -191,7 +192,7 @@ err: | |||
191 | 192 | ||
192 | static struct platform_driver rgbfb_driver = { | 193 | static struct platform_driver rgbfb_driver = { |
193 | .driver = { | 194 | .driver = { |
194 | .name = "rgbfb", | 195 | .name = "pnx4008-rgbfb", |
195 | }, | 196 | }, |
196 | .probe = rgbfb_probe, | 197 | .probe = rgbfb_probe, |
197 | .remove = rgbfb_remove, | 198 | .remove = rgbfb_remove, |
diff --git a/drivers/video/pnx4008/sdum.c b/drivers/video/pnx4008/sdum.c index 51f0ecc2a511..d23bf0d659b6 100644 --- a/drivers/video/pnx4008/sdum.c +++ b/drivers/video/pnx4008/sdum.c | |||
@@ -848,7 +848,7 @@ static int sdum_remove(struct platform_device *pdev) | |||
848 | 848 | ||
849 | static struct platform_driver sdum_driver = { | 849 | static struct platform_driver sdum_driver = { |
850 | .driver = { | 850 | .driver = { |
851 | .name = "sdum", | 851 | .name = "pnx4008-sdum", |
852 | }, | 852 | }, |
853 | .probe = sdum_probe, | 853 | .probe = sdum_probe, |
854 | .remove = sdum_remove, | 854 | .remove = sdum_remove, |