Home | History | Annotate | Download | only in npf

Lines Matching defs:ext

104 	npf_ext_t *ext;
111 LIST_FOREACH(ext, &npf->ext_list, ext_entry)
112 if (strcmp(ext->ext_callname, name) == 0)
115 if (ext != NULL || !autoload)
116 return ext;
132 npf_ext_t *ext;
134 ext = kmem_zalloc(sizeof(npf_ext_t), KM_SLEEP);
135 strlcpy(ext->ext_callname, name, EXT_NAME_LEN);
136 ext->ext_ops = ops;
141 kmem_free(ext, sizeof(npf_ext_t));
144 LIST_INSERT_HEAD(&npf->ext_list, ext, ext_entry);
147 return (void *)ext;
153 npf_ext_t *ext = extid;
158 if (atomic_load_relaxed(&ext->ext_refcnt)) {
163 if (atomic_load_relaxed(&ext->ext_refcnt)) {
167 KASSERT(npf_ext_lookup(npf, ext->ext_callname, false));
168 LIST_REMOVE(ext, ext_entry);
171 kmem_free(ext, sizeof(npf_ext_t));
180 npf_ext_t *ext;
189 ext = npf_ext_lookup(npf, name, true);
190 if (ext) {
191 atomic_inc_uint(&ext->ext_refcnt);
195 if (!ext) {
199 extops = ext->ext_ops;
204 atomic_dec_uint(&ext->ext_refcnt);
208 rp->rp_ext[i] = ext;
341 npf_ext_t *ext = rp->rp_ext[i];
342 const npf_ext_ops_t *extops = ext->ext_ops;
345 atomic_dec_uint(&ext->ext_refcnt);
375 const npf_ext_t *ext = rp->rp_ext[i];
376 const npf_ext_ops_t *extops = ext->ext_ops;
378 KASSERT(atomic_load_relaxed(&ext->ext_refcnt) > 0);