virtual-storage: Add variant without list support
Simply remove the feature flag for the NO_LIST environment variable. This also removes the IDENT variant for now as it has never been implemented as described.
This commit is contained in:
parent
8a5bec6619
commit
cdaa3497d7
1 changed files with 12 additions and 2 deletions
|
@ -220,6 +220,15 @@ dev_delete (FpDevice *dev)
|
||||||
fpi_device_error_new (FP_DEVICE_ERROR_DATA_NOT_FOUND));
|
fpi_device_error_new (FP_DEVICE_ERROR_DATA_NOT_FOUND));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void
|
||||||
|
dev_probe (FpDevice *dev)
|
||||||
|
{
|
||||||
|
/* Disable features listed in driver_data */
|
||||||
|
fpi_device_update_features (dev, fpi_device_get_driver_data (dev), 0);
|
||||||
|
|
||||||
|
fpi_device_probe_complete (dev, NULL, NULL, NULL);
|
||||||
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
fpi_device_virtual_device_storage_init (FpDeviceVirtualDeviceStorage *self)
|
fpi_device_virtual_device_storage_init (FpDeviceVirtualDeviceStorage *self)
|
||||||
{
|
{
|
||||||
|
@ -242,8 +251,8 @@ fpi_device_virtual_device_storage_finalize (GObject *object)
|
||||||
}
|
}
|
||||||
|
|
||||||
static const FpIdEntry driver_ids[] = {
|
static const FpIdEntry driver_ids[] = {
|
||||||
{ .virtual_envvar = "FP_VIRTUAL_DEVICE_STORAGE" },
|
{ .virtual_envvar = "FP_VIRTUAL_DEVICE_STORAGE", .driver_data = 0 },
|
||||||
{ .virtual_envvar = "FP_VIRTUAL_DEVICE_IDENT" },
|
{ .virtual_envvar = "FP_VIRTUAL_DEVICE_STORAGE_NO_LIST", .driver_data = FP_DEVICE_FEATURE_STORAGE_LIST },
|
||||||
{ .virtual_envvar = NULL }
|
{ .virtual_envvar = NULL }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -259,6 +268,7 @@ fpi_device_virtual_device_storage_class_init (FpDeviceVirtualDeviceStorageClass
|
||||||
dev_class->full_name = "Virtual device with storage and identification for debugging";
|
dev_class->full_name = "Virtual device with storage and identification for debugging";
|
||||||
dev_class->id_table = driver_ids;
|
dev_class->id_table = driver_ids;
|
||||||
|
|
||||||
|
dev_class->probe = dev_probe;
|
||||||
dev_class->identify = dev_identify;
|
dev_class->identify = dev_identify;
|
||||||
dev_class->list = dev_list;
|
dev_class->list = dev_list;
|
||||||
dev_class->delete = dev_delete;
|
dev_class->delete = dev_delete;
|
||||||
|
|
Loading…
Reference in a new issue