Lines Matching defs:dm_target
1 /* $NetBSD: dm_target.c,v 1.42 2021/08/21 22:23:33 andvar Exp $ */
32 __KERNEL_RCSID(0, "$NetBSD: dm_target.c,v 1.42 2021/08/21 22:23:33 andvar Exp $");
44 TAILQ_HEAD(dm_target_head, dm_target);
130 dm_target_t *dm_target;
136 TAILQ_FOREACH(dm_target, &dm_target_list, dm_target_next) {
137 dlen = strlen(dm_target->name) + 1;
141 if (strncmp(dm_target_name, dm_target->name, slen) == 0)
142 return dm_target;
150 * dm_target
154 dm_target_insert(dm_target_t *dm_target)
159 if (dm_target->init == NULL) {
160 printf("%s missing init\n", dm_target->name);
163 if (dm_target->strategy == NULL) {
164 printf("%s missing strategy\n", dm_target->name);
167 if (dm_target->destroy == NULL) {
168 printf("%s missing destroy\n", dm_target->name);
172 if (dm_target->upcall == NULL) {
173 printf("%s missing upcall\n", dm_target->name);
180 dmt = dm_target_lookup_name(dm_target->name);
185 TAILQ_INSERT_TAIL(&dm_target_list, dm_target, dm_target_next);
230 dm_target_t *dm_target;
234 while ((dm_target = TAILQ_FIRST(&dm_target_list)) != NULL) {
235 TAILQ_REMOVE(&dm_target_list, dm_target, dm_target_next);
236 kmem_free(dm_target, sizeof(dm_target_t));
269 * Return prop_array of dm_target dictionaries.
275 dm_target_t *dm_target;
281 TAILQ_FOREACH(dm_target, &dm_target_list, dm_target_next) {
289 dm_target->name);
292 prop_array_add_uint32(ver, dm_target->version[i]);
307 * Initialize dm_target subsystem.