Lines Matching refs:pdrv

314 	if (stm->pdrv->output_open) {  in stm_output_assign()
321 ret = stm->pdrv->output_open(priv, output); in stm_output_assign()
346 if (stm->pdrv && stm->pdrv->output_close) in stm_output_free()
347 stm->pdrv->output_close(output); in stm_output_free()
374 const struct stm_protocol_driver *pdrv; member
390 if (!strcmp(name, pe->pdrv->name)) in __stm_lookup_protocol()
397 int stm_register_protocol(const struct stm_protocol_driver *pdrv) in stm_register_protocol() argument
404 if (__stm_lookup_protocol(pdrv->name)) { in stm_register_protocol()
413 if (pdrv->policy_attr) { in stm_register_protocol()
414 pe->node_type = get_policy_node_type(pdrv->policy_attr); in stm_register_protocol()
420 pe->pdrv = pdrv; in stm_register_protocol()
433 void stm_unregister_protocol(const struct stm_protocol_driver *pdrv) in stm_unregister_protocol() argument
440 if (pe->pdrv == pdrv) { in stm_unregister_protocol()
456 static bool stm_get_protocol(const struct stm_protocol_driver *pdrv) in stm_get_protocol() argument
458 return try_module_get(pdrv->owner); in stm_get_protocol()
461 void stm_put_protocol(const struct stm_protocol_driver *pdrv) in stm_put_protocol() argument
463 module_put(pdrv->owner); in stm_put_protocol()
467 const struct stm_protocol_driver **pdrv, in stm_lookup_protocol() argument
475 if (pe && pe->pdrv && stm_get_protocol(pe->pdrv)) { in stm_lookup_protocol()
476 *pdrv = pe->pdrv; in stm_lookup_protocol()
608 if (!stm->pdrv) in stm_write()
611 err = stm->pdrv->write(stm->data, output, chan, buf, count); in stm_write()