Lines Matching defs:p_drv
64 static u_int camperiphnextunit(struct periph_driver *p_drv,
68 static u_int camperiphunit(struct periph_driver *p_drv,
201 struct periph_driver **p_drv;
264 for (p_drv = periph_drivers; *p_drv != NULL; p_drv++) {
265 if (strcmp((*p_drv)->driver_name, name) == 0)
268 if (*p_drv == NULL) {
275 periph->unit_number = camperiphunit(*p_drv, path_id, target_id, lun_id,
277 cur_periph = TAILQ_FIRST(&(*p_drv)->units);
286 TAILQ_INSERT_TAIL(&(*p_drv)->units, periph, unit_links);
287 (*p_drv)->generation++;
316 TAILQ_REMOVE(&(*p_drv)->units, periph, unit_links);
340 struct periph_driver **p_drv;
344 for (p_drv = periph_drivers; *p_drv != NULL; p_drv++) {
345 if (name != NULL && (strcmp((*p_drv)->driver_name, name) != 0))
348 TAILQ_FOREACH(periph, &(*p_drv)->units, unit_links) {
371 struct periph_driver **p_drv;
381 for (p_drv = periph_drivers; *p_drv != NULL; p_drv++) {
382 TAILQ_FOREACH(periph, &(*p_drv)->units, unit_links) {
554 camperiphnextunit(struct periph_driver *p_drv, u_int newunit, bool wired,
562 periph_name = p_drv->driver_name;
564 for (periph = TAILQ_FIRST(&p_drv->units);
612 camperiphunit(struct periph_driver *p_drv, path_id_t pathid,
621 periph_name = p_drv->driver_name;
661 unit = camperiphnextunit(p_drv, unit, wired, pathid, target, lun);
698 struct periph_driver **p_drv;
704 for (p_drv = periph_drivers; *p_drv != NULL; p_drv++) {
705 if (strcmp((*p_drv)->driver_name, periph->periph_name) == 0)
708 if (*p_drv == NULL) {
716 * below, p_drv may change. This doesn't protect against this
720 drv = *p_drv;