list_for_each_entry(iter, &iio_device_types_list, list) if (!strcmp(iter->name, name)) {
d = iter; break;
}
return d;
}
int iio_register_sw_device_type(struct iio_sw_device_type *d)
{ struct iio_sw_device_type *iter; int ret = 0;
mutex_lock(&iio_device_types_lock);
iter = __iio_find_sw_device_type(d->name, strlen(d->name)); if (iter)
ret = -EBUSY; else
list_add_tail(&d->list, &iio_device_types_list);
mutex_unlock(&iio_device_types_lock);
if (ret) return ret;
d->group = configfs_register_default_group(iio_devices_group, d->name,
&iio_device_type_group_type); if (IS_ERR(d->group))
ret = PTR_ERR(d->group);
mutex_lock(&iio_device_types_lock);
iter = __iio_find_sw_device_type(dt->name, strlen(dt->name)); if (iter)
list_del(&dt->list);
mutex_unlock(&iio_device_types_lock);
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.