drm: rework PCI/platform driver interface.

This abstracts the pci/platform interface out a step further,
we can go further but this is far enough for now to allow USB
to be plugged in.

The drivers now just call the init code directly for their
device type.

Signed-off-by: Dave Airlie <airlied@redhat.com>
このコミットが含まれているのは:
Dave Airlie
2010-12-15 03:16:38 +10:00
committed by Dave Airlie
コミット 8410ea3b95
24個のファイルの変更458行の追加361行の削除

ファイルの表示

@@ -52,10 +52,6 @@ static struct drm_driver driver = {
.fasync = drm_fasync,
.llseek = noop_llseek,
},
.pci_driver = {
.name = DRIVER_NAME,
.id_table = pciidlist,
},
.name = DRIVER_NAME,
.desc = DRIVER_DESC,
@@ -65,14 +61,19 @@ static struct drm_driver driver = {
.patchlevel = DRIVER_PATCHLEVEL,
};
static struct pci_driver tdfx_pci_driver = {
.name = DRIVER_NAME,
.id_table = pciidlist,
};
static int __init tdfx_init(void)
{
return drm_init(&driver);
return drm_pci_init(&driver, &tdfx_pci_driver);
}
static void __exit tdfx_exit(void)
{
drm_exit(&driver);
drm_pci_exit(&driver, &tdfx_pci_driver);
}
module_init(tdfx_init);