aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/video/via/via-core.c
diff options
context:
space:
mode:
authorFlorian Tobias Schandinat <FlorianSchandinat@gmx.de>2010-10-24 00:02:14 -0400
committerFlorian Tobias Schandinat <FlorianSchandinat@gmx.de>2010-10-24 09:04:55 -0400
commit51f4332bb5fef869e8a89895a7bac6b4c03b4946 (patch)
treeeb505244dcfa4a20f30cf1da47c04f9bc4efcdd7 /drivers/video/via/via-core.c
parentadac8d65f399b02e8a2222fc75c658e4b8d24f65 (diff)
viafb: add initial VX900 support
This patch adds basic support for the new VX900 IGP. Almost everything that was implemented for other IGPs is expected to work also on VX900 after this patch. The only known issue is that on the CRT output mode setting does not always work. It is clear that the possibility for regressions is zero. A big thanks to VIA Technologies for making this possible and supporting this work. Signed-off-by: Florian Tobias Schandinat <FlorianSchandinat@gmx.de> Cc: Joseph Chan <JosephChan@via.com.tw> Cc: Jonathan Corbet <corbet@lwn.net>
Diffstat (limited to 'drivers/video/via/via-core.c')
-rw-r--r--drivers/video/via/via-core.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/drivers/video/via/via-core.c b/drivers/video/via/via-core.c
index 9b487a6a8d08..31e30338e893 100644
--- a/drivers/video/via/via-core.c
+++ b/drivers/video/via/via-core.c
@@ -333,7 +333,7 @@ EXPORT_SYMBOL_GPL(viafb_dma_copy_out_sg);
333static u16 via_function3[] = { 333static u16 via_function3[] = {
334 CLE266_FUNCTION3, KM400_FUNCTION3, CN400_FUNCTION3, CN700_FUNCTION3, 334 CLE266_FUNCTION3, KM400_FUNCTION3, CN400_FUNCTION3, CN700_FUNCTION3,
335 CX700_FUNCTION3, KM800_FUNCTION3, KM890_FUNCTION3, P4M890_FUNCTION3, 335 CX700_FUNCTION3, KM800_FUNCTION3, KM890_FUNCTION3, P4M890_FUNCTION3,
336 P4M900_FUNCTION3, VX800_FUNCTION3, VX855_FUNCTION3, 336 P4M900_FUNCTION3, VX800_FUNCTION3, VX855_FUNCTION3, VX900_FUNCTION3,
337}; 337};
338 338
339/* Get the BIOS-configured framebuffer size from PCI configuration space 339/* Get the BIOS-configured framebuffer size from PCI configuration space
@@ -370,6 +370,7 @@ static int viafb_get_fb_size_from_pci(int chip_type)
370 case P4M900_FUNCTION3: 370 case P4M900_FUNCTION3:
371 case VX800_FUNCTION3: 371 case VX800_FUNCTION3:
372 case VX855_FUNCTION3: 372 case VX855_FUNCTION3:
373 case VX900_FUNCTION3:
373 /*case CN750_FUNCTION3: */ 374 /*case CN750_FUNCTION3: */
374 offset = 0xA0; 375 offset = 0xA0;
375 break; 376 break;
@@ -474,7 +475,10 @@ static int __devinit via_pci_setup_mmio(struct viafb_dev *vdev)
474 * Eventually we want to move away from mapping this 475 * Eventually we want to move away from mapping this
475 * entire region. 476 * entire region.
476 */ 477 */
477 vdev->fbmem_start = pci_resource_start(vdev->pdev, 0); 478 if (vdev->chip_type == UNICHROME_VX900)
479 vdev->fbmem_start = pci_resource_start(vdev->pdev, 2);
480 else
481 vdev->fbmem_start = pci_resource_start(vdev->pdev, 0);
478 ret = vdev->fbmem_len = viafb_get_fb_size_from_pci(vdev->chip_type); 482 ret = vdev->fbmem_len = viafb_get_fb_size_from_pci(vdev->chip_type);
479 if (ret < 0) 483 if (ret < 0)
480 goto out_unmap; 484 goto out_unmap;
@@ -635,6 +639,8 @@ static struct pci_device_id via_pci_table[] __devinitdata = {
635 .driver_data = UNICHROME_VX800 }, 639 .driver_data = UNICHROME_VX800 },
636 { PCI_DEVICE(PCI_VENDOR_ID_VIA, UNICHROME_VX855_DID), 640 { PCI_DEVICE(PCI_VENDOR_ID_VIA, UNICHROME_VX855_DID),
637 .driver_data = UNICHROME_VX855 }, 641 .driver_data = UNICHROME_VX855 },
642 { PCI_DEVICE(PCI_VENDOR_ID_VIA, UNICHROME_VX900_DID),
643 .driver_data = UNICHROME_VX900 },
638 { } 644 { }
639}; 645};
640MODULE_DEVICE_TABLE(pci, via_pci_table); 646MODULE_DEVICE_TABLE(pci, via_pci_table);