Lines Matching refs:dax_id
17 struct dax_id { struct
36 static struct dax_id *__dax_match_id(struct dax_device_driver *dax_drv, in __dax_match_id() argument
39 struct dax_id *dax_id; in __dax_match_id() local
43 list_for_each_entry(dax_id, &dax_drv->ids, list) in __dax_match_id()
44 if (sysfs_streq(dax_id->dev_name, dev_name)) in __dax_match_id()
45 return dax_id; in __dax_match_id()
71 struct dax_id *dax_id; in do_id_store() local
83 dax_id = __dax_match_id(dax_drv, buf); in do_id_store()
84 if (!dax_id) { in do_id_store()
86 dax_id = kzalloc(sizeof(*dax_id), GFP_KERNEL); in do_id_store()
87 if (dax_id) { in do_id_store()
88 strncpy(dax_id->dev_name, buf, DAX_NAME_LEN); in do_id_store()
89 list_add(&dax_id->list, &dax_drv->ids); in do_id_store()
95 list_del(&dax_id->list); in do_id_store()
96 kfree(dax_id); in do_id_store()
489 struct dax_id *dax_id, *_id; in dax_driver_unregister() local
493 list_for_each_entry_safe(dax_id, _id, &dax_drv->ids, list) { in dax_driver_unregister()
494 list_del(&dax_id->list); in dax_driver_unregister()
495 kfree(dax_id); in dax_driver_unregister()