Commit a04791e7 authored by Dave Jones's avatar Dave Jones Committed by Dave Jones

[AGPGART] give all agpgart drivers a ->remove pci method.

You guessed it, yup. from Christoph again.
parent e94105df
......@@ -373,6 +373,11 @@ static int __init agp_ali_probe(struct pci_dev *pdev,
return 0;
}
static void __exit agp_ali_remove(struct pci_dev *pdev)
{
agp_unregister_driver(&ali_agp_driver);
}
static struct pci_device_id agp_ali_pci_table[] __initdata = {
{
.class = (PCI_CLASS_BRIDGE_HOST << 8),
......@@ -391,6 +396,7 @@ static struct __initdata pci_driver agp_ali_pci_driver = {
.name = "agpgart-ali",
.id_table = agp_ali_pci_table,
.probe = agp_ali_probe,
.remove = agp_ali_remove,
};
static int __init agp_ali_init(void)
......@@ -400,7 +406,6 @@ static int __init agp_ali_init(void)
static void __exit agp_ali_cleanup(void)
{
agp_unregister_driver(&ali_agp_driver);
pci_unregister_driver(&agp_ali_pci_driver);
}
......
......@@ -448,6 +448,11 @@ static int __init agp_amdk7_probe(struct pci_dev *pdev,
return 0;
}
static void __exit agp_amdk7_remove(struct pci_dev *pdev)
{
agp_unregister_driver(&amd_k7_agp_driver);
}
static struct pci_device_id agp_amdk7_pci_table[] __initdata = {
{
.class = (PCI_CLASS_BRIDGE_HOST << 8),
......@@ -466,6 +471,7 @@ static struct __initdata pci_driver agp_amdk7_pci_driver = {
.name = "agpgart-amdk7",
.id_table = agp_amdk7_pci_table,
.probe = agp_amdk7_probe,
.remove = agp_amdk7_remove,
};
static int __init agp_amdk7_init(void)
......@@ -475,7 +481,6 @@ static int __init agp_amdk7_init(void)
static void __exit agp_amdk7_cleanup(void)
{
agp_unregister_driver(&amd_k7_agp_driver);
pci_unregister_driver(&agp_amdk7_pci_driver);
}
......
......@@ -378,6 +378,11 @@ static int __init agp_hp_probe(struct pci_dev *pdev,
return 0;
}
static void __exit agp_hp_remove(struct pci_dev *pdev)
{
agp_unregister_driver(&hp_agp_driver);
}
static struct pci_device_id agp_hp_pci_table[] __initdata = {
{
.class = (PCI_CLASS_BRIDGE_HOST << 8),
......@@ -396,6 +401,7 @@ static struct __initdata pci_driver agp_hp_pci_driver = {
.name = "agpgart-hp",
.id_table = agp_hp_pci_table,
.probe = agp_hp_probe,
.remove = agp_hp_remove,
};
static int __init agp_hp_init(void)
......@@ -405,7 +411,6 @@ static int __init agp_hp_init(void)
static void __exit agp_hp_cleanup(void)
{
agp_unregister_driver(&hp_agp_driver);
pci_unregister_driver(&agp_hp_pci_driver);
}
......
......@@ -578,6 +578,11 @@ static int __init agp_intel_i460_probe(struct pci_dev *pdev,
return 0;
}
static void __exit agp_intel_i460_probe(struct pci_dev *pdev)
{
agp_unregister_driver(&i460_agp_driver);
}
static struct pci_device_id agp_intel_i460_pci_table[] __initdata = {
{
.class = (PCI_CLASS_BRIDGE_HOST << 8),
......@@ -596,6 +601,7 @@ static struct __initdata pci_driver agp_intel_i460_pci_driver = {
.name = "agpgart-intel-i460",
.id_table = agp_intel_i460_pci_table,
.probe = agp_intel_i460_probe,
.remove = agp_intel_i460_remove,
};
static int __init agp_intel_i460_init(void)
......@@ -605,7 +611,6 @@ static int __init agp_intel_i460_init(void)
static void __exit agp_intel_i460_cleanup(void)
{
agp_unregister_driver(&i460_agp_driver);
pci_unregister_driver(&agp_intel_i460_pci_driver);
}
......
......@@ -1446,6 +1446,11 @@ static int __init agp_intel_probe(struct pci_dev *pdev,
return 0;
}
static void __exit agp_intel_remove(struct pci_dev *pdev)
{
agp_unregister_driver(&intel_agp_driver);
}
static struct pci_device_id agp_intel_pci_table[] __initdata = {
{
.class = (PCI_CLASS_BRIDGE_HOST << 8),
......@@ -1464,6 +1469,7 @@ static struct __initdata pci_driver agp_intel_pci_driver = {
.name = "agpgart-intel",
.id_table = agp_intel_pci_table,
.probe = agp_intel_probe,
.remove = agp_intel_remove,
};
/* intel_agp_init() must not be declared static for explicit
......@@ -1481,7 +1487,6 @@ int __init agp_intel_init(void)
static void __exit agp_intel_cleanup(void)
{
agp_unregister_driver(&intel_agp_driver);
pci_unregister_driver(&agp_intel_pci_driver);
}
......
......@@ -218,6 +218,11 @@ static int __init agp_sis_probe(struct pci_dev *pdev,
return 0;
}
static void __exit agp_sis_remove(struct pci_dev *pdev)
{
agp_unregister_driver(&sis_agp_driver);
}
static struct pci_device_id agp_sis_pci_table[] __initdata = {
{
.class = (PCI_CLASS_BRIDGE_HOST << 8),
......@@ -236,6 +241,7 @@ static struct __initdata pci_driver agp_sis_pci_driver = {
.name = "agpgart-sis",
.id_table = agp_sis_pci_table,
.probe = agp_sis_probe,
.remove = agp_sis_remove,
};
static int __init agp_sis_init(void)
......@@ -245,7 +251,6 @@ static int __init agp_sis_init(void)
static void __exit agp_sis_cleanup(void)
{
agp_unregister_driver(&sis_agp_driver);
pci_unregister_driver(&agp_sis_pci_driver);
}
......
......@@ -511,6 +511,11 @@ static int __init agp_serverworks_probe(struct pci_dev *pdev,
return 0;
}
static void __exit agp_serverworks_remove(struct pci_dev *pdev)
{
agp_unregister_driver(&serverworks_agp_driver);
}
static struct pci_device_id agp_serverworks_pci_table[] __initdata = {
{
.class = (PCI_CLASS_BRIDGE_HOST << 8),
......@@ -529,6 +534,7 @@ static struct __initdata pci_driver agp_serverworks_pci_driver = {
.name = "agpgart-serverworks",
.id_table = agp_serverworks_pci_table,
.probe = agp_serverworks_probe,
.remove = agp_serverworks_remove,
};
static int __init agp_serverworks_init(void)
......@@ -538,7 +544,6 @@ static int __init agp_serverworks_init(void)
static void __exit agp_serverworks_cleanup(void)
{
agp_unregister_driver(&serverworks_agp_driver);
pci_unregister_driver(&agp_serverworks_pci_driver);
}
......
......@@ -459,6 +459,7 @@ static struct __initdata pci_driver agp_via_pci_driver = {
.name = "agpgart-via",
.id_table = agp_via_pci_table,
.probe = agp_via_probe,
.remove = agp_via_remove,
};
......@@ -467,14 +468,11 @@ static int __init agp_via_init(void)
return pci_module_init(&agp_via_pci_driver);
}
static void __exit agp_via_cleanup(void)
{
agp_unregister_driver(&via_agp_driver);
pci_unregister_driver(&agp_via_pci_driver);
}
module_init(agp_via_init);
module_exit(agp_via_cleanup);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment