Page MenuHomeFreeBSD

D28031.id81978.diff
No OneTemporary

D28031.id81978.diff

Index: sys/dev/virtio/mmio/virtio_mmio.c
===================================================================
--- sys/dev/virtio/mmio/virtio_mmio.c
+++ sys/dev/virtio/mmio/virtio_mmio.c
@@ -166,7 +166,7 @@
DEVMETHOD_END
};
-DEFINE_CLASS_0(virtio_mmio, vtmmio_driver, vtmmio_methods,
+DEFINE_CLASS_0(virtio, vtmmio_driver, vtmmio_methods,
sizeof(struct vtmmio_softc));
MODULE_VERSION(virtio_mmio, 1);
Index: sys/dev/virtio/mmio/virtio_mmio_acpi.c
===================================================================
--- sys/dev/virtio/mmio/virtio_mmio_acpi.c
+++ sys/dev/virtio/mmio/virtio_mmio_acpi.c
@@ -62,7 +62,7 @@
DEVMETHOD_END
};
-DEFINE_CLASS_1(virtio_mmio, vtmmio_acpi_driver, vtmmio_acpi_methods,
+DEFINE_CLASS_1(virtio, vtmmio_acpi_driver, vtmmio_acpi_methods,
sizeof(struct vtmmio_softc), vtmmio_driver);
static devclass_t vtmmio_acpi_devclass;
Index: sys/dev/virtio/mmio/virtio_mmio_fdt.c
===================================================================
--- sys/dev/virtio/mmio/virtio_mmio_fdt.c
+++ sys/dev/virtio/mmio/virtio_mmio_fdt.c
@@ -76,7 +76,7 @@
DEVMETHOD_END
};
-DEFINE_CLASS_1(virtio_mmio, vtmmio_fdt_driver, vtmmio_fdt_methods,
+DEFINE_CLASS_1(virtio, vtmmio_fdt_driver, vtmmio_fdt_methods,
sizeof(struct vtmmio_softc), vtmmio_driver);
static devclass_t vtmmio_fdt_devclass;
Index: sys/dev/virtio/pci/virtio_pci.c
===================================================================
--- sys/dev/virtio/pci/virtio_pci.c
+++ sys/dev/virtio/pci/virtio_pci.c
@@ -233,11 +233,8 @@
DEVMETHOD_END
};
-static driver_t vtpci_driver = {
- "virtio_pci",
- vtpci_methods,
- sizeof(struct vtpci_softc)
-};
+DEFINE_CLASS_0(virtio, vtpci_driver, vtpci_methods,
+ sizeof(struct vtpci_softc));
devclass_t vtpci_devclass;
Index: sys/dev/virtio/virtio.h
===================================================================
--- sys/dev/virtio/virtio.h
+++ sys/dev/virtio/virtio.h
@@ -64,8 +64,7 @@
};
#define VIRTIO_DRIVER_MODULE(name, driver, devclass, evh, arg) \
- DRIVER_MODULE(name, virtio_mmio, driver, devclass, evh, arg); \
- DRIVER_MODULE(name, virtio_pci, driver, devclass, evh, arg)
+ DRIVER_MODULE(name, virtio, driver, devclass, evh, arg) \
struct virtio_pnp_match {
uint32_t device_type;
@@ -76,9 +75,7 @@
.device_type = devtype, \
.description = desc, \
}; \
- MODULE_PNP_INFO("U32:device_type;D:#", virtio_mmio, driver, \
- &driver ## _match, 1); \
- MODULE_PNP_INFO("U32:device_type;D:#", virtio_pci, driver, \
+ MODULE_PNP_INFO("U32:device_type;D:#", virtio, driver, \
&driver ## _match, 1)
#define VIRTIO_SIMPLE_PROBE(dev, driver) \
(virtio_simple_probe(dev, &driver ## _match))

File Metadata

Mime Type
text/plain
Expires
Fri, Jan 31, 1:39 AM (9 h, 19 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
16350984
Default Alt Text
D28031.id81978.diff (2 KB)

Event Timeline