Lines Matching refs:dax_id
28 struct dax_id { struct
44 static struct dax_id *__dax_match_id(const struct dax_device_driver *dax_drv, in __dax_match_id() argument
47 struct dax_id *dax_id; in __dax_match_id() local
51 list_for_each_entry(dax_id, &dax_drv->ids, list) in __dax_match_id()
52 if (sysfs_streq(dax_id->dev_name, dev_name)) in __dax_match_id()
53 return dax_id; in __dax_match_id()
98 struct dax_id *dax_id; in do_id_store() local
110 dax_id = __dax_match_id(dax_drv, buf); in do_id_store()
111 if (!dax_id) { in do_id_store()
113 dax_id = kzalloc(sizeof(*dax_id), GFP_KERNEL); in do_id_store()
114 if (dax_id) { in do_id_store()
115 strscpy(dax_id->dev_name, buf, DAX_NAME_LEN); in do_id_store()
116 list_add(&dax_id->list, &dax_drv->ids); in do_id_store()
121 list_del(&dax_id->list); in do_id_store()
122 kfree(dax_id); in do_id_store()
1573 struct dax_id *dax_id, *_id; in dax_driver_unregister() local
1576 list_for_each_entry_safe(dax_id, _id, &dax_drv->ids, list) { in dax_driver_unregister()
1577 list_del(&dax_id->list); in dax_driver_unregister()
1578 kfree(dax_id); in dax_driver_unregister()