mirror of
https://github.com/xen-project/xen.git
synced 2026-10-29 10:40:03 +01:00
Remove support for xenbus driver subtypes since with the subtype field there's no fallback.
Signed-off-by: Christian Limpach <Christian.Limpach@cl.cam.ac.uk>
This commit is contained in:
1 parent
c4d04f6326
commit
e9eaa6bafb
2 files changed
+1
-11
No files matched your search
@@ -48,8 +48,7 @@ static const struct xenbus_device_id *
|
||||
match_device(const struct xenbus_device_id *arr, struct xenbus_device *dev)
|
||||
{
|
||||
for (; !streq(arr->devicetype, ""); arr++) {
|
||||
if (streq(arr->devicetype, dev->devicetype) &&
|
||||
streq(arr->subtype, dev->subtype ?: ""))
|
||||
if (streq(arr->devicetype, dev->devicetype))
|
||||
return arr;
|
||||
}
|
||||
return NULL;
|
||||
@@ -284,8 +283,6 @@ static void xenbus_release_device(struct device *dev)
|
||||
if (dev) {
|
||||
struct xenbus_device *xendev = to_xenbus_device(dev);
|
||||
|
||||
if (xendev->subtype)
|
||||
kfree(xendev->subtype);
|
||||
kfree(xendev);
|
||||
}
|
||||
}
|
||||
@@ -331,11 +328,6 @@ static int xenbus_probe_node(struct xen_bus_type *bus,
|
||||
xendev->devicetype = xendev->nodename + strlen(xendev->nodename) + 1;
|
||||
strcpy(xendev->devicetype, type);
|
||||
|
||||
/* This might not exist, but that's OK. */
|
||||
xendev->subtype = xenbus_read(xendev->nodename, "subtype", NULL);
|
||||
if (IS_ERR(xendev->subtype))
|
||||
xendev->subtype = NULL;
|
||||
|
||||
xendev->dev.parent = &bus->dev;
|
||||
xendev->dev.bus = &bus->bus;
|
||||
xendev->dev.release = xenbus_release_device;
|
||||
|
||||
@@ -37,7 +37,6 @@
|
||||
/* A xenbus device. */
|
||||
struct xenbus_device {
|
||||
char *devicetype;
|
||||
char *subtype;
|
||||
char *nodename;
|
||||
struct device dev;
|
||||
int has_error;
|
||||
@@ -53,7 +52,6 @@ struct xenbus_device_id
|
||||
{
|
||||
/* .../device/<device_type>/<identifier> */
|
||||
char devicetype[32]; /* General class of device. */
|
||||
char subtype[32]; /* Contents of "subtype" for this device */
|
||||
};
|
||||
|
||||
/* A xenbus driver. */
|
||||
|
||||